LoRa node acquiring analog input and sending to LoRa Server - Working ok
Dependents: DISCO-L072CZ-LRWAN1_LoRa_node EIoT_LoRa_node_1 EIoT_LoRa_node_2 EIoT_LoRa_node_3
Fork of SX1276GenericLib by
Diff: Arduino-mbed-APIs/arduino-mbed.h
- Revision:
- 92:ee3de1d353cd
- Parent:
- 90:d98572047c9c
- Child:
- 97:3d5d489206aa
--- a/Arduino-mbed-APIs/arduino-mbed.h Tue Oct 24 20:01:02 2017 +0200 +++ b/Arduino-mbed-APIs/arduino-mbed.h Tue Oct 24 20:02:42 2017 +0200 @@ -28,7 +28,7 @@ #endif class DigitalOut; -void InitSerial(Stream *serial, int timeout_ms, DigitalOut *led); +void InitSerial(Stream *serial, int timeout_ms, DigitalOut *led, bool waitForSerial); extern Stream *ser; extern bool SerialUSB_active; @@ -242,6 +242,12 @@ break; } } + int read () { + if (digitalRead(_gpioPin) == HIGH) + return 0; + else + return 1; + } private: int _gpioPin; Callback<void()> _func;