I just started playing with bootloaders for PICs and I find this very useful.
I appreciate the many options of the PC interface, but I need something more "light" (without for eg. the need of mono and libraries) so I found a compromise: Tiny Multi Bootloader+ firmware together with [https://sourceforge.net/projects/tinybldlin/].
With PIC16F88 everything is fine, with both PC interfaces, but now I want to program PIC16F1936: with Tiny Multi Bootloader+ PC interface it works, while with tinybldlin not. Digging I found that tinybldlin expects the second byte of the answer to be "K" as for PIC16F88, but the second byte coming from PIC16F1936 firmware is "B". Could you explain the meaning? Should I simply blindlyu threat it as if it was "K" and let the program go on?
Looking at:
Tiny_Multi_Bootloader+_v0.10.0/piccodes.ini
I found that both pics seem to belong to the same family "B", so why 16F88 is answering "K"?
And above I found the phrase "; letters "K" and "N" can't be used as device family!!!!!". This confuses me even more.
Can someone explain a bit the protocol used and what this second byte stands for?
Isn't enough just consider the maximum flash memory of the chip to be programmed?
Thanks,
Luca
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
This Bootloader is based on "Tiny PIC Bootloader" made by Claudiu Chiculita.
The specification of "Tiny PIC Bootloader" returns "K" or "N" as the second parameter.
"K" is returned to the host from the device when the data transfer was successful.
"N" is returned to the host from the device when there is an abnormality in the data transfer.
"Tiny Multi Bootloader +" In order to respond to a number of devices, we can not distinguish between conventional "K" just a code to each type of device.
As a result the number of devices that can be identified [0 ~ 9, A ~ J, L, M, O ~ Z] * 256 = (10 + 10 + 1 + 1 + 12) * 256 = 8704.
"N" can not be used because it is used in a conventional manner error detection.
"K" will be used in order to maintain compatibility of the firmware created for "Tiny PIC Bootloader".
Best regards
Dan.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
The specification of "Tiny PIC Bootloader" returns "K" or "N" as the second parameter.
"K" is returned to the host from the device when the data transfer was successful.
"N" is returned to the host from the device when there is an abnormality in the data transfer.
Great! This was exactly the piece I was missing, I looked a lot, but I could not find this fundamental information.
So you suggest me to change in the firmware the 'B' with a 'K'
movlw IdTypePIC ;PIC type
movwi 1[INDF1] ;TX1REG.or.TX2REG
; SendL IdSoftVer ;firmware ver x
MainLoop:
movlw 'B'
mainl:
or to add to tinybldlin the condition of receiving a 'B' as the second byte and threat it like the 'K' case?
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I just started playing with bootloaders for PICs and I find this very useful.
I appreciate the many options of the PC interface, but I need something more "light" (without for eg. the need of mono and libraries) so I found a compromise: Tiny Multi Bootloader+ firmware together with [https://sourceforge.net/projects/tinybldlin/].
With PIC16F88 everything is fine, with both PC interfaces, but now I want to program PIC16F1936: with Tiny Multi Bootloader+ PC interface it works, while with tinybldlin not. Digging I found that tinybldlin expects the second byte of the answer to be "K" as for PIC16F88, but the second byte coming from PIC16F1936 firmware is "B". Could you explain the meaning? Should I simply blindlyu threat it as if it was "K" and let the program go on?
Looking at:
Tiny_Multi_Bootloader+_v0.10.0/piccodes.ini
I found that both pics seem to belong to the same family "B", so why 16F88 is answering "K"?
And above I found the phrase "; letters "K" and "N" can't be used as device family!!!!!". This confuses me even more.
Can someone explain a bit the protocol used and what this second byte stands for?
Isn't enough just consider the maximum flash memory of the chip to be programmed?
Thanks,
Luca
Hi,Morpheus
Answer.
This Bootloader is based on "Tiny PIC Bootloader" made by Claudiu Chiculita.
The specification of "Tiny PIC Bootloader" returns "K" or "N" as the second parameter.
"K" is returned to the host from the device when the data transfer was successful.
"N" is returned to the host from the device when there is an abnormality in the data transfer.
"Tiny Multi Bootloader +" In order to respond to a number of devices, we can not distinguish between conventional "K" just a code to each type of device.
As a result the number of devices that can be identified
[0 ~ 9, A ~ J, L, M, O ~ Z] * 256 = (10 + 10 + 1 + 1 + 12) * 256 = 8704.
"N" can not be used because it is used in a conventional manner error detection.
"K" will be used in order to maintain compatibility of the firmware created for "Tiny PIC Bootloader".
Best regards
Dan.
Great! This was exactly the piece I was missing, I looked a lot, but I could not find this fundamental information.
So you suggest me to change in the firmware the 'B' with a 'K'
or to add to tinybldlin the condition of receiving a 'B' as the second byte and threat it like the 'K' case?
Hi,Morpheus
You have the three choices.
①Use the "Tiny Multi Bootloader +" on Linux.
"Tiny Multi Bootloader+" works perfectly on Linux.
http://tinypicbootload.sourceforge.net/pc_software.html
②Use "tinybldlin".
②-1 "K" alone is used, and assign an ID that is not used
②-2 Change the code of tinybldwin。(0.6.1)
Is, for example, "transferhex.py" has the following description.
Technical information.
http://tinypicbootload.sourceforge.net/pic16_firmwares.html
Best regards
Dan.