Dear Ti:
when I write some snipped in sensor controller studio, it show error but has no reason, pls help me!
code as below:
( I also try replace the U16 type by output variable, but the error still here...)
thank you!
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.
Dear Ti:
when I write some snipped in sensor controller studio, it show error but has no reason, pls help me!
code as below:
( I also try replace the U16 type by output variable, but the error still here...)
thank you!
the define of readDatas() as below:
macro readDatas(addr,buf,len) { spiBegin(AUXIO_SPI_CSN_INVNCS); spiTx8bit(addr|0x80); for (U16 n = 0; n < len; n++) { spiRx8bit(buf[n]); } spiEnd(AUXIO_SPI_CSN_INVNCS); }
Hi,
The syntax for Sensor Controller code is not as permissive as other languages like C.
I would recommend to take the lines you have written one by one in order to identify the issue. I would start with the line 31 and avoid doing "aCount * 8" in the macro call - I would rather do this before, leveraging a local variable.
Best regards,