USB-UIRT x86 Fix
|Version||Status||Date Updated||Updated By|
!!! Please Note. This fix is only necessary for LinuxMCE version 7.10. The isue has been resolved in LinxMCE 8.10 !!!
So, you have just received that $60 (or more) USB-UIRT, and you go ahead and plug it in, and learn all of your codes, reload the router and ..... Nothing Happens. You can see the light flashing, but your channels aren't changing. Now What? Below is the fix to get your shiny new USB-UIRT to work, if you have not yet purchased any IR dongles for the units blaster.
Firstly a disclaimer. The USB-UIRT can in fact blast under its own power, however, to get this unit to function flawlessly, you should also purchase additional IR dongles or heads. A good source of these both single and dual headed is from : Smarthomeusa.com If you use these, not only will the UIRT be more accurate and reliable, but it will also be fully supported by the stock LMCE.
Now onto the fix:
What is required
1. LinuxMCE version 7.10 - This is not a necessary step for LinuxMCE 8.10
2. Alternate build environment
3. Original Ubuntu-Gutsy kernel tree
4. 30 minutes to an hour of your time (spoiler at the end)
Alternate Build Environment
Get the necessary build tools
sudo apt-get update sudo apt-get install linux-kernel-devel fakeroot build-essential libncurses5 libncurses5-dev
Get the ubuntu-gutsy source tree - we will do the following as user root
sudo -i cd /usr/src git clone git://kernel.ubuntu.com/ubuntu-archive/ubuntu-gutsy.git ubuntu-gutsy
This step takes a while, but when it is done you should end up with
Change the module file
This is best done with the 'vi' command line editor
Use the "/" key to open a search dialog. In this dialog type:
You are looking for a line that reads
ftdi_tiocmget(struct usb_serial_port *port, struct file *file)
I believe this was the third thing after typing an additional "/" (vi remembers your last search, so to get to the second entry in the file simply hit the "/" again, and press enter) After you have located the entry, look for the line that has
(hint use the "/" key, as this may be a bit down the file) Now after arrowing down to this line hit the "O" key to open a new line directly below the FT2232C line, press "TAB" and enter
Exit out of edit mode by pressing "ESC" key. Now save the file by doing a
That is <shift :>wq! Now the file has been modified. And if you have never used it, you just got a crash course in 'vi' :)
Compile the kernel
This next step may take a while, mine took about 30 minutes to compile, YMMV! :)
Again as user root
Copy over your running config file
cp -vi /boot/config-`uname -r` .config
Now fire up the ncurses compiler menu
Here is a note, unless you know what you are doing, do not change anything here. You don't actually need to change the kernel config, you just need to load it so that the new USB-UIRT module is compiled correctly!!!!!!!!!
With that said, arrow down to the menu entry that says:
Load an Alternate Configuration File
Hit enter and verify ".config" shows up. Then select "OK" Now "TAB" over to "Exit" and hit "Enter"
Ok, now get yourself a cool beverage, and watch your favorite sit-com, because this may take anywhere from 30 to 45 minutes to complete!
Please wait for this to complete before proceeding ;)
Backing up and copying over the new module
After the compile has completed (Congratulations you may have just compiled your first kernel), we need to make a back up copy of your existing USB-UIRT module, in case something goes wrong in the next few steps, you will have a fallback.
Copy the original file to a backup file:
cp /lib/modules/2.6.22-14-generic/kernel/drivers/usb/serial/ftdi_sio.ko /lib/modules/2.6.22-14-generic/kernel/drivers/usb/serial/ftdi_sio.ko.backup
Copy the new file over to your running modules folder:
cp /usr/src/ubuntu-gutsy/drivers/usb/serial/ftdi_sio.ko /lib/modules/2.6.22-14-generic/kernel/drivers/usb/serial/ftdi_sio.ko
OK. Now the new file has been copied to the running modules folder.
Rebooting And/Or Reloading the Module
1. "The Sure Thing"
reboot the box
2. "A Possible Alternative" (though not tested by myself)
rmmod ftdi_sio modprobe ftdi_sio
I simply rebooted, but it is possible to reload modules. To do this I would suggest unplugging the USB-UIRT from the USB port,running the above commands in the order shown, and then plugging it back in.
That's it your done. This resolved my issues, and now the USB-UIRT works with or without IR Blaster Dongles.
The Spoiler: Instant Fix!
I have made available for download the completed module, if you use this, and it should work, you should not have to rebuild the kernel, simply follow the steps from number 5 on. The module is here as a tar file ftdi_sio.ko.tar
I have re-installed my core last evening with 710rc2 x86. I then went out and downloaded the tar file, and rebooted, and Bam! It worked, so if you really want to avoid all these steps, although I recommend it if you want to modify any future drivers, just hit the download link and follow step # 5 and on.
You may certainly try this, although I have not tested it myself, as long as your kernel is 2.6.22-14-generic it should work check this by doing a
UPDATE!!! 7/20/09 - Updated command since gutsy is archived. Also, it looks like if you upgrade the kernel (instructions here: http://wiki.linuxmce.org/index.php/Upgrading_the_Kernel) you will not need to perform this step. I am on 126.96.36.199 and this change is already in the ftdi_sio.c file.
Well let me know if this helps anyone, and by all means if you find a better way, modify this wiki.
Special thanks to eNoodle, linuxmjb, and collinjones for gathering together the necessary bits for the fix. This is merely a howto using information they researched. Kudos guys.