Raspberry Pi LESSON 18: Using a Joystick With the Raspberry Pi
Вставка
- Опубліковано 21 жов 2024
- Announcing the Most Awesome Raspberry Pi Lessons of All Times! This time we RUMBLE!
In this class series, we will be using the most excellent Sunfounder Ultimate Raspberry Pi kit, available here: (Affiliate Link)
amzn.to/3tSk9Mo
or for our UK friends, amzn.to/3I5d401
In this lesson I will show how to incorporate a joystick into your raspberry pi projects. This will require use of the ADC0834 Analog to Digital Converter, which we have covered in other lessons.
If you want to grab those cool little straight jumper wires I am using to keep my breadboard builds neat and clean you can snag a box of them here:
amzn.to/36NyfHq
If you guys are interested in the oscilloscope I am using, you can pick one up here (affiliate link):
amzn.to/3v13Mhl
You guys get your hardware ordered so you can follow along at home!
You will also need a Raspberry Pi. I suggest the Raspberry Pi 4. If you do not already have one, this is the most suitable gear I could find:
amzn.to/3pBMfKm
The Raspberry Pi's are sort of pricy right now, so you can look on ebay or elsewhere to see if there are any deals. You will need a SD card. If you do not already have one, this is a good one:
amzn.to/3KcXTn2
I like using a wireless keyboard and mouse to have fewer wires. You can certainly use your USB keyboard and mouse, but if you want a nice wireless one, this one works on the pi. We demonstrate this by using a button switch to control a LED.
amzn.to/36Rv9Sk
You guys can help me out over at Patreon, and that will help me keep my gear updated, and help me keep this quality content coming:
/ paulmcwhorter
[Disclosure of Material Connection: I am a participant in the Amazon Services LLC Associates Program, an affiliate advertising program designed to provide a means for sites to earn advertising fees by advertising and linking to amazon.com. ]
#GPIO
#SERVO
#RASPBERRYPI
I just realised that you are using a different shirt for each course. Cool visual way to find the correct course in youtube. Amazing tutorials, many thanks.
Glad I found this series after you finished it. Now I can binge watch it instead of waiting a week for each new video :D
Hi Paul, great tutorial very concise and straight to the point! I wanted to ask, Is it possible to use the joysticks in Retropie as I am building a handheld console. I have made one before but using only push buttons and I programmed those using the terminal in Retropie but wondered how to program the joystick. Would I need to use Python as you did in Raspbian OS and somehow dual boot into retropie after and it should work?
Thanks for lesson :)
Thanks Paul. Looking forward to putting the joystick into operation.
that was indeed FUN, Paul... thanks for that intro to Joysticks... looking forward to incorporating this module / lesson later on ... God bless... onto the next exciting lesson... 😉
Have fun!
Paul, thanks for the joystick introduction and explanation. My program would not run at first although it was fine on lesson 15 where you used "from time import sleep" line instead of "import time" The screen came up "GPIO Good to Go" but did not any joystick data. When I used "from time import sleep" and "sleep(.2)" for the delays everything worked fine. Not sure why? Note I am on Python version 3.9.2 and adjusted my library location for the ADC0834 to suit.
Great lesson as always!
Another excellent lesson - Many thanks :)
Many thanks for another great video lecture. Really enjoyed it.
Great lesson !
This is another great lesson! Paul your SERIES are GREAT!
Glad you like them!
Good work Paul thanks
Great video 🤙
Hi Mr.Paul ...
One simple question for you .How conect two joystick? if we have only 3 chanels on ADC 0834?
Hey, Paul! Another great lesson. Your superior teaching skill enabled me to recognize that you missed the KeyboardInterrupt command:)
Excellent!
Great lesson... I have a question, is there a way to use GPIO.PUD_DOWN when setting up joystick's button? I couldn't make it work and had to stick to GPIO.PUD_UP
wondering if you could do a series about Micro controllers AVR and Microchip Studio 7?
I have a question Paul, is it safe to use 5V even though raspberry pi is a 3.3V device. Should I use 3.3V just to be safe or would that not work?
Great video as are all your video’s have been, my OCD is killing me with the blue - used as positive and red + as negative. LOL
Good quick lesson on use of the joystick. I am disappointed in the small useful range of the joystick. At least I can read 0 to 255 on my unit! Thanks for another most-excellent lesson Paul.
Yes, when the useful range of motion is low like this, it makes precise control difficult. In these kits the components let us learn how to do things, but if I was going to really make a game or robot, I would buy better joystick.
Somewhat off topic, can't find Fusion lessons 8 and 9. Could you please date stamp these? Very confusing if there is more than one series.
I HAVE THIS EXACT SAME ONE!!!
Hello Mr Paul. Could you please make the Arduino Robotics Lesson 19 with the obstacle avoidance until September? You would help me with my Thesis. Thank you.
love it
Waiting
I don't watch any cat videos, but I seem to spend an inordinate amount of time watching a 3D printer print.
I struggle with the same issue. I cant just walk away, I sit and watch it. I think it is mesmerizing.
Takk!
Thanks, really appreciate the support.
hi
Very disappointing lesson - not an alien in sight🚀🚀
So true! Well, actually you're the alien... What planet do you come from?