nuttx/arch
Raman Gopalan 0967eb4c24 avr32dev1: Fix compilation and nsh boot-up
I recently imported NuttX version 6.0 (and nsh) into a Microchip
Studio project [1] on Windows to figure out what was going wrong with
the avr32dev1 build. I also briefly checked NuttX version 10.

I worked with the assumption that the avr32 (avr32dev1) specific
changes to the codebase were minimal across NuttX releases.

For the initial proof of concept I used Microchip Studio version 7.0
(with the recent Microchip's ASF updates). I use avr32-gcc (4.4.7)
hosted here [2] for building NuttX for avr32dev1 on GNU/Linux.

Even with the Microchip Studio project, I had initial debug problems
with just stepping through the code a line at a time. I had to bring
in crt0, a trampoline stub and the linker file from one of my older
projects to really build on the suspicion I had with the linker file.

Perhaps an older version of avr32-gcc did something differently. I am
not sure about this. I used avr32-objdump to see the output sections
of the generated elf file. I just had to tweak the linker script to
ensure correct linking of the sections.

With those changes, I was able to inspect the UART sections within
NuttX Microchip Studio project.

Second important change: the transmit pin: I had to reassign the pin
to see the nsh console.

These are the currently assigned UART pins:

RX: PA_24 -> Physical IC pin 59
TX: PB_02 -> Physical IC pin 24

For the avr32dev1 board, they are pins: J1 (berg pin 28) and J2 (berg
pin 10).

In addition, the PR fixes silly compilation problems with avr32dev1.

I have tested the nsh build with my avr32dev1 boards. I used Atmel ICE
to program one of them (flash at 0x80000000) and dfu-programmer to
test my other board (flash at 0x80002000). The other RS-232 parameters
are the same as they were.

References:
[1]: https://github.com/ramangopalan/nuttx_avr32dev1
[2]: https://github.com/ramangopalan/avr32-gnu-toolchain-linux_x86_64
2024-02-08 11:12:13 -03:00
..
arm arch/samv7: add function to retrieve reset cause from HW 2024-02-07 13:26:37 -03:00
arm64 docs/comments: fix some typos 2024-01-15 13:22:13 +08:00
avr avr32dev1: Fix compilation and nsh boot-up 2024-02-08 11:12:13 -03:00
ceva docs/comments: fix some typos 2024-01-15 13:22:13 +08:00
dummy
hc arch/: remove duplicated task exit logs 2024-01-17 09:18:17 -08:00
mips arch/: remove duplicated task exit logs 2024-01-17 09:18:17 -08:00
misoc arch/: remove duplicated task exit logs 2024-01-17 09:18:17 -08:00
or1k arch/: remove duplicated task exit logs 2024-01-17 09:18:17 -08:00
renesas arch/: remove duplicated task exit logs 2024-01-17 09:18:17 -08:00
risc-v arch/risc-v/src/mpfs/mpfs_serial.c: Allow switching uart output to console off 2024-02-06 08:53:05 -08:00
sim rptun: Remove the empty implementation of get_firmware and get_addrenv 2024-02-04 09:54:05 +01:00
sparc arch/: remove duplicated task exit logs 2024-01-17 09:18:17 -08:00
x86 arch/: remove duplicated task exit logs 2024-01-17 09:18:17 -08:00
x86_64 cosmetic changes after pci code rebase 2024-01-25 09:09:30 -08:00
xtensa esp32/dac-one-shot: lower-half driver for ESP32 internal DAC 2024-02-02 09:23:28 -08:00
z16 arch/: remove duplicated task exit logs 2024-01-17 09:18:17 -08:00
z80 arch/: remove duplicated task exit logs 2024-01-17 09:18:17 -08:00
CMakeLists.txt
Kconfig arch/Kconfig: replace RPTUN_PING with RPMSG_PING 2024-02-01 16:50:23 +08:00