It looks like the code is stuck in the constructor or something similar.
Can you share a link to an example program or library of the DS1820 what you use?
Did you check the serial output of the crash report?
I added the swo lib to add some debug printing. Now I can see the programs keeps running and is printing messages in the swv console. With no sensors connected yet I see the line saying so being printed in the swv.
Then I see the expected “start display” line being spit out. So far everything is ok.
But still no display.
To get the display working I have to comment out the Enumerating sensors code.
I get a strong feeling the onewire lib is conflicting with the lcd hardware.
You are probably right in that wait_ms is not compatible with mbed threading.
And I know I will need parralleel treads for my final project.
So I replaced all ‘wait_ms()’ for thread_sleep_for(ms) in ds1820.ccp
Also replaced the HAL_Delay in main. Better keep with one system.
I added rendering the display once before the sensor enumeration also, just to see what happens.
Still no display though.
But look at the output in my SWV:
These output errors are rare, but the do exist.
Maybe be something going wrong with timing are thread scheduling?
By the way, while I had the situation where the displayed image slowly turns into noise,
Most of the builds, including this latest one, the display is simply blank.
At this moment I am moving from the online compiler to PlatformIO in Visual Code.
In parallel I will create a project here using the MaximInterface libary, to see how that turns out.
It seems the problem is not any DS1820 library but about the BSP library is not friendly with Mbed’s delay functions/methods (thread_sleep_for(ms); ThisThread::sleep_for(ms);) and the HAL_Delay(ms); must be used. Maybe someone clever could explain this to us.
However you can try to import this example DISCO-F746NG_OneWire .