@wutu Great, it is working now! I only had tested with host and port set.
-
New plugin pimatic-mqtt
"It always takes longer than you expect, even when you take into account Hofstadter's Law.", Hofstadter's Law
-
thx @mwittig again
new version of pimatic-mqtt - 0.9.2
Support for multiple brokers
transition to mqtt.js 2.x.xPimatic = Smart Home
-
A question: is it possible to send two values via MQTT?
For example I am using ESPEasy on a H801 5 channel dimmer. Since a few months it is possible to not only send a new PWM value, but also a time (in ms) which the ESP should take to dim to the new value, e.g. 1000ms, which gives a nice fading effect of 1s. The time then should be the second argument.
Also see this topic on the ESPEasy forum: http://www.esp8266.nu/forum/viewtopic.php?f=6&t=1944#p9060There also seems to be a new template for setting outputs, maybe it is wise to accomodate for that as well?
-
@Rene-Arts Hi.
Although I am now in the stage just before the laying of cables in Flat1
Yes, I watch it
I’m using now H801 in the kitchen with PIR.
I used MqttSwitch:{ "topic": "mh/ff/kitchen/dimmer/cmd", "onMessage": "pwm,15,1023,2000", "offMessage": "pwm,15,0,2000", "id": "cabinet-light", "name": "Cabinet light", "class": "MqttSwitch" }
You can also use dummy dimmer:
{ "id": "test-dimmer-with-transition", "name": "Test-dimmer-with-transition", "class": "DummyDimmer" }
{ "id": "test-dimmer-rules", "name": "Test-dimmer-rules", "rule": "when $test-dimmer-with-transition.dimlevel changes then publish mqtt message \"pwm,15,$test-dimmer-with-transition.dimlevel,500\" on topic \"mh/gf/lab/dimmer2/cmd\"", "active": true, "logging": true }
Value need to be converted for dimmer resolution. $test-dimmer-with-transition*1023/100 in this example.
ESP Easy newly used status topic for changes.
mh/gf/lab/dimmer2/status { "log": "GPIO 15 Set PWM to 23", "plugin": 1, "pin": 15, "mode": "PWM", "state": 23 }
I guess I’ll have to deploy something like msg template for all devices.
Pimatic = Smart Home
-
Thanks, that might give me a temporary solution. Also just got an idea to use the Rules in ESPEasy.
-
new version of pimatic-mqtt - 0.9.3
Fix sensor dev and change connection status detection@merphun Fixed
Pimatic = Smart Home
-
thank you very much! Now its working like a charm!
br
Michael -
new version of pimatic-mqtt - 0.9.4
Fix buttons incoming message issue: https://github.com/wutu/pimatic-mqtt/issues/19Pimatic = Smart Home
-
new version of pimatic-mqtt - 0.9.5
-
Configurable message for dimmer
-
Node.js 0.10 is no longer supported
Pimatic = Smart Home
-
-
Hi I am getting more and more into the MQTT business and I am beginning to like it (a lot)
However maybe I am overlooking something simple but I do not see how I can do it in a simple way.
I want to control my thermostat by MQTT (OTGW). I can receive the setpoint from the thermostat by “events/central_heating/otmonitor/setpoint” this works OK.
I have added a variable input device for setting the temperature. No problem to create a rule and to send out the MQTT message to the OTGW with the new setpoint “actions/otmonitor/setpoint”.
But the “events/central_heating/otmonitor/setpoint” can be set outside pimatic as well. How do link this value to the parameter used in the variable input device? As the MQTT value is not a parameter and I do not see how I can use or monitor the value in a rule?
Could somebody give me a hint.
And I know there is a seperate plugin for the OTGW but I am not satisfied with that as I have some socket losses, etc…
-
@dynamite said in New plugin pimatic-mqtt:
But the “events/central_heating/otmonitor/setpoint” can be set outside pimatic as well. How do link this value to the parameter used in the variable input device? As the MQTT value is not a parameter and I do not see how I can use or monitor the value in a rule?
I think this is not possible.
I plan to add input devices to MQTT module.
Unfortunately, I have little time.Pimatic = Smart Home
-
@wutu Ok clear to me I will wait and see!
-
This post is deleted!
-
This post is deleted!
-
I’m playing with the plugin, but I can’t get something to work, probably due to some inexperience with this plugin.
I have a ESP that is publishing to a MQTT broker running on my Pimatic server. The MQTT plugin is connected to the broker (“info [pimatic-mqtt]: Successfully connected to MQTT Broker mqttbroker”).
I have created a MQTTSensor device, according to the howto this should be able to grab data from a flat json object published to the topic.
Unfortunately, it doesn’t get any data and stays “Unknown”. I have played with changing the type from number to string, or adding quotes around the value in the json object, but all without any luck.To rule out a issue with the json object the ESP publish to a second topic with just the value. Unfortunately this also stays “Unknown”.
Running a mosquitto client to make sure the data is pushed into the topic:
mosquitto_sub -h 192.168.2.121 -p 1883 -v -t /# /electra { "T1":"1904618","T2":"2226285","L1":350,"L2":279,"L3":27,"Total":676} /t1 1904618
Config of both devices:
{ "brokerId": "mqttbroker", "attributes": [ { "name": "T1", "topic": "electra", "type": "string", "messageMap": { "test": "" }, "acronym": "T1 stroom" }, { "name": "T2", "topic": "electra", "type": "number", "messageMap": {} }, { "name": "Total", "topic": "electra", "type": "number", "messageMap": {} } ], "xAttributeOptions": [], "id": "electra", "name": "electra", "class": "MqttSensor" },
{ "brokerId": "mqttbroker", "attributes": [ { "name": "electrat1", "topic": "t1", "type": "string", "messageMap": {} } ], "xAttributeOptions": [], "id": "electra-t1", "name": "electra-t1", "class": "MqttSensor" }
Can someone give me a hint in what corner to search for my error?
UPDATE: Got it working, I need to use the slash in the topic name : "/electra"
Works like a charmLike my projects and help? Consider donating electroneum etnjwAKGPqF6omQWRmpp9u2BPyVDG9VuyRQjNJ1S8yfBdfR9qeUQ46kRy8KS2CNqbpNLRrsgmNW6F2TMzxmZgPrh6KctrkrYbm
-
new version of pimatic-mqtt - 0.9.7
Added Shutter and Input devPimatic = Smart Home
-
@wutu great will test it soon!
-
Hello, is it possible to use the mqttdimmer- device with ws2812b led’s?
"Really, I'm not out to destroy Microsoft. That will just be a completely unintentional side effect." 09-28-2003, LINUS TORVALDS (http://www.nytimes.com)
-
@thrusty said in New plugin pimatic-mqtt:
Hello, is it possible to use the mqttdimmer- device with ws2812b led’s?
Hello. Not directly. But some WS2812 control softwares can be controlled using MQTT commands.
For example, I use ESP8266 with Melvanimate and I drive it from Pimatic using the mqtt protocol. Also, McLighting looks interesting.
You can find another one here: https://github.com/search?l=Arduino&q=ws2812+mqtt&type=Repositories&utf8=✓ or https://github.com/search?utf8=✓&q=neopixel+mqtt&type=RepositoriesPimatic = Smart Home