<html><head><meta http-equiv="content-type" content="text/html; charset=utf-8"></head><body style="overflow-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;"><div><br></div><div>I’ve made, committed, and pushed, a couple of (hard to find but easy to fix) changes to OVMS Server v3.</div><div><br></div><div><ul class="MailOutline"><li>Proper handling of non-textual, non-binary, websocket messages. This issue caused garbage to be received when some websocket clients disconnected nicely (with connection close messages badly handled). The fix is to only treat text and binary messages as OVMS v2 protocol, and to ignore the other purely-control messages.</li></ul><div><br></div><ul class="MailOutline"><li>The websocket library we use may UTF-8 encode incoming messages leading to garbage messages being sent to connected cars/apps and disconnections. The fix made is simply to treat the messages as streams of bytes (not UTF-8 encoded).</li></ul></div><div><br></div><div>With these changes made, all my tests of websocket clients (and apps) are complete and pass. Hopefully this should be stable to use in production now. It is certainly very easy to use.</div><div><br></div><blockquote style="margin: 0 0 0 40px; border: none; padding: 0px;"><div>Car:</div><div><br></div></blockquote><blockquote style="margin: 0 0 0 40px; border: none; padding: 0px;"><blockquote style="margin: 0 0 0 40px; border: none; padding: 0px;"><div><div><font face="Andale Mono">$ websocat -E wss://<server>:6870/apiv2</font></div><div><font face="Andale Mono">MP-C 1 <user> <password> <vehicleid></font></div><div><font face="Andale Mono">MP-S 1 <user> <vehicleid-list></font></div><div><font face="Andale Mono">Z0</font></div><div><font face="Andale Mono">Z1</font></div><div><font face="Andale Mono">C7,stat</font></div><div><font face="Andale Mono">c7,1,all ok</font></div><div><font face="Andale Mono">Z0</font></div></div></blockquote></blockquote><blockquote style="margin: 0 0 0 40px; border: none; padding: 0px;"><div><br></div><div>App:</div><div><br></div></blockquote><blockquote style="margin: 0 0 0 40px; border: none; padding: 0px;"><blockquote style="margin: 0 0 0 40px; border: none; padding: 0px;"><div><div><font face="Andale Mono">$ websocat -E wss://<server>:6870/apiv2</font></div><div><font face="Andale Mono">MP-A 1 <span style="caret-color: rgb(0, 0, 0); color: rgb(0, 0, 0);"><user> <password> <vehicleid></span></font></div><div><font face="Andale Mono">MP-S 1 <span style="caret-color: rgb(0, 0, 0); color: rgb(0, 0, 0);"><user> <vehicleid-list></span></font></div><div><font face="Andale Mono">Z1</font></div><div><font face="Andale Mono">F1.5.0,VIN123456789012345,5,1,TRDM,</font></div><div><font face="Andale Mono">S80,K,220,13,charging,standard,282,253,13,18,0,0,5,1,0,0,0,1</font></div><div><font face="Andale Mono">D124,8,4,10,20,5,0,9930,50,0,0,0,1,1,12.0,0</font></div><div><font face="Andale Mono">L22.337297,114.187969,90,0,1,1</font></div><div><font face="Andale Mono">W29,2,40,6,29,2,40,6,1</font></div><div><font face="Andale Mono">T15</font></div><div><font face="Andale Mono">C7,stat</font></div><div><font face="Andale Mono">c7,1,all ok</font></div></div></blockquote></blockquote><div><br></div><div>This new code is running at <a href="http://api.openvehicles.com">api.openvehicles.com</a> already, and I recommend anyone running their own server to upgrade if they need websocket (or new unified app) support.</div><div><br></div><div>Regards, Mark.</div><div><br></div></body></html>