This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

EK-TM4C129EXL: I2C_transfer API in non task function

Part Number: EK-TM4C129EXL

Hello,

i2c_transfer API is in non - task thread. Am calling that fthread from task thread. During execution, program exits in I2C_transfer step. Can anyone point in right direction?

can't post the actual code now. but it looks something like this.

Void TaskFxn()

{

I2C_Read(I2C_Handle handle, uint8_t deviceAddr, uint16_t regAddr, uint8_t *data, size_t length);

}

void I2C_Read(I2C_Handle handle, uint8_t deviceAddr, uint16_t regAddr, uint8_t *data, size_t length)

{

i2c_transfer();

}

main()

{

task_create(TaskFxn);

}