Seril monitor issue

Hi everyone
I am working on digital hourglass project. I tried to run the serial monitor however I am getting this message 'not connected. Select a board and a port to connect automatically'. As you see in the pic port and the board already selected. Why I am getting this message. FYI: Circuit don't work as well.

Is your Arduino UNO really on COM8, or is that another serial device?

@muhac80, your topic has been moved to the section of the forum dedicated to IDE2.0

I get the same message, it lasts until the program starts to send serial messages. I would put your code aside and run an example of serial output.

Also read about millis, what I could read of your code its highly unlikely that

if (time = 1000) will ever be true. And it should be if (time == 1000)

The

delay (1000)
will stop the program for 1000 ms. During that time the millis will continue to count if the code does not get run the millisecond that temp = 1000 then that "if" statement will NEVER be true.

Hi @muhac80. Thanks for taking the time to give the Arduino IDE 2.0.0 release candidate a try!

As @JohnRob mentioned already, this "Not connected. Select a board and a port to connect automatically." message is normal and expected under certain conditions. Most notably, that will be while uploading a sketch to your board, since the IDE must disconnect the Serial Monitor from the port so that it can be used by the upload tool.

Unfortunately, there is a bug in the Arduino IDE that also causes this message to occur when the IDE would be expected to connect to the board if it was working correctly. That bug is tracked by the Arduino IDE developers here:

You will probably find that the Serial Monitor is still able to display output from the board despite the claim that it is not connected. However, you will find that if you try to send data from Serial Monitor to your board it does not work, which is tracked here:

If you have a GitHub account, you can subscribe to that issue to get notifications of any new developments related to this subject.


Until these bugs have been fixed, the workaround is to make sure you only ever use the Serial Monitor in one Arduino IDE window per session. If you run into the bug in subsequent windows, you will need to restart the Arduino IDE by exiting (e.g., File > Quit) and then starting the Arduino IDE once again, after which the Serial Monitor should not be affected by this bug in the first window you open it from.

Good call. Thank you.
Rebooting my laptop fixed the serial monitor issue. Thanks everyone.