Menu

BLD code shifting

Requests
Bear
2013-09-01
2013-09-03
  • Bear

    Bear - 2013-09-01

    Hi,
    100 bytes only for BLD is very good idea and very big challenge :) - I like it.
    But I need some additional hardware inits while starting BLD, but there is no place for it.

    I think that it would be good to have possibility to preserve more space if expected.
    Currently PC software has hardcoded BLD start address depends on micro type and writes last block direct before this BLD start address, to store there main application start address extracted from original HEX.
    It would be great to force lower start address in PC Tiny AVR/PIC Bootloader+ application to match with current, modified by user version of BLD.
    I think that in many situations users will write own PC bootloader programs prepared for particular micro, i will do it as well :).

    I am able to make changes in AVR/PIC Bootloader+ sources, but I am Delphi/Pascal user in Windows, C/C++ in another platforms, so I don't know which compiler I need for easy use of PC Tiny AVR/PIC Bootloader+ sources :(.
    So please help me in preparing environment for easy use of the AVR/PIC Bootloader+ sources.

    Thank you in advance.
    Mariusz

     

    Last edit: Bear 2013-09-01
  • edorul

    edorul - 2013-09-01

    Hello Bear,

    If you want to extend bootloader firmware initialisation / capabilities / etc... you don't have to stay in 100words size!!!
    This 100words size is an heritage from the former "tiny pic bootloader" made by Claudiu Chiculita. By now, you can create bootloaders with the size you want (the only thing you need to be carefull about is that the size must be "defaut bootloader size for your PIC family + n * tranfert block size for your specific PIC"

    For example, take the PIC16F818. It's configuration line in "piccodes.ini" is:

    $34, B, 16F 818,  $800, $080,     264, 64,
    

    Then, if you modify its firmware, the size need to be: 200 (default for PIC16 family), 264 (200 + tranfert block size for PIC16F818), 328, 392, 456, etc...
    then you'll have to change the PIC16F818 line, in "piccodes.ini", in accordance to the new firmware's size:

    $34, B, 16F 818,  $800, $080,     456, 64,
    

    Anyway, if you still want to modify the PC software you'll need to download "Microsoft Visual C# express" which is free. I use the 2008 version, but you can use a newer one.

    Best regards,
    Edorul

     
  • Dan

    Dan - 2013-09-01

    Hello Bear,

    Complements.

    If you want to create a bootloader of a different size, Please consider erase block size:EBS(bytes) of the chip to use.

    Only first four words of the bootloader area is rewritten at the time of writing,

    org first_address +4
    IntrareBootloader:

    IntrareBootloader ---> Should be placed on the boundary of the block erase.

    Bootloader size = n*EBS+4.

    Best regards,
    Dan

     

    Last edit: Dan 2013-09-01
  • Bear

    Bear - 2013-09-02

    Hi BLD Gurus,
    thank you for explanation how to configure own sizes in software PC Tiny AVR/PIC Bootloader+.
    I am new in this, and I don't found it - sorry.
    Currently I have already my own draft (but working) software version for use with Tiny BLD and I have already shifted my BLD.
    Now I am looking for why serial receiver in uploaded firmware doesn't works while works programmed with PICkit3.
    Probably some problems in interrupt vectors at the beginning.
    Regards
    Mariusz

     
  • edorul

    edorul - 2013-09-03

    Hello Mariusz,

    It's strange as bootloaded firmwares should work as if programmed with PICkit3 (or alike)...
    If using a bootloader from the "TinyBld+" archive without modifying it with "special" initializations, have you the same problem?

    Best regards,
    Edorul

    PS: "I am new in this, and I don't found it - sorry." you don't have to be sorry because there isn't a real documentation, many many features aren't explained.

     

Log in to post a comment.

MongoDB Logo MongoDB