From 11dac5108970bf48692080b926fcda2469208b08 Mon Sep 17 00:00:00 2001 From: Prakriti Gupta Date: Fri, 2 Oct 2026 10:44:18 -0700 Subject: [PATCH 1/2] Add mosquitto setup information to the build doc --- docs/build_notes/host_machine_build_notes.rst | 52 +++++++++++++++++++ 1 file changed, 52 insertions(+) diff --git a/docs/build_notes/host_machine_build_notes.rst b/docs/build_notes/host_machine_build_notes.rst index e6b4b1f..177fb55 100644 --- a/docs/build_notes/host_machine_build_notes.rst +++ b/docs/build_notes/host_machine_build_notes.rst @@ -245,6 +245,58 @@ Edit ``/etc/hosts`` to include the private network entries for HISPEC, ordered n 192.168.29.153 bluelantronix 192.168.29.154 hs1wireblue +MQTT Broker Setup +----------------- + +Install the Mosquitto broker and command-line clients, and enable the broker to start on boot: + +.. code-block:: bash + + sudo apt install -y mosquitto mosquitto-clients + sudo systemctl enable mosquitto + +Configure the Listener +~~~~~~~~~~~~~~~~~~~~~~ + +Create ``/etc/mosquitto/conf.d/hispec.conf`` with the listener for the host the broker is served from: + +.. code-block:: text + + listener 1883 131.215.193.168 + allow_anonymous true + +.. note:: + The listener address depends on where HISPEC is hosted. ``131.215.193.168`` is the current host; + replace it with the IP address of the machine running the broker. + +Restart the broker to apply the configuration and confirm it is running: + +.. code-block:: bash + + sudo systemctl restart mosquitto + sudo systemctl status mosquitto + +Test the Broker +~~~~~~~~~~~~~~~ + +In one terminal, subscribe to a test topic: + +.. code-block:: bash + + mosquitto_sub -h 131.215.193.168 -p 1883 -t "test/topic" -v + +In a second terminal, publish a message to the same topic: + +.. code-block:: bash + + mosquitto_pub -h 131.215.193.168 -p 1883 -t "test/topic" -m "Hello" + +The subscriber terminal should print: + +.. code-block:: text + + test/topic Hello + Disable Unnecessary Services ---------------------------- From 6d959fb9767b33c8bb7725cfa6235538db073a93 Mon Sep 17 00:00:00 2001 From: Prakriti Gupta Date: Fri, 2 Oct 2026 15:07:01 -0700 Subject: [PATCH 2/2] Change to using hispec.caltech.edu --- docs/build_notes/host_machine_build_notes.rst | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/docs/build_notes/host_machine_build_notes.rst b/docs/build_notes/host_machine_build_notes.rst index 177fb55..a6c3fe7 100644 --- a/docs/build_notes/host_machine_build_notes.rst +++ b/docs/build_notes/host_machine_build_notes.rst @@ -262,12 +262,12 @@ Create ``/etc/mosquitto/conf.d/hispec.conf`` with the listener for the host the .. code-block:: text - listener 1883 131.215.193.168 + listener 1883 hispec.caltech.edu allow_anonymous true .. note:: - The listener address depends on where HISPEC is hosted. ``131.215.193.168`` is the current host; - replace it with the IP address of the machine running the broker. + The listener address depends on where HISPEC is hosted. ``hispec.caltech.edu`` is the current host; + replace it with the address of the machine running the broker. Restart the broker to apply the configuration and confirm it is running: @@ -283,13 +283,13 @@ In one terminal, subscribe to a test topic: .. code-block:: bash - mosquitto_sub -h 131.215.193.168 -p 1883 -t "test/topic" -v + mosquitto_sub -h hispec.caltech.edu -p 1883 -t "test/topic" -v In a second terminal, publish a message to the same topic: .. code-block:: bash - mosquitto_pub -h 131.215.193.168 -p 1883 -t "test/topic" -m "Hello" + mosquitto_pub -h hispec.caltech.edu -p 1883 -t "test/topic" -m "Hello" The subscriber terminal should print: