The AGA simulator is software that allows a PC to be used as a vehicle data simulator. This will enable developers of Android applications to try their applications using vehicle data, without the need of being connected to an actual vehicle.
The simulator is currently supporting all signals found in the FMS specification v03. This standard can be found here.
The simulator can connect to an Android device running the AGA ROM connected to the same LAN as the computer running the simulator, to a virtual Android device on the same computer, or an App using the standalone Jar-files on the same LAN as the simulator computer.
This wiki describes the three steps to make use of the simulator:
- FMS Data
- Arduino sensor
Installation & Running¶
To be able to run the simulator please check the prerequisites. The simulator requires no installation, simply download the simulator at the locations below (for Windows and Linux computers), unzip the file into a folder, and run the simulator.
java -jar simulator-fx-[version].jar
To connect the simulator to an SDP node (i.e. an Android device running the AGA ROM), first make sure the Android device is connected to the same Wifi network as the computer running the simulator, OR connected with a USB cable.
Type the IP-adress of the device in the window, then press "Connect". If the Android device is a virtual device running on the same computer, OR the Android device is connected with a USB cable, simply type "localhost" in the window, then press "Connect".
If the device running the AGA ROM is attached to the same computer with USB, you have to first carry out the following commands:
adb forward tcp:8251 tcp:8251 adb forward tcp:9898 tcp:9898 adb forward tcp:9899 tcp:9899
When conneced, the small dot to the left of the IP adress window will turn blue, indicating you are connected to the given node.
To add a signal that you want to be sent to the Andoid device, click "Add signal" -> "From database". That will give you a list of signals to choose from.
To quickly find a signal, simply start typing the name of that signal in the text field "Add FMS Signal", and the signal picker will automatically start searching for signals. To select a signal, tick the checkbox to the left of the signal. To remove a signal, untick the checkbox to the left of the signal. When you are finished, click OK to close the signal picker window.
Run the simulator¶
To start running the simulator, simply press the "Play" button and the simulator will start sending the signals with their default values to the connected node.
To pause the simulator, press the "Pause" button.
To send all signals one time, press the "Send once" button.
When closing the simulator, all the signals added, as well as the IP-adress of the connected device, are automatically saved and loaded the next time the simulator is started.
If you have issues recieving signals to the Android device, try to carry out the following steps:
- Disconnect simulator by pressing disconnect
- Remove all the added signals (if any)
- Close the simulator
- Stop and start the adb server using:
adb kill-server adb start-server- Start simulator, add signals, connect, press play.