I'm trying to utilize some of the unused servo ports on the NyBoard to add additional functionality to Bittle. I have one servo hooked up to port 0 (the head port), and one hooked up to port 2 (where the tail would be connected). I have two questions:
1)
For the servo connected to port 2, I have defined this skill: const int8_t pher[] PROGMEM = {
-2, 0, 0, 1,
0, 0, 0,
0, -80, -90, 0, 0, -3, 3, 3, 75, 75, 75, 75, -55, -55, -55, -55, 4, 0, 0, 0,
0, -80, 0, 0, 0, -3, 3, 3, 75, 75, 75, 75, -55, -55, -55, -55, 4, 0, 0, 0,
};
Which is located in InstinctBittle.h. The strange thing, is that when I call this new skill, sometimes the servo moves counter clockwise, and sometimes clockwise. Is there a way to ensure the servo moves in the same direction each time?
2)
For the servo connected to port 0, whenever Bittle does any other action such as walking, crawling, etc., the servo moves a few degrees back and forth. I have changed all the other skills in InstinctBittle.h to have 0 for the angle of port 0, however this didn't do anything. Is this oscillation defined somewhere else for this port that I can adjust to eliminate this behavior?
I think you modified the servo angle of the joint index 1(Pin 11 on the NyBoard) and 2(Pin 4 on the NyBoard), as following: