Direction of the wind

Is there any way to display the direction of the wind at Cayenne. Sorry if is very simple but i can`t find the way.

what is the device you are using to get wind direction? there is no data type for widget but you can use value widget to display the wind reading.

I use a device that give me an analog readin, between 0 - 5v, 0v is north , 2,5v is south ā€¦

so you want to display this value on cayenne?
Next, which device are you using to connect to cayenne?

Iā€™m using an arduino with ethernet, i would like to show something like N, S, W, E ā€¦

you can create 4 two state widget on the cayenne dashboard to show the respective direction and code your arduino to publish 1 to the respective widget.

if (wind == 0)
    Cayenne.virtualWrite(1, 1, "digital_sensor", "d");
    Cayenne.virtualWrite(2, 0, "digital_sensor", "d");
    Cayenne.virtualWrite(3, 0, "digital_sensor", "d");
    Cayenne.virtualWrite(4, 0, "digital_sensor", "d");

this will make the widget with channel 1 HIGH indicating that the wind is blowing in the north.
similarly, do for other values.

1 Like

Thanks for your answer !

To add on to what Shramik said, there are not yet text widgets which is why he suggested that workaround.

Ok, thanks, do you think that will be available text widgets soon ?

@shramik_salgaonkar might be able to answer. I do not know.

not soon, maybe in the third quarter.

Perfect, I will be attentive.