Thursday, June 16, 2016

arduino based multi-function display for Vanagon - part 2


I added a clock and calendar screen. It took a bit of work to sort out the navigation logic since this is a new feature that I didn't plan for. With each feature that I add, it had been a hand-to-hand combat to conserve precious memory, both the flash and the static RAM. The latter is most critical as there is only 2k bytes. My goal is to have a least uncommitted 512 bytes left. The power management features that I implemented is working very well now and appears to have few bugs. The joystick UI is very smooth without mis-registration. I also managed to add time stamps to the file creation and modified.

To add time stamps to the file directory I have to abandon the SD.h library and go with the less user-friendly SdFat.h library and I suffered, at least at first. The pain did come with benefit. I saved nearly 2k bytes of flash memory as the SD.h is just a dumbdown wrapper onto the SdFat.h. When you want a light weight uC there are always price to pay for the lightness. For me I always believe in small and less are more, and they take more care and cost to create or make. Big is bad, ugly, and unrefined, but typically cheap, and you can have them now and have all.

This has been a very fun project. I learnt a lot starting very rusty in software programming. I even had a hard time remembering boolean algebra like the very important De Morgan's theorem. It is good to exercise those brain cells once in a while.

these are not laws, they are theorems or rules!

the first cut of the clock screen - very unattractive

I flipped the time and date sequence - it is actually worst

I begun to try balancing out the information on the screen

complexity is seldom good - not to mention when you qualify with GmbH you should have the correct complete name

westfalia's logo has gone through evolution over the decades and in my mind I thought it is always all lower case, but I am wrong

there is still much more to be desired; I want to clean up the look with international format

here the camera happen to catch the screen refresh; it is done in 4 vertical segments, sequentially,  to conserve precious RAM

I forced displaying leading 0 in time fields - it is much better

I tried to better balance the screen; I just notice I need to force 0 on the month and day fields

Sweating the details make all the difference. It takes a lot of time and iterations for someone inexperienced and lack programming skill. I want the time in the middle row as it is the most sought information so it should be easy to pick up at a quick glance. While it seems nice to also force 0 on the month and day fields, there may be downside in doing so.  With the date on the bottom row I have to give consideration to the blinking dot that indicates a data logging session is in progress. The line can become very cluttered with that much text. Still I want to see if I can make it work.

I shifted all the lines left starting from the left most position. That result in adequate delineation between the date and the progress dot to the bottom right corner.



I decided to add "VW" following "westfalia" to balance out the lengths of top and bottom rows


progress dot seen here

I like the version with "westfalia VW", but the capitalize VW is a bit big compared to westfalia. If I have more time, I can custom make the accurate fonts and sizes for both.

here is a version with all caps

yet another iteration with all lower case - vw's font looks glaringly wrong

I think I am done with fussing over the look of "westfalia vw", as the only way to further improve it is creating custom bitmap for that portion of the screen.

of all the iterations I like this one the most - it is far from perfect which is to create a bitmap for "westfalia VW"

The problem with software is it is so malleable that is so hard to stop refining it. I can add a day of week to make it more complete. More important, right now there is no provision to properly support when the micro SD card is removed and inserted. Since the uC is never truly powered down the right way to implement this is to wire up the CARD_DETECT pin of the SD card to a digital pin of the AtMega328, and program the pin to trigger an interrupt when the pin state changes. Each time a card is newly inserted one must perform initialization, or else writing to the card will fail. Carrying out this project on the Adurino Uno has been a challenge due to the limitations of the AtMega328. That does not mean at all it is not a suitable choice. It just force you to work harder. Small is more, and less is more, if you know how to harness the strengths. To me it is the physical size and versatility of the Uno that is very suited.

I decided to have some fun and humor on the clock calendar display that is most fitting for Isolde's German root. I added a field for day of week using German abbreviations - So, Mo, Di, Mi, Do, Fr, Sa. I am having so much fun with this!

Haute ist Donnerstag


I should add to the feature creep list to implement an audio reporting of the clock calendar in Deutsch, activated by the Steuerknüppel (joystick).


No comments:

Post a Comment