-
Messages from UART
01/02/2017 at 18:08 • 0 commentsI modified the message buffer to fill with data received from the UART. Since the code to set up and process serial input is pretty short, it actually saves space vs. the preset message and prep.
Plus, now the project is actually useful. My test device has a Bluetooth serial receiver, so it could be used to display arbitrary messages from my computer or phone.
-
Reduced Font Size
12/30/2016 at 03:07 • 1 commentA quick tip from a community member (hat tip Yann Guidon) saved some space. Since each character of the font begins with the character width, and each character is one-byte tall, the null terminator is redundant. We can infer this information already from the width.
This reduced the font size about 90 bytes, and saved the program about 70 (additional code to process this change). Will do some code cleanup to try to realize some more savings.
-
Word Wrapping
12/29/2016 at 05:34 • 0 commentsThe program now uses word wrapping when displaying the message to the display. This is done naturally based on the width of the characters. Manually newlines are also supported
The project is feature complete, clocking in at 1014 bytes- we just made it!
-
Newline Support
12/29/2016 at 04:36 • 0 commentsAdded support for the newline character, allowing text to extend to multiple lines on the display.
-
Full font with 867 bytes!
12/28/2016 at 04:59 • 0 comments867 bytes! We did it!
The application now contains a fully usable font. This includes all uppercase/lowercase characters, and most punctuation. I also found a quick workaround to the font storage to avoid the strange marks on some characters, without adding any more space.
-
Hello World!
12/27/2016 at 03:12 • 0 commentsWell, technically 'hello world'. Haven't loaded in upper case or symbols yet.
The program is able to draw any character to a specific place on the screen, and increment through a message buffer.
Will need to find a new method for storing the font, as the current method introduces some artifacts in order to identify complete letters in the buffer- that's why some of the letters appear to have weird accent marks.
Current Program Size: 541 bytes
-
Using less memory than I thought
12/21/2016 at 16:51 • 0 commentsI loaded my compressed font into the application, and was pretty bummed about program size- 1.1kB for just a lowercase font, and I'm still missing a ton of functionality.
Then, I realized that I'm overcalculating my memory usage by a long shot.
I was basing my calculation off the .hex file produced by the linker. This isn't right- I should be basing it off the actual program size saved to application ROM.
After copying the contents from the memory map in the Atmel simulator, I'm at 402 bytes. Way way way under!
-
Setting Individual Pixels
12/20/2016 at 05:26 • 0 commentsAdded the ability to set an individual pixel on the screen by coordinate. Doesn't look like much, but from here I can bring in font processing.
At 656 bytes- so getting pretty close the the line already. Going to have to find something to trim...
Had to pull out some fun, space-saving assembly math tricks:
y % 8 == y AND 0x07
y / 8 ... is the same as... right shift y 3 times