6. MQTT Topic Help - DIT113-V22/group-01 GitHub Wiki

MQTT Topics

Below are the topics which the car/app subscribes from and publishes to. Idea being that once information is received through a sensor it is published on the sensor's topic, then the app subscribing to the topic gets that information to display it.

  • Publish = send to broker via topic
  • Subscribe = receive from broker via topic

  • Car controls:
    • Steering - "/smartcar/controls/steering"
    • Throttle - "/smartcar/controls/throttle"
  • Sensors:
    • Infrared: "/smartcar/sensor/ir"
    • Ultrasonic: "/smartcar/sensor/ultrasonic"
    • Odometer: "/smartcar/sensor/odometer"
    • Camera: "/smartcar/sensor/camera"
    • Gyroscope: "/smartcar/sensor/gyroscope"
  • Extra Features:
    • Blinkers: "/smartcar/status/blinkers"
    • Emergency stop: "/smartcar/controls/stop"
  • Derived Data:
    • Speed: "/smartcar/derivedData/speed"
    • Distance "/smartcar/derivedData/distance"

MQTT Help

  • Make sure to have your mqtt broker (mosquitto) running ;)