Menu

TinyBootloader & HEF Memory ( Warning)

2018-12-04
2019-07-15
  • William Roth

    William Roth - 2018-12-04

    HEF memory is located in the last 128 bytes of Program memory, This is the same range of memory where the Tinybooltloader firmware resides. Therefore writing to HEF memory will clobber the bootloader firmware resulting in a chip that will not boot up.

    To use a bootloader AND HEF, a bootloader that resides below the HEF memory range must be used.

    William

     
    • Hanspeter

      Hanspeter - 2019-07-15

      Hi Willi,

      This post was last year, but will address it for GCBasic users who want to
      implement HEF with TinyBootloader.

      See diagram below.

      In the example you create HEF space below the BootLoader
      with entries as such

      addwf PCL,F
      retlw ’B' ;ASCII
      retlw 0x55 ;Hex
      retlw 29 ;Decimal

      You will have to account for 16words extra as part of BootLoader in
      piccodes.ini.

      Example:
      ; PIC10 family
      ; example: PIC10F322 Flash: 512 words = 200h; 200h2 = 400h
      ; $yy, B, |PIC |(Boot |200h
      2 |EE |Boot |Erase,
      ;-----------------------------------------------------------
      $12, B, 10F322 (100W), $400, $000, 200, 32, ;Without (HEF)
      $13, B, 10F322 (116W), $400, $000, 232, 32, ;With 16bytes (HEF) as EE data

      Cheers,
      Hanspeter.

       

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.