Actually use the MAC address from a ch341 (#5704)

Co-authored-by: Tom Fifield <tom@tomfifield.net>
This commit is contained in:
Jonathan Bennett 2024-12-31 00:46:03 -06:00 committed by GitHub
parent d1e5be515a
commit 58ebd5bcdb
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -18,6 +18,7 @@
#include <fstream>
#include <iostream>
#include <map>
#include <sstream>
#include <sys/ioctl.h>
#include <unistd.h>
@ -231,6 +232,9 @@ void portduinoSetup()
dmac[3] = hash[3];
dmac[4] = hash[4];
dmac[5] = hash[5];
std::stringstream mactmp;
mactmp << std::hex << +dmac[0] << +dmac[1] << +dmac[2] << +dmac[3] << +dmac[4] << +dmac[5];
settingsStrings[mac_address] = mactmp.str();
}
}