From 902eeb1414b9ac90e4d3235124ddf0fff1651426 Mon Sep 17 00:00:00 2001 From: Klaus K Wilting Date: Wed, 19 Sep 2018 19:36:41 +0200 Subject: [PATCH] lorawan.cpp: prepared bugfix for DEVEUI generator --- src/lorawan.cpp | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/lorawan.cpp b/src/lorawan.cpp index 03cfeca8..0f2a6071 100644 --- a/src/lorawan.cpp +++ b/src/lorawan.cpp @@ -43,14 +43,14 @@ void gen_lora_deveui(uint8_t *pdeveui) { void gen_lora_deveui(uint8_t *pdeveui) { uint8_t *p = pdeveui, dmac[6]; ESP_ERROR_CHECK(esp_efuse_mac_get_default(dmac)); - *p++ = dmac[0]; - *p++ = dmac[1]; - *p++ = dmac[2]; + *p++ = dmac[5]; + *p++ = dmac[4]; + *p++ = dmac[3]; *p++ = 0xff; *p++ = 0xfe; - *p++ = dmac[3]; - *p++ = dmac[4]; - *p++ = dmac[5]; + *p++ = dmac[2]; + *p++ = dmac[1]; + *p++ = dmac[0]; } */