PDA

View Full Version : Control AWx000 devices via http strings (URL calls)



evandort
05-09-2013, 02:53 PM
Hi,

I am using the AW2000 an AW3000 streaming products, and I want to integrate these in my digitalSTROM system. digitalSTROM has been launched in the Netherlands recently (see www.digitalstrom.nl). It turned my home into a real Smart Home and offers a.o. the possibility to control IP devices via http strings (URL calls).

For example, I can mute the sound of my IPTV receiver for a few seconds if the doorbell rings, or I can turn off my WiFi access points if I leave home, simply by sending the appropriate http strings to the devices.

Is there a way to control my AWx000 devices in this way? Something like:
http://<IP address of AWx000>/api/<command>?<parameter=value>

There are lots of use cases that would make life much more convenient, like:
Turn off the device automatically when I leave home and when I go to sleep.
Turn off the device automatically when I turn on the TV. (digitalSTROM detects turning on/off the TV set by sensing a change in its power consumption)
Turn on the device and select my favorite station when I wake up in the morning. (digitalSTROM supports sending commands like URL calls at predefined times, so I can use my AWx000 as an alarm clock this way)

It would be great if someone could send me a document that describes how to control AWx000 in this way.

Thanks in advance.

Regards, Erik

Blechtrottel
05-13-2013, 07:10 AM
I've used Bubbleplayer on my Android phone.
It gave me a link like ...

http://192.168.178.32:8889/index

... after which you click you see the same as in the Airstudio APP. Saw you've to use Google Chrome or Safari browser. Normal IE won't work.

Enjoy ...

(... the IP above shown was the IP assigned to my unit ...) :rolleyes:

evandort
05-17-2013, 08:13 AM
Thanks, but that's not what I'm looking for. I'm looking for a document that describes all possible http strings to control the AWx000 devices. For my dreambox (the sat-receiver I'm using) this document looks as follows:
http://dream.reichholf.net/wiki/Enigma2:WebInterface

Is such a document available for the AWx000 products?

Thanks.

lemvigh
05-20-2013, 06:05 PM
I'm afraid that only parts of the speaker will be directly accesible through URLs. I've experimented a bit with the AW3000 and it seems like the speaker is stateful and some of the urls are relative to what you did last. But as Blechtrottel says, if you know the IP address of your device, you can go to http://{your ip}:8889/index in a browser on a pc. This will allow you to navigate the menus using the browser, and you can use this to dicsover the URLs you need - and whether they are based on the speakers state or not. For example http://{you ip}:8889/nowplay will take you to the Now Playing screen. http://{you ip}:8889/CTRL$STANDBY may set the speaker in standby. I cannot test it myself, since I'm having a problem with my speaker - it will only go in standby using the hardware button.

Selecting specific music or radio channels seems to be more difficult since this is where the speaker's state kicks in, but try to do a bit of testing with a browser and see how far you can get.

lemvigh
05-22-2013, 01:40 PM
...But if your automation system allows several sequential URLs as one command, then you should be able to do most things, since you will be able to build up the state.

lemvigh
05-23-2013, 08:57 AM
Thanks, but wrong thread I guess...

Philips - QK
05-23-2013, 09:37 AM
Yes, wrong thread. Now moving it back to the correct thread.

andreasm
05-28-2013, 08:07 PM
A RESTful API would be really great.
So the Community could integrate the speakers in custom apps.

evandort
08-04-2013, 07:20 AM
Playing around learned that the CTRL$STANDBY command toggles between on and off. The return value "playstate" then shows whether the new state is on or off.

I need at least a command to turn the device off, regardless of it's current state.

Reverse engineering is usually not the right way to find out how devices interact with their environment, and for sure it's very time consuming.

@Philips: if you want the community to integrate your products in a system, a webinterface API document is really needed. Is Philips interested in integration of its products in smart homes?

Blechtrottel
08-12-2013, 03:03 AM
Hi.
Why not use a sequence like ...

<IP-ADDRESS>:8889/index (which turns the set on, no matter what)
WAIT for 1500ms
<IP-ADDRESS>:8889/CTRL$STANDBY

... for turning off the set ?

You can mostly decode this by using Google Chrome / Inspect Element / Resources / ...

As another post mentions above, there seems to be caching in the pages involved. Based on my quick testing, you've always to ask for <IP-ADDRESS>:8889/index to make a clean start.

lemvigh
08-12-2013, 06:53 AM
If the speaker was put in standby while playing, it will resume playing when taken out of standby by going to the index page. This might not be what you want.

Blechtrottel
08-12-2013, 12:57 PM
Indeed. The set is not defined to have an one by one unique command control protocol. It requires prior knowledge. If no active playback is wanted, dirty tricks have to be applied. Call MP3Link as a source (assuming nothing is hooked up) ...

But in the end - no free lunch.