1. Got a question or need help troubleshooting? Post to the troubleshooting forum or Search the forums!

Undervolted Raspberry Pi

Discussion in 'Troubleshooting' started by sgomes, Dec 15, 2018.

  1. sgomes

    sgomes Active Member

    Joined:
    Dec 29, 2016
    Messages:
    136
    Likes Received:
    57
    Hey folks!

    After rolling out my own software for the R2 and upgrading to the latest Octoprint, I started getting a little icon in the status bar (attached).

    This icon was added in the latest version of Octoprint and indicates when the Raspberry Pi it's running on is undervolted. An undervolted Raspberry Pi still works, but the CPU speed gets throttled, which of course means it gets slower.

    In order to validate the issue I did some research and found a way of checking for throttling via the command line. And sure enough, I can see the Raspberry Pi inside the R2 is undervolted:

    $ /opt/vc/bin/vcgencmd get_throttled
    throttled=0x50005


    (An unthrottled Pi would have returned something like throttled=0x0)

    Is anyone else seeing the same in their R2? I'm wondering if this is some sort of issue with my printer, or if it's a design issue that affects every R2.
     

    Attached Files:

    supercazzola likes this.
  2. mark tomlinson

    mark tomlinson ༼ つ ◕_ ◕ ༽つ
    Staff Member

    Joined:
    Feb 21, 2013
    Messages:
    23,959
    Likes Received:
    7,344
    Probably normal.

    It is not unusual (even on wall warts rated for the Pi) to get that. I don't have an R2 to look at, but the C2 doesn't do this (although they have different power supplies the Pi is connected/powered the same way).

    If you roll back to the stock SD card image does it go away again?
     
  3. sgomes

    sgomes Active Member

    Joined:
    Dec 29, 2016
    Messages:
    136
    Likes Received:
    57
    I can give that a try once I'm done with the current stuff I'm printing, but I don't expect a change there, unless there happens to be a bug in the version of Raspbian I'm running that causes it to misreport things.
     
  4. mark tomlinson

    mark tomlinson ༼ つ ◕_ ◕ ༽つ
    Staff Member

    Joined:
    Feb 21, 2013
    Messages:
    23,959
    Likes Received:
    7,344
    Just ruling out anything software related.
    It is not terribly likely since that is handled at the OS driver level for Raspbian, but needs to be checked :)
     
  5. mark tomlinson

    mark tomlinson ༼ つ ◕_ ◕ ༽つ
    Staff Member

    Joined:
    Feb 21, 2013
    Messages:
    23,959
    Likes Received:
    7,344
    For what it is worth I always see that on Raspbian if I power then from a USB controller.
    If I use a standalone Pi class (i.e. 2amp of better wall wart) then usually it is not there.
     
  6. WheresWaldo

    WheresWaldo Volunteer ( ͠° ͟ʖ ͡°)
    Staff Member

    Joined:
    Feb 18, 2015
    Messages:
    5,905
    Likes Received:
    3,593
    The rPi while it can run on USB power by default it will display the lightning bolt icon indicating it is underpowered. In the past you would only see this on the rPi Linux command line display, but if OctoPrint added it to show through then that is a good thing. Also you can disable it by a prompt added to /boot/cmdline.txt, I just forget which one exactly and can't look it up today.
     
  7. mark tomlinson

    mark tomlinson ༼ つ ◕_ ◕ ༽つ
    Staff Member

    Joined:
    Feb 21, 2013
    Messages:
    23,959
    Likes Received:
    7,344
    Then there was this. Came with a recent purchase... I *think* they mean you *might* be using older software :)

    Pi3B.jpg
     
  8. sgomes

    sgomes Active Member

    Joined:
    Dec 29, 2016
    Messages:
    136
    Likes Received:
    57
    It seems that Robo knows that the Raspberry Pi inside the R2 is undervolted. They added a line to /boot/config.txt in RoboOS to hide that fact:

    # Remove lightning/rainbow icon from screen (added by victor)
    avoid_warnings=1


    That's why the lightning bolt icon doesn't show up in the official firmware. That's the wrong way to fix things, Victor ;)
     
    supercazzola likes this.
  9. mark tomlinson

    mark tomlinson ༼ つ ◕_ ◕ ༽つ
    Staff Member

    Joined:
    Feb 21, 2013
    Messages:
    23,959
    Likes Received:
    7,344
    sgomes likes this.
  10. mark tomlinson

    mark tomlinson ༼ つ ◕_ ◕ ༽つ
    Staff Member

    Joined:
    Feb 21, 2013
    Messages:
    23,959
    Likes Received:
    7,344
    We used another (car style for 12v input) on some of them that had 12v supplies. The above one works well for this application since it doesn't require 12v. It will work on the c2 (19v) and the R2 (24v)

    Honestly I think most electrical designer types get surprised by how much load the Pi can add. It can easily demand 2 amps off the 5v supply and that will "sag" the ones not actually rated at more than 2 amps enough so that the APX803 chip (which monitors voltage on the Pi) will trigger a low-voltage condition. It samples a lot and it only has to see it infrequently sag enough to raise the issue.
     
    #10 mark tomlinson, Dec 21, 2018
    Last edited: Dec 21, 2018
  11. mark tomlinson

    mark tomlinson ༼ つ ◕_ ◕ ༽つ
    Staff Member

    Joined:
    Feb 21, 2013
    Messages:
    23,959
    Likes Received:
    7,344
    If I plug a Pi into most computer USB connections it will invariably show "low voltage" :)
    Very few PC USB drivers will source that current and not drop enough to trigger it.
    Some will, but most will not. I have even had it sag a powered USB hub ... go figure. In fact I have one sitting on my desk now that is running from a powered hub and ... sure enough it shows the lightning bolt. Most hubs are not expecting that strong of a pull on the current either I imagine.
     
  12. WheresWaldo

    WheresWaldo Volunteer ( ͠° ͟ʖ ͡°)
    Staff Member

    Joined:
    Feb 18, 2015
    Messages:
    5,905
    Likes Received:
    3,593
    I use a 2.4A USB charger and don't have that issue with the rPi I have set up for my UniFiPi server. I ignore the error in the Robo. The undervolting isn't really an issue if you don't plug in a flash drive or use WiFi.
     
    Geof and mark tomlinson like this.
  13. mark tomlinson

    mark tomlinson ༼ つ ◕_ ◕ ༽つ
    Staff Member

    Joined:
    Feb 21, 2013
    Messages:
    23,959
    Likes Received:
    7,344
    Yea, the ones I have dedicated wall-warts for are fine (no lightning bolt) :) The ones in the OctoPi boxes we did for the R1's are fine too.
     
    Geof likes this.
  14. RoboticsRob

    RoboticsRob Member

    Joined:
    Oct 11, 2018
    Messages:
    60
    Likes Received:
    19
    I ran into this issue over the weekend while replacing the software stack on my R2’s. Had to run the pi off an external supply to get Octoptint to update and install plugins.

    Those voltage step downs, has anyone added them in their R2? Looked at the board and looks like the best place might be to solder them to the power switch leads/pads, unless there’s a 24v header that I missed and can supply enough current.
     
    supercazzola likes this.
  15. supercazzola

    supercazzola Active Member

    Joined:
    Jun 1, 2017
    Messages:
    424
    Likes Received:
    111
    What did you wind up doing? I am in the same boat now, wanting to run standard Octoprint, but can't install the plugin for the touch screen since it sees the undervoltage? I do not mind running the pi off of a wallwart if I have to, but if there is a way to use one of the converters Mark suggested, I would. Where does the microUSB connector in the R2 get it's power from in stock model ?
     
  16. mark tomlinson

    mark tomlinson ༼ つ ◕_ ◕ ༽つ
    Staff Member

    Joined:
    Feb 21, 2013
    Messages:
    23,959
    Likes Received:
    7,344
    You can get an official Pi power supply (wall wart) and run it into the back/bottom of the printer.
    The converters we used (from that link) we powered from the DC brick that came with the printer (tapped it off of where it lands on the control board in the printer on the C2 -- the R2 should be very similar)

    I can get pictures/details from our C2 if you need. The R2 supply is slightly different but I imagine the internal wiring is similar
     

Share This Page