Trying to figure out how a virtual button on a dashboard works. Seems like the only action I can pickup is 'pushed'.
Here is what I am trying to do. I have an application where we are controlling some automated windows. I want the ability to jog the windows. So what I wanted to do is put a button on a dashboard. As long as the button is held the window moves. When I release the button the window stops.
That is correct. More specifically, this just calls the pushed() command on the device with your specified button number. This can be used to simulate a "digital" push for a real/physical button device (if the driver implements this command; it's technically optional) or by the same means effectively cause the "pushed" event to fire on a virtual button device (which of course will not generate events unless commands are run on it). But other actions, like held(), are not choose-able.
This is a different problem: Dashboard button tiles (or any Dashboard tile really) only send one command at the moment they're tapped. I don't technically know whether this happens on click/push or "release," but regardless, you only get one action.
Have you considered a different approach? Maybe two Dashboard button tiles, one of which you can press to start the movement and the other to stop? (You can do some trickery to make this appear to take the same amount of space as a single tile--like making everything else double--but it will be two taps required on different areas either way.) Or a level/position slider you can use to just move the shade position where you want it?
I knew I could do it with 2 buttons or switches. Just trying to make it easier on someone who doesn't really understand. Probably the easiest I will use one virtual switch. If motor is off it will turn it on, if motor is on it will turn it off.