Russell Shomberg
/
shomberg_hw_6
HW6 for OCE560
Fork of shomberg_hw_5 by
OCE360Input.h@9:da0b72918880, 2018-10-25 (annotated)
- Committer:
- rshomberg
- Date:
- Thu Oct 25 18:12:33 2018 +0000
- Revision:
- 9:da0b72918880
- Child:
- 11:42914083ac70
does not compile
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
rshomberg | 9:da0b72918880 | 1 | #ifndef OCE360INPUT_H |
rshomberg | 9:da0b72918880 | 2 | #define OCE360INPUT_H |
rshomberg | 9:da0b72918880 | 3 | |
rshomberg | 9:da0b72918880 | 4 | #include "mbed.h" |
rshomberg | 9:da0b72918880 | 5 | |
rshomberg | 9:da0b72918880 | 6 | DigitalIn myswitch(p7); |
rshomberg | 9:da0b72918880 | 7 | AnalogIn Ain(p20); |
rshomberg | 9:da0b72918880 | 8 | |
rshomberg | 9:da0b72918880 | 9 | int switchPosition; |
rshomberg | 9:da0b72918880 | 10 | int sensorVoltage; |
rshomberg | 9:da0b72918880 | 11 | int sensorTemp; |
rshomberg | 9:da0b72918880 | 12 | |
rshomberg | 9:da0b72918880 | 13 | int read_switch(void); |
rshomberg | 9:da0b72918880 | 14 | |
rshomberg | 9:da0b72918880 | 15 | float read_sensor(void); |
rshomberg | 9:da0b72918880 | 16 | |
rshomberg | 9:da0b72918880 | 17 | float convert_mV_to_temp(float sensorVoltage); |
rshomberg | 9:da0b72918880 | 18 | |
rshomberg | 9:da0b72918880 | 19 | #endif |