Gemalto is now part of the Thales Group, find out more.

You are here

Using i2c | Thales IoT Developer Community

May 2, 2021 - 6:57pm, 991 views

In the com.cinterion.io.i2c documentation I can find this:

Write Transfer Frame, where a = message ID, AE = Slave Address and write request:

String data = "<aAE000102030405060708090A0B0C0E0F>";

But I am unavailable translate what to do here..

In arduino I have this simple

void MMA8452Q::writeRegister(MMA8452Q_Register reg, byte data) 

MMA8452Q::readRegister(MMA8452Q_Register reg) 

where the slave address is given in MMA8452Q

In my bluetooth I have this

I2cWriteReg8(slave_addr, reg_addr, reg_val) and

I2cReadReg8(slave_addr, reg_addr, reg_val)

So I need an translation in String data = = "<aAE000102030405060708090A0B0C0E0F>";

I do not know wether this is correct:

String data = "<"+reg_addr+slave_addr+reg_data+">";all 8 bit Any help?