I’m trying to set up development for an ATTiny10, which isn’t included in platform-atmelavr.
I created ~/.platformio/boards and the file ~/.platformio/boards/attiny10.json:
{
"build": {
"f_cpu": "1000000L",
"mcu": "attiny10"
},
"name": "ATtiny10",
"upload": {
"maximum_ram_size": 32,
"maximum_size": 1024,
"protocol": "atmel-ice"
},
"url": "http://www.atmel.com/devices/ATTINY10.aspx",
"vendor": "Atmel"
}
Creating an ATTiny project loaded the necessary files:
Tool Manager: Installing platformio/toolchain-atmelavr @ ~1.70300.0
Unpacking [####################################] 100%
Tool Manager: toolchain-atmelavr@1.70300.191015 has been installed!
Tool Manager: Installing platformio/tool-scons @ ~4.40300.0
Unpacking [####################################] 100%
Tool Manager: tool-scons@4.40300.1 has been installed!
Verbose mode can be enabled via `-v, --verbose` option
CONFIGURATION: https://docs.platformio.org/page/boards/atmelavr/attiny10.html
PLATFORM: Atmel AVR (3.4.0) > ATtiny10
HARDWARE: ATTINY10 1MHz, 32B RAM, 1KB Flash
PACKAGES:
- toolchain-atmelavr @ 1.70300.191015 (7.3.0)
LDF: Library Dependency Finder -> https://bit.ly/configure-pio-ldf
LDF Modes: Finder ~ chain, Compatibility ~ soft
Found 0 compatible libraries
Scanning dependencies...
No dependencies
and generated a platformio.io
file:
[env:attiny10]
platform = atmelavr
board = attiny10
upload_flags = -e
Entering pio run
on the command line throws a linker error though:
~/.platformio/packages/toolchain-atmelavr/bin/../lib/gcc/avr/7.3.0/../../../../avr/bin/ld: cannot find crtattiny10.o: No such file or directory
which translates to: "ld
can’t find the file crtattiny10.o
."
That file does exist:
~/.platformio/packages/toolchain-atmelavr/avr/lib/avrtiny/crtattiny10.o
But I don’t know how to tell the build system to look in the right directory.
My OS is MacOS 12.4 Monterey, and I’m using the command line/vim version of platformio.