-
Notifications
You must be signed in to change notification settings - Fork 638
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Problem in websocket with DHT [WEBSOCKET] #9 error(1002): Invalid UTF-8 in text frame #2163
Comments
Thanks! Looking at the last message, before the UTF-8 error:
Can you try changing this unit to just espurna/code/espurna/sensor.ino Line 85 in 8f7d77b
|
Hi, |
Cool. |
Hi here is the output
as far as I understand there is no problem with that, am I wrong? |
Just wondering. For some reason Yours:
Mine (built generic env with -DDHT_SUPPORT=1)
edit: Why I was asking about the locale, this is what happens when converting stuff with pre-unicode era encoding: >>> b'\xb0\x43'.decode('latin1')
'°C'
>>> b'\xb0\x43'.decode('utf-8')
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
UnicodeDecodeError: 'utf-8' codec can't decode byte 0xb0 in position 0: invalid start byte
>>> b'\xc2\xb0\x43'.decode('utf-8')
'°C' |
Based on my previous comment about decoding / encoding being wrong, I tried installing PIO with python2 and check what exactly happens with .ino conversion:
Same thing with python3 version:
Since python2 is EOL, I'm inclined to leave things as they are.
|
hi, do you think there might be something wrong in my FW file? Oscar |
Yes. To fix the issue completely you would need to change PIO installation
from python 2 to python 3. There is a workaround though, but I'd rather
incentivise py3 migration.
… |
The same happens with generic-esp01s-ds18b20-10-ota, I believe it does make sense since it is ºC... I know I'm having the one installed with pip2 how would you go from pip2 to pip3? edit: add missing 'you' |
Use |
how about this: `[268971] [MQTT] Received domoticz/out => { [268998] [DOMOTICZ] Error parsing data Could it be something related to previous problem? |
Unlikely. Can you open a separate issue about that? But, based on what I see, |
Ok, I will do that |
Closing via platformio/platformio-core#3393 |
Hi, Thanks |
I'm afraid I must be doing something wrong
Oscar |
Hi
Apparently now it's working, I'll keep on testing tomorrow |
Before creating a new issue please check that you have:
Fulfilling this template will help developers and contributors to address the issue. Try to be as specific and extensive as possible. If the information provided is not enough the issue will likely be closed.
You can now remove this line and the above ones. Text in italic is meant to be replaced by your own words. If any of the sections below are not relevant to the issue (for instance, the screenshots) then you can delete them.
Bug description
[WEBSOCKET] #9 error(1002): Invalid UTF-8 in text frame
I'm testing now with 2.6.3.
I do not have set WIFI_...
erase.config/ERASE.CONFIG does not help, -DPIO_FRAMEWORK_ARDUINO_ESPRESSIF_SDK221 doesn't help either.
I could only change the password, no wifi, nothing.
Relays doesn't seem to have the issue but I haven't tested any more
Steps to reproduce
You have to run esptool.py erase_flash and then flash the latest build 1.14.2-dev afterwards, or
flash directly latest 1.14.2-dev build on top of previous version from 23/01/20
Expected behavior
This is the expected behavior
[184195] [WEBSOCKET] #7 connected, ip: 192.168.20.222, url: /ws
[184363] [WEBSOCKET] #7 error(1002): Invalid UTF-8 in text frameevi� � [WEBSOCKET] #7 error(1002): Invalid UTF-8 in text frameevi� � [WEBSOCKET] #7 error(1002): Invalid UTF-8 in text frameevi� � [WEBSOCKET] #7 error(1002): Invalid UTF-8 in text frameevi� � [WEBSOCKET] #7 error(1002): Invalid UTF-8 in text frameevi� � [WEBSOCKET] #7 error(1002): Invalid UTF-8 in text frameevi� � [WEBSOCKET] #7 error(1002): Invalid UTF-8 in text frameevi� � [WEBSOCKET] #7 error(1002)
[184396] [WEBSOCKET] #7 disconnected
Screenshots
N/A
Device information
[000175] [MAIN] ESPURNA 1.14.2.PA5-dev (200219)
[000175] [MAIN] [email protected]
[000176] [MAIN] http://tinkerman.cat
[000177] [MAIN] CPU chip ID: 0x8E1600
[000180] [MAIN] CPU frequency: 80 MHz
[000184] [MAIN] SDK version: 2.2.2-dev(38a443e)
[000188] [MAIN] Core version: 2.6.3
[000191] [MAIN] Core revision: 3d128e5c
[000194] [MAIN] Build time: 1582320145
[000198]
[000199] [MAIN] Flash chip ID: 0x146085
[000202] [MAIN] Flash speed: 40000000 Hz
[000206] [MAIN] Flash mode: DOUT
[000208]
[000210] [MAIN] Flash size (CHIP) : 1048576 bytes / 256 sectors ( 0 to 255)
[000217] [MAIN] Flash size (SDK) : 1048576 bytes / 256 sectors ( 0 to 255)
[000224] [MAIN] Reserved : 4096 bytes / 1 sectors ( 0 to 0)
[000231] [MAIN] Firmware size : 569392 bytes / 140 sectors ( 1 to 140)
[000238] [MAIN] Max OTA size : 450560 bytes / 110 sectors ( 141 to 250)
[000245] [MAIN] EEPROM size : 4096 bytes / 1 sectors ( 251 to 251)
[000253] [MAIN] Reserved : 16384 bytes / 4 sectors ( 252 to 255)
[000260]
[000261] [MAIN] EEPROM sectors: 251, 250
[000264] [MAIN] EEPROM current: 251
[000267]
[000268] [MAIN] EEPROM: 4096 bytes initially | 1288 bytes used (31%) | 2808 bytes free (68%)
[000277] [MAIN] Heap : 40984 bytes initially | 5280 bytes used (12%) | 35704 bytes free (87%)
[000285] [MAIN] Stack : 4096 bytes initially | 1232 bytes used (30%) | 2864 bytes free (69%)
[000293]
[000294] [MAIN] Boot version: 31
[000297] [MAIN] Boot mode: 1
[000300] [MAIN] Last reset reason: External System
[000304] [MAIN] Last reset info: Fatal exception:0 flag:6 (EXT_SYS_RST) epc1:0x00000000 epc2:0x00000000 epc3:0x00000000 excvaddr:0x00000000 depc:0x00000000
[000317]
[000319] [MAIN] Board: GENERIC_ESP01S_DHT11_10
[000322] [MAIN] Support: ALEXA API BROKER BUTTON DEBUG_SERIAL DEBUG_TELNET DEBUG_WEB DOMOTICZ HOMEASSISTANT LED MDNS_SERVER MQTT NTP SCHEDULER SENSOR TELNET TERMINAL THINGSPEAK WEB
[000338] [MAIN] OTA: ARDUINO ASYNCTCP WEB
[000342] [MAIN] Sensors: DHTXX
[000345] [MAIN] WebUI image: SENSOR
[000348]
[000349] [MAIN] Power: 2475 mV
[000351] [MAIN] WiFi Sleep Mode: MODEM
[000355]
---8<-------
Core version 2.6.3
1.14.2-dev
esptool but curl upgrade works as well
generic-esp01s-dht11-10
Tools used
Ubuntu 19.10
Firefox 73.0 (64-bit)
PlatformIO Core 4.2 and PIO Home 3.1
Additional context
Add any other context about the problem here.
firmware.zip
tcpdump.zip
The text was updated successfully, but these errors were encountered: