So far this is a quick implementation of the falling blocks game. It is complete and works, albeit with trominos instead of the standard tetrominos. The current compilation statistics are (with avr-gcc 6.2.0):
AVR Memory Usage ---------------- Device: attiny13a Program: 1016 bytes (99.2% Full) (.text + .data + .bootloader) Data: 31 bytes (48.4% Full) (.data + .bss + .noinit)
Things it has:
- Full falling blocks game logic, with row removal and game speedup as removed rows increase.
- Full control capability (down, rotate, left, right), using a single I/O pin (via the ADC).
- Single-buffered video (it had double buffered, but I needed the RAM from the second buffer and the flash from the buffer swapping code). The framerate is high enough so that it isn't noticeable.
- Complete tromino bitmap.
- Completely implemented in C, relying only on the GCC -Os optimizer flag.
Things it doesn't yet have:
- Space to put the tetromino bitmap in (140 bytes with the current inefficient bitmap format).
- Randomized piece selection (currently it just alternates between pieces). I plan to squeeze a small LFSR in there at some point soon. Sadly the ATTiny13A's LSL operation only shifts once per instruction.
- A schematic in Kicad format. It's just a picture from my notebook right now. Possibly the worst schematic I've ever published online.
- A second 74HC595. I only have one and so the other I had to hack together from some Fry's Electronics rebranded, overpriced 7400 ICs.