"cola007" wrote:
Downloaded the latest C# update and SSDP discovery doesn't seem to be working for me. Are there any logs that I can provide that would help out in figuring out why?
Is your roku on WiFi?
Can you detect the roku using wireshark?
The only thing I can think of that would help would be if you could step through the Discover() process in debug mode using F11 and post what each Receive is giving. It should look something like these:
http/1.1 200 ok
cache-control: max-age=300
st: roku:ecp
usn: uuid:roku:ecp:############
ext:
server: roku upnp/1.0 miniupnpd/1.4
location: http://192.168.#.#:8060/
http/1.1 200 ok
cache-control: max-age=300
st: upnp:rootdevice
usn: uuid:########-####-####-####-############::upnp:rootdevice
ext:
server: roku upnp/1.0 miniupnpd/1.4
location: http://192.168.#.#:8060/
To do this:
1) Add a breakpoint, Right Click -> Breakpoint -> Insert Breakpoint, before Discover(); is called. In the sample I have provided it's around line 61 under 'IP Settings.cs'.
2) Then Debug -> Start Debugging.
3) Once the Remote starts up click the 'Settings' Button, unless it's the first time starting up and stops at the breakpoint.
4) Continue to press F11, Step Into, until you pass 443, 'string resp = Encoding.ASCII.GetString(buffer, 0, length).ToLower();'.
5) Hover your mouse over 'resp' and click on the little magnifying glass. This should open a 'Text Visualizer' window the the source of the 'resp' string.
6) Copy that into your Response to me, you can censor out your roku info for me as I just need what I posted.
7) Continue to do this until it times out.
Another thing to try would be to extend the send and receive timeouts found in the 'Roku .NET' source, lines 424 and 425. Right now there at 500ms each which handles fine on my wireless laptop to my wired roku. With this you would have to rebuild Roku .NET and use the new DLL when you rebuild the Remote.
Let me know if any of this helps.
You can PM me with a IM name if you need more help. Which I'm always happy to give.
EDIT: I've updated Roku .NET so you can define your own timeouts for the Discover() process, and the Roku Remote Example so you can choose a longer timeout when searching the network.
"If I had a nickel for every time I was wrong, I'd be broke." Stephen Colbert