I have an arduino sketch that sets up a very simple serial protocol to do various tasks. I have a corresponding C# application that creates a serial connection and uses it to communicate with the Arduino through this protocol. For the most part it works flawlessly, however, with the arduino Uno (only board we really use) I have a handful of users that are experiencing problems.
Part of the protocol is that the arduino sketch sends a heartbeat message using Serial.write to send a little bit of data identifying the data as the heartbeat.
What's happening to this small set of users, is that after some amount of time, the C# application stops receiving the heartbeat message and so it assumes something has gone wrong with the connection.
The only other bit of information is this event seems to be caused by some kind of electrical interference. Fairly close to the arduino is an 18v power supply driving a small motor (slot car). When no power is applied to the motor at least one particular user has no issues, but some random time after applying power to the motor he gets the signal loss.
Any thoughts on what this could be, how to fix it, and/or how to troubleshoot it? I've tried virtually everything I can think of.
All help is appreciated. Thanks Dave