VFD modular clock firmware

Dependencies:   DipCortex-EEprom RTC flw mbed

Embed: (wiki syntax)

« Back to documentation index

Show/hide line numbers IV18Display.h Source File

IV18Display.h

00001 /*
00002  * VFDDeluxe / Simpleclock VFD - mbed
00003  * (C) 2011-14 Akafugu Corporation
00004  *
00005  * This program is free software; you can redistribute it and/or modify it under the
00006  * terms of the GNU General Public License as published by the Free Software
00007  * Foundation; either version 2 of the License, or (at your option) any later
00008  * version.
00009  *
00010  * This program is distributed in the hope that it will be useful, but WITHOUT ANY
00011  * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A
00012  * PARTICULAR PURPOSE.  See the GNU General Public License for more details.
00013  *
00014  */
00015 
00016 
00017 #ifndef __IV18_DISPLAY_H_
00018 #define __IV18_DISPLAY_H_
00019 
00020 #include "mbed.h"
00021 #include "VFDDisplay.h"
00022 
00023 class IV18Display : public VFDDisplay
00024 {
00025 public:
00026     IV18Display(PinName data, PinName clock, PinName latch, PinName blank);
00027     
00028     virtual void writeDisplay(uint8_t digit, uint16_t segments);
00029     //virtual void printTime(time_t t, uint8_t hundredths);
00030     virtual void printTime(struct tm* tm, uint8_t hundredths);
00031     virtual void printTimeLong(struct tm* tm, uint8_t hundredths);
00032     virtual void printTimeSet(struct tm* tm, bool showSeconds = true);
00033     virtual void printDate(struct tm* tm);
00034 
00035 private:
00036     virtual uint16_t calculateSegments(char c, uint8_t digit);
00037     virtual void handleBlink(char d);
00038 };
00039     
00040 #endif // __IV18_DISPLAY_H_