Question on SMBUS slave transmit with PEC enabled

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello All,

I have the following questions wrt SMBUS PEC support on the SLAVE side,

As we know when Master sends a read request, Slave keeps on
transferring data until STOP/NACK is received from Master.
This means Slave doesn't have a prior idea about how many bytes to
transmit to Master.

Let's say, the Master wants to read 1 byte of data with PEC enabled,
in this case Slave needs to send a total of two bytes (1st byte data
and 2nd byte PEC).
When Master puts this request on Bus, following events will happens,

1. Slave sends 1st bytes
2. Master receives 1st byte and sends ACK
3. Since no STOP is received from Master, slave send 2nd byte (But
Master is expecting PEC bytes as 2nd byte)
4. Master receives 2nd byte and sends NACK/STOP.

This means Slave didn't send PEC byte and is no longer driving the SDA
line to send PEC bytes.
When Master checks PEC it will not match and Master read will fail.

How do we handle this case, what is the expected behavior from Slave
as per SMBUS protocol ?
In this case when should Slave send PEC bytes ?

Please let me know.

Best regards,
Rayagonda



[Index of Archives]     [Linux GPIO]     [Linux SPI]     [Linux Hardward Monitoring]     [LM Sensors]     [Linux USB Devel]     [Linux Media]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux