UPnP Server and Devices (Media Receivers)
What is UPnP?
UPnP stands for "Universal Plug and Play". It is an architecture for devices to interact with other Universal Plug and Play devices or software. The most common type of device used with Media Center is a Media Receiver.
What are Media Receivers?
Media Receivers are devices that sit next to your stereo or TV and play music/photos from your computer on the stereo/TV. They serve as a connection hub between your home network, home theater or TV, and computer. With a Media Receiver next to your home stereo or TV, you can access the digital music or photos stored on your computer and play them on your stereo or TV, even when the computer is somewhere else in the house. The media receiver connects to your computer via an internet connection (ethernet or wireless), and it connects to your TV or stereo via the old-fashioned way-with cables.
To set up a UPnP Device
- Go to the organization tree and select Services & Plug-ins > UPnP Server.
- Set your UPnP Server Options by selecting the Options button in the content pane (to the right). See below for what the options mean.
- Exit Options, and then click on the Start Server button (you only need to do this once; it will restart automatically every time Media Center opens, until you manually select Stop Server).
If a media receiver is already on the network, and the server is started, the receiver should pick up the server right away. When a media receiver is first turned on, if the server is already started, the receiver should pick up the server. Some receivers may not do both correctly, so try both.
To View your Schemes
- In the tree select the View Scheme you want to make available to the device. Make sure that the View Scheme is a child of "Audio", "Images" or "Video".
- Right-click and select Edit View Scheme.
- Check "Show in Theater View".
To access Options, select Services & Plug-ins in the organization tree, then UPnP Server. Select the Options button in the content pane to the right.
- File Conversion. You can convert files to other formats (such as MP3 or WMA) as they are streamed. All devices are limited in the types of files they can play. If your content is stored in a different format (such as APE) or if the bitrate needed to transfer the file is too great with your network, then you need to convert the file (either to a format that is handled or to a lower bitrate).
- Encoder. Select the encoder to use when converting files (see above).
WAV cannot be used as an encoder - it needs to process the entire stream and then write metadata at the beginning.
- Specify the TCP port to use.
- Warn on unrecognized NOTIFY: Leave this disabled unless you are encountering problems. If that is the case, enable it, and also enable [[Debug Logging. In the Debug Logging menu, select "service" as the type of events to log.
- Receiver. This should be set to automatic, but you can set it manually by selecting your device from the drop-down menu. Important Note: Check the status messages to make sure your device was correctly identified.
- Shrink Large Images shrinks JPEG images larger than 640x480. It is useful with the DSM-320 that will otherwise refuse to display large images.
- Replace Empty Genre is required for the NETGEAR MP101, and possibly others. It replaces blank genres with "Unknown". The MP101 will otherwise refuse to play tracks with blank genres.
- Use Flat URLs is required for the SMC EZ Stream and the Terratec Noxon. These receivers cannot handle complex URLs (internal to the protocol) and this hack changes the URLs to simpler ones.
- Include SessionID must be turned off for Roku. It may be required for others.
- No server header must be turned on for the D-Link DSM 320. It stops the emission of an HTTP Server header.
- Allow Visual Content should be selected for devices that can display pictures or movies.
- Filter International Characters should be selected if the device cannot detect or play content with international characters in the filename or the tags. It replaces all characters except 7 bit ASCII with a "?". At this time, I know of no devices which properly display international characters.
- Skip Child Count may be selected if the device seems to take too long to browse media in the Organization Tree. Deselect if this causes problems with browsing.
- Log File Requests is turned off by default. When turned on, it will log messages to the status window each time a media file is requested. Some devices, like the DLink DSM-320, make many requests per second to retrieve a single video file. If these requests are logged, they slow down the server enough to interrupt playback.
Note: Choosing Advanced in the Receiver window will leave the options for the last selected device. They can then be changed. This is useful when you want the options to be the same as for a particular device with only one change.
UPnP and Random Smartlists
When a UPnP device asks for information about collection of songs (a container in UPnP protocol-speak), it may ask several questions in a row about the same collection. It may ask when first seeing the collection as a child of the current collection, and then again to find out how many songs when that child is selected, and then again a few times for information about the songs making up that collection.
If the collection is a smartlist with random sorting, the random shuffling cannot be applied for every query. The order of the songs would be different, and even the number of songs may be different. The UPnP device, in asking the sequence of questions, assumes the collection to be the same songs in the same order.
To make UPnP devices work well with random smartlists, the UPnP server keeps track of which collections have been queried recently. If a collection is far enough away to mean that the user has browsed to a different portion of the tree, then the next time the smartlist is visited a new order will be returned. Far enough means at least the grandparent of the smartlist, or a nephew or an aunt. Merely browsing to the parent and back is not enough, nor a sibling.
UPnP and International Characters
At this time, only the Roku SoundBridge M500 and XBMC support international characters. As pointed out here by Horse, the Denon does not. For devices that do support international characters, de-select the Filter International Characters option.
Ignoring Some Network Interfaces
Media Center 13 only.
Today's computers often have several network interfaces available, and you may want to ignore some of these for UPnP. In particular, if there is a control point on the same computer as the UPnP server, you will want to ignore all interfaces except for those that have UPnP devices on them. This is done with a registry key:
- HKEY_CURRENT_USERS\Software\J. River\Media Center 13\Plugins\Interface\UPnPServer\Ignored IP Addresses
This is a String value, and should have a list of interfaces to ignore, with the "/" format for subnets. For example, "127.0.0.1/8,184.108.40.206/16" will ignore all localhost addresses (127.x.x.x) and all 169.252.x.x addresses (commonly assigned to devices that cannot locate a DHCP server).
Supported UPnP Devices
Currently, the XBOX 360 is not supported. It uses a UPnP-like protocol, but it isn't UPnP. It's a proprietary Microsoft protocol. J. River is investigating implementing support for the XBOX 360.
Intel's VIIV may or may not work, depending on the device. The VIIV protocol, while UPnP-like, is not required to be UPnP. The DirecTV HR20 does not work with J. River's UPnP server. The NetGear EVA700, however, does work with J. River's UPnP server.
- Make sure the track is playable in MEDIA CENTER.
- Make sure the track is playable by the device, or that conversion is selected.
- If it takes a long time to load containers with many children, try the Skip Child Count option.
- If the UPnP Server is set to autodetect, try specify the device type manually.