From 01713bbe20d2cf5aafbe5eb32721d3e4fc5823d8 Mon Sep 17 00:00:00 2001 From: Filip Wandzio Date: Fri, 5 Sep 2025 03:30:24 +0200 Subject: Standarize the project directory for monorepo-like developer experience Move the clang formatter to the root of the three so all nested projects could use it Provide README for all other projects Refactor the code in rtt agregator Signed-off-by: Filip Wandzio --- analysis/rtt/README.txt | 40 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 40 insertions(+) create mode 100644 analysis/rtt/README.txt (limited to 'analysis/rtt/README.txt') diff --git a/analysis/rtt/README.txt b/analysis/rtt/README.txt new file mode 100644 index 0000000..4a45e6d --- /dev/null +++ b/analysis/rtt/README.txt @@ -0,0 +1,40 @@ +Project: MQTT RTT and Throughput Logger + +Description: +This project implements an MQTT client that connects to a broker, subscribes to a topic, and logs message round-trip time (RTT) and throughput statistics to a CSV file and standard output. The logger measures the time difference between message sent timestamps and received timestamps to calculate RTT and maintains a sliding window of message times to estimate throughput in messages per second. + +Files: + +mqtt_client.h / mqtt_client.c: MQTT client wrapper using the Mosquitto library. + +logger.h / logger.c: Logger module for handling incoming MQTT messages and logging RTT/throughput. + +main.c: Entry point initializing the MQTT client and logger, then running the MQTT client loop. + +Dependencies: + +Mosquitto library (libmosquitto) + +Standard C libraries (stdio, stdlib, string, sys/time, time) + +Build Instructions: + +Look at the Dockerfile and Makefile to find out. +Usage: + +Configure MQTT broker address, port, and topic in main.c. + +Run the compiled executable. + +The program connects to the broker, subscribes to the specified topic, and logs RTT and throughput stats to a CSV file. + +Output is also printed to the console. + +Notes: + +The logger expects the payload of received messages to contain a timestamp string representing the sent time in milliseconds. + +The program uses blocking call mosquitto_loop_forever to run the MQTT network loop. + +Contact: +For questions contact Filip Wandzio at contact@philw.dev -- cgit v1.2.3