Page 1 of 1

Selector switch URL's

Posted: Sunday 18 August 2019 22:06
by Apievuisy
Hi,

I have a Denon Receiver which responds wonderfully to http requests. When i fire a command in the web browser, the receiver responds accordingly.
I made a switch to power the Denon on and Off. This works fine.
OnOff.png
OnOff.png (203.73 KiB) Viewed 2024 times
Then i wanted to expand the capabilities by creating a selector switch to change the source of the receiver.
selector.png
selector.png (198.81 KiB) Viewed 2024 times
In the actions pane i added the various urls to control the receiver. This does not work. The receiver does not respond to my requests.
Could it be that the selector switch does something to the urls which makes them unreadable for the receiver?
Here is an example of a url that works in the web browser but not from the selector switch:
http://192.168.1.244/MainZone/index.put ... eStatus%2F

Then i tried to fix this in blockly:
blockly.png
blockly.png (10.49 KiB) Viewed 2021 times
This also does not work, i think because the "Quoted" string is not recognized... when i tell blockly to look for != "Game" then the script fires and acts accordingly.

Any help would be greatly appreciated!

Re: Selector switch URL's

Posted: Monday 19 August 2019 1:01
by StanHD
Hi,

Did you change your switch type from "On/Off" to "Selector"?
This can cause problems. If so then try it again by creating a new switch from Dummy hardware type.

With your Blockly, try using the Selector "Level" in the If block:

If Selector = Level 20%

Sent from my SM-T820 using Tapatalk


Re: Selector switch URL's

Posted: Monday 19 August 2019 9:43
by Apievuisy
StanHD wrote: Monday 19 August 2019 1:01 Hi,

Did you change your switch type from "On/Off" to "Selector"?
This can cause problems. If so then try it again by creating a new switch from Dummy hardware type.

With your Blockly, try using the Selector "Level" in the If block:

If Selector = Level 20%

Sent from my SM-T820 using Tapatalk
Hi, thanks for your reply!

I think i didnt change the type, but i will check tonight if making a new dimmer switch will do the trick.

I also tried the level percentages in blockly and this did not work..

Re: Selector switch URL's

Posted: Monday 19 August 2019 10:39
by StanHD
Apologies, you're correct.

The "If" should work with the level name and the "Set" should work with the level name or level %. The below is working:-

Image

Both "Kitchen Extract Manual" and "Extract Fan" are selector switches created from the Virtual Dummy hardware.

Re: Selector switch URL's

Posted: Monday 19 August 2019 11:17
by waaren
StanHD wrote: Monday 19 August 2019 10:39 The "If" should work with the level name and the "Set" should work with the level name or level %. The below is working:-
@StanHD, does the set level name also works for labels other then Off ? (cannot test right now)

btw. Please use uploaded images ( the link might not work in the future )

Re: Selector switch URL's

Posted: Monday 19 August 2019 12:06
by StanHD
waaren wrote: Monday 19 August 2019 11:17
@StanHD, does the set level name also works for labels other then Off ? (cannot test right now)

btw. Please use uploaded images ( the link might not work in the future )
@waaren, I don't think it does. I just looked through my Blockleys and in every instance (other than "off") I have used the Level %.
(I also use 0% to set switch to off)

I will find out about uploading images, thanks for the tip. :)

Re: Selector switch URL's

Posted: Monday 19 August 2019 14:57
by StanHD
OK, so here's some testing:-

Neither Set instructions work:
Blockley1.JPG
Blockley1.JPG (25.42 KiB) Viewed 1970 times
Both Set instructions work
Blockley2.JPG
Blockley2.JPG (25.23 KiB) Viewed 1970 times

Both Set instructions work
Blockley3.JPG
Blockley3.JPG (26.02 KiB) Viewed 1970 times
So I was incorrect (again :cry: ). When I analyzed my existing Blockleys that utilise "Off", I found them not working correctly. (I was sure they used to work), I stand corrected.

Re: Selector switch URL's

Posted: Monday 19 August 2019 21:24
by Apievuisy
Thanks for the reply's. They pointed me in the right direction :)
The substype of "Denon Source" was lightwave-RF and not Selector Switch.
I deleted the device and made a new one, after that i added the various url's.
Now evertything works as it should.

Thanks again!

Ps. Is it possible to mark this topic as solved?

Re: Selector switch URL's

Posted: Monday 19 August 2019 23:21
by waaren
Apievuisy wrote: Monday 19 August 2019 21:24 Ps. Is it possible to mark this topic as solved?
As topic starter you should be able to do that yourself. Do you see the V symbol ?
Solved.png
Solved.png (54.25 KiB) Viewed 1942 times