Hey guys, I am back again. I am looking for some help with the Pololu Micro Maestro servo controller. Currently I have the sequences for the differ positions of the arm of the robot. What I need is to learn how to call those sequences with the Arduino. Specifically, if the color sensor hooked up to the Arduino "sees" red, I need the Micro Maestro to execute the "go to red bin" sequence. Similarly, I will be using an IR sensor to detect the presence of a fish, but for the time being am going to use a button. Any tips? I am still pretty new to the Ardunio and only know enough to be dangerous, so bear with me. Thanks in advance.
I've seen some stupid names for variables, but this one really takes the cake.
Currently I have the sequences for the differ positions of the arm of the robot.
Where? Are they somewhere where the Arduino can read them? Have you written any code to read that file? Have you written any code to parse that XML file?
What I need is to learn how to call those sequences with the Arduino.
I'm very new to this, but so far i have my Arduino looking for button pushes (1, 2 or 3) and then it calls the corrasponding subroutines, however - the servo controller only plays the first line of each subroutine when it is called?
I'm after the subroutine to be played on a loop untill the Arduino calls up another - is this possible?
Whenever anyone posts code that has switches connected to INPUT pins, instead of INPUT_PULLUP pins, I have to ask how ARE the switches wired, and why did you do it THAT way?
A link to the Maestro library would be in order. I'm guessing that will answer a lot of questions that b3ttykr0ck3r wouldn't.
Being a 'newbie' I have just followed a tutorial for connecting push buttons, so thats why I've done it that way (please see attached image to clarify how I have my buttons connected)
Please also find attached the Arduino library for the Maestro.
Thanks for the pointer - I had a play in the Maestro code with where I had placed the 'begin' and 'repeat' tags - these control the looping and I have it doing what I need.