|
/*--------------------------------------------------------------------------* |
|
* Main program |
|
*---------------------------------------------------------------------------* |
|
* 14-Apr-2014 ShaneG |
|
* |
|
* Template program for ATtiny85 C/asm projects. |
|
*--------------------------------------------------------------------------*/ |
|
#include <stdint.h> |
|
#include <stdbool.h> |
|
#include <avr/io.h> |
|
#include <avr/pgmspace.h> |
|
#include "softuart.h" |
|
#include "utility.h" |
|
#include "nokialcd.h" |
|
|
|
// Forward declaration with 'noreturn' attribute |
|
void main() __attribute__ ((noreturn)); |
|
|
|
const uint8_t IMAGE_TGL_LOGO[] PROGMEM = { |
|
0xeb, 0x00, 0x00, 0x00, 0x80, 0x80, 0x80, 0xc0, 0xc0, 0xe0, 0x60, 0x60, |
|
0x30, 0x30, 0x38, 0x18, 0x18, 0x0c, 0x0c, 0x0e, 0x06, 0x06, 0x03, 0x03, |
|
0x03, 0x03, 0x06, 0x06, 0x0e, 0x0c, 0x1c, 0x18, 0x18, 0x30, 0x30, 0x60, |
|
0x60, 0xc0, 0xc0, 0xc0, 0x80, 0x80, 0x00, 0x00, 0x00, 0x06, 0x03, 0x03, |
|
0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0xf8, 0x08, 0x48, 0x48, 0x48, 0x48, |
|
0x48, 0x48, 0x48, 0x48, 0x48, 0x48, 0x48, 0x48, 0x48, 0x48, 0x48, 0x48, |
|
0x48, 0x48, 0x48, 0x48, 0x48, 0x48, 0x08, 0xf8, 0x00, 0x00, 0x00, 0x01, |
|
0xff, 0xff, 0x03, 0x03, 0x06, 0x00, 0x00, 0x00, 0xff, 0xff, 0x00, 0x00, |
|
0x00, 0x00, 0xff, 0x00, 0x92, 0x92, 0x92, 0x92, 0x92, 0x92, 0x92, 0x92, |
|
0x92, 0x92, 0x92, 0x92, 0x92, 0x92, 0x92, 0x92, 0x92, 0x92, 0x92, 0x92, |
|
0x92, 0x92, 0x00, 0xff, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0x00, 0x00, |
|
0x00, 0x40, 0xe0, 0xe0, 0xff, 0xff, 0xe0, 0xe0, 0xe0, 0xe0, 0xff, 0xe0, |
|
0xe4, 0xe4, 0xe4, 0xe4, 0xe4, 0xe4, 0xe4, 0xe4, 0xe4, 0xe4, 0xe4, 0xe4, |
|
0xe4, 0xe4, 0xe4, 0xe4, 0xe4, 0xe4, 0xe4, 0xe4, 0xe4, 0xe4, 0xe0, 0xff, |
|
0xe0, 0xe0, 0xe0, 0xe0, 0xff, 0xff, 0xe0, 0xe0, 0x40, |
|
}; |
|
|
|
/** Program entry point |
|
*/ |
|
void main() { |
|
lcdInit(); |
|
lcdClear(false); |
|
// Display the logo |
|
lcdImageP(0, 20, IMAGE_TGL_LOGO, false); |
|
lcdPrint(5, 0, "The Garage Lab", false); |
|
// Block forever |
|
while(true); |
|
} |