I have been trying to get this 'One Wire - DS18B20' component to work on my project without success. It worked using FC5. So, I have downloaded the sample Single One Wire Demo and tried to compile that using FC7, same problem. This is what the compiler reports using the Demo file:
The unreachable warning prevents the device from allowing data been read by the PIC. I have checked to see if the bus is active using a scope and data is clearly been sent on the bus, either from the PIC or from the device. Not sure which, the scope does not show this. However, the read-out is always zero. Any help would be greatly appreciated.Registered to: johnsondav
Licence key: XXXXXX
http://www.matrixtsl.com
Launching the compiler...
C:\Program Files (x86)\Flowcode 7\compilers\pic\bin\xc8.exe --chip=16F1937 "SingleOneWire.c" --MSGDISABLE=359,1273,1388
SingleOneWire.c: FCD_0bbd1_OneWire1__Get_Next_ID()
637: break;
^ (345) unreachable code (warning)
.
Memory Summary:
Program space used B26h ( 2854) of 2000h words ( 34.8%)
Data space used B4h ( 180) of 200h bytes ( 35.2%)
EEPROM space used 0h ( 0) of 100h bytes ( 0.0%)
Data stack space used 0h ( 0) of 110h bytes ( 0.0%)
Configuration bits used 2h ( 2) of 2h words (100.0%)
ID Location space used 0h ( 0) of 4h bytes ( 0.0%)
Microchip MPLAB XC8 C Compiler (Free Mode) V1.36
Build date: Jan 14 2016
Part Support Version: 1.36
Copyright (C) 2016 Microchip Technology Inc.
License type: Node Configuration
Dave