Skip to content

This daemon is specifically designed for RODOS-5NS temperature/humidity sensors with USB HID interface.

License

Notifications You must be signed in to change notification settings

SmartElectroni/rodosDev

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

rodosDev

MIT License Copyright (c) 2025 SmartElectroni

Overview

RODOS-5NS Daemon - A lightweight Linux daemon for interfacing with RODOS-5NS temperature/humidity sensors via USB.

This C daemon provides continuous access to sensor data through a simple file interface at /dev/rodos5ns. It handles USB communication using libusb and outputs real-time sensor readings in a human-readable format, eliminating the need for direct USB access in user applications.

Compatible Devices

RODOS-5NS (Temperature and Humidity sensor) Compatible with sensors using the same USB HID protocol (VID: 0x0483, PID: 0x5750) Supports both REX-5NS (temperature/humidity) and DS18B20 (temperature-only) sensor types

Features

Automatic USB detection - Continuously monitors and connects to the sensor Simple file-based interface - Read data directly from /dev/rodos5ns Real-time updates - Data refreshes every 100ms with configurable intervals Human-readable format - Output in temperature=XX.X,humidity=XX.X,status=X,type=X,valid=X format Background operation - Runs as a daemon with system service integration Error resilience - Automatic reconnection on USB errors Resource efficient - Lightweight implementation with minimal overhead

Requirements

libusb-1.0 development package: libusb-1.0-0-dev C compiler: gcc or clang Linux (tested on Ubuntu/Debian, Fedora, Arch) Root/sudo access: Required for USB device access and creating /dev/rodos5ns

Usage

Open and get data from link /dev/rodos5NS in your project:

fd = open("/dev/rodos5ns", O_RDONLY);
int bytes = read(fd, buffer, sizeof(buffer) - 1);

//see examples for more information

Building

You need run make in your device and setting daemon for auto start after loaded system.

make # Build daemon

make run # Run daemon (requires sudo)

make clean # Clean build files

make help # Show all commands


make # Build client example

make run # Run example

make test # Check device and run

make clean # Clean client build


Note: This daemon is specifically designed for RODOS-5NS temperature/humidity sensors with USB HID interface. Compatibility with other sensors depends on protocol similarity.

🚀 Quick Start

# Clone the repository
git clone https://github.com/SmartElectroni/rodosDev.git

cd rodosDev

Build the daemon

make

Run tests

make test

About

This daemon is specifically designed for RODOS-5NS temperature/humidity sensors with USB HID interface.

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published