No description
  • QML 33.2%
  • C++ 32.3%
  • Java 31.5%
  • CMake 3%
Find a file
Repository files (latest commit first)
Filename Latest commit message Latest commit date
2026-04-17 10:14:41 +00:00
android v0.1.0 2026-04-17 15:43:25 +05:30
.gitignore first commit 2026-04-01 18:33:19 +05:30
CMakeLists.txt v0.0.9 2026-04-16 17:18:02 +05:30
configinterface.cpp v0.0.9 2026-04-16 17:18:02 +05:30
configinterface.h v0.0.7 2026-04-13 17:49:08 +05:30
images.qrc first commit 2026-04-01 18:33:19 +05:30
main.cpp first commit 2026-04-01 18:33:19 +05:30
Main.qml v0.1.0 2026-04-17 15:43:25 +05:30
moving_container.h v0.0.4 2026-04-04 12:24:03 +05:30
NotificationManager.java first commit 2026-04-01 18:33:19 +05:30
README.md v0.1.0 2026-04-17 15:43:25 +05:30
service.cpp v0.0.9 2026-04-16 17:18:02 +05:30
service.h v0.0.9 2026-04-16 17:18:02 +05:30
servicemain.cpp first commit 2026-04-01 18:33:19 +05:30
udplistener.cpp v0.1.0 2026-04-17 15:43:25 +05:30
udplistener.h v0.1.0 2026-04-17 15:43:25 +05:30
WaterTank1.png first commit 2026-04-01 18:33:19 +05:30

Water Level Sensor

Builds using QtCreator, use Qt Version 6.9.
Builds for android and desktop.
On Android Creates a service from service.cpp and android/src/org/qtproject/example/appwaterLevelSensor/WaterLevelService.java.
Changes in AndroidManifest.xml are important.
On Desktop just waits for values from a UDP Broadcast on local network with port 8176 and shows those values.
On Android the service does that, and creates an alert notification if the value in broadcast is less than alert threshold.


Create a new socket in Worker that will instantly start listening.
In the service launch the threads and immediately send client hello to the worker socket.
On client hello send command data to the android service.
On quit send server bye to android service.
On server bye deinit the sockets that send data to cpp server.
On next launch, the command and client threads can be reinitialized from the StartService java class.