Is there a way to get around this issue? I can't print a statement in setup(). I don't want to have to do it in loop().
Any help please?
Is there a way to get around this issue? I can't print a statement in setup(). I don't want to have to do it in loop().
Any help please?
Probably you print the message before the initialization of the serial or USB interface you want use.
thanks for your response.
I have the following but nothing:
#include <Wire.h>
void setup()
{
SerialUSB.begin();
SerialUSB.println("hello world");
Wire.begin();
}
void loop(){
}
I have tried multiple arrangements and still i get no output on the serial monitor.
Have you tried:
#include <Wire.h>
void setup()
{
delay(2000);
//SerialUSB.begin();
SerialUSB.println("hello world");
Wire.begin();
}
void loop(){
}
I noticed that the processor is faster than I am opening the serial port window. So I put a few seconds to make sure I receive everything.
That being said, this USB comm is no the most reliable thing in the world.
In arduino, when you open a serial window it causes a reset to the uC so thats why you can see a message in the setup().In maple thats not happening..
Also its not necessary to put SerialUSB.begin();
Try this code and press the button to see the hello world
void setup()
{
waitForButtonPress(0);
SerialUSB.println("hello world");
}
void loop(){
}
You must log in to post.