18F4620 and SHT11 problems
Hi Members,
I've been using a 16F877 successfully interfaced to a SHT11 humidity sensor - PortC.3 for Data and PortD.0 for clock.
I had cause to upgrade to a 18F4620 but can no longer get meaningful data from the sensor using the same Port assignments and the same proven code. Swapping back to the 877 shows the sensor is still alive and well - what am I doing wrong with the 18F part? Other sections of the program (LCD, serial, etc.) work correctly so the chip is alive and working in all other respects.
Changing the data line to PortB.4 while keeping PortD.0 for clock I can get good sensor data so something is stange about PortC.3 - any suggestions? I've looked at the data sheet for the 18F4620 but I don't see anything that helps with Port C.
Kind regards to all,
Bill
4620 is not a drop in replacement for 877
There are several differences between the two PICs. ADCON2 and CMCON spring to mind. Sadly it is a case of RTFM to spot the differences as each pin on the 4620 has several functions that must be correctly configured.
HTH
BrianT