Problem with Push Button Widget on Dashbboard using IoT Cloude

Dear All,

I have started a project based on MKR 1010 Wifi including several shields. The processor controls a scientific instrument that measures several physical environmental parameters in deep oceans. The instrument is controlled by a mobile phone that receives data from, and send data to, the instrument (via a long cable).

The project uses IoT Cloud and the mobile phone app is developed by using the Dashboard function. The Dashboard is built by using different Widgets. Most of the Widgets' work as expected but I have a problem with one Widget, the PUSH BUTTON Widget.

The PUSH BUTTON is an ON/OFF function that toggles. The variable linked to the Widget is defined as a BOOL-variable and I can get the button to work exactly as desired BUT in different pictures, available over Internet, it seems like the button can work with different COLORS and TEXTS "printed" on the button.

In my case the PUSH button becomes GREEN in the periphery when the button is pressed and as soon the pressure is relieved the color disappears.

Does anybody know how I can get the button stable GREEN when it is switched ON and stable RED when it is switched OFF and how do I get the text ON/OFF "printed" on the button itself?

As a summary the question is, how to I control the COLORS and the TEXT using Widget PUSH BUTTON?

AlI advises and ideas are highly appreciated.

Best Regards: DNA_BO

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.