Hi, i'm using arduino with a mac comp..
I found the servo timer 1 library and I downloaded it onto my comp, but I can't find the hardware/libraries folder to put it in..
Is there something different I have to do to get it on arduino mac software?
The hardware folder should be in the root folder that your arduino s/w loaded into. On my Mac it downloaded to Downloads/arduino-0016 and I've just left it in Downloads for the moment. Hence my library folder is:
Downloads/arduino-0016/hardware/libraries
ok, i found the hardware/library in show package contents..
i uploaded the library and tried using this script to control the servos plugged into my roboduino:
#include <ServoTimer1.h>
ServoTimer1 servo1;
ServoTimer1 servo2;
void setup() {
Serial.begin(9600); // set up Serial library at 9600 bps
Serial.println("Servo test!");
servo1.attach(10);
servo2.attach(9);
}
void loop() {
Serial.print("tick");
servo1.write(180);
servo2.write(0);
delay(1000);
Serial.print("tock");
servo1.write(0);
servo2.write(180);
delay(1000);
}
when i press verify i get this error:
/Applications/Arduino.app/Contents/Resources/Java/hardware/tools/avr/bin/../lib/gcc/avr/4.3.2/../../../../avr/include/stdlib.h:111: error: expected unqualified-id before 'int'
/Applications/Arduino.app/Contents/Resources/Java/hardware/tools/avr/bin/../lib/gcc/avr/4.3.2/../../../../avr/include/stdlib.h:111: error: expected `)' before 'int'
/Applications/Arduino.app/Contents/Resources/Java/hardware/tools/avr/bin/../lib/gcc/avr/4.3.2/../../../../avr/include/stdlib.h:111: error: expected `)' before 'int'
anyone know whats going on? please help!!
Servo timer1 was replaced by the standard Arduino library in version 0012. If you are using Arduino Version 0012 through 0016 you don't need ServoTimer1 (just use the included Servo library). Arduino version 0017 uses a new library that supports more servos.
What arduino version are you running?