Hi
I am attempting to create a slider for the volume for my Sonos device. I have a horizontal line, which lights up green as you drag your finger along, and the volume increase and decreases (although with an annoying lag*).
1) How does one create a speaker icon to drag along the bar, like the Sonos app?
2) I have a plus and minus at either end of the horizontal line - if I tap these, how do I get the green horizontal display to react accordingly, ie give visual feedback?
If anyone has a project to share where they have implemented such a thing, I'd be grateful...
Thanks
Karen
*Has anyone else noticed that adding flags creates a noticeable delay in response times?
Volume Slider
Re: Volume Slider
For the plus and minus buttons, the next release of the app (due in a week or so) allows you to specify commands for numbers using [+] and [-] followed by a value, eg to increase a number by one, the data you would enter as the command would be:
Action Type: Set a Number
Data: [+]1
Adding flags should not affect response times at all - if you'd like to email your project to [email protected] we can have a look to see why you are experiencing issues.
Action Type: Set a Number
Data: [+]1
Adding flags should not affect response times at all - if you'd like to email your project to [email protected] we can have a look to see why you are experiencing issues.
Re: Volume Slider
Ah - I actually tried that, so that is a good, intuitive approach! I look forward in having it actually work, in the next release.Action Type: Set a Number
Data: [+]1
I have implemented a mute toggle button, but before I did that, when I was learning the basics, I had a simple MUTE=OFF if flag SonosMute = ON, followed by a play command. The play reacted immediately before I added the flag, but had a slight (but noticeable) delay after. May just be my network, though.Adding flags should not affect response times at all - if you'd like to email your project to [email protected] we can have a look to see why you are experiencing issues.
Thanks for the support!
Karen
PS - any ideas for sliding an icon along a bar?
Re: Volume Slider
For sliding an icon across the bar, you simply need the '100%' image to have the icon at the top (or the right if using a horizontal gauge), gauges just slide one image over the top of another. The only issue would be when sliding to 0%, as the icon would completely vanish. You might be able to combat that by altering your 0% image to show something at the bottom, but it depends on the icon..either that or use a normally hidden icon that is shown in response to a flag, which is set when the gauge goes to 0%...
Re: Volume Slider
Okay, I've downloaded the new version, and tried the [+]1, but it doesn't work.
I have a speaker icon which sets a VolUp flag to ON while pressed, and OFF when released, and another which sets a VolDown flag in the same manner (ie as for a repeating key).
I have a custom number variable (SonosVolume) which manages the commands to the Sonos device, increments the volume by 5 between the values 5 and 95.
I have a page load action which sets SonosVolume to [+]5 (repeating every 0.25 sec) while VolUp flag is ON.
I have another action which sets SonosVolume to [-]5 (repeating every 0.25 sec) while VolDown flag is ON.
It does nothing. In fact, tapping either of the icons (whether the page loads are there or not) results in the volume jumping down to about 5%.
Should this work/am I doing something wrong, or am I just trying to force the gauges/numbers to do something they're not designed to do, and thus what I'm attempting will never work?
Thanks
Karen
I have a speaker icon which sets a VolUp flag to ON while pressed, and OFF when released, and another which sets a VolDown flag in the same manner (ie as for a repeating key).
I have a custom number variable (SonosVolume) which manages the commands to the Sonos device, increments the volume by 5 between the values 5 and 95.
I have a page load action which sets SonosVolume to [+]5 (repeating every 0.25 sec) while VolUp flag is ON.
I have another action which sets SonosVolume to [-]5 (repeating every 0.25 sec) while VolDown flag is ON.
It does nothing. In fact, tapping either of the icons (whether the page loads are there or not) results in the volume jumping down to about 5%.
Should this work/am I doing something wrong, or am I just trying to force the gauges/numbers to do something they're not designed to do, and thus what I'm attempting will never work?
Thanks
Karen
-
- Posts: 37
- Joined: Mon Jul 16, 2012 3:35 pm
- Location: UK
- Contact:
Re: Volume Slider
karenlee wrote:Okay, I've downloaded the new version, and tried the [+]1, but it doesn't work.
Thats a new function that has yet to be released. I'm guessing there will be an updated version of the iOS app and Designer to support this.DemoPad wrote:For the plus and minus buttons, the next release of the app (due in a week or so)
Re: Volume Slider
Oh, okay! I downloaded the new designer yesterday, and it says: You can now use [+]1 and [-]1 actions to increase or decrease number variables. But silly me, I skimmed this part without taking it in properly (requires app version 1.4.1 or later). My app version is 1.3.9.
Thanks very much for your response, saved me some more hair-tear
Thanks very much for your response, saved me some more hair-tear