THUNDER_POINTER is a joystick-controlled dual-servo system designed for the ESP32. It provides smooth two-axis movement and can optionally control a laser diode.
I have used AI to learn some of the basics of C++ because I am new to this language.
THUNDER_POINTER is a joystick-controlled dual-servo system designed for the ESP32. It provides smooth two-axis movement and can optionally control a laser diode.
I have used AI to learn some of the basics of C++ because I am new to this language.
I made a joystick-controlled servo pointer that I like to call THUNDER POITER. The hardest part of the building process was the coding probably because I am more of an electrical and mechanical guy rather than a programer but I managed. I also saw that the Raspberry Pi, I was trying to run the project on, was limiting my abilities so I bought an ESP32 and it works. I am really happy with the results and its amazing how it all started with an ideal and a dream and now I have it finished.
My items package arrived and included - ESP32s x2, Laser Diodes x3, DC Plug x1. I am really happy that the items arrived because they, especially the ESP32s, will unlock new possibilities like, using the Arduino IDE app which is much better than the laggy SHH I was using before with my Raspberry Pi. Also this allows me to start doing my programming on C++ which is much, much, more faster that Python!
Anyways, I have been trying out the capabilities of my new microcontroller and I am really pleased with what I was able to do, having in mind the short experience I have with it:
Log in to leave a comment
Today I did some more research and it turns out that it is not possible to control servos with C++ on a raspberry pi the way I imagined it. So I purchased two ESP32s. I did my research and I found that they are great for this kind of stuff and for future projects. I expect them to arrive soon but till then I will be converting my .py code to .cpp that is what the ESP32 uses. For that I installed the Arduino IDE cause I read that is the best GUI for this microcontroller.
P.S. I did, or at least tried, to do some cable management and I also purchased three laser diodes to attach to the THUNDER POINTER.
Firstly I tried to program PID but I failed miserably and gave up (only for now). So I decided to redo my code in C++ because my cousin told me it is MUCH faster than python. I did use AI for the conversion but I also spend like two hours studying it. I made comments on almost every function and if statement. I can say that I am starting to know the basics of C++ and I can’t wait to be able to actually use it for PID!
Log in to leave a comment
I am so happy with the progress I made today :D. I was able to run both of the servos: ( X –>; and Y –> ), at the same time. This is thanks to the custom external power supply I soldered for one of the servos.
As I said in the previous declog, the code was almost a copy and paste though I had to tweak some parameters. I also started to work on some stick drift calibration but haven’t tested it, yet.
Log in to leave a comment
Today I was able to control my X servo and I also got 180 degrees of rotation (which is the maximum for the SG92R. I am really happy that succeeded to do that because the code for the Y servo will be almost like a copy-paste. Though my servo really jitters a lot so that is something I should fix. And I really need to buy some type of a wall adapter so I can power my servos separately from the raspberry pi.
Overall really happy till now and can’t wait for tomorrow to see what if I can start up the Y servo right up.
Log in to leave a comment
Today I worked on my code trying to make it to move ONE of my TWO servos and it worked but not how I wanted it to. Instead of getting a 0 to 180 degree action I was able to get like only have of it so that is something to put on the list for fixes. Another thing is “noise”. I think there is something disturbing the servos input because it doesn’t stop vibrating when I try to run the program.
Overall I am happy with what I did today and I can see that it is starting to come all together! :D
Log in to leave a comment
Today I was able to print the TPU cover I designed yesterday. Unfortunately it didn’t work because it was too thick so I should make it thinner. I also managed to get my code to work. For what it is, is not much but I am still happy because it works and it took me a lot of time and effort to write it.
What my project can do, for now ofc, is that it converts the analog output from a Joystick to a digital using a ADC7830. Then the code reads the output and prints it in the console.
Today I wrote some code which I haven’t tested, yet. That’s because my Raspberry Pi is not responding :(. Though I hope I can test it tomorrow. I also designed a TPU Cover for my joystick holder.
Log in to leave a comment