The app will have a main function to show a WebView for a web app and a secondary function described in the following steps. This secondary function will be referred as the Wi-Fi Setup from now on.
Since most of the time the users will only access the WebView to interact, the Wi-Fi Setup must be available but in a way that doesn’t reduce the WebView of the main function.
The first task of the project will be a proposal on how the app will look and how the user will access both functions.
1)The app should first show a list of available Wi-Fi networks (only 2.4GHz) and once the user selects a network one will be prompted for the password.
2)Once the password is entered the app should find a Wi-Fi network with a specific SSID (this SSID will be defined in the app source code) and connect to it. This network will not have Internet access, and this may be an issue in some devices that must be managed in order to complete the next steps.
3) On this network, the app must connect to a TCP socket server on a fixed IP and port.
4) Then the app will send a package in JSON format with the SSID and password entered by the user on the steps 1 and 2.
5) If the package is accepted by the TCP server, it will reply with a package in JSON format containing the device unique ID.
6) The connection with the Wi-Fi should be close and the app restores the connection setting on the device as it was before this procedure in order to have internet access
7) The app then will open a WebView and send the device ID as a part of the URL.
*The app will show all text in English and Spanish, but English will be the default language if the device language doesn’t match with either.
The color palette will be provided and logos.