Skip to content

Commit

Permalink
0.8.57
Browse files Browse the repository at this point in the history
* merge PR: MI-MQTT and last retransmit #1363
* fixed DTU-ID, now built from the unique part of the MAC
* fix lang in `/system` #1346
  • Loading branch information
lumapu committed Jan 15, 2024
1 parent c68c3a3 commit 358344a
Show file tree
Hide file tree
Showing 7 changed files with 20 additions and 15 deletions.
3 changes: 3 additions & 0 deletions src/CHANGES.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@

## 0.8.57 - 2024-01-15
* merge PR: fix immediate clearing of display after sunset #1364
* merge PR: MI-MQTT and last retransmit #1363
* fixed DTU-ID, now built from the unique part of the MAC
* fix lang in `/system` #1346

## 0.8.56 - 2024-01-15
* potential fix of update problems and random reboots #1359 #1354
Expand Down
1 change: 0 additions & 1 deletion src/hm/CommQueue.h
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@
#include "hmInverter.h"
#include "../utils/dbg.h"

// needs a '+1' because the comparison does not send if attempts is equal 0
#define DEFAULT_ATTEMPS 5
#define MORE_ATTEMPS_ALARMDATA 15
#define MORE_ATTEMPS_GRIDONPROFILEPARA 15
Expand Down
4 changes: 2 additions & 2 deletions src/hm/Communication.h
Original file line number Diff line number Diff line change
Expand Up @@ -144,14 +144,14 @@ class Communication : public CommQueue<> {
} else {
if(IV_MI == q->iv->ivGen)
q->iv->mIvTxCnt++;
if(mFirstTry){
if(mFirstTry) {
mFirstTry = false;
mState = States::START;
setAttempt();
mHeu.evalTxChQuality(q->iv, false, 0, 0);
//q->iv->radioStatistics.rxFailNoAnser++;
q->iv->radioStatistics.retransmits++;
mWaitTime.stopTimeMonitor();
mState = States::START;

/*if(*mSerialDebug) {
DPRINT_IVID(DBG_INFO, q->iv->id);
Expand Down
15 changes: 9 additions & 6 deletions src/hm/radio.h
Original file line number Diff line number Diff line change
Expand Up @@ -103,16 +103,19 @@ class Radio {
void generateDtuSn(void) {
uint32_t chipID = 0;
#ifdef ESP32
uint64_t MAC = ESP.getEfuseMac();
chipID = ((MAC >> 8) & 0xFF0000) | ((MAC >> 24) & 0xFF00) | ((MAC >> 40) & 0xFF);
chipID = (ESP.getEfuseMac() & 0xffffffff);
#else
chipID = ESP.getChipId();
#endif
mDtuSn = 0x80000000; // the first digit is an 8 for DTU production year 2022, the rest is filled with the ESP chipID in decimal
for(int i = 0; i < 7; i++) {
mDtuSn |= (chipID % 10) << (i * 4);
chipID /= 10;

uint8_t t;
for(int i = 0; i < (7 << 2); i += 4) {
t = (chipID >> i) & 0x0f;
if(t > 0x09)
t -= 6;
mDtuSn |= (t << i);
}
mDtuSn |= 0x80000000; // the first digit is an 8 for DTU production year 2022, the rest is filled with the ESP chipID in decimal
}

uint32_t mDtuSn;
Expand Down
2 changes: 1 addition & 1 deletion src/web/html/update.html
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
<div id="content">
<fieldset>
<legend class="des">{#SELECT_FILE} (*.bin)</legend>
<p>{#INSTALLED_VERSION}: <span id="version" style="background-color: var(--input-bg); padding: 7px;"></span></p>
<p>{#INSTALLED_VERSION}:<br/><span id="version" style="background-color: var(--input-bg); padding: 7px; display: block; margin: 3px;"></span></p>
<form id="form" method="POST" action="/update" enctype="multipart/form-data" accept-charset="utf-8">
<input type="file" name="update">
<input type="button" class="btn my-4" value="{#BTN_UPDATE}" onclick="hide()">
Expand Down
8 changes: 4 additions & 4 deletions src/web/lang.h
Original file line number Diff line number Diff line change
Expand Up @@ -73,15 +73,15 @@
#endif

#ifdef LANG_DE
#define FACTORY_RESET "Ahoy Factory Reset"
#else /*LANG_EN*/
#define FACTORY_RESET "Ahoy auf Werkseinstellungen zurücksetzen"
#else /*LANG_EN*/
#define FACTORY_RESET "Ahoy Factory Reset"
#endif

#ifdef LANG_DE
#define BTN_REBOOT "Reboot"
#else /*LANG_EN*/
#define BTN_REBOOT "Ahoy neustarten"
#else /*LANG_EN*/
#define BTN_REBOOT "Reboot"
#endif

#endif /*__LANG_H__*/
2 changes: 1 addition & 1 deletion src/web/lang.json
Original file line number Diff line number Diff line change
Expand Up @@ -781,7 +781,7 @@
{
"token": "IRQ_WORKING",
"en": "Interrupt Pin working",
"de": "Interrupt Pin funktoniert"
"de": "Interrupt Pin funktioniert"
},
{
"token": "NRF24_DATA_RATE",
Expand Down

0 comments on commit 358344a

Please sign in to comment.