Main Page   Modules   Data Structures   File List   Data Fields   Globals   Related Pages   Examples  

term.h

00001 #ifndef _DEV_TERM_H_
00002 #define _DEV_TERM_H_
00003 
00004 #include <sys/device.h>
00005 
00006 #define TERM            11
00007 
00008 #define TERM_READ_PERIOD_TIME 5000
00009 
00010 #define DALLAS_IN cbi(DDRB,PORT7);sbi(PORTB,PORT7) 
00011 #define DALLAS_L sbi(DDRB,PORT7);cbi(PORTB,PORT7) 
00012 #define DALLAS_H sbi(DDRB,PORT7);sbi(PORTB,PORT7) 
00013 
00014 typedef struct _TERMICB TERMICB;
00015 typedef struct _TERMDCB TERMDCB;
00016 
00026 struct _TERMICB {
00030         volatile float temp;
00031 
00035     u_short readPeriodTime;
00036 };
00037 
00041 struct _TERMDCB {
00045         u_long address;
00046 };
00047 
00051 extern NUTDEVICE devTerm0;
00052 
00061 extern int TermInit(NUTDEVICE* dev);
00062 
00069 extern void SetReadTempInterval(NUTDEVICE *dev, u_int seconds);
00070 
00078 extern float ReadTemp(NUTDEVICE *dev);
00079 
00083 #endif

Generated on Thu Jan 30 22:30:52 2003 for EduNet by doxygen1.2.18