Re-including libraries

Hi,

I am currently in the middle of project where I require the Talkie library, PS2Keyboard library and Servo library. As I am using the arduino uno, I understand there is a clash with using the timers on the board, and I cannot use all three at once. It is also giving me problems with using Serial.readString().

When I comment out the '#include "Talkie.h"' and 'Talkie voice;' at the start of my program, my PS2 Keyboard and the rest of my code works fine. The same is true for when I comment out the PS2Keyboard initialisations.

Is there a way I can include a library, only inside the function that uses it, and then somehow "un-initialise" it?

I am open to any other suggestions on how to get around this.

Can you provide pointers to the "Talkie" and "PS2Keyboard" libraries?

I know the built-in Servo library uses Timer1 so if that is the conflict you can often use the third-party ServoTimer2 library (GitHub - nabontra/ServoTimer2: ServoTimer2 is a simple library for Arduino 1.x that does not use Timer1 in case of a conflict.) in its place.