esp-knx-ip icon indicating copy to clipboard operation
esp-knx-ip copied to clipboard

ESP32 Quickfix

Open c-o-m-m-a-n-d-e-r opened this issue 4 years ago • 4 comments
trafficstars

quick try to implement ESP32

c-o-m-m-a-n-d-e-r avatar Mar 15 '21 08:03 c-o-m-m-a-n-d-e-r

Good Fox for ESP32, but this part change not needed (is wrong):

#ifdef ESP32
    long m = pow(round(v), 0x7FF);
#else
    long m = round(v) & 0x7FF;
#endif

wladwnt avatar Sep 09 '21 21:09 wladwnt

Why? :-)

c-o-m-m-a-n-d-e-r avatar Sep 10 '21 07:09 c-o-m-m-a-n-d-e-r

Because round(v) & 0x7f gives correct result on ESP32, checked via ETS5. Why the calculation on ESP32 should be different to ESP8266?

wladwnt avatar Sep 10 '21 15:09 wladwnt

haha oh man ... you are right, sorry was writing from the autobahn ... ignore that please 🤣

c-o-m-m-a-n-d-e-r avatar Sep 10 '21 15:09 c-o-m-m-a-n-d-e-r