Jump to content

Recommended Posts

Posted

Hi,

 

Running on Armbian_community 24.8.0-trunk.529 Bookworm with Linux 6.6.43-current-sunxi64 onthe orangepi zero3

And need to use the GPIO pins with python, not an expert here but have tried a few recommandations with no luck.

Can anyone suggest method that works with the above OS/build please?

 

Thanks!

 

Rob.

Posted

Yes I did thanks with no luck, I've since moved away from using the GPIOs.
Have an embedded PIC micro for this project hence I've moved all GPIO functions to this and used  serial comms from the orange to this micro to kick off the GPIO stuff.
But the good part that I did pick up was that the orange has TWO serial ports which the original doc. only said it had one. Hence that came in super handy!!


Rob.

Posted

I might need to use the serial port pins, instead of USB-serial adapters.

 

What did you activate in system>hardware? (or post your armbianEnv.txt)

 

Can the 2 serial ports work with 230400 baud? (lidar snesors) Can they work with pyserial?

Posted

Hi,

Not sure about those speeds, I'm running "slighly" slower @19200 🙂

Here's what inside  armbianEnv.txt:

Used verbosity=1
bootlogo=false
console=both
disp_mode=1920x1080p60
overlay_prefix=sun50i-h616
rootdev=UUID=f7af041d-782e-4204-ac39-37060a9a922b
rootfstype=ext4
overlays=uart2-ph uart5-ph
usbstoragequirks=0x2537:0x1066:u,0x2537:0x1068:u

Posted

Thank you!

 

The first serial port is the debug serial port (probably UART2), the second is UART5 in the 26 pin terminal.

 

Are you able to use UART2? I think it would only be owned for boot up messages and a bash session.

Posted

No probs. 

You can use all three actually, I'm pretty sure  ttys0 is the debug port. 

But in my instance I'm using the two ports on the 26way connector s1&s2 for general comms. Via pyserial

And debugging via the three pin debug port which is s0. 

Posted

Don't have the pin out in front of me but yes, unfortunately shared with other comms protocols spi & i2c.  Never explored the other header, think it's a 10way. But wonder if they could be used as well for comms.  

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...

Important Information

Terms of Use - Privacy Policy - Guidelines