server/display.h

00001 /*
00002  * Copyright Ian Burnett 2005, 2006.
00003  *
00004  * This file is part of Ian's Interactive LCD controller (IILC).
00005  * 
00006  * IILC is free software; you can redistribute it and/or modify it under
00007  * the terms of the GNU General Public License as published by the Free
00008  * Software Foundation; either version 2 of the License, or (at your
00009  * option) any later version.
00010  *
00011  * IILC is distributed in the hope that it will be useful, but WITHOUT
00012  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
00013  * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
00014  * for more details.
00015  *
00016  * You should have received a copy of the GNU General Public License along
00017  * with IILC; if not, write to the Free Software Foundation, Inc.,
00018  * 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA.
00019  */
00020 
00021 #if !(defined __DISPLAY_H__)
00022 #define __DISPLAY_H__
00023 
00024 #include "lcd.h"
00025 #include "module.h"
00026 #include "screen.h"
00027 
00028 typedef struct _tag_display * LPDISPLAY;
00029 
00030 typedef void (* pfnDspCBFanSpeed)(void * context,
00031                                   unsigned int fan_id,
00032                                   const char * pszFanName,
00033                                   unsigned int rpm);
00034 
00035 typedef void (* pfnDspCBTemp)(void * context,
00036                               unsigned int sensor_id,
00037                               double degrees_c);
00038 
00039 typedef void (* pfnDspCBKeyEvent)(void * context,
00040                                   unsigned int key_event);
00041 
00042 
00043 LCD_API int displayCreate(const char * pszClass,
00044                           const char * pszPort,
00045                           LPDISPLAY * ppDisplay);
00046 
00047 LCD_API int displayOpen(LPDISPLAY pDisplay);
00048 
00049 LCD_API int displayClose(LPDISPLAY pDisplay);
00050 
00051 LCD_API int displayDispose(LPDISPLAY * ppDisplay);
00052 
00053 LCD_API int displayGetSize(LPDISPLAY pDisplay,
00054                            int * width,
00055                            int * height);
00056 
00057 LCD_API int displayAddFanReportListener(LPDISPLAY pDisplay, 
00058                                         unsigned int fan_id,
00059                                         LPMODULE pModule,
00060                                         const char * pszName);
00061 
00062 LCD_API int displayAddTempReportListener(LPDISPLAY pDisplay,
00063                                          unsigned int sensor_id,
00064                                          LPMODULE pModule,
00065                                          const char * pszName);
00066 
00067 LCD_API int displayScreenAdd(LPDISPLAY pDisplay,
00068                              LPSCREEN pScreen);
00069 
00070 /*
00071 
00072 LCD_API int displaySetKeyEventListener(LPDISPLAY pDisplay, 
00073                                        pfnKeyEventListener pfnListener,
00074                                        void * context);
00075 */
00076 int displayStart(LPDISPLAY pDisplay);
00077 
00078 int displayStop(LPDISPLAY pDisplay);
00079 
00080 
00081 
00082 #endif /* __DISPLAY_H__ */
00083 

Generated on Mon Jul 17 01:36:11 2006 for IILC by  doxygen 1.4.6