Skip to content

Commit a42e303

Browse files
committed
fix return values after recent PR
1 parent c8de670 commit a42e303

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

targets/esp8266/jshardware.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -529,7 +529,7 @@ bool CALLED_FROM_INTERRUPT jshPinGetValue( // can be called at interrupt time
529529
) {
530530

531531
if ((pinInfo[pin].port & JSH_PORT_MASK) == JSH_PORTA) {
532-
return NAN;
532+
return false;
533533
}
534534
/* handle D16 */
535535
if (pin == 16) {
@@ -554,7 +554,7 @@ int jshPinAnalogFast(Pin pin) {
554554
if ( pin == 255 || ( pinInfo[pin].port & JSH_PORT_MASK) == JSH_PORTA ) {
555555
return (int)system_adc_read() << 6; // left-align to 16 bits
556556
} else {
557-
return NAN;
557+
return 0;
558558
}
559559
}
560560

0 commit comments

Comments
 (0)