Showing posts with label diy. Show all posts
Showing posts with label diy. Show all posts

Monday, January 02, 2012

HTPC: Displaying the Windows Media Center actively recording program on an LCD Display

A project that I took on over this past Christmas break was to get my HTPC to display on an LCD display mounted in the PC’s case informaton about the TV program actively being recorded by the Windows Media Center DVR, so that I could see what was being recorded even when the attached TV was off.

The basic hardware/software setup for this project was:

  • LCD Display: An nMediaPC PRO-LCD-B display, which is a blue LCD display that can display 2 rows of 20 characters, and fits into a standard PC case 5 1/4” drive bay. 
  • A PC running Windows 7 64-bit, configured to act as a DVR using Windows Media Center.

This project turned out to be significantly more complex that I originally planned on it being, although after nearly a full day of tinkering, I did finally get it to work!  The remainder of this post is a set of instructions for what I did to get the LCD display working to display the active Windows Media Center recording (leaving out many of the missteps and dead ends I encountered along the way, although I do include a couple of the major ones as an appendix at the end of this post). 

WorksOnMyMachineI’m providing this information for my own future reference and in the hopes that it may be helpful to you, the reader; however, please note that this is in no way an “official” set of instructions.  It worked for me, but may not work for you.  Your mileage may vary.  I am awarding this post the official Jeff Atwood / Jon Galloway “It works on my machine!” seal of approval. 

These instructions assume that you already have Windows Media Center actively running as a DVR on your PC, and that you have a reasonable level of technical expertise, and patience – there are a lot of steps here, and quite a few “moving parts” to get working together!

Enough disclaimers; on with the show!

1. Purchase the nMedia PRO-LCD-B LCD Display

Purchase the nMediaPC PRO-LCD-B.  As I write this post, it’s available from newegg.com for US $38 shipped.

Other nmMdiaPC PRO-LCD models may work with these instructions as well, but I only tried them with the PRO-LCD-B.

2. Install the PRO-LCD-B hardware

Power off your PC, and install the PRO-LCD-B in an empty 5 1/4” drive bay. 

The install was fairly easy; the PRO-LCD-B has two connections: One to a standard disk drive power cable from the PC’s internal power supply, and one to a 4-pin USB connection on the motherboard.  My HTPC’s motherboard (a Gigabyte AMD GA-MA785GM-US2H) had several such 4-pin USB leads available on the motherboard, even with all of my case’s front and rear USB ports already hooked up.

(When I powered my PC back on, I *think* I saw some stock/default text on the LCD display, but I’m not 100% sure about this – and I’m not about to voluntarily revert my HTPC to that state at this point just to double-check.) :-)

3. Install the PRO-LCD-B driver software

Download and install the PRO-LCD-B driver software from the nMediaPC website:

http://www.nmediapc.com/LCD/download.htm

I also have a mirrored copy (current as of January 2012) in the event that the file ever becomes unavailable from the nMediaPC site:

http://jonschneider.com/jsblog/CDM20600.zip (1.8 MB)

(Although at this point my next step at this point was to install nMediaPC’s “M-Play Home Center (MHC)” software to drive the LCD display, this turned out to be a dead end, and I recommend you skip it if your goal is to get your LCD display to show the actively-recording Windows Media Center program.  See the “Dead Ends” appendix at the end of this post for more on this.)

4. Install LCDSmartie

LCDSmartie is a free open-source program for Windows that can drive the display of text on LCD display devices, including the PRO-LCD-B.

I downloaded and installed the 5.4.2.92 beta release (dated June 8, 2011).  LCDSmartie downloads are available from here:

http://lcdsmartie.sourceforge.net/smartied.htm

I mirrored the 5.4.2.92 beta release here:

http://jonschneider.com/jsblog/lcd_smartie_v5.4.2.92 Beta.zip (2 MB)

Uncompress the “lcd_smartie_v5.4.2.92 Beta” folder and its contents from that .zip archive.  I put this folder onto the root directory of my C: drive.

5. Install the lisvfd.dll display driver for LCDSmartie

None of the out-of-the-box drivers that come with the LCDSmartie 5.4.2.92 release work with the PRO-LCD-B.  However, there is another driver available on the LCDSmartie site that did work for me: the “L.I.S VFD” display driver.

It’s available on the LCDSmartie SourceForce site from here:

http://downloads.sourceforge.net/lcdsmartie/lisvfd.zip?download

If that link doesn’t work anymore, try looking for it on the LCDSmartie site download page under “Plugins”, or else download my mirrored copy:

http://jonschneider.com/jsblog/lisvfd.zip

After downloading that, place the lisvfd.dll file from the .zip archive into the “displays” folder under your LCDSmartie installation folder.

6. Configure the lisvfd.dll display driver in LCDSmartie

Run LCDSmartie (via the LCDSmartie.exe file in the extracted “lcd_smartie_v5.4.2.92 Beta” folder that you created in step 4 above).

When LCDSmartie comes up, it should show a small window showing the content that it is sending to the LCD display (although nothing will actually appear on the PRO-LCD-B until the steps in this section are completed).  Click the “Setup” button in the lower-left corner of the window to bring up the Setup window.

In the LCDSmartie setup window, in the “LCD Size” dropdown in the Display Size section in the top-right corner, select the “2x20” value (the display size of the PRO-LCD-B).

Next, still in the Display Size section, click the Plugin tab.  In the Display Plugin dropdown, select lisvfd.dll.  (This option will only appear if you copied the lisvfd.dll file into the LCDSmartie “displays” subfolder in the previous step.)

For the next step, you need to know what COM port your PRO-LCD-B is running on.  To determine this:

  • Bring up the Windows 7 “Devices and Printers” screen by opening the Windows Start menu, typing “devices” into the text field, and selecting the “Devices and Printers” option that appears.
  • On the “Devices and Printers” screen, in the “Unspecified” section, look for a device named “FT232R USB UART”.  Right-click on it and select Properties from the context menu.
  • On the Properties window, select the Hardware tab.
  • In the “Device Functions” table that appears, look for an entry like “USB Serial Port (COM4)”, where the “4” might be any number.  Make a note of that number.
  • Close the FT232R properties window and the “Devices and Printers” window.

Then, return to LCDSmartie.  (It doesn’t appear in the Alt+Tab list on my machine, so you may need to select it from the Windows taskbar).  In the LCDSmartie Setup dialog, in the Display Settings section, in the Plugin tab, in the Startup Parameters field, enter “COM4,38400” where “COM4” is the actual COM port value from the Devices and Printers section above.

  • If for whatever reason you couldn’t find the FT232R device in “Devices and Printers”, then an alternative here might just be to try entering different values for the COM port number in this field to see if you can get something to display on the PRO-LCD-B screen.

Once this is done, click OK on the LCDSmartie setup dialog.  You should now see some text from LCDSmartie (a scrolling LCDSmartie logo, and possibly some other information) appear on the PRO-LCD-B screen on your PC!

7. Install the “LCDSmartie dll to display Windows Media Center status”

Once LCDSmartie is successfully configured to display information on the PRO-LCD-B screen, the next step is to get it to display what’s currently recording in Windows Media Center.  A plug-in called “LCDSmartie dll to display Windows Media Center status” by Dave Perrow can be used to do this.

Download the “LCDSmartie dll to display Windows Media Center status” from its website, here:

http://mcedll.codeplex.com/

Or grab my mirrored version (current as of January 2012):

http://jonschneider.com/jsblog/MCE_DLL.zip

Extract the MCE_dll.dll, MCE_dll.cfg, and MCE_dll.ini files to the “plugins” folder under your LCDSmartie installation.

8. Install Windows Media Center TCP/IP Controller

The MCE_dll plugin relies on another piece of open-source for Windows called Windows Media Center TCP/IP Controller (or “TcpIpController”) to function.  TcpIpController publishes a “feed” of what Windows Media Center is currently doing (including what program it’s recording) to a particular TCP port on your PC, where it can be read by MCE_dll.

I installed the “Win7 64 and 32 bit Alpha - button command fix” release of TcpIpController.  (Note: This is not the default release of TcpIpController – I’m not sure whether or not the default release works with MCE_dll.)

Download the “Win7 64 and 32 bit Alpha - button command fix” release of TcpIpController from its codeplex.com website here:

http://vmccontroller.codeplex.com/releases/view/23251

Or get this version from my website:

https://jonschneider.com/jsblog/Setup%20x64.msi

Run the downloaded .msi file, and continue through the prompts to complete the installation wizard.

When the installation finishes, reboot – without a reboot, TcpIpController will not work properly.

9. Configure TV channel names

The MCE_dll plugin will display the name of the channel being recorded, along with the channel number and the name of the program being recorded.  It gets the channel number and program name from Windows Media Center (via the TcpIpStatus plugin), but we need to manually supply the channel names.

To do this, in a text editor, open the MCE_dll.ini file that you previously placed in the “plugins” folder under the LCDSmartie folder, and replace all of the values with the channel numbers and names for your local channels.

(You can skip this step if you happen to live in the same region of Scotland as the MCE_dll author.) :-)

10. Configure LCDSmartie to use the Windows Media Center status (MCE_dll) plugin

Now that we have the MCE_dll plugin and its TcpIpController dependency in place, we need to configure LCDSmartie to use them.

Bring up the LCDSmartie Setup dialog.  In the “Screens settings” section, make sure Screen 1 is selected (set the value of the Screen field to 1), and then replace the values in the two large fields in this section (which represent what LCDSmartie will display on the PRO-LCD-B screen):

Line 1: 

$dll(MCE_dll.dll,1,,)

Line 2:

$dll(MCE_dll.dll,2,,)

An explanation of what these values mean, along with some other values you can play with, can be found on the MCD_dll plugin site.

Finally, click OK.  If your Windows Media Center is actively recording something, you should now see the channel number, channel name, and show name on the PRO-LCD-B display!

The finished product on my HTPC (with the PRO-LCD-B installed just below the DVD drive):

PRO-LCD-B

(The actual LCD display image is far cleaner/sharper than it appears in the photo; my iPod camera refused to take a nice image of it.)

11. Configure LCDSmartie to run at Windows startup

In the LCDSmartie setup dialog, in the Startup/Shutdown tab, click the “Autostart hidden” radio button, then click OK.

Appendix: Dead ends

A couple of the things that I tried that didn’t work:

  • A piece of open-source software for Windows called LCDWriter by “andy vt” says that it will also get an LCD display to display what Windows Media Center is currently recording, among several other functions.  However, I couldn’t get the 64-bit version to successfully display anything to my PRO-LCD-B; and the 32-bit version (which can work with LCDSmartie display plugins via a wrapper dll) gave me a runtime error on my PC every time I tried to run it, so I eventually gave up on getting it to work on my PC.
  • The default PRO-LCD-B display software from nMedia has a lot of cool functions, and it was very easy to install and get initially working, but I was unable to successfully get it to display the recording program in Windows Media Center.  It also seemed to be slightly buggy in other ways (at least for me); for example, after exiting Windows Media Center, the PRO-LCD-B would continue to display “Channel Listing”, for example, instead of reverting back to the default date/time display.

Appendix: Thanks!

Thanks to the authors of LCDSmartie, the lisvfd.dll display driver, the “Windows Media Center status” plugin for LCDSmartie, and the Windows Media Center TCP/IP Controller.  Without all of those open source projects having been developed and made freely available, I wouldn’t have been able to complete this project – or at least, it would have taken me significantly longer to code up a solution myself!

Sunday, May 16, 2010

HTPC Build Part 1 – Constructing and Installing a DIY Antenna

This is the first in a series of posts I’m writing about an HTPC (Home Theatre PC) build that I recently completed.  To see all posts in the series, click here.

As I’ve mentioned in a previous post on inexpensive home services, I’ve been getting High Definition (HD) TV at home for free via an over-the-air antenna for several months now.  (In most markets in the U.S., since the 2009 digital transition, the major network channels, and often several others, are available 100% legally for free, in HD, via over-the-air broadcast.)  This has been worked great for me, particularly for the price tag ($0/month!), but not perfectly: With my cheap $20 small store-bought antenna positioned next to my TV on the lower level of my home, I could not get the local PBS station, and I had to position the antenna just right to get several other stations (and reposition it whenever anything bumped the antenna).

I set for myself a goal of getting high-quality (strong signal / reliable), hi-def TV into my home, and recording that TV via a DVR (digital video recorder) of some kind, while still maintaining a monthly TV/DVR payment $0.  (If this turned out to be unachievable, I set a fallback plan of getting TV service through one of the satellite TV companies; but even a “cheap” price tag of $25/month ($300/year) was somewhat unpalatable to me compared to a potential payment of $0/year!)

My first step towards this goal was to fix the situation with the reception.  According to the Digital TV reception map at ftc.gov, I should be able to get a strong PBS signal at my location.  My wife and I were very interested in getting PBS due to the good amount of high-quality kids’ programming on that station.

I got several quotes from area companies to install a roof-mounted or in-attic antenna.  All of the quotes came back for north of $500, which was more than I was willing to pay, so I started looking into other antenna solutions.

Poking around online, I came across some interesting plans for a Do-It-Yourself (DIY) antenna on makezine.com.  The plans involved basically assembling a small vertical frame out of wood and a metal pipe, then using pieces from some old wire hangers that are already around the house to form the actual antenna.  When it comes to things other than computers, I’m not exactly a big do-it-yourself guy.  However, these plans seemed simple to do and inexpensive in terms of parts, and there were quite a few very positive comments/reviews on the makezine.com article on the design, so I decided to give it a shot.

Including a trip to the hardware store, the DIY antenna took about $30 in parts and about 4-5 hours of my time to construct.  (I suspect someone used to building this type of thing could have completed the project a lot faster.)  I set the antenna next to my TV and hooked it up, and it worked very nicely!  All of the stations that I already got (including HD signals from the major networks ABC, NBC, CBS, and FOX, as well as many other high-def and standard-def channels) came in better than before. 

However, at this point, I didn’t get PBS.  The next step was to try hooking the antenna up on the second floor of my two-story house, since antennas are supposed to work better when they are positioned higher up relative to ground level. 

Most of the rooms in my house are wired for cable; however, all of the cables in the basement were unlabeled.  Going around my house to one cable jack at a time, I used a little ball of aluminum foil to “short out” the end of a short piece of coax cable connected to the jack, and then I was able to use an ohmmeter to identify the corresponding end of the same cable in the basement utility room. 

Having identified and labeled all of the cables in the basement, I used a connector to directly connect my TV-room cable to my master bedroom cable down in the utility room in the basement.  Then I carried the DIY antenna up to the master bedroom, and tried the TV channels again.  Success – I was now able to get PBS, in great-looking HD!

The final step for the antenna was to install it up in the attic.  I extended the coax cable from my master bedroom (since I intentionally do not, and will not, have a TV in there) up into the attic.  Then I carried the antenna up into the attic, and hooked it up.  I positioned the antenna in the attic by having my wife watch TV and report on how the signal was doing, while I talked to her via our home wireless phones, and made adjustments according to her feedback.  Having found a position where all stations came in great, I left the antenna up in the attic, and closed the attic up again. 

End result: Great-looking and reliable high-definition TV, with my TV simply connected to the wall cable jack.  If you’re looking for a fun DIY project with the end result of getting free, totally legal HD network TV plus more stations, I can recommend giving the makezine.com DIY antenna plans a shot!

The next post in this series will cover my purchase of a PC TV tuner, and trying it out with the DVR software included out-of-the-box with Windows 7, called Windows Media Center.