Hallo,
After running B4R on my pc, i go to log Windows, and click Connect for displaying the messages from the arduino board. In this case the arduino program restart, why ?i wish looking for the messages arduino send, not restarting the arduino
Best regards
We need more information about your code,hardware,Arduino-Version, etc.
How does your MCU behave when you have this minimal sketch with only a log output ?
B4X:
Sub Process_Globals
Public Serial1 As Serial
Private Timer1 As Timer
End Sub
Private Sub AppStart
Serial1.Initialize(115200)
Log("AppStart")
Timer1.Initialize("Timer1_Tick", 2000)
Timer1.Enabled = True
End Sub
Private Sub Timer1_Tick
Dim bState As Boolean = True
Log("State: ", bState)
Log("State: ", Not(bState))
End Sub
Not all programs make arduino restart after connection, I've developed many .NET applications for arduino and they don't make arduino restart. Hyper terminal makes arduino restart after connection.
I believe this is a hardware thing. A Pro Mini will restart every time you reconnect. The ESP32 doesn't do this. In the past I just keep the Pro Mini connected to catch a log I need. Use something like PuTTy to write to file or capture long periods of logs. I've done this before on occasion.