I2C setting change during Jetson TX2 operation

Hi All,

I developing custom serdes in Jetson Tx2 .

custom serializer intialial setup have to change i2c address type 16bit address to 8bit address.
What process is required to change to 8bit after setting 16bit using devm_regmap_init_i2c function?

Modify below configure in sensor driver.

static struct regmap_config ov5693_regmap_config = {
.reg_bits = 16,
.val_bits = 8,
};

Hi ShaneCCC,

When the custom device is initialized, it uses 16bit address mode once, and from the next initialization i2c _write, it must be converted to 8bit address mode.

The first 16-bit address type i2c_write operates normally through the regmap_config setting value as shown below.

const struct regmap_config thcv241a_regmap_config = {
	.reg_bits = 16,
	.val_bits = 8,
};

How can I convert to 8bit address method during operation set to 16bit address?

Thanks,

Can’t do that during operation.
You can reference to the ov5693.c that read the eeprom that using the 8 bit address.

Hi ShaneCCC,

If modification is not possible during operation,
what function call can I use to terminate the 16bit setting and set it 8bit mode?

Thanks,

Sorry, I am not really understand your comment.
But I think the i2c_transfer() API should be able match your request. You can define the address size and dynamically.