MCPcopy Create free account
hub / github.com/OpenEPaperLink/OpenEPaperLink / get_mac_format2

Method get_mac_format2

ESP32_AP-Flasher/src/flasher.cpp:307–320  ·  view source on GitHub ↗

extract original mac from segmented tag

Source from the content-addressed store, hash-verified

305
306// extract original mac from segmented tag
307void flasher::get_mac_format2() {
308 zbs->select_flash(0);
309
310 for (uint8_t c = 0; c < 3; c++) {
311 mac[c] = zbs->read_flash(mac_offset + c); // 0x7802
312 }
313 for (uint8_t c = 3; c < 6; c++) {
314 mac[c] = zbs->read_flash(mac_offset + 2 + c);
315 }
316
317 uint16_t type = mac_suffix;
318 mac[6] = (uint8_t)(type >> 8);
319 mac[7] = (uint8_t)(type & 0xFF);
320}
321
322// erase flash and program from flash buffer
323bool flasher::writeFlash(uint8_t *flashbuffer, uint16_t size) {

Callers

nothing calls this directly

Calls 2

select_flashMethod · 0.45
read_flashMethod · 0.45

Tested by

no test coverage detected