2017-11-15 07:25 AM
2017-11-22 05:43 AM
What exactly is not working? Do you have the same issue as in this thread ?
https://community.st.com/0D50X00009XkafxSAB
-- pa
2017-11-22 07:10 AM
First, somehow DR (data register is not showing anything), I clean ADDR by reading SR1 and SR3, clean TXE by writing DR twice, but can't get any data to buffer from MXL90614 temperature sensor
2017-11-22 12:44 PM
Well, the code *may be* correct - though it does not use the official STM library for i2c and system clock.
You need to hook a logic analyzer on i2c lines and see what the host sends and what the sensor answers.
-- pa
2017-11-22 12:48 PM
Sure.
It send this. Though according to manual I send DR 2times to clear txe. Address of device 0x5A
.
2017-11-22 01:56 PM
This is a write command because the lowest bit of the address byte (0xB4) is 0. To read, set the lowest bit to 1 (0xB5).
-- pa
2017-11-22 02:22 PM
Shouldn't first I send something to slave - sensor, in order to read what data it should send to the stm8s103?
2017-11-24 06:57 AM
The commands should be explained in the sensor's documentation.
-- pa