Actual processes happening in the i2c while issuing commands to LPCXpresso804 via USB

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Actual processes happening in the i2c while issuing commands to LPCXpresso804 via USB

688 Views
roshanmohammed
Contributor I

@yang_zhang 

Updating firmware is successful when inputting commands from PC to LPCXpresso804 EVK via USB converter.

Example commands are giving below

1) Issue the 8 command to send the GetVerision.

2) Issue the 1 command to update the firmware.

But in actual case we are updating firmware from I.Mx6 based board to MCU. Board has no USB provision for passing commands. So we forced to pass commands directly through i2c. So on updating firmware there are total 8 commands needs to pass. Out of 8 , 5 commands done successfully and after that device is ready to receive the new firmware.

Successful commands are showing below

1. Program the sample application image.
2. Press the Reset button to boot the application image.
3. Issue the f command to pull nHostIRQ low.
4. Press the Reset button to reset the LPCXpresso804 Board.
5. Issue the g command to program nHostIRQ as input.

The other 3 commands are showing below

6. Issue the 8 command to send the GetVersion.
7. Issue the 1 command to update the firmware, and then input the name of Firmware.
8. Issue the b command to BOOT the latest firmware.

We got from the document that the slave address are 0x18, 0x1C, 0x30. we choose 0x18.

As per document, information showing below this much only

roshanmohammed_0-1652855033102.png

When LPCXpresso804 is ready to accept the new firmware , I passed the command i2cdump -y 0 0x18 for reading values

root@imx6ull-iwg18m-sm:~# i2cdump -y 0 0x18
No size specified (using byte-data access)
0 1 2 3 4 5 6 7 8 9 a b c d e f 0123456789abcdef
00: 55 55 55 55 55 55 55 55 55 55 55 55 55 55 55 55 UUUUUUUUUUUUUUUU

 

Then when i tried to write the offset 0x01 to value 0xA1, Writing command is successful but after that while reading again the same data address it is showing the old value. Instead of passing directly through i2c commands, if i am using USB converter and passing command 8 from PC, it is getting a response.

 

So may i know the real process happening on the i2c channel while issuing the commands 8, 1, b? what actually needs to pass through i2c for making it ready? Why not able to read register? What actually happening while passing command 8 from PC to LPCXpresso804 via USB converter?

 

Labels (2)
0 Kudos
Reply
1 Reply

652 Views
CarlosGarabito
NXP TechSupport
NXP TechSupport
0 Kudos
Reply