Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit8666278

Browse files
committed
Fix build script
1 parent99a75ba commit8666278

File tree

1 file changed

+9
-2
lines changed

1 file changed

+9
-2
lines changed

‎bootloaders/build.sh‎

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,18 @@
1-
if [$AVR_GCC_PATH=="" ];then
1+
#!/bin/bash
2+
3+
if [ x$AVR_GCC_PATH== x"" ];then
24
AVR_GCC_PATH=/bin/
35
fi
46

7+
echo Compiling
58
${AVR_GCC_PATH}/avr-gcc -c -g -Os -w -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics -Wno-error=narrowing -Wl,--gc-sections -w -mmcu=atmega4809 -DF_CPU=16000000L boot.c -o boot.o
69
${AVR_GCC_PATH}/avr-gcc -g -Os -w -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics -Wno-error=narrowing -nostartfiles -Wl,--gc-sections -w -mmcu=atmega4809 -DF_CPU=16000000L boot.o -o boot.elf
710

8-
${AVR_GCC_PATH}/avr-objcopy -O binary -R .fuses boot.elf boot.bin
11+
echo Extracting bin
12+
${AVR_GCC_PATH}/avr-objcopy -O ihex -R .fuses boot.elf boot.hex
913
#${AVR_GCC_PATH}avr-objcopy -O binary -j .fuses --set-section-flags=.fuses=alloc,load --no-change-warnings --change-section-lma .fuses=0 boot.elf boot.fuses
1014

15+
echo Moving hex
16+
mv boot.hex atmega4809_uart_bl.hex
17+
1118
${AVR_GCC_PATH}/../avrdude/6.3.0-arduino14/bin/avrdude -C${AVR_GCC_PATH}/../avrdude/6.3.0-arduino14/etc/avrdude.conf -v -patmega4809 -cxplainedmini_updi -Pusb -Ufuses:w:boot.fuses:r -Uflash:w:boot.bin:r

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp