TWI_DRV_BUS_CTRL Двухпроводной интерфейс: список регистров 31 |•|•|•|•|•|•|•|•|•|•|•|•|•|•|•|•| 16 15 |•|•|•|•|•|•|•|•|•|•|•|•|•|•|•|•| 00 Unused Bits 31 : 17CLK_COUNT_MODE Bit 16W 0x0 0: scl clock high period count on oscl CLK_DUTY Bit 15R/W 0x1 Setting duty cycle of Clock as Master CLK_N Bits 14 : 12R/W 0x0 TWI_DRV bus sampling clock F0=24 MHz/2^CLK_N CLK_M Bits 11 : 8R/W 0x0 TWI_DRV output SCL frequency is FSCL=F1/10=(F0/(CLK_M+1))/10 SCL_STA Bit 7R 0x1 SCL current status SDA_STA Bit 6R 0x1 SDA current status Unused Bits 5 : 4SCL_MOV Bit 3R/W 0x0 SCL manual output value SDA_MOV Bit 2R/W 0x0 SDA manual output value SCL_MOE Bit 1R/W 0x0 SCL manual output en SDA_MOE Bit 0R/W 0x0 SDA manual output en Команда U-Boot для чтения регистра md 5002210 1md 5002610 1 md 5002a10 1 md 5002e10 1 md 5003210 1 md 7081610 1 Bit fields structuretypedef union twi_drv_bus_ctrl { struct { unsigned sda_moe : 1; unsigned scl_moe : 1; unsigned sda_mov : 1; unsigned scl_mov : 1; unsigned unused0 : 2; unsigned sda_sta : 1; unsigned scl_sta : 1; unsigned clk_m : 4; unsigned clk_n : 3; unsigned clk_duty : 1; unsigned clk_count_mode : 1; unsigned unused1 : 15; } b; unsigned long w; } TWI_DRV_BUS_CTRL |