1-Wire Communication with a Microchip PICmicro Microcontroller

Abstract: Several of Maxim's products contain a 1-Wire® communication interface and are used in a variety of applications. These applications may include interfacing to one of the popular PICmicros® (PICs) from Microchip. To facilitate easy interface between a 1-Wire device and a peripheral interface controller (PIC) microcontroller, this application note presents general 1-Wire software routines for the PIC microcontroller, explaining timing and associated details. This application note also provides an included file that covers all 1-Wire routines. Additionally, sample assembly code is included, which is specifically written to enable a PIC16F628 to read from a DS2762 high-precision Li+ battery monitor.