mirror of
https://github.com/thelsing/knx.git
synced 2025-07-01 01:17:26 +02:00
* generate unique serial number (#90) * see https://github.com/ricaun/ArduinoUniqueID * calculated from ESP.getEfuseMac() on ESP32 * ESP.getChipId() on ESP8266 * SERIAL_NUMBER_WORD_0-3 on SAMD * HAL_GetUIDw0-2() on STM32 * defaults to 0x01020304 on other platforms * fix variable name for ESP platform * another fix variable name for ESP platform (need more coffee...)
22 lines
368 B
C++
22 lines
368 B
C++
#include "arduino_platform.h"
|
|
|
|
#include "Arduino.h"
|
|
|
|
#ifdef ARDUINO_ARCH_SAMD
|
|
|
|
class SamdPlatform : public ArduinoPlatform
|
|
{
|
|
public:
|
|
SamdPlatform();
|
|
SamdPlatform( HardwareSerial* s);
|
|
|
|
// unique serial number
|
|
uint32_t uniqueSerialNumber() override;
|
|
|
|
void restart();
|
|
uint8_t* getEepromBuffer(uint16_t size);
|
|
void commitToEeprom();
|
|
};
|
|
|
|
#endif
|