<html><head><meta http-equiv="Content-Type" content="text/html charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class="">Two known issues:<div class=""><br class=""></div><div class=""><ol class="MailOutline"><li class="">The Silicon Labs driver for OSX seems pretty flaky. Linux seems much better, and I haven’t tried Windows. On OSX, I had horrendous problems with the v5 drivers crashing my whole machine (Sierra 10.12). In the installation package, there is a “Legacy MacVCP Driver” directory containing the older 4.11.2 version - using that older version at least works without crashes, but has one known issue. If you ‘make monitor’ and are in the console to the board, then unplug the board, you get left with a /dev.tty.SLAB* device hanging around that messes up that one USB port and future ‘make monitor’ connections. Workaround is to power off the USB hub, and then everything cleans out nicely. If you are directly connected to your MAC’s USB port, then you seem to need to reboot the whole machine to fix the issue. Getting used to being careful to disconnect from the terminal before unplugging (or simply not unplugging - which was happening a lot when I was working on power optimisation, sleep modes, and external 12V power).<br class=""><br class=""></li><li class="">I’m having problems getting SD CARDs to work reliably. Some work recognise at all (a timeout error when mounting), and some will recognise but fail under heavy writes to the sd card. Frustrating as hell. I don’t think it is a hardware issue (even the googling that error message points to pull-up resistors as the culprit), but suspect some issue with the ESP IDF 2.1 library we are using. We’re working on this one at the moment. I would appreciate your feedback, when you get the boards, as to whether you get any success with SD CARDs.</li></ol></div><div class=""><br class=""><div class="">Regards, Mark.</div><div class=""><br class=""><div><blockquote type="cite" class=""><div class="">On 22 Sep 2017, at 3:22 PM, Mark Webb-Johnson <<a href="mailto:mark@webb-johnson.net" class="">mark@webb-johnson.net</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><meta http-equiv="Content-Type" content="text/html charset=utf-8" class=""><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class="">For those of you about to receive OVMS v3 modules, and for others listening in, here is a ‘getting started’ guide.<div class=""><br class=""></div><div class=""><ol class="MailOutline"><li class="">Follow the instructions in the developer’s guide to download the ESP IDF, extensa tools, and OVMS firmware source tree.</li><li class="">Connect a powered USB hub to your PC, and then connect the OVMS v3 module to that hub, using a micro-usb cable. OVMS v3 is currently in prototype stage, and is not yet FCC/CE approved, so we don’t recommend directly connecting it to your PC’s USB ports.</li><li class="">Do a “make” and “make flash”.</li><li class="">Do a “make monitor” and enjoy the “Welcome” prompt and cursor awaiting your commands.</li></ol></div><div class=""><br class=""></div><div class="">Developer’s documentation is here:</div><div class=""><br class=""></div><blockquote style="margin: 0 0 0 40px; border: none; padding: 0px;" class=""><div class=""><a href="https://docs.google.com/document/d/1q5M9Lb5jzQhJzPMnkMKwy4Es5YK12ACQejX_NWEixr0/edit?usp=sharing" class="">https://docs.google.com/document/d/1q5M9Lb5jzQhJzPMnkMKwy4Es5YK12ACQejX_NWEixr0/edit?usp=sharing</a></div></blockquote><div class=""><br class=""></div><div class="">You can check the Over-The-Air update system with:</div><div class=""><br class=""></div><blockquote style="margin: 0 0 0 40px; border: none; padding: 0px;" class=""><div class=""><div class=""><font face="Andale Mono" class=""><span style="font-size: 14px;" class="">OVMS > ota status</span></font></div><div class=""><font face="Andale Mono" class=""><span style="font-size: 14px;" class="">Firmware: 3.0.0/factory/main build (idf v2.1-2-g7138fb0) Sep 22 2017 13:33:43</span></font></div><div class=""><font face="Andale Mono" class=""><span style="font-size: 14px;" class="">Running partition: factory</span></font></div><div class=""><font face="Andale Mono" class=""><span style="font-size: 14px;" class="">Boot partition: factory</span></font></div></div></blockquote><div class=""><br class=""></div><div class="">The adventurous can put an firmware image on SD card, push it into the OVMS slot, and then “ota flash vfs /sd/<imagename>”.</div><div class=""><br class=""></div><div class="">Now, let’s do some radio stuff and bring up a wifi connection:</div><div class=""><br class=""></div><blockquote style="margin: 0 0 0 40px; border: none; padding: 0px;" class=""><div class=""><font face="Andale Mono" class=""><span style="font-size: 14px;" class="">OVMS > config set wifi.ssid <SSID> <PASSWORD></span></font></div><div class=""><font face="Andale Mono" class=""><span style="font-size: 14px;" class=""><br class=""></span></font></div><div class=""><font face="Andale Mono" class=""><span style="font-size: 14px;" class="">(replace <SSID> with your wifi’s SSID, and <PASSWORD> with it’s password - no spaces supported at the moment)</span></font></div><div class=""><font face="Andale Mono" class=""><span style="font-size: 14px;" class=""><br class=""></span></font></div><div class=""><font face="Andale Mono" class=""><span style="font-size: 14px;" class="">OVMS > wifi mode client <SSID></span></font></div><div class=""><font face="Andale Mono" class=""><span style="font-size: 14px;" class="">I (1446306) wifi: connected with STUBBY, channel 11</span></font></div><div class=""><font face="Andale Mono" class=""><span style="font-size: 14px;" class="">I (1448626) event: ip: 192.168.1.100, mask: 255.255.255.0, gw: 192.168.1.1</span></font></div><div class=""><font face="Andale Mono" class=""><span style="font-size: 14px;" class="">I (1448626) ovms-mdns: Launching MDNS service<br class="">I (1448626) obd2wifi: Launching telnet server</span></font></div></blockquote><div class=""><br class=""></div><div class="">Cool. Now OVMS is a wifi client on your network. You can even “telnet 192.168.1.100” (or whatever address is shown) to remotely access it over wifi. If you want to be really fancy, try taking advantage of the Bonjour mDNS system and “telnet OVMS.local”.</div><div class=""><br class=""></div><div class="">If you don’t have a wifi network to connect to (seriously?), OVMS can be a wifi Access Point itself:</div><div class=""><br class=""></div><blockquote style="margin: 0 0 0 40px; border: none; padding: 0px;" class=""><div class=""><div class=""><font face="Andale Mono" class=""><span style="font-size: 14px;" class="">OVMS > config set wifi.ap <SSID> <PASSWORD></span></font></div><div class=""><font face="Andale Mono" class=""><span style="font-size: 14px;" class=""><br class=""></span></font></div><div class=""><font face="Andale Mono" class=""><span style="font-size: 14px;" class="">(replace <SSID> with the SSID you choose, and <PASSWORD> with a password that clients will use to connect - no spaces supported at the moment)</span></font></div><div class=""><font face="Andale Mono" class=""><span style="font-size: 14px;" class=""><br class=""></span></font></div><div class=""><font face="Andale Mono" class=""><span style="font-size: 14px;" class="">OVMS > wifi mode ap <SSID></span></font></div></div></blockquote><div class=""><br class=""></div><div class="">Then connect to the OVMS module using your phone/PC, as required. Telnet is your friend.</div><div class=""><br class=""></div><div class="">Let’s try to configure some vehicle parameters, so we can connect to an OVMS v2 server:</div><div class=""><br class=""></div><blockquote style="margin: 0 0 0 40px; border: none; padding: 0px;" class=""><div class=""><font face="Andale Mono" class=""><span style="font-size: 14px;" class="">OVMS > config set vehicle id <VEHICLEID></span></font></div><div class=""><font face="Andale Mono" class=""><span style="font-size: 14px;" class="">OVMS > config set server.v2 server <a href="http://api.openvehicles.com/" class="">api.openvehicles.com</a></span></font></div><div class=""><font face="Andale Mono" class=""><span style="font-size: 14px;" class="">OVMS > config set server.v2 password <SERVERPASSWORD></span></font></div><div class=""><font face="Andale Mono" class=""><span style="font-size: 14px;" class=""><br class=""></span></font></div><div class=""><font face="Andale Mono" class=""><span style="font-size: 14px;" class="">(The <VEHICLEID> and <SERVERPASSWORD> are whatever you registered with <a href="http://openvehicles.com/" class="">openvehicles.com</a>).</span></font></div><div class=""><font face="Andale Mono" class=""><span style="font-size: 14px;" class=""><br class=""></span></font></div><div class=""><font face="Andale Mono" class=""><span style="font-size: 14px;" class="">OVMS > server v2 start</span></font></div><div class=""><font face="Andale Mono" class=""><span style="font-size: 14px;" class="">Launching OVMS Server V2 connection (oscv2)<br class="">I (1881896) ovms-server: Launching OVMS Server V2 connection task (oscv2)</span></font></div><div class=""><font face="Andale Mono" class=""><span style="font-size: 14px;" class="">I (1881936) ovms-server-v2: Connected to OVMS Server V2 at <a href="http://api.openvehicles.com/" class="">api.openvehicles.com</a></span></font></div><div class=""><font face="Andale Mono" class=""><span style="font-size: 14px;" class="">I (1881966) ovms-server-v2: OVMS V2 login successful, and crypto channel established</span></font></div><div class=""><font face="Andale Mono" class=""><span style="font-size: 14px;" class="">I (1881976) ovms-server-v2: Incoming Msg: MP-0 Z0</span></font></div></blockquote><div class=""><br class=""></div><div class="">Note that this will have the side-effect of changing that mDNS advertisement to be <VEHICLEID>.local.</div><div class=""><br class=""></div><div class="">We can now see some metrics:</div><div class=""><br class=""></div><blockquote style="margin: 0 0 0 40px; border: none; padding: 0px;" class=""><div class=""><span style="font-family: 'Andale Mono'; font-size: 14px;" class="">OVMS > metrics list</span></div><div class=""><font face="Andale Mono" class=""><span style="font-size: 14px;" class="">m.freeram 46716<br class="">m.hardware OVMS WIFI BLE BT cores=2 rev=ESP32/1<br class="">m.serial aa:bb:cc:dd:ee:ff<br class="">m.tasks 18<br class="">m.version 3.0.0/factory/main build (idf v2.1-2-g7138fb0) Sep 22 2017 06:33:43<br class="">s.v2.connected yes<br class="">s.v2.peers 0<br class="">v.b.12v 0</span></font></div></blockquote><div class=""><br class=""></div><div class="">Looks good. Try connecting an App to the server (on the same vehicle ID) and watch s.v2.peers go from 0 to 1.</div><div class=""><br class=""></div><div class="">Now, start up a vehicle module:</div><div class=""><br class=""></div><blockquote style="margin: 0 0 0 40px; border: none; padding: 0px;" class=""><div class=""><div class=""><font face="Andale Mono" class=""><span style="font-size: 14px;" class="">OVMS > vehicle module TR</span></font></div><div class=""><font face="Andale Mono" class=""><span style="font-size: 14px;" class="">I (2016816) v-teslaroadster: Tesla Roadster v1.x, v2.x and v3.0 Vehicle Module</span></font></div></div></blockquote><div class=""><br class=""></div><div class="">Plug it into the car, and watch the other metrics arrive. Power it from the vehicle’s 12V, and watch v.b.12v show your voltage.</div><div class=""><br class=""></div><div class="">Don’t forget that we’ve got a modem as well:</div><div class=""><br class=""></div><blockquote style="margin: 0 0 0 40px; border: none; padding: 0px;" class=""><div class=""><div class=""><font face="Andale Mono" class=""><span style="font-size: 14px;" class="">OVMS > power simcom on</span></font></div><div class=""><font face="Andale Mono" class=""><span style="font-size: 14px;" class="">Power mode of simcom is now on</span></font></div></div><div class=""><font face="Andale Mono" class=""><span style="font-size: 14px;" class=""><br class=""></span></font></div><div class=""><font face="Andale Mono" class=""><span style="font-size: 14px;" class="">OVMS > simcom tx AT</span></font></div></blockquote><div class=""><br class=""></div><div class="">So, how do we make this work automatically at startup? We’ve still got a lot of work to do on this, but one way at the moment is to take a SD card and format it as FAT32. Then, create directories:</div><div class=""><br class=""></div><blockquote style="margin: 0 0 0 40px; border: none; padding: 0px;" class=""><div class=""><font face="Andale Mono" class=""><span style="font-size: 14px;" class="">/events</span></font></div><div class=""><font face="Andale Mono" class=""><span style="font-size: 14px;" class="">/events/system.start</span></font></div><div class=""><font face="Andale Mono" class=""><span style="font-size: 14px;" class="">/events/system.wifi.sta.gotip</span></font></div></blockquote><div class=""><br class=""></div><div class="">Create two scripts:</div><div class=""><br class=""></div><blockquote style="margin: 0 0 0 40px; border: none; padding: 0px;" class=""><span style="font-family: 'Andale Mono'; font-size: 14px;" class="">/events/system.start/myscript</span></blockquote><blockquote style="margin: 0 0 0 40px; border: none; padding: 0px;" class=""><blockquote style="margin: 0 0 0 40px; border: none; padding: 0px;" class=""><span style="font-family: 'Andale Mono'; font-size: 14px;" class="">wifi mode client <SSID></span></blockquote><blockquote style="margin: 0 0 0 40px; border: none; padding: 0px;" class=""><span style="font-family: 'Andale Mono'; font-size: 14px;" class="">vehicle module TR</span></blockquote><br class=""></blockquote><blockquote style="margin: 0 0 0 40px; border: none; padding: 0px;" class=""><span style="font-family: 'Andale Mono'; font-size: 14px;" class="">/events/system.wifi.sta.gotip</span></blockquote><blockquote style="margin: 0 0 0 40px; border: none; padding: 0px;" class=""><blockquote style="margin: 0 0 0 40px; border: none; padding: 0px;" class=""><span style="font-family: 'Andale Mono'; font-size: 14px;" class="">server v2 start</span></blockquote></blockquote><div class=""><br class=""></div><div class="">Unmount the SD from your computer, and put it in the OVMS module. On boot, you’ll see it mounted under ESP-32’s vfs as /sd. You’ll also see your scripts run (the first at boot, and the second once the wifi comes up). The scripting system will automatically run all scripts it can find in the /store/events/<eventname> and /sd/events/<eventname> directories.</div><div class=""><br class=""></div><div class="">There’s a lot more there, and it is early days, but that should give you a start and a better idea how this is coming together.</div><div class=""><br class=""></div><div class="">Regards, Mark.</div><div class=""><br class=""></div></div>_______________________________________________<br class="">OvmsDev mailing list<br class=""><a href="mailto:OvmsDev@lists.teslaclub.hk" class="">OvmsDev@lists.teslaclub.hk</a><br class="">http://lists.teslaclub.hk/mailman/listinfo/ovmsdev<br class=""></div></blockquote></div><br class=""></div></div></body></html>