For Terrance

Dependencies:   mbed

Committer:
emh203
Date:
Wed Jun 13 15:10:06 2012 +0000
Revision:
0:085749c8446f

        

Who changed what in which revision?

UserRevisionLine numberNew contents of line
emh203 0:085749c8446f 1 #include "System.h"
emh203 0:085749c8446f 2
emh203 0:085749c8446f 3 #ifndef SMART_SWITCH_H
emh203 0:085749c8446f 4 #define SMART_SWITCH_H
emh203 0:085749c8446f 5
emh203 0:085749c8446f 6 extern DigitalOut EnableSmartSwitchPower;
emh203 0:085749c8446f 7 extern DigitalOut SmartSwitch_SS;
emh203 0:085749c8446f 8 extern DigitalOut SmartSwitch_SCK;
emh203 0:085749c8446f 9 extern DigitalOut SmartSwitch_SDI;
emh203 0:085749c8446f 10
emh203 0:085749c8446f 11 #define SMART_SWITCH_CMD_DISPLAY_DATA 0x55
emh203 0:085749c8446f 12 #define SMART_SWITCH_CMD_SET_BACKLIGHT_COLOR 0x40
emh203 0:085749c8446f 13 #define SMART_SWITCH_CMD_SET_BRIGHTNESS 0x41
emh203 0:085749c8446f 14 #define SMART_SWITCH_CMD_RESET 0x5E
emh203 0:085749c8446f 15 #define SMART_SWITCH_CMD_RESET_PARAMETER 0x03
emh203 0:085749c8446f 16
emh203 0:085749c8446f 17 #define SMART_SWITCH_BACKLIGHT_RED (0x03<<4)
emh203 0:085749c8446f 18 #define SMART_SWITCH_BACKLIGHT_YELLOW (0x03<<4)|(0x03<<2)
emh203 0:085749c8446f 19 #define SMART_SWITCH_BACKLIGHT_GREEN (0x03<<2)
emh203 0:085749c8446f 20
emh203 0:085749c8446f 21
emh203 0:085749c8446f 22
emh203 0:085749c8446f 23 void SmartSwitch_Reset();
emh203 0:085749c8446f 24 void SmartSwitch_SetBackLightColor(BYTE Red,BYTE Green,BYTE Blue);
emh203 0:085749c8446f 25 void SmartSwitch_SetBrightnss(BYTE Brightness);
emh203 0:085749c8446f 26 void InitSmartSwitch();
emh203 0:085749c8446f 27 void PowerUpSmartSwitch();
emh203 0:085749c8446f 28 void PowerDownSmartSwitch();
emh203 0:085749c8446f 29 void SmartSwitchWriteByte(BYTE DataOut);
emh203 0:085749c8446f 30 void SmartSwitch_SetBackLightColor2(BYTE RGB);
emh203 0:085749c8446f 31 void SmartSwitch_ImageDump(BYTE *Img);
emh203 0:085749c8446f 32 void SmartSwitchClear();
emh203 0:085749c8446f 33
emh203 0:085749c8446f 34 #endif