This shows you the differences between two versions of the page.
| Both sides previous revision Previous revision Next revision | Previous revision | ||
|
steam:examples:start [2020/08/21 07:58] brinkhaus |
steam:examples:start [2021/07/11 16:22] (current) brinkhaus |
||
|---|---|---|---|
| Line 1: | Line 1: | ||
| - | === Laden von Steam als Container, erzeugen von Dummy-JSON-Einträgen === | + | === Loading Steam as a container, creating dummy JSON entries === |
| - | * Laden von Steam als Image im TAR-Format: | + | * Loading Steam as an image in TAR format: |
| - | <code>docker load -i steam.tar</code> | + | <code> |
| + | docker load -i steam.tar | ||
| + | </code> | ||
| - | * Prüfen, ob das Image real vorliegt: | + | * Check if the image is real: |
| - | <code>docker image ls</code> | + | <code> |
| + | docker image ls | ||
| + | </code> | ||
| - | * Erstellen einer einfachen docker-compose.yml: | + | * Create a simple docker-compose.yml: |
| <code> | <code> | ||
| version: '2' | version: '2' | ||
| - | services: | + | SERVICES: |
| Steam: | Steam: | ||
| image: steam:0.9 | image: steam:0.9 | ||
| volumes: | volumes: | ||
| - /var/steam/:/etc/runtime/share | - /var/steam/:/etc/runtime/share | ||
| + | network_mode: "host" | ||
| + | </code> | ||
| + | |||
| + | * Installing Mosquitto to track the creation of entries. | ||
| + | |||
| + | <code> | ||
| + | sudo apt-get install mosquitto mosquitto-clients | ||
| + | </code> | ||
| + | |||
| + | * Starting the container for the first time. | ||
| + | |||
| + | <code> | ||
| + | docker-compose up | ||
| + | </code> | ||
| + | |||
| + | * Modification of the settings XML file (under/var/steam/Settings/). | ||
| + | |||
| + | <code> | ||
| + | --> <SamplingThread-type>ADAS</SamplingThread-type> | ||
| + | --> <ProcessingThread-type>MQTT</ProcessingThread-type> | ||
| + | <!--ETHERCAT IP :127.0.0.1 / PORT 54011--> | ||
| + | <!--MODBUS IP :192.168.0.12 / PORT 502--> | ||
| + | <PhoenixIPAddress>192.168.214.152</PhoenixIPAddress> | ||
| + | <PhoenixPort>54011</PhoenixPort> | ||
| + | <packet-size>100</packet-size> | ||
| + | --> <MQTT_Client_ID>ExampleClientPub</MQTT_Client_ID> | ||
| + | --> <MQTT_Address>tcp://localhost:1883</MQTT_Address> | ||
| + | <MQTT_Topic>communicationAdapter/hf</MQTT_Topic> | ||
| + | <MQTT_UserName>testName</MQTT_UserName> | ||
| + | <MQTT_Password>testPassword</MQTT_Password> | ||
| + | </code> | ||
| + | |||
| + | * Start reading out entries posted in Mosquitto - please start in separate console: | ||
| + | |||
| + | <code> | ||
| + | paho_c_sub -t communicationAdapter/hf --connection tcp://localhost:1883 | ||
| </code> | </code> | ||
| - | * Installation von Mosquitto | + | * Restarting the container |
| - | * Erstmaliges Starten des Containers | + | |
| <code> | <code> | ||
| Line 27: | Line 66: | ||
| </code> | </code> | ||
| - | * Modifikation der XML-Datei | + | After this, the console named above as "separate console" should output the JSON messages from Steam. |
| - | * Start des Auslesens von in Mosquitto geposteten Einträgen | + | |
| - | * Erneuter Start des Containers | + | |