I have been watching on YouTube "Raspberry Pi Pan Tilt Camera Guide"by TuckerShannon how to control a kind of pantilthat using arrow keys. It differs from Pimoronis pantilthat in such way that servos are connected directly to GPIO-pins 7 and 11 and running pantilt.py using arrowkeys. I have been struggling last four days to get it alive. I get camerapreview, I can see up-down-left-right on he screen, pushing “p” takes a snapshot. Everything else works except servos are NOT moving. I think the problem is related to get servoblaster installed correctly. The pantilt.py script contains two rows that confuses me:
#use code “python pantilt.py” after you cd into the correct folder!
“#activating servo blaster (servod must be in the same folder as this script!)”
I have used a fresh Full Stretch 2017-11-29 and installed pantilthat OneLine Installer and PiBits servoblaster from GitHub which all seem to install correctly, but thats my impression I could be mistaking on this point. “ls /dev/servoblaster” is ok also sudo ./servod show list of available GPIO-pins.
Trying command line “echo N=100 > dev/servoblaster” doesnot move any servo for testing purpose. (N refers to GPIO# in servod listing).
The YouTube video refers back to 2016 when Stretch was not released ? Could that be my problem ?
I am using the Pimoroni complete pantilthat board on top of RPi3B, servos connected to the board. Is that a problem ?
Any guidance appreciated…
Thanx In Advance
calleblyh
PanTilt HAT uses a PIC-based servo driver, and the servos themselves are not directly connected to any GPIO pin on the Pi. It wont work with servo blaster (deliberately so, since the Pi is terrible at controlling servos).
You would have to modify the code to control PanTilt HAT via the driver, or via the Python library.
I am also doing the same project… Same problem has occurred to me and when i go to the site you recommended to change the servod.c file… It seems to be already modified as specified. I think there is problem with connection of servos to the specific pins… I am using same connection given in that YouTube video. Can you help me to provide information about connections between servos and GPIO pins and any website information where I can execute pan/tilt using GPIO, servoblaster and keyboard keys to control the servo?.. Thank you
And also tell me how may degrees can i rotate both pan and tilt… And how to change it. One more thing is that my picam led light is blinking but no camera interface opened… I can’t able to view the camera interface terminal… Do you have any idea where the problem lies?
I will get back to you later. Right now I am away from home and dont have access to my equipment. In the meanwhile please inform me which version OS you are using. Mine is based on Jessie back in 2018. And next have installed PiBits / Servoblaster alreadynngi