Plugin: Popcorn Hour - Remote

Plugin has been unpublished by me. I don’t want to continue to work for such a company.

Plugin: Popcorn Hour - Remote

After reading this I decided to purchase a Popcorn Hour PopBox v8. But it seems like the article mentioned is just a myth, so I decided to start developping my own plugin to be able to control the PopBox from the vera.

IMPORTANT: Development of this Plugin is not continued:
http://forum.micasaverde.com/index.php/topic,9518.msg66762.html#msg66762

Description:
This plugin creates a device which allows controlling a Popcorn Hour Mediabox with your vera (only tested with PopBox v8 as for the moment). Up to now the following functions have been implemented: power, suspend, mute, menu, info, subtitle, setup, return, left, right, up, down, enter, play, pause, stop, rewind, fwd, prev, next, red, yellow, green, blue. These commands can also be used in scenes in the advanced tab. As a proof of concept the plugin also reads out some states of the mediabox. In example this means it provides events to give you the possibility to run a scene if a movie is playing or paused. More to come in the next version…

Hardware:
This has only been tested on UI5 on vera2 and vera3.
Up to now the plugin was only tested on a Popcorn Hour PopBox v8.
I guess it should also work with PopBox 3D, A-200, A-210,C-200,A-300 and C-300. Please let me know if it does!

Variables:
IP: The ipaddress of the mediabox, has to be entered manually.
InfoFirmware: The actual firmware running. (pulled directly from device)
InfoNet: The actual network status. (pulled directly from device)
InfoVideoState: The actual state of a video playing [i.e. play, pause, buffering, no video playing]. (pulled directly from device)
InfoAudioState: The actual state of a audio playing [i.e. play, pause, buffering, no audo playing]. (pulled directly from device)
InfoCurrentApp: The actual app running [i.e. flashlite, screensaver, VOD_playback]. (pulled directly from device)
InfoConnected: Shows if mediabox is connected.
Port: Allows to set a custom port, standard is 8008.
UpdatePeriod: Is the update period in seconds. Allows to set how often the above variables are updated.
PowerOnCommand/PowerOffCommand: Allows to set custom http calls for turning the mediabox on and off. (i.e. I used a separate wall plug to turn my popbox on and off completely). On command will not work without a separate zwave device since you can’t turn on a network device via the network which is turned of. Example: http://ipaddress:3480/data_request?id=action&output_format=xml&DeviceNum=6&serviceId=urn:upnp-org:serviceId:SwitchPower1&action=SetTarget&newTargetValue=1

ServiceID:
urn:upnp-org:serviceId:PHour1

Scene Events:
As for the moment only the event (to trigger scenes) “Video Play State” has been implemented. This has three possible states “video is playing”, “video is paused” and “no video is playing”.

Version 1.0
This is a very basic release of the plugin. It serves as a proof of concept to show that commands can be sent to the mediabox and some states are read out.
After the installation the ipaddress of the mediabox has to be entered in the device’s advanced tab.

UI4 (Manual installation, not tested):
http://apps.mios.com/download-plugin.php?PK_Version=3678

UI5 (Installation through apps.mios.com):
MiOS Apps

Donation:
Since I want to keep this plugin free I am always glad to receive donation’s: DONATE

Please request / wish functions for feauture releases here, I will see what i can do.

Filed Requests:

  • Events for Audio Play State
  • Events for Current App
  • Options for configuring important settings from vera
  • Buttons / Command for Volume Settings
  • Show name of file playing
  • Show ON/OFF state of device

AFAICT, my PCH A110 (latest firmware) doesn’t support the interface you’re using for the communication with the PCH.

The A110 UPnP-advertizes itself as an UPnP compatible device, so it should be possibe to control the A110 via UPnP.

service: urn:schemas-upnp-org:service:AVTransport:1
actions: Pause, Play, Stop, Seek, …

BUT:
Pause does work, but you cannot UnPause the media (neither by invoking Play nor Pause again) - what a silly UPnP implementation!

I strongly recommend to install ‘DeviceSpy’ (part of ‘Developer Tools for UPnP technology’ - Windows only) and to check whether your PCH has a more complete/less buggy UPnP implementation.

If going the UPnP route, you could borrow some code from the Sonos plugin that is based on UPnP.

Thanks for the input ap15e. I will investigate that sometime this weekend, I am always happy to learn new things. And thanks for proposing a plugin to borrow some code.

You know whats funny, even with my approach and the Popbox v8 the pause command does make problems, you can’t unpause using the pause button, not even when using the original remote.

[tt]http://support.popbox.com/article.aspx?ID=1141[/tt]

“Added an updated uPnP stack. (Mainly a benefit for developers that use the uPnP protocols.)” - sounds promising.

It does, but I have a PopBox v8, not a PopBox 3D, and it doesn’t say anything about upnp in the last firmware release for this device:
http://support.popbox.com/article.aspx?id=1137

I signed up as a developer on developer.popbox.com, and on the documentation there (where I got my ideas from) it says nothing from upnp, but will check again this weekend.

Hi

Your plugin works very well with an A300
super good job

@Chixxi

if you can help me about this very thanks because i don’t understand al about a plugin developpement

links[url=http://forum.micasaverde.com/index.php/topic,9520.0.html]http://forum.micasaverde.com/index.php/topic,9520.0.html[/url]

IMPORTANT MESSAGE:

I will not continue to develop / update / test this plugin for the following reasons (I owned my PooBox for two month and I hate it!):
http://forum.micasaverde.com/index.php/topic,9879.0.html

If anybody is interested in becoming the owner of this plugin an continue to develop, let me know, I will give it to you.

I have a little programming experience. Could you send me the source code? I want to give it a try. I have no experience with a popcorn. and i do not no where to start.could you give a little startup chixxi?

Greatings Peter

Use the Link for manual installation in the first post of this topic or download the files directly from your vera if you have the plugin installed.

Use the wiki and this forum to learn how to create plugins, its not really hard ;D