Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Miscellanous updates #5

Open
wants to merge 3 commits into
base: main
Choose a base branch
from
Open

Miscellanous updates #5

wants to merge 3 commits into from

Conversation

saxofon
Copy link

@saxofon saxofon commented Mar 28, 2024

  • send OBIS data in separate mqtt messages
  • only send data that has changed
  • debug logging via mqtt
  • build procedures automated in Makefile

Per Hallsmark added 3 commits March 28, 2024 17:03
* send OBIS data in separate mqtt messages
* only send data that has changed
* debug logging via mqtt
* build procedures automated in Makefile

Signed-off-by: Per Hallsmark <[email protected]>
Signed-off-by: Per Hallsmark <[email protected]>
@saxofon
Copy link
Author

saxofon commented Apr 18, 2024 via email


.PHONY: deploy
deploy: dependencies
cp $(shell basename $(PICO_RST)) /run/media/per/RPI-RP2

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
cp $(shell basename $(PICO_RST)) /run/media/per/RPI-RP2
cp $(shell basename $(PICO_RST)) /media/$(USER)/RPI-RP2

deploy: dependencies
cp $(shell basename $(PICO_RST)) /run/media/per/RPI-RP2
sleep 15
cp $(shell basename $(MP)) /run/media/per/RPI-RP2

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
cp $(shell basename $(MP)) /run/media/per/RPI-RP2
cp $(shell basename $(MP)) /media/$(USER)/RPI-RP2


.PHONY: unit-test
unit-test:
sudo stty -F /dev/ttyUSB0 raw

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I guess the path here depends on you operating system and slot selected


.PHONY: mqtt-viewer
mqtt-viewer:
sub --auto-reconnect \

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Shall it be mqttcli sub --auto-reconnect ? Were is the mqttcli downloaded, multiple variants exists :)

.PHONY: mqtt-viewer
mqtt-viewer:
sub --auto-reconnect \
--broker tcp://$$(grep MQTTHost config.py.home | cut -d\' -f2):1883 \

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
--broker tcp://$$(grep MQTTHost config.py.home | cut -d\' -f2):1883 \
--broker tcp://$$(grep MQTTHost config.py | cut -d\' -f2):1883 \

mqtt-viewer:
sub --auto-reconnect \
--broker tcp://$$(grep MQTTHost config.py.home | cut -d\' -f2):1883 \
--topic $$(grep MQTTTopic config.py.home | cut -d\' -f2)/#

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
--topic $$(grep MQTTTopic config.py.home | cut -d\' -f2)/#
--topic $$(grep MQTTTopic config.py | cut -d\' -f2)/#

PSK = '<PSK>'
MQTTHost = '<IP to mqtt server>'
MQTTTopic = 'electric-meter/main'

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybee add user and password for the MQTT client?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants