FU-Dyson-BMS icon indicating copy to clipboard operation
FU-Dyson-BMS copied to clipboard

How to compile firmware

Open liujixu1984 opened this issue 1 year ago • 4 comments

May I ask how to compile firmware? I will use Git to clone it locally in Ubuntu environment, then enter the project folder firmware, and then run it/ Makefile command prompt: root@ubuntu:~/FU-Dyson-BMS/firmware# ./Makefile

./Makefile: line 54: build:: command not found

./Makefile: line 56: .build-pre:: command not found
./Makefile: line 59: .build-post:: command not found
./Makefile: line 64: clean:: command not found
./Makefile: line 66: .clean-pre:: command not found
./Makefile: line 74: .clean-post:: command not found
./Makefile: line 79: clobber:: command not found
./Makefile: line 81: .clobber-pre:: command not found
./Makefile: line 84: .clobber-post:: command not found
./Makefile: line 89: all:: command not found
./Makefile: line 91: .all-pre:: command not found
./Makefile: line 94: .all-post:: command not found
./Makefile: line 99: help:: command not found
./Makefile: line 101: .help-pre:: command not found
./Makefile: line 104: .help-post:: command not found
./Makefile: line 110: include: command not found
./Makefile: line 113: include: command not found

May I ask if there is a help file that teaches me how to do it?

liujixu1984 avatar Dec 29 '23 06:12 liujixu1984

I think you'll have to use MPLABX IDE from Microchip. I think there is a Linux version. Once you have that installed, it should be straightforward to open the project and then run/compile.

tinfever avatar Dec 29 '23 16:12 tinfever

Thank you! I installed the software and compiled the source code, and got a hex file, but after flashing the battery, I put in the vacuum cleaner and pressed the trigger, and the red light flashed 10 times, but I didn't make any changes before compiling, what do I need to modify to make this work properly? I tried to change the

FaultHandling.c // result &= (ISL_RegData[Status] == 0); //No ISL error flags

These lines can be used when flashed into the battery, what is the reason for this?

liujixu1984 avatar Dec 30 '23 02:12 liujixu1984

That's odd. Were you using the Initial Release - Version 1 hex file previously? Could you test again to compare both the Initial Release - Version 1 release and the one you've compiled with no changes, and confirm they behave differently? They should be the same.

tinfever avatar Dec 30 '23 17:12 tinfever

Yes, I'm attaching the compiled file without any changes, please compare it

firmware.production.hex.txt

liujixu1984 avatar Dec 31 '23 01:12 liujixu1984