'Serial1' does not name a type - Error in arduinoCharlieplexing with ArduinoArduino error: does not name a type?Error with arduino: does not name a typeArduino Mega receiving correct data through Serial 0 but not Serial 1-3Trouble Compiling EKfilter C++ Library on Arduino DUEArduino struct does not name a type errorArduino: If/Else issuesAssistance with understanding serial communication (SPI) on the Arduino MegaWhy I got this error?ESP32 direct port manipulation

Is a stroke of luck acceptable after a series of unfavorable events?

Anatomically Correct Strange Women In Ponds Distributing Swords

What Brexit proposals are on the table in the indicative votes on the 27th of March 2019?

Sort a list by elements of another list

Avoiding estate tax by giving multiple gifts

CREATE opcode: what does it really do?

Why is Lord Kartikeya called 'Devasenapati'?

Why not increase contact surface when reentering the atmosphere?

Unexpected indention in bibliography items (beamer)

Gears on left are inverse to gears on right?

Lay out the Carpet

How can a function with a hole (removable discontinuity) equal a function with no hole?

Large drywall patch supports

What does this 7 mean above the f flat

Type int? vs type int

Did Dumbledore lie to Harry about how long he had James Potter's invisibility cloak when he was examining it? If so, why?

Does "every" first-order theory have a finitely axiomatizable conservative extension?

How to draw lines on a tikz-cd diagram

What can we do to stop prior company from asking us questions?

What is the intuitive meaning of having a linear relationship between the logs of two variables?

Short story about space worker geeks who zone out by 'listening' to radiation from stars

Trouble understanding the speech of overseas colleagues

Go Pregnant or Go Home

What does "I’d sit this one out, Cap," imply or mean in the context?



'Serial1' does not name a type - Error in arduino


Charlieplexing with ArduinoArduino error: does not name a type?Error with arduino: does not name a typeArduino Mega receiving correct data through Serial 0 but not Serial 1-3Trouble Compiling EKfilter C++ Library on Arduino DUEArduino struct does not name a type errorArduino: If/Else issuesAssistance with understanding serial communication (SPI) on the Arduino MegaWhy I got this error?ESP32 direct port manipulation













0















I am trying to verify the Arduino code in ADS1198 and Arduino Due. It comes the error show 'Serial1' does not name a type' even I defined two serial port in the beginning(where I gave the comments now). How to deal with this error 'Serial1' does not name a type'. how can I define these two port on ArduinoDue so that complieling successfully.



#include <ads1298.h>
#include <Base64.h>

// Minimal sketch for connection to ADS129n family. Load this script and open Tools/SerialMonitor.
// You should see text like this
// Device Type (ID Control Register): 62 Channels: 8
// If you see "Channels: 0" then check your wiring

#include "ads1298.h"
#include "adsCMD.h"
#include <Base64.h>


#include <SPI.h> // include the SPI library:
int gMaxChan = 0; //maximum number of channels supported by ads129n = 4,6,8
int gIDval = 0; //Device ID : lower 5 bits of ID Control Register

int activeSerialPort = 0; //data will be sent to serial port that last sent commands. E.G. bluetooth or USB port
const int kPIN_LED = 13; //pin with in-built light - typically 13, 11 for Teensy 2.0.

//ADSCMD

#include "Arduino.h"

//For Leonardo SPI see http://openenergymonitor.blogspot.com/2012/06/arduino-leonardo-atmega32u4-and-rfm12b.html
//constants define pins on Arduino

// Arduino Due
const int IPIN_PWDN = 47; //not required for TI demo kit
const int PIN_CLKSEL = 49; //6;//*optional
const int IPIN_RESET = 48; //*optional

const int PIN_START = 46;
const int IPIN_DRDY = 45;
const int IPIN_CS = 52;
const int PIN_DOUT = 11; //SPI out
const int PIN_DIN = 12; //SPI in
const int PIN_SCLK = 13; //SPI clock
//

//function prototypes
void adc_wreg(int reg, int val); //write register
void adc_send_command(int cmd); //send command
int adc_rreg(int reg); //read register

//start Serial Peripheral Interface
int numActiveChannels = 0;
boolean gActiveChan[9]; // reports whether channels 1..9 are active
boolean isRdatac = false;
boolean base64Mode = false;
int sampleCount=0;
boolean isLimit=false;

char hexDigits[] = "0123456789ABCDEF";
uint8_t serialBytes[200];
char sampleBuffer[1000];
uint8_t chan1[2];

const char *hardwareType = "unknown";
const char *boardName = "HackEEG";
const char *makerName = "Hamid, Mujahid, Abdul Hameed";
const char *driverVersion = "ADS1298 driver v0.1";

#if defined(__SAM3X8E__)
//#define isDUE //Detect Arduino Due
//#define WiredSerial SerialUSB //Use Due's Native port
//#define NSerial SerialUSB
#endif

void setup()
using namespace ADS1298;
//prepare pins to be outputs or inputs
pinMode(PIN_SCLK, OUTPUT); //optional - SPI library will do this for us
pinMode(PIN_DIN, OUTPUT); //optional - SPI library will do this for us
pinMode(PIN_DOUT, INPUT); //optional - SPI library will do this for us
pinMode(IPIN_CS, OUTPUT);
pinMode(PIN_START, OUTPUT);
pinMode(IPIN_DRDY, INPUT);
pinMode(PIN_CLKSEL, OUTPUT); // *optional
pinMode(IPIN_RESET, OUTPUT); // *optional
pinMode(IPIN_PWDN, OUTPUT); // *optional
digitalWrite(PIN_CLKSEL, HIGH); // External clock
//start Serial Peripheral Interface


SPI.begin();
SPI.setBitOrder(MSBFIRST);
#ifndef isDUE
SPI.setClockDivider(SPI_CLOCK_DIV4); //forum.pjrc.com/.../1156-Teensy-3-SPI-Basic-Clock-Questions
#endif
SPI.setDataMode(SPI_MODE1);
//Start ADS1298
delay(500); //wait for the ads129n to be ready - it can take a while to charge caps
digitalWrite(PIN_CLKSEL, HIGH); // External clock
delay(10); // wait for oscillator to wake up
delay(1);
digitalWrite(IPIN_PWDN, HIGH); // *optional - turn off power down mode
digitalWrite(IPIN_RESET, HIGH);
delay(1000);// *optional
digitalWrite(IPIN_RESET, LOW);
delay(1);// *optional
digitalWrite(IPIN_RESET, HIGH);
delay(1500); // *optional Wait for 18 tCLKs AKA 9 microseconds, we use 1 millisecond

adc_send_command(SDATAC); // Send SDATAC Command (Stop Read Data Continuously mode)
// delayMicroseconds(2);
delay(100);
// Determine model number and number of channels available
gIDval = adc_rreg(ID); //lower 5 bits of register 0 reveal chip type
switch (gIDval & B00011111 ) //least significant bits reports channels
case B10000: //16
hardwareType = "ADS1294";
gMaxChan = 4; //ads1294
break;
case B10001: //17
hardwareType = "ADS1296";
gMaxChan = 6; //ads1296
break;
case B10010: //18
hardwareType = "ADS1298";
gMaxChan = 8; //ads1298
break;
case B11110: //30
hardwareType = "ADS1299";
gMaxChan = 8; //ads1299
break;
case B10110: //22
hardwareType = "ADS1198";
gMaxChan = 8; //ads1198
break;
default:
gMaxChan = 0;



void detectActiveChannels()

//start serial port
Serial1.begin(115200);
Serial.begin(115200); //use native port on Due









share|improve this question









New contributor




Amber Liu is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
























    0















    I am trying to verify the Arduino code in ADS1198 and Arduino Due. It comes the error show 'Serial1' does not name a type' even I defined two serial port in the beginning(where I gave the comments now). How to deal with this error 'Serial1' does not name a type'. how can I define these two port on ArduinoDue so that complieling successfully.



    #include <ads1298.h>
    #include <Base64.h>

    // Minimal sketch for connection to ADS129n family. Load this script and open Tools/SerialMonitor.
    // You should see text like this
    // Device Type (ID Control Register): 62 Channels: 8
    // If you see "Channels: 0" then check your wiring

    #include "ads1298.h"
    #include "adsCMD.h"
    #include <Base64.h>


    #include <SPI.h> // include the SPI library:
    int gMaxChan = 0; //maximum number of channels supported by ads129n = 4,6,8
    int gIDval = 0; //Device ID : lower 5 bits of ID Control Register

    int activeSerialPort = 0; //data will be sent to serial port that last sent commands. E.G. bluetooth or USB port
    const int kPIN_LED = 13; //pin with in-built light - typically 13, 11 for Teensy 2.0.

    //ADSCMD

    #include "Arduino.h"

    //For Leonardo SPI see http://openenergymonitor.blogspot.com/2012/06/arduino-leonardo-atmega32u4-and-rfm12b.html
    //constants define pins on Arduino

    // Arduino Due
    const int IPIN_PWDN = 47; //not required for TI demo kit
    const int PIN_CLKSEL = 49; //6;//*optional
    const int IPIN_RESET = 48; //*optional

    const int PIN_START = 46;
    const int IPIN_DRDY = 45;
    const int IPIN_CS = 52;
    const int PIN_DOUT = 11; //SPI out
    const int PIN_DIN = 12; //SPI in
    const int PIN_SCLK = 13; //SPI clock
    //

    //function prototypes
    void adc_wreg(int reg, int val); //write register
    void adc_send_command(int cmd); //send command
    int adc_rreg(int reg); //read register

    //start Serial Peripheral Interface
    int numActiveChannels = 0;
    boolean gActiveChan[9]; // reports whether channels 1..9 are active
    boolean isRdatac = false;
    boolean base64Mode = false;
    int sampleCount=0;
    boolean isLimit=false;

    char hexDigits[] = "0123456789ABCDEF";
    uint8_t serialBytes[200];
    char sampleBuffer[1000];
    uint8_t chan1[2];

    const char *hardwareType = "unknown";
    const char *boardName = "HackEEG";
    const char *makerName = "Hamid, Mujahid, Abdul Hameed";
    const char *driverVersion = "ADS1298 driver v0.1";

    #if defined(__SAM3X8E__)
    //#define isDUE //Detect Arduino Due
    //#define WiredSerial SerialUSB //Use Due's Native port
    //#define NSerial SerialUSB
    #endif

    void setup()
    using namespace ADS1298;
    //prepare pins to be outputs or inputs
    pinMode(PIN_SCLK, OUTPUT); //optional - SPI library will do this for us
    pinMode(PIN_DIN, OUTPUT); //optional - SPI library will do this for us
    pinMode(PIN_DOUT, INPUT); //optional - SPI library will do this for us
    pinMode(IPIN_CS, OUTPUT);
    pinMode(PIN_START, OUTPUT);
    pinMode(IPIN_DRDY, INPUT);
    pinMode(PIN_CLKSEL, OUTPUT); // *optional
    pinMode(IPIN_RESET, OUTPUT); // *optional
    pinMode(IPIN_PWDN, OUTPUT); // *optional
    digitalWrite(PIN_CLKSEL, HIGH); // External clock
    //start Serial Peripheral Interface


    SPI.begin();
    SPI.setBitOrder(MSBFIRST);
    #ifndef isDUE
    SPI.setClockDivider(SPI_CLOCK_DIV4); //forum.pjrc.com/.../1156-Teensy-3-SPI-Basic-Clock-Questions
    #endif
    SPI.setDataMode(SPI_MODE1);
    //Start ADS1298
    delay(500); //wait for the ads129n to be ready - it can take a while to charge caps
    digitalWrite(PIN_CLKSEL, HIGH); // External clock
    delay(10); // wait for oscillator to wake up
    delay(1);
    digitalWrite(IPIN_PWDN, HIGH); // *optional - turn off power down mode
    digitalWrite(IPIN_RESET, HIGH);
    delay(1000);// *optional
    digitalWrite(IPIN_RESET, LOW);
    delay(1);// *optional
    digitalWrite(IPIN_RESET, HIGH);
    delay(1500); // *optional Wait for 18 tCLKs AKA 9 microseconds, we use 1 millisecond

    adc_send_command(SDATAC); // Send SDATAC Command (Stop Read Data Continuously mode)
    // delayMicroseconds(2);
    delay(100);
    // Determine model number and number of channels available
    gIDval = adc_rreg(ID); //lower 5 bits of register 0 reveal chip type
    switch (gIDval & B00011111 ) //least significant bits reports channels
    case B10000: //16
    hardwareType = "ADS1294";
    gMaxChan = 4; //ads1294
    break;
    case B10001: //17
    hardwareType = "ADS1296";
    gMaxChan = 6; //ads1296
    break;
    case B10010: //18
    hardwareType = "ADS1298";
    gMaxChan = 8; //ads1298
    break;
    case B11110: //30
    hardwareType = "ADS1299";
    gMaxChan = 8; //ads1299
    break;
    case B10110: //22
    hardwareType = "ADS1198";
    gMaxChan = 8; //ads1198
    break;
    default:
    gMaxChan = 0;



    void detectActiveChannels()

    //start serial port
    Serial1.begin(115200);
    Serial.begin(115200); //use native port on Due









    share|improve this question









    New contributor




    Amber Liu is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
    Check out our Code of Conduct.






















      0












      0








      0








      I am trying to verify the Arduino code in ADS1198 and Arduino Due. It comes the error show 'Serial1' does not name a type' even I defined two serial port in the beginning(where I gave the comments now). How to deal with this error 'Serial1' does not name a type'. how can I define these two port on ArduinoDue so that complieling successfully.



      #include <ads1298.h>
      #include <Base64.h>

      // Minimal sketch for connection to ADS129n family. Load this script and open Tools/SerialMonitor.
      // You should see text like this
      // Device Type (ID Control Register): 62 Channels: 8
      // If you see "Channels: 0" then check your wiring

      #include "ads1298.h"
      #include "adsCMD.h"
      #include <Base64.h>


      #include <SPI.h> // include the SPI library:
      int gMaxChan = 0; //maximum number of channels supported by ads129n = 4,6,8
      int gIDval = 0; //Device ID : lower 5 bits of ID Control Register

      int activeSerialPort = 0; //data will be sent to serial port that last sent commands. E.G. bluetooth or USB port
      const int kPIN_LED = 13; //pin with in-built light - typically 13, 11 for Teensy 2.0.

      //ADSCMD

      #include "Arduino.h"

      //For Leonardo SPI see http://openenergymonitor.blogspot.com/2012/06/arduino-leonardo-atmega32u4-and-rfm12b.html
      //constants define pins on Arduino

      // Arduino Due
      const int IPIN_PWDN = 47; //not required for TI demo kit
      const int PIN_CLKSEL = 49; //6;//*optional
      const int IPIN_RESET = 48; //*optional

      const int PIN_START = 46;
      const int IPIN_DRDY = 45;
      const int IPIN_CS = 52;
      const int PIN_DOUT = 11; //SPI out
      const int PIN_DIN = 12; //SPI in
      const int PIN_SCLK = 13; //SPI clock
      //

      //function prototypes
      void adc_wreg(int reg, int val); //write register
      void adc_send_command(int cmd); //send command
      int adc_rreg(int reg); //read register

      //start Serial Peripheral Interface
      int numActiveChannels = 0;
      boolean gActiveChan[9]; // reports whether channels 1..9 are active
      boolean isRdatac = false;
      boolean base64Mode = false;
      int sampleCount=0;
      boolean isLimit=false;

      char hexDigits[] = "0123456789ABCDEF";
      uint8_t serialBytes[200];
      char sampleBuffer[1000];
      uint8_t chan1[2];

      const char *hardwareType = "unknown";
      const char *boardName = "HackEEG";
      const char *makerName = "Hamid, Mujahid, Abdul Hameed";
      const char *driverVersion = "ADS1298 driver v0.1";

      #if defined(__SAM3X8E__)
      //#define isDUE //Detect Arduino Due
      //#define WiredSerial SerialUSB //Use Due's Native port
      //#define NSerial SerialUSB
      #endif

      void setup()
      using namespace ADS1298;
      //prepare pins to be outputs or inputs
      pinMode(PIN_SCLK, OUTPUT); //optional - SPI library will do this for us
      pinMode(PIN_DIN, OUTPUT); //optional - SPI library will do this for us
      pinMode(PIN_DOUT, INPUT); //optional - SPI library will do this for us
      pinMode(IPIN_CS, OUTPUT);
      pinMode(PIN_START, OUTPUT);
      pinMode(IPIN_DRDY, INPUT);
      pinMode(PIN_CLKSEL, OUTPUT); // *optional
      pinMode(IPIN_RESET, OUTPUT); // *optional
      pinMode(IPIN_PWDN, OUTPUT); // *optional
      digitalWrite(PIN_CLKSEL, HIGH); // External clock
      //start Serial Peripheral Interface


      SPI.begin();
      SPI.setBitOrder(MSBFIRST);
      #ifndef isDUE
      SPI.setClockDivider(SPI_CLOCK_DIV4); //forum.pjrc.com/.../1156-Teensy-3-SPI-Basic-Clock-Questions
      #endif
      SPI.setDataMode(SPI_MODE1);
      //Start ADS1298
      delay(500); //wait for the ads129n to be ready - it can take a while to charge caps
      digitalWrite(PIN_CLKSEL, HIGH); // External clock
      delay(10); // wait for oscillator to wake up
      delay(1);
      digitalWrite(IPIN_PWDN, HIGH); // *optional - turn off power down mode
      digitalWrite(IPIN_RESET, HIGH);
      delay(1000);// *optional
      digitalWrite(IPIN_RESET, LOW);
      delay(1);// *optional
      digitalWrite(IPIN_RESET, HIGH);
      delay(1500); // *optional Wait for 18 tCLKs AKA 9 microseconds, we use 1 millisecond

      adc_send_command(SDATAC); // Send SDATAC Command (Stop Read Data Continuously mode)
      // delayMicroseconds(2);
      delay(100);
      // Determine model number and number of channels available
      gIDval = adc_rreg(ID); //lower 5 bits of register 0 reveal chip type
      switch (gIDval & B00011111 ) //least significant bits reports channels
      case B10000: //16
      hardwareType = "ADS1294";
      gMaxChan = 4; //ads1294
      break;
      case B10001: //17
      hardwareType = "ADS1296";
      gMaxChan = 6; //ads1296
      break;
      case B10010: //18
      hardwareType = "ADS1298";
      gMaxChan = 8; //ads1298
      break;
      case B11110: //30
      hardwareType = "ADS1299";
      gMaxChan = 8; //ads1299
      break;
      case B10110: //22
      hardwareType = "ADS1198";
      gMaxChan = 8; //ads1198
      break;
      default:
      gMaxChan = 0;



      void detectActiveChannels()

      //start serial port
      Serial1.begin(115200);
      Serial.begin(115200); //use native port on Due









      share|improve this question









      New contributor




      Amber Liu is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.












      I am trying to verify the Arduino code in ADS1198 and Arduino Due. It comes the error show 'Serial1' does not name a type' even I defined two serial port in the beginning(where I gave the comments now). How to deal with this error 'Serial1' does not name a type'. how can I define these two port on ArduinoDue so that complieling successfully.



      #include <ads1298.h>
      #include <Base64.h>

      // Minimal sketch for connection to ADS129n family. Load this script and open Tools/SerialMonitor.
      // You should see text like this
      // Device Type (ID Control Register): 62 Channels: 8
      // If you see "Channels: 0" then check your wiring

      #include "ads1298.h"
      #include "adsCMD.h"
      #include <Base64.h>


      #include <SPI.h> // include the SPI library:
      int gMaxChan = 0; //maximum number of channels supported by ads129n = 4,6,8
      int gIDval = 0; //Device ID : lower 5 bits of ID Control Register

      int activeSerialPort = 0; //data will be sent to serial port that last sent commands. E.G. bluetooth or USB port
      const int kPIN_LED = 13; //pin with in-built light - typically 13, 11 for Teensy 2.0.

      //ADSCMD

      #include "Arduino.h"

      //For Leonardo SPI see http://openenergymonitor.blogspot.com/2012/06/arduino-leonardo-atmega32u4-and-rfm12b.html
      //constants define pins on Arduino

      // Arduino Due
      const int IPIN_PWDN = 47; //not required for TI demo kit
      const int PIN_CLKSEL = 49; //6;//*optional
      const int IPIN_RESET = 48; //*optional

      const int PIN_START = 46;
      const int IPIN_DRDY = 45;
      const int IPIN_CS = 52;
      const int PIN_DOUT = 11; //SPI out
      const int PIN_DIN = 12; //SPI in
      const int PIN_SCLK = 13; //SPI clock
      //

      //function prototypes
      void adc_wreg(int reg, int val); //write register
      void adc_send_command(int cmd); //send command
      int adc_rreg(int reg); //read register

      //start Serial Peripheral Interface
      int numActiveChannels = 0;
      boolean gActiveChan[9]; // reports whether channels 1..9 are active
      boolean isRdatac = false;
      boolean base64Mode = false;
      int sampleCount=0;
      boolean isLimit=false;

      char hexDigits[] = "0123456789ABCDEF";
      uint8_t serialBytes[200];
      char sampleBuffer[1000];
      uint8_t chan1[2];

      const char *hardwareType = "unknown";
      const char *boardName = "HackEEG";
      const char *makerName = "Hamid, Mujahid, Abdul Hameed";
      const char *driverVersion = "ADS1298 driver v0.1";

      #if defined(__SAM3X8E__)
      //#define isDUE //Detect Arduino Due
      //#define WiredSerial SerialUSB //Use Due's Native port
      //#define NSerial SerialUSB
      #endif

      void setup()
      using namespace ADS1298;
      //prepare pins to be outputs or inputs
      pinMode(PIN_SCLK, OUTPUT); //optional - SPI library will do this for us
      pinMode(PIN_DIN, OUTPUT); //optional - SPI library will do this for us
      pinMode(PIN_DOUT, INPUT); //optional - SPI library will do this for us
      pinMode(IPIN_CS, OUTPUT);
      pinMode(PIN_START, OUTPUT);
      pinMode(IPIN_DRDY, INPUT);
      pinMode(PIN_CLKSEL, OUTPUT); // *optional
      pinMode(IPIN_RESET, OUTPUT); // *optional
      pinMode(IPIN_PWDN, OUTPUT); // *optional
      digitalWrite(PIN_CLKSEL, HIGH); // External clock
      //start Serial Peripheral Interface


      SPI.begin();
      SPI.setBitOrder(MSBFIRST);
      #ifndef isDUE
      SPI.setClockDivider(SPI_CLOCK_DIV4); //forum.pjrc.com/.../1156-Teensy-3-SPI-Basic-Clock-Questions
      #endif
      SPI.setDataMode(SPI_MODE1);
      //Start ADS1298
      delay(500); //wait for the ads129n to be ready - it can take a while to charge caps
      digitalWrite(PIN_CLKSEL, HIGH); // External clock
      delay(10); // wait for oscillator to wake up
      delay(1);
      digitalWrite(IPIN_PWDN, HIGH); // *optional - turn off power down mode
      digitalWrite(IPIN_RESET, HIGH);
      delay(1000);// *optional
      digitalWrite(IPIN_RESET, LOW);
      delay(1);// *optional
      digitalWrite(IPIN_RESET, HIGH);
      delay(1500); // *optional Wait for 18 tCLKs AKA 9 microseconds, we use 1 millisecond

      adc_send_command(SDATAC); // Send SDATAC Command (Stop Read Data Continuously mode)
      // delayMicroseconds(2);
      delay(100);
      // Determine model number and number of channels available
      gIDval = adc_rreg(ID); //lower 5 bits of register 0 reveal chip type
      switch (gIDval & B00011111 ) //least significant bits reports channels
      case B10000: //16
      hardwareType = "ADS1294";
      gMaxChan = 4; //ads1294
      break;
      case B10001: //17
      hardwareType = "ADS1296";
      gMaxChan = 6; //ads1296
      break;
      case B10010: //18
      hardwareType = "ADS1298";
      gMaxChan = 8; //ads1298
      break;
      case B11110: //30
      hardwareType = "ADS1299";
      gMaxChan = 8; //ads1299
      break;
      case B10110: //22
      hardwareType = "ADS1198";
      gMaxChan = 8; //ads1198
      break;
      default:
      gMaxChan = 0;



      void detectActiveChannels()

      //start serial port
      Serial1.begin(115200);
      Serial.begin(115200); //use native port on Due






      arduino






      share|improve this question









      New contributor




      Amber Liu is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.











      share|improve this question









      New contributor




      Amber Liu is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.









      share|improve this question




      share|improve this question








      edited Mar 22 at 1:42









      Kentaro Okuda

      10717




      10717






      New contributor




      Amber Liu is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.









      asked Mar 21 at 15:50









      Amber LiuAmber Liu

      1




      1




      New contributor




      Amber Liu is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.





      New contributor





      Amber Liu is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.






      Amber Liu is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.






















          1 Answer
          1






          active

          oldest

          votes


















          0














          Serial1.begin(115200) and Serial.begin(115200) need to be placed in a function. Put them in setup().






          share|improve this answer






















            Your Answer






            StackExchange.ifUsing("editor", function ()
            StackExchange.using("externalEditor", function ()
            StackExchange.using("snippets", function ()
            StackExchange.snippets.init();
            );
            );
            , "code-snippets");

            StackExchange.ready(function()
            var channelOptions =
            tags: "".split(" "),
            id: "1"
            ;
            initTagRenderer("".split(" "), "".split(" "), channelOptions);

            StackExchange.using("externalEditor", function()
            // Have to fire editor after snippets, if snippets enabled
            if (StackExchange.settings.snippets.snippetsEnabled)
            StackExchange.using("snippets", function()
            createEditor();
            );

            else
            createEditor();

            );

            function createEditor()
            StackExchange.prepareEditor(
            heartbeatType: 'answer',
            autoActivateHeartbeat: false,
            convertImagesToLinks: true,
            noModals: true,
            showLowRepImageUploadWarning: true,
            reputationToPostImages: 10,
            bindNavPrevention: true,
            postfix: "",
            imageUploader:
            brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
            contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
            allowUrls: true
            ,
            onDemand: true,
            discardSelector: ".discard-answer"
            ,immediatelyShowMarkdownHelp:true
            );



            );






            Amber Liu is a new contributor. Be nice, and check out our Code of Conduct.









            draft saved

            draft discarded


















            StackExchange.ready(
            function ()
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55284357%2fserial1-does-not-name-a-type-error-in-arduino%23new-answer', 'question_page');

            );

            Post as a guest















            Required, but never shown

























            1 Answer
            1






            active

            oldest

            votes








            1 Answer
            1






            active

            oldest

            votes









            active

            oldest

            votes






            active

            oldest

            votes









            0














            Serial1.begin(115200) and Serial.begin(115200) need to be placed in a function. Put them in setup().






            share|improve this answer



























              0














              Serial1.begin(115200) and Serial.begin(115200) need to be placed in a function. Put them in setup().






              share|improve this answer

























                0












                0








                0







                Serial1.begin(115200) and Serial.begin(115200) need to be placed in a function. Put them in setup().






                share|improve this answer













                Serial1.begin(115200) and Serial.begin(115200) need to be placed in a function. Put them in setup().







                share|improve this answer












                share|improve this answer



                share|improve this answer










                answered Mar 21 at 19:45









                Kentaro OkudaKentaro Okuda

                10717




                10717






















                    Amber Liu is a new contributor. Be nice, and check out our Code of Conduct.









                    draft saved

                    draft discarded


















                    Amber Liu is a new contributor. Be nice, and check out our Code of Conduct.












                    Amber Liu is a new contributor. Be nice, and check out our Code of Conduct.











                    Amber Liu is a new contributor. Be nice, and check out our Code of Conduct.














                    Thanks for contributing an answer to Stack Overflow!


                    • Please be sure to answer the question. Provide details and share your research!

                    But avoid


                    • Asking for help, clarification, or responding to other answers.

                    • Making statements based on opinion; back them up with references or personal experience.

                    To learn more, see our tips on writing great answers.




                    draft saved


                    draft discarded














                    StackExchange.ready(
                    function ()
                    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55284357%2fserial1-does-not-name-a-type-error-in-arduino%23new-answer', 'question_page');

                    );

                    Post as a guest















                    Required, but never shown





















































                    Required, but never shown














                    Required, but never shown












                    Required, but never shown







                    Required, but never shown

































                    Required, but never shown














                    Required, but never shown












                    Required, but never shown







                    Required, but never shown







                    Popular posts from this blog

                    SQL error code 1064 with creating Laravel foreign keysForeign key constraints: When to use ON UPDATE and ON DELETEDropping column with foreign key Laravel error: General error: 1025 Error on renameLaravel SQL Can't create tableLaravel Migration foreign key errorLaravel php artisan migrate:refresh giving a syntax errorSQLSTATE[42S01]: Base table or view already exists or Base table or view already exists: 1050 Tableerror in migrating laravel file to xampp serverSyntax error or access violation: 1064:syntax to use near 'unsigned not null, modelName varchar(191) not null, title varchar(191) not nLaravel cannot create new table field in mysqlLaravel 5.7:Last migration creates table but is not registered in the migration table

                    용인 삼성생명 블루밍스 목차 통계 역대 감독 선수단 응원단 경기장 같이 보기 외부 링크 둘러보기 메뉴samsungblueminx.comeh선수 명단용인 삼성생명 블루밍스용인 삼성생명 블루밍스ehsamsungblueminx.comeheheheh

                    155 수학 과학 기타 둘러보기 메뉴eh추가해eh문서를 완성해