I've been working with PICs for a while, with the CCS compiler. It's been ~8 years since the last time I did any serious work in assembler, and that was for school. I'd like to use a bootloader on my target board, so firmware updates can be done without relying on an ICSP programmer. The board I predominantly work with has PIC18F2620 and a 3.686MHz clock, although I'd also like to eliminate the external clock and go with the internal on-chip oscillator. I would prefer a bootloader that does not require modification of the target application code. I tried CodeLoader, but I couldn't get it to actually let me write a program into the 2620. After a while of trying, I gave up, and went looking again, and came across the Tiny Bootloader. One of the pre-assembled images provided with Tiny is a target for the 2620 and a 20 MHz clock. If I use my CCS Mach-X programmer to flash a 2620, I get the following verification error complaining about the configuration data: 00 02 19 00 00 84 80 00 0F C0 0F E0 0F 00 - Actual Data FF 32 F9 E0 FF FC FA FF FF FF FF FF FF 00 - Expected Data BUT - If I stick the chip on a proto board with a 20 MHz clock, it seems to work correctly. I tried changing the xtal value to 3686400 and using MPASM to build it, but it errors out building the configuration data, saying that _XINST_OFF_4L is undefined. If I comment that value out of the config data, the firmware builds just fine. If I use the Mach-X to load the bootloader, this is the message I get: 00 02 19 00 00 84 C0 00 0F C0 0F E0 0F 00 - Actual Data FF 32 F9 E0 FF FC BA FF FF FF FF FF FF 00 - Expected Data Stick the chip on the proto board with a 3.6864 MHz clock, and the client can talk to the bootloader. I can even use the bootloader to install a test program. But the program doesn't work. The test program I'm using displays a "hello" message and then counts on the serial port (using printf() and an int8) and blinks an LED on B1. The test program works as expected on the 2620 with the pre-assembled bootloader and a 20MHz clock. Using the modified bootloader that I assembled myself, it just spits garbage. ( either a never-ending string of null bytes, or a couple random characters repeating endlessly) Does anyone have suggestions on things I could do to get Tiny to work correctly? Or an alternate bootloader to try? Also, is it mandatory that the config word for the bootloader be identical to that of the application program? -- http://www.piclist.com PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist