A template Rust repository for the ATtiny 2313
| .cargo | ||
| avr-specs | ||
| docs | ||
| src | ||
| .gitignore | ||
| Cargo.lock | ||
| Cargo.toml | ||
| README.md | ||
| rust-toolchain.toml | ||
ATtiny2313 Template
Rust project for the ATtiny2313.
Build Instructions
-
Install prerequisites as described in the [
avr-halREADME] (avr-gcc,avr-libc,avrdude, [ravedude]). -
Run
cargo build --releaseto build the firmware. -
Use an Arduino as an ISP to upload your firmware:
-
Connect your AVR based Arduino to your PC, opening the Arduino IDE, select the correct port and Arduino board then open the example sketch File -> Examples -> 11.ArduinoISP -> ArduinoISP and upload it.

-
Take note of what port your arduino is on
-
-
Connect your arduino to your ATtiny2313:
- Arduino pin 13 -> ATtiny2313 pin 19
- Arduino pin 12 -> ATtiny2313 pin 18
- Arduino pin 11 -> ATtiny2313 pin 17
- Arduino pin 10 -> ATtiny2313 pin 1

-
With
avrdudeinstalled, upload using the following command:
avrdude -c arduino_as_isp -p t2313 -P [serial port of arduino] -U flash:w:"target/avr-attiny2313/release/[executable name].elf":a