Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Messages - bherbie

Pages: [1] 2 3
Developers / Re: [SOLVED] Device Template using SOAP
« on: October 23, 2014, 03:03:39 am »
Reading the thread above I can't see any mention of the registration process - without it you may get intermittent or unreliable control capability.
Correct.  I did this simply by using php cURL from the command line. The issues I was running into is my particular model does not use the same ports as the Sonys that I could find the protocols for. I did register my core as a device before I began setting up the template for the device itself and I still have some kinks to work out such as hard coding in the magic packet for WOL.


Developers / Re: [SOLVED] Device Template using SOAP
« on: September 23, 2014, 11:56:15 pm »
Any progress on the subject?

I have been able to build a template that works using SOAP although I am a ways from being finished.  The code provided by mkbrown69 was enough to get me pointed in the right direction as the Sony interface expects information in its header that is different then what mkbrown69 needed for his.  Also, I am not sure if it is just my setup, but the buttons work intermittently with the this template.  I see a lot of 'Could Not Handle This Message' errors in the logs and after a quick reload it works fine for a click or two and then it does it again.  Once again - not sure if it is my lack of knowledge in Ruby or if there is another issue at play.

Also, my device uses WOL as its 'power on' and I have hard coded the device number into the template (i.e. system('sudo /usr/pluto/bin/ --dev 125') and once I get a more elegant solution, I will add it (or could this be part of the issue noted above?)

So long story short, see if you can make any progress using the code snippets outlined in this thread or post back if you need more of a start as I am in the middle of getting a wiki page put together once I know more myself.


Developers / Re: [SOLVED] Device Template using SOAP
« on: September 08, 2014, 04:36:46 am »
Are we putting this in a wiki page? :)

Absolutely.  Just need to work out a few more kinks...


Developers / Re: Device Template using SOAP
« on: September 08, 2014, 03:06:23 am »
it always comes down to the details

Code: [Select]
s+= "Content-Type: text/xml; charset=\"utf-8\" \x0D\x0A"
changed to
Code: [Select]
s+= "Content-Type: text/xml; charset=utf-8 \x0D\x0A"
fixes my problem and it now works as expected.  Thanks for the help!


Developers / Re: Device Template using SOAP
« on: September 06, 2014, 06:20:27 pm »
I made the suggested changes and still get the same bad request error.  Here is the log:

Code: [Select]
06-09-2014  10:05:50  *****sending AAAAAwAAHFoAAAAWAw== ******
06-09-2014  10:05:50  POST /upnp/control/IRCC HTTP/1.1
User-Agent: MediaRemote
Content-Type: text/xml; charset="utf-8"
Content-Length: 374
Content-Transfer-Encoding: text
SOAPAction: "urn:schemas-sony-com:service:IRCC:1#X_SendIRCC"
Connection-Close: close

<SOAP-ENV:Envelope xmlns:SOAP-ENV="" SOAP-ENV:encodingStyle=""><SOAP-ENV:Body><m:X_SendIRCC xmlns:m="urn:schemas-sony-com:service:IRCC:1"><IRCCCode xmlns:dt="urn:schemas-microsoft-com:datatypes" dt:dt="string">AAAAAwAAHFoAAAAWAw==</IRCCCode></m:X_SendIRCC></SOAP-ENV:Body></SOAP-ENV:Envelope>
06-09-2014  10:05:50  HTTP/1.1 400 Bad Request
Connection: close
Date: Sat, 06 Sep 2014 16:05:49 GMT
Server: Linux/2.6
06-09-2014  10:05:50  UPnP/1.0 Sony-BDP/2.0

and sending the code from my php script works fine and it looks identical to the ruby code so I am not sure where to go.  I tried pulling up your template and when I click on the ruby codes it kicks me out to the admin home page - I completed an sqlCVS update and get the same thing so I am not sure if I am missing something in the initialize section or not.

any help you can provide is greatly appreciated!


Developers / Re: Device Template using SOAP
« on: September 05, 2014, 04:10:01 am »
thanks for the help!  I know it is close and probably something I am overlooking as I am a noob in ruby.

here is the code

Code: [Select]
def log(word)
   logTime =
   timeStr = logTime.strftime("%d-%m-%Y  %H:%M:%S  ")
   $logFile.print(timeStr + word + "\n" )
   print(word + "\n")

def RemoteKey(key)

soapBody ='<?xml version="1.0"?>'
soapBody ='<SOAP-ENV:Envelope xmlns:SOAP-ENV="" SOAP-ENV:encodingStyle="">'
soapBody+='<m:X_SendIRCC xmlns:m="urn:schemas-sony-com:service:IRCC:1">'
soapBody+='<IRCCCode xmlns:dt="urn:schemas-microsoft-com:datatypes" dt:dt="string">' +key+ '</IRCCCode></m:X_SendIRCC>'

s = "POST /upnp/control/IRCC HTTP/1.0 \x0D\x0A"
        s+= "User-Agent: MediaRemote \x0D\x0A"
s+= "SOAPAction: \"urn:schemas-sony-com:service:IRCC:1#X_SendIRCC\" \x0D\x0A"
s+= "Content-Type: text/xml; charset=\"utf-8\" \x0D\x0A"
s+= "Content-Length: "+soapBody.length.to_s+" \x0D\x0A"
        s+= "Content-Transfer-Encoding: text \x0D\x0A"
        s+= "Connection-Close: close \x0D\x0A\x0D\x0A"
s+= soapBody.to_s

log("*****sending " +key+ " ******")

and then to send the key:
Code: [Select]

Developers / Re: Device Template using SOAP
« on: September 05, 2014, 02:50:20 am »
Have you seen this thread on Sony SOAP commands?  Might be helpful...,3

Yes, I have seen this and my code is based on a hybrid of that and yours.  It works flawlessly from the command line using php cURL but I must be doing something incorrect when translating it to ruby.  The logfile shows the command being sent and it looks correct but the response looks like this:

Code: [Select]
04-09-2014  18:43:44  HTTP/1.1 400 Bad Request
Connection: close
Date: Fri, 05 Sep 2014 00:43:44 GMT
Server: Linux/2.6
04-09-2014  18:43:44  UPnP/1.0 Sony-BDP/2.0


Developers / Re: Device Template using SOAP
« on: September 04, 2014, 03:39:21 pm »
Thanks Mike!

This is exactly what I was looking for - I read your post about it when you were developing it but didn't see a device template for it.  I tried out your code and I am getting back a `bad request` error which in my experience has been a malformed SOAP request so I am still working with it to see if I can iron out the issues but I am by no means a ruby expert.

Again, thanks for the nudge in the right direction!

Developers / [SOLVED] Device Template using SOAP
« on: September 03, 2014, 08:17:40 pm »
Recently I had to retire my OPPO Blu Ray Player with its RS232 interface and went looking for something new.  Of all the Blu Ray choices out there, I settled on a Sony for its cost and features - one of which is its ability to accept network commands via SOAP.  I have been able to send commands to my Sony using command line and have fleshed out exactly what it can and cannot do and now I wish to create a device template to integrate this into my LMCE system and I have a few questions...

First of all, I have looked in the GSD source code and cannot quite figure out if it is possible to send headers to use SOAP in Ruby.  In my testing (using cURL) there is a header that needs sent in order for this to work - if it is not present, the player disregards the message and returns a 404.  So my question is - can I send a header to make this work and if so - how?

I have seen other posts about using SOAP in a device template but I do not see where it has been successful and I do not see any templates that currently use SOAP...

thanks in advance,

Installation issues / Re: 1204 MythTV - Can't Configure HDHomerun
« on: August 17, 2014, 09:17:12 pm »
I experienced this same issue and as soon as I set up my own video source and mapped to that - it works just fine.  I tried changing the default by adding my username to the Schedules Direct and save it but that too had no affect.  Set up your own video source, map your inputs to it and you will be up and running.


Users / Re: NAS - FreeNAS, LMCE or something else?
« on: July 12, 2014, 01:23:05 am »
IMHO FreeNAS is the best way to go for several reasons: ease of setup, ZFS, Plug and Play with LMCE, etc.  In my setup, I use FreeNAS setup with RAID 5 and with a dual NIC - one for my personal network and one on the LMCE network.  Once you have your FreeNAS setup, you can add Transmission, Sickbeard and Couch Potato to download media that will automatically show in LMCE...

Users / Re: old server proliant ml530 G1
« on: May 20, 2014, 11:06:30 pm »
I have tested older hardware with LMCE and my first 'production' Hybrid was the same ml530 you are running now and it ran fine.. at first.  Mine began to slow down and I started seeing lagging\jerking video on MDs during playback and long log in times when trying to ssh, long boot times on MDs and some other weird behavior.  After a lot of hair pulling and late nights on the forum looking for answers, I stumbled across a thread here (sorry don't have the link) talking about the network is one of the most crucial parts of this setup.   

I changed out all of my cheap switches with higher priced Gigabit switches and the problem went away.  Now I only use Gigabit Nics and Gigabit network equipment and haven't seen this issue out of any subsequent build I have done and there have been quite a few of them.

As a side note, you will want more RAM then 2.5GB and some may say that is the issue too...


Users / Re: No sound on cisco 7970
« on: November 27, 2013, 09:28:17 pm »
I'm not sure how many folks actually use the 7970 with LMCE.  I have one and installed it for use mostly as an orbiter in my bedroom but the orbiter part runs extremely slow and some parts of it just aren't functional(floor plan for lights and climate).  I am running 10.04 and thought that the telecom was fixed in the RC but I have never had sound on the 7970.  I have sound on my MDs during telecom but the other party cannot hear me so there are parts of the telecom that are working.

I know this isn't helpful to correcting the issue and I am just letting you know that it doesn't work for me and because of the latency with the orbiter, I am not sure a lot of folks are even using this phone.  I know there are some threads about the 7970 here on the forum but none of them are related to the sound issue - just mostly how to install.


Users / Blu-ray Player or Blu-ray Drive?
« on: October 27, 2013, 01:43:44 am »
I currently have an Oppo bdp-83 with rs232 controls and it now has some issues.  It does not play a lot of the newer discs and there are some playback issues with the ones that do work and the firmware upgrades do not resolve these issues.  So it leads me to ask the question if I should get a new Blu-ray player to replace this one (and if so, what model works best with LMCE) or just add a blu-ray drive to my media director? 

From previous experience I know that blu-ray drives do not work well with Linux (or has this issue been resolved?) but it would provide a more transparent experience when using LMCE. 

Thoughts or suggestions?


Users / Re: Need some dedicated testers.
« on: September 26, 2013, 03:22:52 am »
My Razzr met an untimely death and I now have a Motorola Moto X running android 4.2.2 and testing the qt4 nightly build.  This is a screen shot of what I get, nothing more and nothing less.

Pages: [1] 2 3