From: Anthony M. <am...@sa...> - 2009-05-19 17:48:19
|
I am trying to get UPnP support working on my Linux box (Fedora Core 5). I am using the thttpd web server so I don't need (or want) the web server support included with pupnp/libupnp. What I want is for the device to show up via UPnP on the client machine, but when the user clicks on the device, the thttpd web server handles serving up the appropriate pages, content, etc. When I get the device to show up and click on it, the device ends up trying to serve up http://192.168.1.101:49152/index.html. I think I need to change the port so it goes to port 80 for the web server to handle the requests...right? If I try to disable the web server in UPnP the device never shows up in the "My Network Places". I have moved the call to UpnpEnableWebserver around, but it doesn't seem to allow the UPnP advertisement to work properly if I have the call in there. Here are the calls into the UPnP API I am using: status = UpnpInit(ip_address, port); status = UpnpEnableWebserver(0); status = UpnpRegisterRootDevice2(UPNPREG_FILENAME_DESC, "tvdevicedesc.xml", 0, 1, &DeviceCallbackEventHandler, NULL, &device_handle); status = UpnpSendAdvertisement(device_handle, 100); Any help is appreciated to assist me in figuring out what I'm doing wrong. Thanks. |