Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
PIC24FJ256DA206 - problem with overwrite bootloader [solved]
#1
Hi Mikael.
I found your bootloader and it's a great solution for me. Realy usefull bootloader.
But can you help me with this?

I'm using PIC 24FJ256DA206. Bootloader is in one special project, aplication in other project.
When I export hex (File -> Export) from aplication project and I'm trying flash it to device (with ds30 Loader GUI), wrote me issues "The hex-file contains code that will overwrite the bootloader".
When I tick "Don't write empty pages", everithing is ok and flashing is correct.
Bootloader is located to page 169.
Exported hex from aplication project contains code from 0x00000h to 0x2ABF6h, what means up to page 170 (over existing bootloader).
When I export code from 0x00000h to 0x0x2A3FEh (without pages 169 and 170), everithing is ok (even without tick "Don't write empty pages").

My question is, how can I restrict aplication project in order to code in aplication occupy only memory , where bootloader not placed?
So, every pages except page 169 (bootloader).
When I properly understood, memory place between adress 0x2A800h to 0x2ABF6h is free (see picture adress.png).
Can I reaach this with any linker script or what?
How can I see Usage Memory Gauge in aplication project only with real usable memory range (without bootloader memory range)?
Is it possible?
Correct me, if I'm wrong.

Do you understand what I mean? I hope that you can help me with this.

Thanks.
Best regards

Peter

[Image: adress.jpg]
[Image: GUI.jpg]


Attached Files
.zip   bootloader_project.zip (Size: 99.58 KB / Downloads: 33)
.zip   aplication_project.zip (Size: 325.82 KB / Downloads: 29)
Reply
#2
Hi,
You will have to create a custom linker script to exclude the boot loader space and make use of the space after the boot loader.

I don't know how the memory gauge in MPLAB IDE works.

Why don't you use the file output by the language tool suite instead of doing an export manually?
Reply
#3
And how can I create a custom linker script?
I thing, this is necessary for everyone who are using this bootloader. Aplication project must know, where is bootloader space and that space are no free for user code. When you have a big project (near 100% used memory) user CODE overwrite bootloader space everytime and it is dangerous.

Because, my experiences with automatically created hex by MPLAB IDE are no so good. Sometimes hex doesn't work.
Reply
#4
Does anybody know how to do it?
Reply
#5
This kind of support is not available to users of the free version.
You are welcome to contact me from this page if you need commercial support:
http://ds30loader.com/
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)