2021年3月1日星期一

Add devmem in OpenWRT

make menuconfig

1) Select Global build settings

2) Select Kernel build options

3) Select [*] /dev/mem virtual device support

4) Return to main menu

5) select Base System

6) select <*> busybox

7) select <*>Customize busybox options

8) select Miscellaneous Utilities

9) select <*> devmem (2.5 kb)


Usage: devmem ADDRESS [WIDTH [VALUE]]

Read/write from physical address

    ADDRESS Address to act upon, for example 0x????????
    WIDTH   Width (8/16/...)
    VALUE   Data to be written, for example 0x????????


read 32bit register: devmem address

read 16bit register: devmem address 16

read 8bit register: devmem address 8

write 32bit register: devmem address 32 value

write 16bit register: devmem address 16 value

write 8bit register: devmem address 8 value


沒有留言:

發佈留言