Hi,
First time moving from Arduino IDE to PIO.
My project uses a SparkFun AST-CAN485 board, which is not in the PIO boards list. There is a AT90CAN128, which is what the Sparkfun board is based upon.
Looking at the AT90CAN128 boards JSON file, I see everything seems to make sense except the LED definition, so I changed it like so:
I saved the changes to a copy of the file and am using that in my project.
I’m using the sparkfun FTDI basic programmer. which is what I always use with the Arduino IDE.
I get the following error when trying to upload:
Processing AT90CAN128 (platform: atmelavr; board: AT90CAN128-MDR; framework: arduino)
-------------------------------------------------------------------------------------------------------------------------------Verbose mode can be enabled via `-v, --verbose` option
CONFIGURATION: https://docs.platformio.org/page/boards/atmelavr/AT90CAN128-MDR.html
PLATFORM: Atmel AVR (5.1.0) > AT90CAN128-mdr
HARDWARE: AT90CAN128 16MHz, 4KB RAM, 128KB Flash
PACKAGES:
- framework-arduino-avr-megacore @ 3.0.2
- tool-avrdude @ 1.70200.0 (7.2.0)
- 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 11 compatible libraries
Scanning dependencies...
Dependency Graph
|-- ArduinoJson @ 7.3.1
Building in release mode
Checking size .pio\build\AT90CAN128\firmware.elf
Advanced Memory Usage is available via "PlatformIO Home > Project Inspect"
RAM: [== ] 15.5% (used 635 bytes from 4096 bytes)
Flash: [ ] 4.6% (used 6000 bytes from 130560 bytes)
Configuring upload protocol...
AVAILABLE: urclock
CURRENT: upload_protocol = urclock
Looking for upload port...
Using manually specified: COM3
Uploading .pio\build\AT90CAN128\firmware.hex
avrdude: AVR device initialized and ready to accept instructions
avrdude error: unknown bootloader ... please specify -xbootsize=<num>
avrdude error: unable to read signature data for part AT90CAN128, rc=-1
avrdude error: unable to read signature data, rc=-1
avrdude done. Thank you.
*** [upload] Error 1
Can you please go into the Arduino IDE, go to File → Preferences → check “Verbose output during upload”. Then upload again. Paste last few lines of the log output (starting at the “avrdude” command) here, or to pastebin.com.