Rust on an Arduino Uno

I have no idea what I’m doing.

I recently started working with a 8x32 LED matrix powered by an Arduino Uno. I got an example working without using any external libraries by using the onboard shift register to transfer data. The whole thing was coded using the Arduino language, something very close to C++.

Somewhere in my code I was allocating an array on the heap to store data to write to the device. I noted to myself that the performance could be improved by moving the allocation out of the hot loop, but turning lights on and off shouldn’t need that much CPU time anyway. Allocating in a hot loop is fine… as long as you remember to deallocate in the hot loop as well.

After a few seconds, the lights stopped, and I was confused why at first, until I suspiciously noticed no calls to free in my code.

Moving to Rust

This along with the very annoying #ifdef macros throwing locallity of behavior out the window made me want to move to rust if I wanted to do anything more complex.

I challenged myself to make some sort of tetris clone using this “screen” as a display.

A more detailed list of goals to accomplish in the project are

Devlog 0

I still have no idea what I’m doing.

find

tring to use ravedude to run the program but cargo install ravedude is failing for some reason realize that I’m inside of a rust project using the wrong compiler and just cd. that fixes it