version: '3.7' services: camera: image: cyrilix/robocar-camera command: - "-mqtt-pub-frequency=20" - "-video-device=0" - "-video-width=160" - "-video-height=128" devices: - "/dev/video0:/dev/video0:rw" user: "1234:44" # Set 44/video group to access to video device network_mode: host environment: MQTT_BROKER: "${MQTT_BROKER}" MQTT_USERNAME: "${MQTT_USERNAME}" MQTT_PASSWORD: "${MQTT_PASSWORD}" MQTT_CLIENT_ID: rc-camera MQTT_TOPIC: "${MQTT_TOPIC_CAMERA}" MQTT_QOS: "0" TZ: "Europe/Paris" arduino: image: cyrilix/robocar-arduino command: - "-device=/dev/ttyAMA1" - "-baud=115200" - "-mqtt-retain=false" - "-debug=false" devices: - "/dev/ttyAMA1:/dev/ttyAMA1:rw" user: "1234:20" # Set 20/dialout group to access to serial device network_mode: host environment: MQTT_BROKER: "${MQTT_BROKER}" MQTT_USERNAME: "${MQTT_USERNAME}" MQTT_PASSWORD: "${MQTT_PASSWORD}" MQTT_CLIENT_ID: rc-arduino MQTT_TOPIC_THROTTLE: "${MQTT_TOPIC_RC_THROTTLE}" MQTT_TOPIC_STEERING: "${MQTT_TOPIC_RC_STEERING}" MQTT_TOPIC_DRIVE_MODE: "${MQTT_TOPIC_RC_DRIVE_MODE}" MQTT_TOPIC_SWITCH_RECORD: "${MQTT_TOPIC_RC_SWITCH_RECORD}" MQTT_QOS: "0" TZ: "Europe/Paris" led: image: cyrilix/robocar-led command: - "-mqtt-retain=false" devices: - "/dev/gpiomem:/dev/gpiomem:rw" user: "1234:997" # Set 997/gpio group to access to serial device network_mode: host environment: MQTT_BROKER: "${MQTT_BROKER}" MQTT_USERNAME: "${MQTT_USERNAME}" MQTT_PASSWORD: "${MQTT_PASSWORD}" MQTT_CLIENT_ID: rc-led MQTT_TOPIC_DRIVE_MODE: "${MQTT_TOPIC_RC_DRIVE_MODE}" MQTT_TOPIC_RECORD: "${MQTT_TOPIC_RC_SWITCH_RECORD}" MQTT_QOS: "0" TZ: "Europe/Paris" pca9685: image: cyrilix/robocar-pca9685 command: - "-mqtt-retain=false" - "-throttle-channel=1" - "-steering-channel=0" - "-throttle-zero-pwm=378" - "-throttle-min-pwm=250" - "-throttle-max-pwm=500" - "-steering-left-pwm=490" - "-steering-right-pwm=265" - "-update-pwm-frequency=10" devices: - "/dev/i2c-1:/dev/i2c-1:rw" user: "1234:998" # Set 998/i2c group to access to i2c device network_mode: host environment: MQTT_BROKER: "${MQTT_BROKER}" MQTT_USERNAME: "${MQTT_USERNAME}" MQTT_PASSWORD: "${MQTT_PASSWORD}" MQTT_CLIENT_ID: rc-pca9685 MQTT_TOPIC_THROTTLE: "${MQTT_TOPIC_THROTTLE}" MQTT_TOPIC_STEERING: "${MQTT_TOPIC_STEERING}" MQTT_QOS: "0" TZ: "Europe/Paris" tflite-steering: image: cyrilix/robocar-tflite-steering command: "--tf-model-path=/model/model.tflite" user: "1234:1234" network_mode: host volumes: - /home/pi/models/steering:/model environment: MQTT_BROKER: "${MQTT_BROKER_HOST}" MQTT_USERNAME: "${MQTT_USERNAME}" MQTT_PASSWORD: "${MQTT_PASSWORD}" MQTT_CLIENT_ID: rc-tflite-steering MQTT_TOPIC_CAMERA: "${MQTT_TOPIC_CAMERA}" MQTT_TOPIC_STEERING: "${MQTT_TOPIC_TF_STEERING}" MQTT_QOS: "0" TZ: "Europe/Paris" steering: image: cyrilix/robocar-steering command: - "-mqtt-retain=false" user: "1234:1234" network_mode: host environment: MQTT_BROKER: "${MQTT_BROKER}" MQTT_USERNAME: "${MQTT_USERNAME}" MQTT_PASSWORD: "${MQTT_PASSWORD}" MQTT_CLIENT_ID: rc-steering MQTT_TOPIC_STEERING: "${MQTT_TOPIC_STEERING}" MQTT_TOPIC_TF_STEERING: "${MQTT_TOPIC_TF_STEERING}" MQTT_TOPIC_RC_STEERING: "${MQTT_TOPIC_RC_STEERING}" MQTT_TOPIC_DRIVE_MODE: "${MQTT_TOPIC_RC_DRIVE_MODE}" MQTT_QOS: "0" TZ: "Europe/Paris" throttle: image: cyrilix/robocar-throttle command: - "-mqtt-retain=false" user: "1234:1234" network_mode: host environment: MQTT_BROKER: "${MQTT_BROKER}" MQTT_USERNAME: "${MQTT_USERNAME}" MQTT_PASSWORD: "${MQTT_PASSWORD}" MQTT_CLIENT_ID: rc-throttle MQTT_TOPIC_THROTTLE: "${MQTT_TOPIC_THROTTLE}" MQTT_TOPIC_RC_THROTTLE: "${MQTT_TOPIC_RC_THROTTLE}" MQTT_TOPIC_DRIVE_MODE: "${MQTT_TOPIC_RC_DRIVE_MODE}" THROTTLE_MIN: "0.3" THROTTLE_MAX: "0.4" MQTT_QOS: "0" TZ: "Europe/Paris" road: image: cyrilix/robocar-road command: - "-horizon=20" - "-mqtt-retain=false" user: "1234:1234" network_mode: host environment: MQTT_BROKER: "${MQTT_BROKER}" MQTT_USERNAME: "${MQTT_USERNAME}" MQTT_PASSWORD: "${MQTT_PASSWORD}" MQTT_CLIENT_ID: rc-road MQTT_TOPIC_CAMERA: "${MQTT_TOPIC_CAMERA}" MQTT_TOPIC_ROAD: car/satanas/part/road MQTT_QOS: "0" TZ: "Europe/Paris" # objects: # image: cyrilix/robocar-objects-detection # command: # - "-mqtt-retain=false" # - "-tf-model-path=/model/frozen_inference_graph.pb" # - "-tf-model-config-path=/model/ssd_mobilenet_v2_coco_2018_03_29.pbtxt" # user: "1234:1234" # volumes: # - /home/pi/models/objects-detection:/model # network_mode: host # environment: # MQTT_BROKER: "${MQTT_BROKER}" # MQTT_USERNAME: "${MQTT_USERNAME}" # MQTT_PASSWORD: "${MQTT_PASSWORD}" # MQTT_CLIENT_ID: rc-objects-detection # MQTT_TOPIC_CAMERA: "${MQTT_TOPIC_CAMERA}" # MQTT_TOPIC_OBJECTS: car/satanas/part/objects # MQTT_QOS: "0" # TZ: "Europe/Paris" record: image: cyrilix/robocar-record command: - "-mqtt-retain=true" user: "1234:1234" network_mode: host environment: MQTT_BROKER: "${MQTT_BROKER}" MQTT_USERNAME: "${MQTT_USERNAME}" MQTT_PASSWORD: "${MQTT_PASSWORD}" MQTT_CLIENT_ID: rc-record MQTT_TOPIC_CAMERA: "${MQTT_TOPIC_CAMERA}" MQTT_TOPIC_STEERING: "${MQTT_TOPIC_RC_STEERING}" MQTT_TOPIC_SWITCH_RECORD: "${MQTT_TOPIC_RC_SWITCH_RECORD}" MQTT_TOPIC_RECORDS: "${MQTT_TOPIC_RECORDS}" MQTT_QOS: "0" TZ: "Europe/Paris"