04-26-2014 03:52 PM
Hello everyone,
I have a question about a project we have to do for school. We have to build a linefollowing robot, which also uses a RGB sensor and a distance sensor. We use the Arduino Uno for this project and the code for Arduino is almost ready. But another function of the robot is that it has to be possible to control the robot with a LabVIEW program on our laptop (by using Bluetooth). The intention of this function is that we can take over control of Arduino when it does something wrong (for example, to avoid a collision). LabVIEW is new for us, so a little help would be nice.
In the LabVIEW program I use the event-structure. For the moment, I have 5 events: Forward, TurnLeft, TurnRight, Stop and another event to stop the whole labVIEW program. They all have a boolean and when the value change, the correspending event is performed by the robot.
But I have a question about changing the control between LabVIEW and Arduino. How should I do this? I think I will probably have to make another event with a boolean and value change? For example: when the robot is controlled by the code in Arduino and I push the boolean button, the control goes to LabVIEW and vice versa. But only a boolean won't be enough, so what do I have to do for this?
Many thanks
04-26-2014 04:20 PM
04-26-2014 04:36 PM
You're totally right.. I hadn't seen the file was 5MB. I attached a smaller one here.
04-26-2014 04:37 PM
Here is the smaller image
04-26-2014 05:03 PM
04-26-2014 05:34 PM
I've played with Arduinos a bit. Just take a look at the basic serial command sketch that ships with the IDE. You can use that and poll for a serial command without stalling your arduino loop.