Raspberry Pi Pico W LESSON 57: Calibrating a Joystick in MicroPython

Поделиться
HTML-код
  • Опубликовано: 11 сен 2024
  • 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
    In this class we will be using the Sunfounder Raspberry Pi Pico W Keppler Kit. It will make things a lot easier if we are working on identical hardware. the link below is to amazon, and is for the identical hardware I will be using in this entire class.
    amzn.to/3ubMRs1
    In this video, I will show you how to control use a joystick with the Raspberry Pi Pico W using MicroPython. I will show you how to read X and Y values from the joystick. I will then show how to calibrate those raw readings to give more intuitive values for joystick position. After showing this, I will give a homework assignment
    [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. ]
    #raspberrypipicow
    #joystick
    #micropython

Комментарии • 29

  • @rickbonari4493
    @rickbonari4493 6 месяцев назад +1

    Great lesson and love the math. Would like to see an explanation of what the magnitude formula is all about and how the formula was derived. Showing this on your pad like you do with the slope calculations, etc. would be very helpfull. You went over this very quickly.

    • @theamericanhaul331
      @theamericanhaul331 5 месяцев назад

      I believe it is an application of the Pythagorean theorem. If you draw a straight line from any coordinate back to the origin, you can create a right triangle where the base (adjacent side) is your x coordinate, the height (opposite side) is your y coordinate, and the long side (hypotenuse) is the distance or magnitude of the point from the origin. You can then simplify A^2 + B^2 = C^2 to find that C = sqrt(A^2 + B^2)

  • @larryplatzek9017
    @larryplatzek9017 6 месяцев назад +2

    THIS IS ANOTHER GREAT LESSON, THANK YOU PAUL!

  • @edSabio572
    @edSabio572 6 месяцев назад +1

    Thanks Paul! You take math to a new level of usefulness...Ready to use/deploy.
    I am healed and back to your lessons.

  • @deniszawad
    @deniszawad 6 месяцев назад

    Keep them comming. Tanks

  • @TravelTejas
    @TravelTejas 6 месяцев назад

    Congratulations. Keep up the great content.

  • @scottwait3585
    @scottwait3585 6 месяцев назад

    Thank you Paul!

  • @pralaymajumdar1206
    @pralaymajumdar1206 5 месяцев назад

    Learn a lot from every lesson❤..
    Sir, can you please give us the idea of internet of things in future?

  • @squaremarket973
    @squaremarket973 6 месяцев назад

    👍thank you for everything you do. 🍻

  • @crs1548
    @crs1548 6 месяцев назад

    I am legend! For fun, I put a low pass filter in as well.

  • @RenierEngelbrecht
    @RenierEngelbrecht 5 месяцев назад

    Hi there. The pico pi supposed to have a 12bit ADC instead of 16bit ADC. can you possibly elaborate in this statement, as scaling is going to be a bit different when using an OLED for example?

  • @andyprest
    @andyprest 6 месяцев назад +1

    Hi Paul, will there be anymore fusion 360 classes coming up please? Thank you 😊

  • @harshvardhan4771
    @harshvardhan4771 6 месяцев назад

    Lets talk in form of Spherical Coordinates (just because I don't have to define anything, not like I am drawing some analogy here). So, when you say that we have to calculate the angle, do you mean just the θ, or also the ϕ? Because the joystick sitting right at the dead-center, vs it being at the end of the +ve x-axis (equivalent of 0° in the 0°-360° anti-clockwise direction) couldn't possibly mean the same. We have to differentiate it somehow. And hence, we need the angle with respect to x-axis, as well as with the z-axis.

  • @brucemilyko8549
    @brucemilyko8549 6 месяцев назад +1

    Here is my solution to lesson 56. I also added a wire and code to check for the switch in the joystick.
    ruclips.net/user/shortsYT_F6okHYMQ?feature=share

  • @LorisHW
    @LorisHW 6 месяцев назад +1

    Here is my attempt at it: ruclips.net/video/wOh8iXDgdgM/видео.html. Thanks for the lesson Paul!

  • @subhojitbose3678
    @subhojitbose3678 6 месяцев назад

    22:26 "there is no such thing as moving" Most respectfully, why is that sir? I mean let's assume a-b=x then a=x+b, now there are 2 explanation:-
    1. b has moved from left side to the right side changing minus sign to positive.
    2. b has been added to both sides.
    I know both have same meaning, but I believe from your point of view point no 1 is wrong. why??

    • @paulmcwhorter
      @paulmcwhorter  6 месяцев назад +2

      Moving is not a math term. If (y+7)/2 = 6x, can I move the y? can I move the 7? can I move the 2? NO! There is no such thing as moving. The correct math concept is, whatever you do to one side of the equation you do to the other. I could multiply both sides by 2, than I could add 7 to both sides, then I would have y. I did not move anything.

    • @subhojitbose3678
      @subhojitbose3678 6 месяцев назад

      @@paulmcwhorter Thank you

  • @drdentin3215
    @drdentin3215 6 месяцев назад

    My HWruclips.net/video/z09lgS7XtJ0/видео.html. Sorry posted late. I did it almost immediately but did't get it on RUclips. Really! Honest I did!