GPIO on the RockPro64 - all pins high?
#1
Hi everyone,

I'm playing around with my brand new RockPro64 and trying to blink an LED using libgpiod. I have pin 24 hooked up to an LED, and no matter what I do, the LED is (dimly) lit. That's despite the fact that `gpioinfo` shows all the pins:


Quote:gpiochip4 - 32 lines:
        line  0:      unnamed      unused  input  active-high
        line  1:      unnamed      unused  input  active-high
     
        line  23:      unnamed      unused  input  active-high
        line  24:      unnamed      unused  input  active-high
        line  25:      unnamed      unused  output  active-high  # I've been trying to switch this pin on and off.

What's even weirder, every GPIO pin seems to be pushing a few volts out, even the ones marked GND in the diagram (for example, pin 6). To be specific, if I connect a jumper cable from PIN 6 to an LED/resistor and then to ground, the led lights up. 

Did I break something? Is there something I'm missing? I'm wondering if it has to do with u-boot, which I've flashed to SPI in order to support booting from a generic Manjaro image.

Thanks in advance for the help!
Colin
  Reply
#2
That's because you didn't set a pull-down biasmode on the GPIOs, which by default I believe leaves them pulled up.

You can set them to pull-down bias with:

Code:
gpioset --bias=pull-down chipnum pinnum=value

There's probably also a way to set this from the device tree, but I don't know it off-hand.

In short, no, you didn't break anything.

Pin 6 should be an actual ground though, that's suspicious.

Occasional Linux Kernel Contributor, Avid Wiki Updater, Ask Me About Quartz64
Open Hardware Quartz64 Model A TOSLink Adapter
Pi-bus GPIO Extender For ROCKPro64 And Quartz64 Model A
Plebian GNU/Linux
  Reply
#3
(11-01-2022, 10:13 AM)CounterPillow Wrote: That's because you didn't set a pull-down biasmode on the GPIOs, which by default I believe leaves them pulled up.

You can set them to pull-down bias with:

Code:
gpioset --bias=pull-down chipnum pinnum=value

There's probably also a way to set this from the device tree, but I don't know it off-hand.

In short, no, you didn't break anything.

Pin 6 should be an actual ground though, that's suspicious.

Hi, thanks for the help! I redid the wiring and tried your suggestion and now it's working!

What's odd is that connecting the LED to the GPIO GND in the circuit (ie the RockPro64's GND) works, but using the GND on my breadboard (connected to another microcontroller or a common ground, same thing) doesn't seem to work. I guess I'm missing something basic about GPIO or microcontrollers, which is maybe outside the scope of this board.

Thanks again!
  Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  ROCKPro64 with 16 ports SATA controller ZeblodS 19 19,223 12-18-2022, 06:25 PM
Last Post: heyghoge
  Using RPI hat on RockPro64? misterc 0 122 12-16-2022, 02:05 PM
Last Post: misterc
  ROCKPro64 DOA ajtravis 8 3,512 11-08-2022, 03:40 AM
Last Post: ajtravis
  RockPro64 not booting up mvicha@gmail.com 0 406 09-19-2022, 07:35 AM
Last Post: mvicha@gmail.com
  GPIO Expander HAT for ROCKPro64 and Quartz64 CounterPillow 7 2,821 07-18-2022, 10:05 PM
Last Post: zer0sig
  RockPro64 premium aluminium casing justwantin 2 951 05-27-2022, 06:51 PM
Last Post: justwantin
  charging 3 rockpro64 from single source rpt312 1 769 05-16-2022, 02:34 AM
Last Post: dukla2000
  help or suggestions removing RockPro64 Playbox please? jahway603 2 1,152 03-22-2022, 12:17 PM
Last Post: jahway603
  rockpro64 13 megapixel camera Aycaramba 9 9,720 01-24-2022, 02:47 PM
Last Post: solbs
  RockPro64 doesn't boot when PCIe to M.2 adapter is installed Cerberus 3 2,122 11-27-2021, 11:38 PM
Last Post: Cerberus

Forum Jump:


Users browsing this thread: 1 Guest(s)