Page 1 of 1

Call a function when ‘Connect’ is clicked

Posted: Tue Oct 15, 2019 1:04 pm
by indridkold
Hello,
Is there a way to call an ‘OnConnect’ function? I’d like to initialize the display values with current values from the Arduino. I have an ‘Initialize’ button that does this, but sometimes users forget to click it. Any assistance appreciated, IK

Re: Call a function when ‘Connect’ is clicked

Posted: Wed Oct 16, 2019 5:30 am
by philr
Hi you can use the serial connection item in the interface panel
x2scrap2.png
x2scrap2.png (24.46 KiB) Viewed 7187 times
It will send your microcontroller a message after connection is established.

Cheers
Phil

Re: Call a function when ‘Connect’ is clicked

Posted: Fri Oct 18, 2019 12:22 pm
by indridkold
Perfect! That’s exactly what I was looking for.
Thanks,
IK