Integrate USB BOOTLOADER to my project?

General discussion on mikroC PRO for dsPIC30/33 and PIC24.
Post Reply
Author
Message
Csucsu
Posts: 4
Joined: 30 Dec 2017 20:37

Integrate USB BOOTLOADER to my project?

#1 Post by Csucsu » 30 Dec 2017 21:57

Dear All,

Is it possible to integrate USB HID BOOTLOADER in my projet at source level.
If i try this the compiler generate error message:
75 355 Redefinition of 'main [Main.c] main' already defined in 'Gazagyu_MK2_main.c' Main.c

I think if it possible I get one hex file (when i finish the project) and programming at first time the pic in one step.
Not only bootloader or only my app but boot in one step.

I made my project with the TFT wizard!

Thank you any idea.

Csucsu

User avatar
dusan.poluga
mikroElektronika team
Posts: 780
Joined: 02 Feb 2017 14:21

Re: Integrate USB BOOTLOADER to my project?

#2 Post by dusan.poluga » 03 Jan 2018 11:44

Hi,

Compiler will simply not allow 2 main's to be present in the same project.

The easiest way to program both firmware files is to program the bootloader and then program your application code over the bootloader.

There is a procedure that you can try. Try to compile both projects and try merging .hex files from both projects into one by hand.
I personally have not tried this method, but it should be possible to get it to function if everything is merged properly.

Best Regards,
Dusan Poluga.

Post Reply

Return to “mikroC PRO for dsPIC30/33 and PIC24 General”