PiDome Domotica/Home Automation
-
Hi John!
Can You tell, is it possible to show battery level and sketch name and version in PiDome? How to describe this information under custom device?
Thanks in advance
Vj
Hi @bomber
Battery status can be done this way:
- Drag an drop a group to the device declaration field. You can give it any name you want, but the group id must be named "INTERNAL"(capital letters without the " (quotes)).
- Drag and drop a data field control to this group. You can give it any name. but the id must be "I_BATTERY_LEVEL" (also without the quotes).
Set the datatype to "FLOAT". All battery levels in the server are handled this way. - If you want, you can select "Battery (0-100%)" as a visual type. This is for future references when the server is able to report low battery levels to users and visualize this in clients.
Sketch name and version is not available, let me see how quick this can be added (if it is a quick add will do it immediately, otherwise it get's a position on my to do list, recent (unfortunate) developments are requiring a lot of my time).
Cheers,
-
I_SKETCH_NAME and I_SKETCH_VERSION have been added, only currently they only appear after a device has been added and is restart (during presentation and the device is known in the server).
I currently do not have the time to have a persistent solution where the values are remembered during discovery (inclusion). Group id for both is also "INTERNAL" and the control id's must be I_SKETCH_NAME or I_SKETCH_VERSION. The data type is String.
P.S. it is currently builing on the build server, give it a couple of minutes.
-
Hi John,
I'm pretty new to PiDome and MySensors but I've been gradually figuring things out. However I can't get the battery information to display in PiDome. I followed your instructions you gave above but it never receives the information even though I can see it being sent via the com port on my pc. Has the method of receiving the battery information changed in the last 7 months since you posted this?
-
Hi @AndrewB
As far as i'm concerned the methods for displaying battery status have not been changed. it could have been changed between some days seven months ago.
Are you using group id "INTERNAL" and control id "I_BATTERY_LEVEL" ?
-
It currently is quite late i will test this tomorrow as i also have some resource available then. I have to get some hardware together, if i find everything quick will test it in a moment for you. I need some info from you though:
What is your current build number being used (see server settings page)?
What is the mysensors library version you are using, 1.4 or 1.5?Cheers!
-
Oh dear, we are already at build 540 for the server with full platform build at: 0.1-snapshot-2015-09-05.746. The next server build version will probably stay at 540 but the platform number will become 747. I will notify here when there is an update.
Build 747 will require you to update the android, desktop or raspberry pi client if in use, so be prepared ;)
Cheers.
[EDIT]
I can confirm the battery level is not handled correctly. I'm on it now. The issue is that the data type is not handled correctly. If you would have used something else then float it would not work. I'm doing an explicit cast to float and did not respect the set type as set in the device editor. Currently testing and updating.
[/EDIT] -
There currently is a new version of the server being built on the build server. The location is: http://builder.pidome.org/view/Snapshot builds/
When it's done you can click 0.1-snapshot-2015-09-06.747 and download the server. On the pi stop the server, overwrite files, and start it again. Don't worry, important data will not be overwritten (as with any update)
You can see it is done when on the left side there are no active jobs being displayed.
Let me know if it has been solved for you.
-
Could you make a screenshot of your created device it's
- Group control details
- Control details
And check in the file logs/system/appLog.txt if you got messages mentioning mysensors? (quite at the end, you can do a "tail-f log/system/appLog.txt -n 200" in putty "ctrl+c" to stop it, select lines, click (copy) and paste them)
-
Well that would give a big amount of data, and it definitely will help... If you do not mind i will send my email address using chat so i can send you files if needed what could help in solving this quicker.
-
Send via chat
-
With help from @AndrewB The issue has been solved.
The battery level via the MQTT gateway seems to need some extra attention as it is broadcasted in an unexpected mqtt path.
to show battery level using mqtt please use group id "255" and control id "V_"
Cheers!
-
@ericvdb said:
Hi eric,try to set the on command to 3A1 and the off command to 3A0 in the V_LIGHT toggle control. I know this is not what you want because this means you have to create a device for every address. And with flexible addresses you want to use the options so users can enter them.
You are using the device editor the correct way, it currently only is not implemented yet. There is a task on my to-do list to take a look on how common fields for controls can use the options created in the editor.
You know what, send an email to support@pidome.org with some of your device details, and I will come up with something. (If the programming API was ready i could have given some guidelines, but unfortunately it is not yet).
P.S. it is 00:46 here, so expect an answer tomorrow ;).
[edit]typo's[/edit]
@John
Hi John,I also stuck on the same problem as Eric has described. His post is quite a long time ago, so I don't know, if there is a solution now. The point is that I want not only transfer a status on/off to the mysensor node but the house and device code for the RF switches. I tried to do this as you have answered but if i look in the log file it say only true or false as payload to the sensor.
Is this a limitation of using V_LIGHT (allowing only boolean coded payload)? But I also tried to use other V_* like V_IR_SEND, it was the same result.
Thanks in advance.
-
Sorry for the late response, have you tried to change the datatype to string with the codes as the values?
-
Hi John,
appLog.txt
I also tried using datatype string but it doesen't work. Meanwhile I have studies the log files more detailed and found the following behavior:-
when defining the device skeletal and when updating the derived device (first approx. 25 lines in the log file V_STATUS is declared as string with values 51 resp. 52 as specified in the web interface. The entity is "Modul 433 MHz".
-
Later on, when using the toggle switch in the web interface the value has changed in the decription in the log file (see line 164 or 185) value has been changed to on/off. With this definition it seem that the mysensors-Plugin is feeded has been changed from the specified values.
My conclusion is that the change is taking place somewhere outside the mysensors-plugin.
By the way, if I change the type to string do I have to use quotation marks in the web interface?
Thanks a lot for your support.
Martin
-