Jump to content

SPI on rock s0


Go to solution Solved by grixm,

Recommended Posts

Posted (edited)

Hi guys, I got a SPIdev overlay to work on the rock S0, figured I'd just share it here for the record, since I could have used this info myself (I spent days trying to figure it out since I had no experience with device trees or whatnot).

 

Basically, download the attached .dts file, then run

sudo armbian-add-overlay rk3308-spi2-spidev.dts

I also edited /boot/armbianEnv.txt and added this line, but I'm unsure if that's actually necessary?

param_spidev_spi_bus=2

 

This worked on Armbian 24.5.1 Noble, creating /dev/spidev2.0. You can verify that it works using this tool: https://github.com/rm-hull/spidev-test

The dts file is based on this one from radxa, however changed to "fragment@" syntax like other armbian overlays: https://github.com/radxa-pkg/radxa-overlays/blob/main/arch/arm64/boot/dts/rockchip/overlays/rk3308-spi2-spidev.dts

Maybe this will also work on Rock Pi S, but haven't tested.

 

 

rk3308-spi2-spidev.dts

Edited by grixm
Posted (edited)

No I don't think it has ADC. But you can use the numerous SPI or i2c ports to connect an external adc.

Edited by grixm
Posted (edited)

Ty.

I picked up a cheap sda1115 ADC which uses I2C.

Will i2c on the Rock-S0 need an overlay or is it already enabled by default in armbian. Haven't figured out how to test for that yet.

 

NM - it "just works", I didn't have to change anything or add an overlay! 🙂

Edited by Meestor_X
Posted
On 1/6/2025 at 8:06 PM, Meestor_X said:

 

(Got the overlays working finally)

What did you do? I am also experiencing all my overlays breaking after updating the armbian version.

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