Please enable javascript, or click here to visit my ecommerce web site powered by Shopify.
Jump to: navigation, search

Rock3/extlinux

< Rock3
Revision as of 03:55, 8 November 2022 by Nascs (Talk | contribs)

Common Hardware Interfaces, I2C, PWM, SPI, UART, CAN, etc

This page teaches how to enable overlays in file /boot/extlinux/extlinux.conf. The directory /dtbs/4.19.193-53-rockchip-gc36f859f0a63/rockchip/overlay/ includes overlays you can enable, to enable overlay, we just need add an absolute path of overlay after the key word fdtoverlays, there is a space between each overlay and a space between fdtoverlays and overlay's absolute path, for example,

fdtoverlays  /dtbs/4.19.193-53-rockchip-gc36f859f0a63/rockchip/overlay/rk3568-fiq-debugger-uart2m0.dtbo /dtbs/4.19.193-53-rockchip-gc36f859f0a63/rockchip/overlay/rk3568-disable-npu.dtbo  /dtbs/4.19.193-53-rockchip-gc36f859f0a63/rockchip/overlay/rk3568-spi3-m1-cs0-spidev.dtbo  

The examples above indicates that rk3568-fiq-debugger-uart2m0 and rk3568-disable-npu and rk3568-spi3-m1-cs0-spidev and are enabled

To enable I2C, PWM, SPI, UART, CAN, etc, please see RK3566/RK3568 Available Overlay (ROCK 3A, ROCK 3B, Radxa CM3) part of Device Tree Overlays

I2C

To enable I2C-2 (/dev/i2c-2), add item "rk3568-i2c2-m0" to the "overlays=" line.

 overlays=rk3568-i2c2-m0

To enable I2C-3 (/dev/i2c-3), add item "rk3568-i2c3-m0" to the "overlays=" line.

 overlays=rk3568-i2c3-m0

PWM

PWM0
Option 1: PWM0-M0

To enable PWM0-M0, add item "rk3568-pwm0-m0" to the "overlays=" line.

overlays=rk3568-pwm0-m0

The related directory /sys/devices/platform/fdd70000.pwm/pwm/pwmchip* will be created. And you can do the operation in the directory.

Option 2: PWM0-M1

To enable PWM0-M0, add item "rk3568-pwm0-m1" to the "overlays=" line.

overlays=rk3568-pwm0-m1

The related directory /sys/devices/platform/fdd70000.pwm/pwm/pwmchip* will be created.

PWM1
PWM1-M1

To enable PWM11-M1, add item "rk3568-pwm1-m1" to the "overlays=" line.

overlays=rk3568-pwm1-m1

The related directory /sys/devices/platform/fdd70010.pwm/pwm/pwmchip* will be created.

SPI

UART

System default enable uart2-m0 (/dev/ttyS2) to be debug console.

 overlays=rk3568-fiq-debugger-uart2m0

If you want to enable uart2-m0 (/dev/ttyS2) to be normal console, modify item "rk3568-uart2-m0" to the "overlays=" line.

 overlays=rk3568-uart2-m0

CAN

I2C

PWM

SPI

UART

CAN


I2C

PWM

SPI

UART