i2c

A command of the separate bcma command line; see Commands for other chip families.

I2C control user interface.

i2c show
reset <chan>
read saddr <comm> <len>
readw saddr <comm>
readb saddr <len>
write saddr <comm> <data>
writew saddr <comm> <word_data>
writeb saddr <byte_data>

Built-in help

show
    - show devices found and their attributes.
reset <chan>
    - reset I2C controller channel <0|1>.
read saddr <comm> <len>
    - generic interface to read devices, do probe first
readw saddr <comm>
    - generic interface to read one word from devices, do probe first
readb saddr <len>
    - generic interface to read devices without register based access,
      do probe first
write saddr <comm> <data>
    - generic interface to write a byte to devices, do probe first
    - comm is data when writing directly otherwise command register
writew saddr <comm> <word_data>
    - generic interface to write a word to devices, do probe first
    - comm is data when writing directly otherwise command register
writeb saddr <byte_data>
    - generic interface to write a byte to devices, do probe first

Built-in examples

show
readb 0x27 1
read 0x5c 0xe6 1
readw 0x5c 0xe7
write 0x73 0x8 0x8
writeb 0x71 0x2