MiddleWare GUS
Sensors.h@1:fd355dc296b1, 2015-12-09 (annotated)
- Committer:
- RoHe
- Date:
- Wed Dec 09 04:44:37 2015 +0000
- Revision:
- 1:fd355dc296b1
- Child:
- 3:d527bae62c60
ok
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
RoHe | 1:fd355dc296b1 | 1 | #include "mbed.h" |
RoHe | 1:fd355dc296b1 | 2 | |
RoHe | 1:fd355dc296b1 | 3 | /*Macros*/ |
RoHe | 1:fd355dc296b1 | 4 | #define BAD_PARAMETER (-1) |
RoHe | 1:fd355dc296b1 | 5 | #define OFF 0 |
RoHe | 1:fd355dc296b1 | 6 | #define ON 1 |
RoHe | 1:fd355dc296b1 | 7 | #define FALSE 0 |
RoHe | 1:fd355dc296b1 | 8 | #define TRUE 1 |
RoHe | 1:fd355dc296b1 | 9 | #define CLOSED 0 |
RoHe | 1:fd355dc296b1 | 10 | #define OPEN 1 |
RoHe | 1:fd355dc296b1 | 11 | |
RoHe | 1:fd355dc296b1 | 12 | |
RoHe | 1:fd355dc296b1 | 13 | |
RoHe | 1:fd355dc296b1 | 14 | |
RoHe | 1:fd355dc296b1 | 15 | /*Extern Functions*/ |
RoHe | 1:fd355dc296b1 | 16 | //////////////////////////////////////////////////// |
RoHe | 1:fd355dc296b1 | 17 | extern bool GetPrescenceStatus(); |
RoHe | 1:fd355dc296b1 | 18 | /* GetPrescenceStatus: |
RoHe | 1:fd355dc296b1 | 19 | Input parameters -> void |
RoHe | 1:fd355dc296b1 | 20 | Output parameters -> bool RoomStatus; 0-> No Prescence Detected |
RoHe | 1:fd355dc296b1 | 21 | 1-> Prescence Detected |
RoHe | 1:fd355dc296b1 | 22 | */ |
RoHe | 1:fd355dc296b1 | 23 | |
RoHe | 1:fd355dc296b1 | 24 | //////////////////////////////////////////////////// |
RoHe | 1:fd355dc296b1 | 25 | extern bool GetDoorStatus(); |
RoHe | 1:fd355dc296b1 | 26 | /* GetDoorStatus: |
RoHe | 1:fd355dc296b1 | 27 | Input parameters -> void |
RoHe | 1:fd355dc296b1 | 28 | Output parameters -> bool DoorStatus; 0-> Door Closed |
RoHe | 1:fd355dc296b1 | 29 | 1-> Door Open |
RoHe | 1:fd355dc296b1 | 30 | */ |
RoHe | 1:fd355dc296b1 | 31 | |
RoHe | 1:fd355dc296b1 | 32 | //////////////////////////////////////////////////// |
RoHe | 1:fd355dc296b1 | 33 | extern int GetWindowStatus(int window); |
RoHe | 1:fd355dc296b1 | 34 | /* GetWindowStatus: |
RoHe | 1:fd355dc296b1 | 35 | Input parameters -> int window |
RoHe | 1:fd355dc296b1 | 36 | Output parameters -> int WindowStatus; -1-> Bad parameter or error |
RoHe | 1:fd355dc296b1 | 37 | 0-> Window Closed |
RoHe | 1:fd355dc296b1 | 38 | 1-> Window Open |
RoHe | 1:fd355dc296b1 | 39 | */ |
RoHe | 1:fd355dc296b1 | 40 | |
RoHe | 1:fd355dc296b1 | 41 | //////////////////////////////////////////////////// |
RoHe | 1:fd355dc296b1 | 42 | extern int SetLight(bool Light); |
RoHe | 1:fd355dc296b1 | 43 | /* SetLight: |
RoHe | 1:fd355dc296b1 | 44 | Input parameters -> bool Light; 0-> Light is OFF |
RoHe | 1:fd355dc296b1 | 45 | 1-> Light is ON |
RoHe | 1:fd355dc296b1 | 46 | |
RoHe | 1:fd355dc296b1 | 47 | Output parameters -> int WindowStatus; -1-> Bad parameter or error |
RoHe | 1:fd355dc296b1 | 48 | 0-> Light is OFF |
RoHe | 1:fd355dc296b1 | 49 | 1-> Light is ON |
RoHe | 1:fd355dc296b1 | 50 | */ |
RoHe | 1:fd355dc296b1 | 51 | |
RoHe | 1:fd355dc296b1 | 52 | //////////////////////////////////////////////////// |
RoHe | 1:fd355dc296b1 | 53 | extern unsigned int GetPersonStatus(); |
RoHe | 1:fd355dc296b1 | 54 | /* GetPersonStatus: |
RoHe | 1:fd355dc296b1 | 55 | Input parameters -> void |
RoHe | 1:fd355dc296b1 | 56 | |
RoHe | 1:fd355dc296b1 | 57 | Output parameters -> unsigned int PersonNumber; 0 - 4294967296. |
RoHe | 1:fd355dc296b1 | 58 | */ |