¡Esta es una revisión vieja del documento!
Para poder integrar y utilizar el mismo entrenador que estamos construyendo como grabador/programador de microcontroladores PIC, al menos la serie 16f8x (otras compatibilidades no probadas, pero se puede adaptar con pequeños cambios) vamos a usar un desarrollo que emplea el mismo módulo Arduino para programar por puerto serie.
Tras buscar y probar varios proyectos el que me ha funcionado bien ha sido el de http://rweather.github.io/ardpicprog/index.html que os traduzco un poco.
Ardpicprog en una solución basada en Arduino para programar microcontroladores PIC y dispositivos EEPROM de Microchip Tecnology Inc., como pueden ser el PIC16f84, PIC16f628A, PIC12F675, 24LC256, etc. La solución tiene tres partes:
Circuit that is built on one or more prototyping shields to interface to the PIC or EEPROM and provide the 13 volt programming voltage. Sketches called ProgramPIC and ProgramEEPROM that are loaded into an Arduino to directly interface with the device during programming. The sketches implement a simple serial protocol for interfacing with the host.
El circuito que está construido en una o más camisas prototipo (para arduino, mas información sobre el concepto en
Host program called ardpicprog; a drop-in replacement for picprog that implements the serial protocol and controls the programming process on the computer side. Note: Ardpicprog is not compatible with JDM-style PIC programmers. Those programmers typically use RS-232 control signals such as DTR and CTS to interface to the host computer. The Arduino has a simple serial interface over USB with no access to the RS-232 control signals from the host. Because of this, ardpicprog uses a completely different interface between the host and the programmer that runs over a regular serial data link. The host side was deliberately made compatible with the picprog tool to make it easier to replace picprog with ardpicprog in existing build scripts.
More information about Ardpicprog can be found on the following pages:
Installation instructions. Circuit details for 14-bit PIC programmer. ProgramPIC sketch for interfacing with the PIC programmer. ProgramEEPROM sketch for programming EEPROM's from the 24LCXX family. Host program for controlling the PIC programmer. Supported PIC and EEPROM devices. Serial protocol for programming PIC's and EEPROM's with Arduino. Ardpicprog's software is distributed under the terms of the GNU General Public License, Version 3. The circuit diagrams, board layouts, and documentation are provided under the terms of the Creative Commons Attribution-ShareAlike 2.5 license.
For more information on Ardpicprog, to report bugs, or to suggest improvements, please contact the author Rhys Weatherley via email. Patches to support new device types are very welcome.
Detalles en: Documentación, esquemas, y software en: http://rweather.github.io/ardpicprog/index.html