Added sample script from another project in 76935952708135e9d4e302569579a962ae1275f6 , however it's not particularly refined.
Might end up becoming a separate repository once completed to a decent standard.
Basic requirements:
Send 0xc1 to PIC
Check for 0x4b response
Send first 64 bytes of data from .hex file, with the first 8 bytes replaced with the tinybld GOTO instructions
Wait for 0x4b response from PIC confirming it has recieved the data correctly
Send the rest of the data packets in a similar way
Send some tinybld specific code at the end
Data packets consist of:0x00 To write flash
0x0000 Flash address
0x40 Number of bytes (always 64)
64 data bytes Pad with 0xff ( nop instruction) if necessary)
checksum Two's complement of the simple 8 bit sum of all the data bytes
Hex file:
Each line consists of a 9 byte header, data, and a 1 byte two's complement checksum. This should be parsed by the script to extract the data bytes. http://www.microchip.com/forums/m34461.aspx
Tinybld does not write configuration bits. Those must be set in the tinybld asm.
Added sample script from another project in 76935952708135e9d4e302569579a962ae1275f6 , however it's not particularly refined.
Might end up becoming a separate repository once completed to a decent standard.
Basic requirements: Send
0xc1
to PIC Check for0x4b
response Send first 64 bytes of data from .hex file, with the first 8 bytes replaced with the tinybldGOTO
instructions Wait for0x4b
response from PIC confirming it has recieved the data correctly Send the rest of the data packets in a similar way Send some tinybld specific code at the endData packets consist of:
0x00
To write flash0x0000
Flash address0x40
Number of bytes (always 64)64 data bytes
Pad with0xff
(nop
instruction) if necessary)checksum
Two's complement of the simple 8 bit sum of all the data bytesHex file: Each line consists of a 9 byte header, data, and a 1 byte two's complement checksum. This should be parsed by the script to extract the data bytes. http://www.microchip.com/forums/m34461.aspx
Tinybld does not write configuration bits. Those must be set in the tinybld asm.