Skip to content
Linux / Raspberry C++ to send data from a Gamma Scout Online to a MQTT server
C C++ Other
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Type Name Latest commit message Commit time
Failed to load latest commit information.


Linux / Raspberry C++ to send data from a Gamma Scout Online to a MQTT server

This application is running on a Linux operating system ideally like a Raspberry.

This software will collect data from a Gamma Scout Online using USB serial port, clean the data and sent it to a MQTT server.


./gammaScout2Mqtt -h Connecting to Gamma Scout... Connected to Gamma Scout Online. Connected to mqtt: Received: 0.169 Received: 0.169 Received: 0.175 Received: 0.175 Received: 0.163 Sending []: 0.163 Received: 0.157 Received: 0.157 Received: 0.151 Received: 0.138

Tested with

  • Gamma Scout Online Hardware Version
  • Ubuntu 19.04
  • Raspbian (Raspberry PI Zero W)

Prepare to build it

You need to connect to the terminal.

Add the user that will run the application to "dialout" (allow access to serial port)

sudo adduser $USER dialout

First update the system

sudo su
apt-get update; apt-get upgrade; apt-get dist-upgrade;apt autoremove

If you are running a raspberry, update the firmware of the raspberry

sudo rpi-update
sudo reboot

Install some package to be able to build the application

sudo apt-get install cmake git

You can now clone the project

git clone

Build it

The easiest way to build it is to run


Or if you want to do it manually

mkdir build
cd build
cmake ..

You can get help using

./gammaScout2Mqtt --help


If you use the following command, data will be sent on the MQTT server, topic /gammascout/monitor

/gammaScout2Mqtt -h -t /gammascout/monitor

Some other parameters

./gammaScout2Mqtt --help

./gammaScout2Mqtt Version 0.1

Read data from an online gamma scout and send it to a MQTT server

-?, --help: Display some help -v, --version: Display the version of this software -d, --device: Device to use, default /dev/ttyUSB0

Settings for MQTT -h, --host: Host, default -p, --port: Port, default 1883 -u, --username: User name -P, --password: Password -s, --seconds: Send the value every s, 0 = as soon as possible, default 30 seconds -t, --topic: Base topic, default /GammaScout


If you want to run it on a production system,

Exit your cron and add the following line

@reboot /{PATH_TO_GAMMASCOUT2MQTT}/ &>/tmp/gammaScout2Mqtt.log

You can’t perform that action at this time.