Support
Wiki Documentation
Support Forum
Mobile
- Rocweb Browser
- WIO-Control ESP32
- andRoc Android
- Rocview Tablet
DIY
User
Wiki writer
Legal
Support
Wiki Documentation
Support Forum
Mobile
DIY
User
Wiki writer
Legal
Each hardware component has the same software package.
The software is written in C using the Arduino IDE. Standard the IDE is not able to upload files to a specific area of the ESP8266 module. This area, the Serial Periferal Interface Flash File System (SPIFFS) is non-volatile memory. We use it to store all files to create the Eltraco configuration website. First of all a library, FS.h, is needed to access this memory. This library needs to be "included" only, it is part of the "ESP8266 software package" of the Arduino IDE. Furthermore we need to place a tool in the “sketchbook” directory. Create a directory called “tools” next to the directory called “libraries”. Via this link https://github.com/esp8266/arduino-esp8266fs-plugin you get to all information you need to install the tool.
The software is as straight forward as possible to enhance readability. Software is documented to explain what the software modules are supposed to do.
Furthermore when selecting a port in the Arduino IDE next to the serial port, the OTA address of a decoder is advertised also. (it takes some time to appear after booting the decoder). Displaying the identity in the list with available WiFi networks on the computer does NOT work. The original factory ID of the ESP module is shown in the WiFi network list.
The software package is uploaded to the decoder via a USB cable using the Arduino IDE. After the first installation of software, Over The Air (OTA) uploading of new software via the Arduino IDE is supported.
Besides the software some extra files have to be uploaded to the SPIFFS. For that reason the extra tool to do this has been added to the Arduino IDE. All files located in the directory “data” next to the “eltraco.ino” file will be uploaded. These files are: Eltraco.js, index.html, main.css, servo.html and wifi.txt.
If the configuration web site does not pop-up properly you might have forgotten to upload these files.
A second way to upload files to SPIFFS is using FTP. Eltraco decoders are provided with an "FTP server". With any FTP client, like "Filezilla" it is possible to upload files to SPIFFS. The user has to apply the IP-address of the decoder with user "eltraco" and password "eltraco". Only FTP on port "21" is supported in a single session, no multiple uploads simultaneously.
After each upload the stored data for the WiFi network are not available anymore. The decoder has to be rebooted to allow the Wifi manager to start and to insert the WiFi data again.
The required library can be downloaded here https://github.com/nailbuster/esp8266FTPServer
The Eltraco software can be downloaded here: https://github.com/eporocrail/Eltraco
The new version is to be found under "EltracoCore".
Adapting the decoder to your WiFi network has to be done once only. During booting a WiFi manager presents a webpage to insert the networkname and the credentials of the network. The Wifi configuration webpage is presented when booting has proceeded until as shown below:
After joining this network, the wifi manager webpage is displayed automatically.
It has two webpages, one to configure the decoder and one to adjust the angles of the two servo's of the turnout decoder.
Following the “ servo settings” link on top of the page presents the servo adjustment page.
After submitting data, the decoder is rebooted. That means that the connection between web page and web server does not exist anymore. The page has to be renewed or the browser needs to be pointed to the URL again. This has to be done when a value is still visible in one of the three IP triplet fields.
It is not possible to 100% prevent the user from inserting wrong data. For that reason some recovery options have been created. The most disturbing situation would be when the WiFi network is unaccessible. If this happens for whatever reason, the user needs to open the file “wifi.txt” in the directory “data” next to the sketch which contains the Eltraco software. With a texteditor the one and only character has to be replaced with a “1”. The file has to be saved. Than the files can be uploaded to SPIFFS again. During the next boot process the WiFi manager will start.
When the IP triplet for Mosquitto has the wrong value, the software will try five times to establish the connection. Than the connection loop is exited and via the configuration web page the triplet gan be given the right value.
When the IP triplet of the Gateway has the wrong value, it will take a little bit longer to continue the boot proces but it will not halt.
The rest of the values can easily be corrected by configuration.