Skip to content

Commit c2c8a87

Browse files
committed
Add compile guards to getMacAddress
1 parent fe60d94 commit c2c8a87

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

Firmware/RTK_Surveyor/Display.ino

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2544,13 +2544,17 @@ void paintEspNowPaired()
25442544
displayMessage("ESP-Now Paired", 2000);
25452545
}
25462546

2547-
const uint8_t * getMacAddress ()
2547+
const uint8_t * getMacAddress()
25482548
{
25492549
static const uint8_t zero[6] = {0, 0, 0, 0, 0, 0};
25502550

2551+
#ifdef COMPILE_BT
25512552
if (bluetoothState != BT_OFF)
25522553
return btMACAddress;
2554+
#ifdef COMPILE_WIFI
25532555
else if (wifiState != WIFI_OFF)
25542556
return wifiMACAddress;
2557+
#endif
2558+
#endif
25552559
return zero;
25562560
}

0 commit comments

Comments
 (0)