u/UpsetCricket6627

▲ 3 r/embeddedlinux+1 crossposts

MAX96861 I2C register returns changing values after repeated reads (Linux i2c-tools)

Hi everyone,
I’m working on an embedded Linux platform (Qualcomm SA8797) and validating I2C communication with MAX96861 devices.
I have successfully identified the I2C buses from the device tree and confirmed communication with two devices:
MAX96861_1 on /dev/i2c-0 (7-bit address 0x42)
MAX96861_2 on /dev/i2c-9 (7-bit address 0x60)
Communication is working (no I2C errors), but I’m seeing behavior that I don’t fully understand.
For example, on MAX96861_2:
i2cset -f -y 9 0x60 0x00 0x55

i2cget -f -y 9 0x60 0x00
0x34

i2cget -f -y 9 0x60 0x00
0x50

i2cget -f -y 9 0x60 0x00
0x00

i2cget -f -y 9 0x60 0x00
0x41

i2cget -f -y 9 0x60 0x00
0x98
Interestingly, performing the exact same test on MAX96861_1 (/dev/i2c-0, address 0x42) produces a very similar sequence.
I also dumped registers 0x00–0x0F several times and noticed that many registers change between successive reads, even without performing any writes.
I don’t currently have access to the MAX96861 register documentation, so I don’t know whether these are status registers, indirect registers, or whether a page-selection mechanism is required before accessing the register map.
My questions are:
Is this expected behavior for MAX96861 devices?
Do these devices require indirect/page-based register access instead of simple SMBus byte reads?
Could i2cget/i2cset be using an access mode that is not appropriate for this device?
Has anyone worked with MAX96861 and can suggest the correct Linux access method or register sequence?
Thanks in advance for any pointers.

reddit.com
u/UpsetCricket6627 — 9 days ago

Unable to read GPIO

I am setting a gpio to high
After setting when I am trying to read it , it is returning 0. Not the value that I set.

Also i see the direction if the pin is changed to input

reddit.com
u/UpsetCricket6627 — 11 days ago

Unable to read Gpio after setting

I am setting a gpio to high
After setting when I am trying to read it , it is returning 0. Not the value that I set.

Also i see the direction if the pin is changed to input

reddit.com
u/UpsetCricket6627 — 11 days ago
▲ 4 r/embeddedlinux+1 crossposts

/dev/spi* not available

Hi,
I recently joined my current team and am working as a Test Software Developer for automotive hardware components.
Currently, I am working on a task to read ADC values from the SCC. My software runs on the SoC, and reading SCC ADC values requires communication between the SoC and SCC, which is done via SPI.
The OS is linux.
And the OS binaries are recieved from Another team. I am only responsible for the SW interface
As part of the integration, I need to configure the SPI interface in my software. However, I do not see any SPI device nodes under:
/dev/spi*
On the other hand, I do see the SPI device listed under:
/sys/bus/spi/devices/spi21.1

My question is: can this SPI device under /sys/bus/spi/devices/ be used directly for communication, or do I need a corresponding SPI character device (for example, /dev/spidevX.Y) to be available under /dev?
Thanks in advance for your guidance.

reddit.com
u/UpsetCricket6627 — 22 days ago