![]() I know this because the 98 and 97 values match up with the default values that should be at address 0x0001 and 0x0002.Ĭan anyone tell me what I am doing wrong here and how I can access register 0x09? I think i am using the proper u-boot syntax, but clearly something is not right here. My suspicion is that this is just reading the first 16 addr values starting at 0x0000. The PHY register is 0x09 (I am not sure how this fits in to the picture, but that may be the reason I am having issues) Remember to recompile boot.cmd to boot.scr and note that changes will come into action after second boot. You can do this by adding saveenv command at the end of boot script (boot.cmd). The address of the 16 bit register I am trying to read/write from is Parameters regarding video must be saved into U-Boot environment file since they must be read before reading boot script. Get Version(2) 0x01 Gets the protocol version. I2C bootloader commands Commands(1) Command code Command description Get(2) 0x00 Gets the version and the allowed commands supported by the current version of the protocol. The slave address of this part is 1011_111 = 0x5F commands instead of equivalent regular commands whenever possible. The following screenshot is of the register that I am trying to read/write to: I have a KSZ9897 Ethernet switch, and my goal is to use u-boot i2c commands to set bits to 001 to put the switch in the proper test mode. In the above in register 0x01, the 0xd0 value is the correct device version and device ID code of the re-timer IC.I am a new to linux/u-boot and just generally reading and writing to specific registers. Read the first 16 registers values of the I2C device at hardware address 0x18 on channel fiveĠ000: 00 d0 00 00 01 0f 00 05 00 00 00 00 00 00 00 00. The 0x0d is channel five: om the mux's data sheet, this sets the B3 enable bit and the B2-B0 channel number. Here address 0x00 was chosen but any value can be used to select the mux's only register, its Control Register. In the above example "i2c mw 0x77 0x00 0x0d" selects the mux at I2C address 0x77 and writes 0x0d to the Control Register which in turn selects channel 5. ![]() Valid chip addresses: 18 19 1A 1B 66 67 77 ![]() Now probe for devices on the mux's channel five Valid chip addresses: 19 1B 1D 36 37 50 51 53 55 57 66 67 68 77įrom the schematics we know that 0x77 is the address of the mux and that the re-timers are connected to channel five of the mux. Now that we've selected the first I2C controller, list what device addresses are there But each variable can have only one value, so once you change (and save) a variable, the default value is gone (unless the saved environment is found to. The various environment variables, especially bootcmd, can be assigned a default value. Select I2C bus 0 which is the LS2088A I2C1 controller U-Boot commands can be enabled or disabled by configuration, but not redefined (unless code is modified). See what I2C buses are available (the LS2088A has four I2C controllers) For example, to access the XFI Ethernet re-timer I2C devices on channel 5 of the mux, you need to first set the mux to channel 5. The LS2088A device has four I2C controllers and on the LS2088AQDS development system, the PCA9547 mux is connected to I2C1 at address 0x77. valid command in uboot is i2c mw 0x50.0 AA 1 >times of reading. ![]() To access the I2C devices on one of the eight channels of the mux you must first set the mux to the needed channel. So you could use ‘mw’ to setup an area of memory with the right contents or even hexedit a file on your host and then load the file to memory, write the memory to EEPROM. Our 32 patches patch series adding TPM 2. So we implemented, contributed and upstreamed to U-Boot support for TPM 2.0. Back when we worked on this topic in 2018, there was no support for TPM 2.0 in U-Boot, but one of customer needed this support. Many development systems use the NXP I2C mux to increase the number of devices on a I2C channel. Bootlin’s contribution: U-Boot support for TPM 2.0.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |