The Nintendo Switch is a handheld videogame platform based on the Nvidia Tegra X1 SoC.
| Interface | Hardware Supported | TinyGo Support |
|---|---|---|
| GPIO | ? | ? |
| UART | ? | ? |
| SPI | ? | ? |
| I2C | ? | ? |
| ADC | ? | ? |
| PWM | ? | ? |
Documentation for the machine package for the Nintendo Switch
You will need the linkle (https://github.com/MegatonHammer/linkle) program to convert to the NRO format needed by the Switch:
You can use a Nintendo Switch software emulator such as yuzu (https://yuzu-emu.org/) to test your programs.
Build your Nintendo Switch programs using -target nintendoswitch like this:
tinygo build -o main.elf -target nintendoswitch examples/serial
Once you have created the ELF file, convert it into the NRO format using linkle:
linkle nro main.elf main.nro
You can now use the NRO file with your emulator or flash it onto your physical hardware.
Information needed here…
See the gonx package (https://github.com/racerxdl/gonx) for wrappers around Nintendo Switch APIs.
Examples using gonx can be found at https://github.com/racerxdl/go-switch-examples