1 comment:
ret |= realtek_mst_i2c_spi_write_register(fd, 0xF4, 0x9F);
ret |= realtek_mst_i2c_spi_write_register(fd, 0xF5, GPIO_CONFIG_ADDRESS >> 8);
ret |= realtek_mst_i2c_spi_write_register(fd, 0xF4, GPIO_CONFIG_ADDRESS & 0xFF);
That's a good idea and thanks for identifying the pattern Angel. […]
I forgot to add, the func is almost correct but would be:
static int realtek_mst_i2c_spi_select_indexed_register(uint16_t address, uint8_t val)
{
int ret = 0;
ret |= realtek_mst_i2c_spi_write_register(fd, 0xF4, 0x9F);
ret |= realtek_mst_i2c_spi_write_register(fd, 0xF5, address >> 8);
ret |= realtek_mst_i2c_spi_write_register(fd, 0xF4, address & 0xFF);
ret |= realtek_mst_i2c_spi_write_register(fd, 0xF5, val);
return ret;
}
To view, visit change 46089. To unsubscribe, or for help writing mail filters, visit settings.