Comments (6)
- The forecast field is missing its text value and it is showing always 0 instead, like so:
I think it is related to how you map the MySensors field data types. Here at plugin/gateway/provider/mysensors_v2/constant.go you map it as a float type, but according to the MySensors Protocol 2.x documentation it should be a string of either "stable", "sunny", "cloudy", "unstable", "thunderstorm" or "unknown". Your old v1 controller seems to intercept that correctly and shows for example the sun or the cloud symbol. Do you intent that to do the same also in your new v2?
I do update V_FORECAST
as string. That will help to resolve this.
at this time, in v2.0 dashboard we do not have symbol display option. So for now it shows the string only.
To support symbol on dashboard, I have added a request in mycontroller-org/web-console#2
- Regarding the data types it seems when the type none is mapped a string can be displayed for a field. For example this is the case for your old v1 style RSSI indicator message:
So maybe the first point can be partly resolved by changing the type. Furthermore do you intent also reuse your old style RSSI message to let it show at the node status page? Or do you want to support either the MySensors I_SIGNAL_REPORT_REQUEST feature or the NodeManagers signal sensor to show its value at the node status page? In my case the later solution would fit the best because our node is sleeping most of the time without smart sleep to conserve power.
For easy maintenance, I am not going to support this option in V2. However, We can achieve this by using a script, I will update the script soon.
It is good idea to implement MySensors native option to get RSSI. Please create a ticket with details, If have an idea on MySensors native support.
- Currently the internal message for the battery percentage is not showing up anywhere. Also there your old v1 controller would show the percentage on the node status page. The MySensors implementation is similar as the NodeManagers SensorSignal solution but it is using an internal message type.
Did you check it on the node details page? Please let me know if you
Sure I will check this and report back.
Thanks @j54n1n
from server.
93d3fdb fixes V_FORECAST
issue
from server.
@j54n1n I have added an option to display images based on the field value. I believe this can satisfy the forecast status display.
Please let me know if you face a difficultly.
Displaying icon is not implemented yet. mycontroller-org/web-console#2
Widget configuration
Here I have used to display motor status based on a field value. You can adjust the value based on your requirement.
# cat mycontroller.yaml
...skiped content...
directories:
data: /mc_home/data
logs: /mc_home/logs
tmp: /mc_home/tmp
secure_share: /mc_home/secure_share
insecure_share: /mc_home/insecure_share
# ls mc_home/secure_share/
fan_off.png fan_on.png
from server.
Now supports icon too. details are in mycontroller-org/web-console#2
from server.
@j54n1n
The following script can convert MyController v1 properties into a field in MyController v2.
Add this script on the field V_VAR5
(click on Update Javascript
)
// script to convert MyController v1 properties in MyController v2
// creates new properties based on the name mentioned here
let key = ""
let parsedValue = ""
if (value.includes("p:rssiAsQty")) {
key = "rssi_quality"
parsedValue = value.replace("p:rssiAsQty=", "")
} else if (value.includes("p:ip=")) {
key = "ip"
parsedValue = value.replace("p:ip=", "")
} else if (value.includes("p:heap-f=")) {
key = "heap"
parsedValue = value.replace("p:heap-f=", "")
} else if (value.includes("p:host=")) {
key = "hostname"
parsedValue = value.replace("p:host=", "")
} else if (value.includes("rssi:")) {
key = "rssi"
parsedValue = value.replace("rssi:", "").replace("dBm", "").trim()
}
if (key.length == 0) {
key = "invalid-property"
parsedValue = value
}
const finalResult = {
value: value,
labels: {
controlled_by: "custom_script"
},
metricTypes: {
rssi_quality: "gauge_float",
ip: "none",
heap: "gauge",
hostname: "none",
rssi: "gauge"
},
}
// console.log("key:", key, ", Value:", parsedValue, ", ORG:", value)
finalResult[key] = parsedValue
result = finalResult
from server.
@j54n1n I believe I addressed all the requests and closing this issue.
If you feel something missing, kindly reopen with the details. Thanks!
from server.
Related Issues (12)
- Layout is a little messy, and it is a little difficult to understand specificity of each stats, HOT 2
- MySensors naming scheme HOT 3
- Analytics leads an issue on no internet
- delete all the children elements of a resource
- server is not running on disconnected environment
- Gateway mqtt : "error on subscription:connection lost before" HOT 9
- MySensors native RSSI support
- Concurrent map read/write race condition at startup HOT 2
- support sleeping node HOT 1
- Post Webhook Handler Error
- nill pointer exception in tasmota gateway
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from server.