You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
|
4 years ago | |
|---|---|---|
| cli | 4 years ago | |
| schemas | 4 years ago | |
| .gitignore | 4 years ago | |
| Containerfile | 4 years ago | |
| LICENSE | 4 years ago | |
| README.md | 4 years ago | |
| go.mod | 4 years ago | |
| go.sum | 4 years ago | |
| migrations.go | 4 years ago | |
| mqtt.go | 4 years ago | |
| podman-compose.yaml | 4 years ago | |
| process.go | 4 years ago | |
| tic-tsdb.yaml | 4 years ago | |
README.md
Saves TIC events to TimescaleDB
Testing
podman-compose up -d
go run cli/main.go process
declare -a fields=(IINST IINST1 IINST2 IINST3 PAPP BASE HCHP HCHC)
while sleep 1; do
value=$((1 + RANDOM % 100))
field=${fields[1 + $((RANDOM % ${#fields[@]}))]}
echo "{\"ts\":$EPOCHSECONDS,\"val\":\"$(printf %03d $value)\"}" | pub -broker mqtt://localhost:1883 -topic esp-tic/status/tic/$field -username dev -password secret -qos 1
done