I dont usually go messing around with core files or class files with out specific directions..
while trying to use the ServoTimer2 library....(which I have used n the past, with older projects and hence older IDE versions without issue)..
I start getting these error at compile/upload time:
Arduino: 1.6.4 (Windows 7), Board: "Arduino Duemilanove or Diecimila, ATmega328" Build options changed, rebuilding all In file included from IM_servo_n_eye_n_sound_2.ino:17:0: C:\Program Files (x86)\Arduino\hardware\arduino\avr\cores\arduino/Arduino.h:117:14: error: conflicting declaration 'typedef bool boolean' typedef bool boolean; ^ In file included from IM_servo_n_eye_n_sound_2.ino:8:0: C:\Users\username\Documents\Arduino\libraries\ServoTimer2/ServoTimer2.h:41:17: error: 'boolean' has a previous declaration as 'typedef uint8_t boolean' typedef uint8_t boolean; ^ Error compiling. This report would have more information with "Show verbose output during compilation" enabled in File > Preferences.
I would imagine it would be best to alter the ServoTimer2 library? vs some core IDE file?
But to what is best/suggested?
update: I tried the answer posted here:
but am now getting this error:
In file included from adavoice_servo_v1.ino:45:0: C:\Users\username\Documents\Arduino\libraries\ServoTimer2/ServoTimer2.h:73:2: error: 'boolean' does not name a type boolean attached(); // return true if this servo is attached ^ C:\Users\username\Documents\Arduino\libraries\ServoTimer2/ServoTimer2.h:93:2: error: 'boolean' does not name a type boolean attached(int); // return true if the servo on the given channel is attached ^ Error compiling.
after reading another suggested fix here:
(change any reference of boolean to bool)..
- and of course still having this line commented out:
//typedef uint8_t bool;
I am left with this now:
C:\Users\username\AppData\Local\Temp\build5716230445635923787.tmp\ServoTimer2\ServoTimer2.cpp.o: In function `__vector_9': C:\Users\username\Documents\Arduino\libraries\ServoTimer2/ServoTimer2.cpp:25: multiple definition of `__vector_9' C:\Users\username\AppData\Local\Temp\build5716230445635923787.tmp\adavoice_servo_v1.cpp.o:C:\Program Files (x86)\Arduino/adavoice_servo_v1.ino:507: first defined here collect2.exe: error: ld returned 1 exit status Error compiling.
not really sure what this one is suggesting the issue is?
I am trying to add a servo to a the Adafruit 'voice changer' tutorial/project: (which is working as expected)
I do a search for: "_vector_9" in both .cpp and.h files.. and nothing shows up/is found? (not sure why it is referencing TEMP directories either? (or build logs/files?)
anyone point me in the right direction?
I should have read the code comments better/closer.. :(
I see this now:
// WaveHC library already defines a Timer1 interrupt handler. Since we // want to use the stock library and not require a special fork, Timer2 // is used for a sample-playing interrupt here. As it's only an 8-bit // timer, a sizeable prescaler is used (32:1) to generate intervals // spanning the desired range (~4.8 KHz to ~19 KHz, or +/- 1 octave // from the sampling frequency). This does limit the available number // of speed 'steps' in between (about 79 total), but seems enough.
I thought I had read in another thread/post out there, that they had servos working with Adavoice? (maybe I mis-read?.. or there is some alternate way to achieve this?)
has anyone ever gotten the Waveshield (WaveHC)... working with a Leonardo? or Pro-Micro yet?)