[riot-notifications] [RIOT-OS/RIOT] boards/atmega: cleanup BOOTLOADER variables definitions (#15887)

Alexandre Abadie notifications at github.com
Sun Jan 31 15:41:32 CET 2021


I adapted this PR following https://github.com/RIOT-OS/RIOT/pull/15884#discussion_r566867697
Now only `<board>_BOOTLOADER` must be set in the board config. The `ATMEGA_BOOTLOADER` is set in the common Makefile and by default it's based on the `<board>_BOOTLOADER` variable content.

<details><summary>Tested on arduino-mega2560</summary>

```
$ BUILD_IN_DOCKER=1 make BOARD=arduino-mega2560 -C examples/hello-world flash term --no-print-directory 
Launching build container using image "riot/riotbuild:latest".
docker run --rm --tty --user $(id -u) -v '/usr/share/zoneinfo/Europe/Paris:/etc/localtime:ro' -v '/work/riot/RIOT:/data/riotbuild/riotbase:delegated' -e 'RIOTBASE=/data/riotbuild/riotbase' -e 'CCACHE_BASEDIR=/data/riotbuild/riotbase' -e 'BUILD_DIR=/data/riotbuild/riotbase/build' -e 'RIOTPROJECT=/data/riotbuild/riotbase' -e 'RIOTCPU=/data/riotbuild/riotbase/cpu' -e 'RIOTBOARD=/data/riotbuild/riotbase/boards' -e 'RIOTMAKE=/data/riotbuild/riotbase/makefiles'      -e 'BOARD=arduino-mega2560'  -w '/data/riotbuild/riotbase/examples/hello-world/' 'riot/riotbuild:latest' make 'BOARD=arduino-mega2560'    
Building application "hello-world" for "arduino-mega2560" with MCU "atmega2560".

"make" -C /data/riotbuild/riotbase/boards/arduino-mega2560
"make" -C /data/riotbuild/riotbase/boards/common/arduino-atmega
"make" -C /data/riotbuild/riotbase/boards/common/atmega
"make" -C /data/riotbuild/riotbase/core
"make" -C /data/riotbuild/riotbase/cpu/atmega2560
"make" -C /data/riotbuild/riotbase/cpu/atmega_common
"make" -C /data/riotbuild/riotbase/cpu/atmega_common/periph
"make" -C /data/riotbuild/riotbase/cpu/avr8_common
"make" -C /data/riotbuild/riotbase/cpu/avr8_common/avr_libc_extra
"make" -C /data/riotbuild/riotbase/drivers
"make" -C /data/riotbuild/riotbase/drivers/periph_common
"make" -C /data/riotbuild/riotbase/sys
"make" -C /data/riotbuild/riotbase/sys/auto_init
"make" -C /data/riotbuild/riotbase/sys/malloc_thread_safe
"make" -C /data/riotbuild/riotbase/sys/stdio_uart
   text	   data	    bss	    dec	    hex	filename
   5002	    318	    901	   6221	   184d	/data/riotbuild/riotbase/examples/hello-world/bin/arduino-mega2560/hello-world.elf
avrdude -c stk500v2 -p m2560 -P /dev/ttyACM0 -D -U flash:w:/work/riot/RIOT/examples/hello-world/bin/arduino-mega2560/hello-world.hex

avrdude: AVR device initialized and ready to accept instructions

Reading | ################################################## | 100% 0.01s

avrdude: Device signature = 0x1e9801 (probably m2560)
avrdude: reading input file "/work/riot/RIOT/examples/hello-world/bin/arduino-mega2560/hello-world.hex"
avrdude: input file /work/riot/RIOT/examples/hello-world/bin/arduino-mega2560/hello-world.hex auto detected as Intel Hex
avrdude: writing flash (5320 bytes):

Writing | ################################################## | 100% 0.86s

avrdude: 5320 bytes of flash written
avrdude: verifying flash memory against /work/riot/RIOT/examples/hello-world/bin/arduino-mega2560/hello-world.hex:
avrdude: load data flash data from input file /work/riot/RIOT/examples/hello-world/bin/arduino-mega2560/hello-world.hex:
avrdude: input file /work/riot/RIOT/examples/hello-world/bin/arduino-mega2560/hello-world.hex auto detected as Intel Hex
avrdude: input file /work/riot/RIOT/examples/hello-world/bin/arduino-mega2560/hello-world.hex contains 5320 bytes
avrdude: reading on-chip flash data:

Reading | ################################################## | 100% 0.69s

avrdude: verifying ...
avrdude: 5320 bytes of flash verified

avrdude: safemode: Fuses OK (E:FD, H:D0, L:FF)

avrdude done.  Thank you.

/work/riot/RIOT/dist/tools/pyterm/pyterm -p "/dev/ttyACM0" -b "9600"  
Twisted not available, please install it if you want to use pyterm's JSON capabilities
2021-01-31 15:32:45,616 # Connect to serial port /dev/ttyACM0
Welcome to pyterm!
Type '/exit' to exit.
2021-01-31 15:32:46,621 # in(): This is RIOT! (Version: 2021.04-devel-365-gb8f6d-pr/boards/atmega_bootloader)
2021-01-31 15:32:46,622 # H�
2021-01-31 15:32:46,624 # main(): This is RIOT! (Version: 2021.04-devel-365-gb8f6d-pr/boards/atmega_bootloader)
2021-01-31 15:32:46,631 # Hello World!
2021-01-31 15:32:46,684 # You are running RIOT on a(n) arduino-mega2560 board.
2021-01-31 15:32:46,729 # This board features a(n) atmega2560 MCU.
2021-01-31 15:32:48,200 # Exiting Pyterm
```

</details>

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/RIOT-OS/RIOT/pull/15887#issuecomment-770392640
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.riot-os.org/pipermail/notifications/attachments/20210131/99197d15/attachment.htm>


More information about the notifications mailing list