remove esp_eth_get_mac (for IDF 4.x)

This commit is contained in:
cyberman54 2021-12-22 16:49:03 +01:00
parent 82bac3f7d2
commit a7bc2be9b7

View File

@ -126,7 +126,8 @@ void setup() {
// hash 6 byte device MAC to 4 byte clientID // hash 6 byte device MAC to 4 byte clientID
uint8_t mac[6]; uint8_t mac[6];
esp_eth_get_mac(mac); esp_read_mac(mac, ESP_MAC_WIFI_STA);
const uint32_t hashedmac = myhash((const char *)mac, 6); const uint32_t hashedmac = myhash((const char *)mac, 6);
snprintf(clientId, 20, "paxcounter_%08x", hashedmac); snprintf(clientId, 20, "paxcounter_%08x", hashedmac);
ESP_LOGI(TAG, "Starting %s v%s (runmode=%d / restarts=%d)", clientId, ESP_LOGI(TAG, "Starting %s v%s (runmode=%d / restarts=%d)", clientId,