The Factory | Device drivers with Raspberry Pi Pico PIO

แชร์
ฝัง
  • เผยแพร่เมื่อ 7 มิ.ย. 2024
  • The Raspberry Pi Pico has a wonderfully flexible feature called PIO that we can use to craft custom, non-blocking device drivers. We're working on a new load-cell ADC project in #TheFactory, and the serial protocol is a little unusual - the perfect case for PIO! We'll walk through the protocol and show you what we came up with.
    If you have any questions about this content or want to share a project you're working on head over to our maker forum coreelec.io/forum
    Core Electronics is located in the heart of Newcastle, Australia. We're powered by makers, for makers. Drop by if you are looking for:
    • Raspberry Pi core-electronics.com.au/raspb...
    • Arduino core-electronics.com.au/ardui...
    • Sparkfun core-electronics.com.au/brand...
    • Adafruit core-electronics.com.au/brand...
    • Pololu core-electronics.com.au/brand...
    • DFRobot core-electronics.com.au/brand...
    The following trademarks are owned by Core Electronics Pty Ltd:
    "Core Electronics" and the Core Electronics logo
    "Makerverse" and the Makerverse logo
    "PiicoDev" and the PiicoDev logo
    "GlowBit" and the GlowBit logo

ความคิดเห็น • 17

  • @andrewowens5653
    @andrewowens5653 2 ปีที่แล้ว +7

    Thanks guys, I was literally just about to start working on that code for that sensor for a project I'm working on. I turned on TH-cam and it was magically at the top of the page. Cheers!

    • @aakashjana6225
      @aakashjana6225 ปีที่แล้ว

      Machine Learning magic after all!

  • @WACkZerden
    @WACkZerden 10 หลายเดือนก่อน

    cool demonstration!

  • @romiolover6852
    @romiolover6852 2 ปีที่แล้ว +1

    Great tutorial.

  • @MrAlFuture
    @MrAlFuture ปีที่แล้ว

    This was great! I'm a bit late seeing it but that was such a clear, useful and practical explanation and example of writing for and using the PIO for good. Thanks!

    • @Core-Electronics
      @Core-Electronics  ปีที่แล้ว

      Glad you enjoyed! PIO is pretty esoteric, so it's nice to have plenty of practical examples out there 😀

  • @andrewowens5653
    @andrewowens5653 2 ปีที่แล้ว +3

    Perhaps you can do a quick follow-up video on how to use multiple load cells together. In other words is there a way to wire up the load cells to a single analog to digital converter chip?

    • @Core-Electronics
      @Core-Electronics  2 ปีที่แล้ว +2

      Hey Andrew 😃 If you want to read separate load cells individually it would be best to use separate ADCs. Multiple instances of this state machine can be instantiated to handle multiple ADCs. Otherwise - If you want to read multiple load cells and *combine them for a single weight* look into using a "combinator". These are used when you want to measure the weight of a load, but you can't guarantee it'll be placed in the exact middle of a scale's tray.

    • @gautombose4172
      @gautombose4172 2 ปีที่แล้ว

      Multiple Analog Load cells connect together (shunt), via a junction box, as simple as that. What I would like to know is, "can the HX710/HX711 be in the heart of a Weighbridge/Large Platform, Indicator (using 4 to 6 load cells)?"

  • @mohinderkaur6671
    @mohinderkaur6671 ปีที่แล้ว +1

    Link to the PIO code for this please!

  • @RamjetX
    @RamjetX 2 ปีที่แล้ว

    I haven't yet tried... but I'm assuming you can sm.active(0) to stop the state machine. And perhaps then reassign new SM function by having a different ASM def for the PIO and ... re-initialise the sm again with the line 24 init sequence but reference a new Def for the PIO to change function?
    Is that possible?

  • @gautombose4172
    @gautombose4172 2 ปีที่แล้ว

    Thank you for this excellent video. This is raw data with no feedback (such as in Sigma Delta Converter). Is it possible to introduce some sort of Software Digital Filter, (such as rollover averaging filter etc) to make the data more tame.
    Should one wishes to make a weighing scales using HX710C/HX711, how many parts accuracy can one expect ?

  • @gautombose4172
    @gautombose4172 2 ปีที่แล้ว

    Just wondering if the program is trying to read the Data at the very instance it makes the Clock Low. Perhaps, you could demonstrate that it makes no difference, if you put an additional delay [1] when you make the clock low and then, read the Data Pin. If you change the code slightly, e.g. ..... nop() .side 0 [1] and the on the next line write .... in(pins,1).
    It may be possible to see, the result, on the scope on the screen.

  • @victorldunn9638
    @victorldunn9638 2 ปีที่แล้ว +1

    "finely calibrated thumb" 😂

  • @gautombose4172
    @gautombose4172 ปีที่แล้ว

    Can you do video on RPI Pico C/C ++ debug under window10, that works?

  • @digmatology
    @digmatology 2 ปีที่แล้ว +3

    Sorry unsubing every channel until the dislike button works again. No dislike? No like!

  • @MichaelKingsfordGray
    @MichaelKingsfordGray ปีที่แล้ว

    Dreadful coding!