From a5e4cc9e68640ed9ee82c02e7b9796c8511cfccf Mon Sep 17 00:00:00 2001 From: Dave Chapman Date: Sat, 10 Nov 2007 20:26:54 +0000 Subject: [PATCH] Document how to use tcctool in Windows, and include the appropriate .inf file for use with the libusb-win32 device driver git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15559 a1c6a512-1295-4272-9138-f99709370657 --- utils/tcctool/README | 27 ++++ utils/tcctool/tcctool-driver-win32/tcc.cat | 3 + utils/tcctool/tcctool-driver-win32/tcc.inf | 139 ++++++++++++++++++ .../tcctool/tcctool-driver-win32/tcc_x64.cat | 3 + utils/tcctool/tcctool-windows.txt | 31 ++++ 5 files changed, 203 insertions(+) create mode 100644 utils/tcctool/tcctool-driver-win32/tcc.cat create mode 100644 utils/tcctool/tcctool-driver-win32/tcc.inf create mode 100644 utils/tcctool/tcctool-driver-win32/tcc_x64.cat create mode 100755 utils/tcctool/tcctool-windows.txt diff --git a/utils/tcctool/README b/utils/tcctool/README index c2fa8a0fb9..2031f6fdb9 100644 --- a/utils/tcctool/README +++ b/utils/tcctool/README @@ -27,3 +27,30 @@ A first test when using tcctool on a new device can be to upload the original firmware. If you do this, make sure you upload the same version that is installed on your player - otherwise you may find yourself with corrupted config files and music database. + + +Building for Windows +-------------------- + +1) Download libusb-win32-device-bin-0.1.12.1.tar.gz from: + +http://sourceforge.net/project/showfiles.php?group_id=78138 + +2) Extract libusb-win32-device-bin-0.1.12.1.tar.gz in the tcctool +source directory. + +3) Type "make tcctool.exe" to compile. + +4) Copy the following four files from libusb-win32-device-bin-0.1.12.1/bin +to tcctool-driver-win32/ + +libusb0.dll +libusb0.sys +libusb0_x64.dll +libusb0_x64.sys + +5) Create the tcctool-win32.zip file from the directory above tcctool as follows: + +zip tcctool-win32.zip tcctool/tcctool.exe tcctool/tcctool-windows.txt tcctool/tcctool-driver/win32/* + +6) See tcctool/tcctool-windows.txt for Windows usage instructions. diff --git a/utils/tcctool/tcctool-driver-win32/tcc.cat b/utils/tcctool/tcctool-driver-win32/tcc.cat new file mode 100644 index 0000000000..2ef39c526e --- /dev/null +++ b/utils/tcctool/tcctool-driver-win32/tcc.cat @@ -0,0 +1,3 @@ +This file will contain the digital signature of the files to be installed +on the system. +This file will be provided by Microsoft upon certification of your drivers. diff --git a/utils/tcctool/tcctool-driver-win32/tcc.inf b/utils/tcctool/tcctool-driver-win32/tcc.inf new file mode 100644 index 0000000000..63bc8a64d4 --- /dev/null +++ b/utils/tcctool/tcctool-driver-win32/tcc.inf @@ -0,0 +1,139 @@ +[Version] +Signature = "$Chicago$" +provider = %manufacturer% +DriverVer = 03/20/2007,0.1.12.1 +CatalogFile = tcc.cat +CatalogFile.NT = tcc.cat +CatalogFile.NTAMD64 = tcc_x64.cat + +Class = LibUsbDevices +ClassGUID = {EB781AAF-9C70-4523-A5DF-642A87ECA567} + +[ClassInstall] +AddReg=libusb_class_install_add_reg + +[ClassInstall32] +AddReg=libusb_class_install_add_reg + +[libusb_class_install_add_reg] +HKR,,,,"LibUSB-Win32 Devices" +HKR,,Icon,,"-20" + +[Manufacturer] +%manufacturer%=Devices,NT,NTAMD64 + +;-------------------------------------------------------------------------- +; Files +;-------------------------------------------------------------------------- + +[SourceDisksNames] +1 = "Libusb-Win32 Driver Installation Disk",, + +[SourceDisksFiles] +libusb0.sys = 1,, +libusb0.dll = 1,, +libusb0_x64.sys = 1,, +libusb0_x64.dll = 1,, + +[DestinationDirs] +libusb_files_sys = 10,system32\drivers +libusb_files_sys_x64 = 10,system32\drivers +libusb_files_dll = 10,system32 +libusb_files_dll_wow64 = 10,syswow64 +libusb_files_dll_x64 = 10,system32 + +[libusb_files_sys] +libusb0.sys + +[libusb_files_sys_x64] +libusb0.sys,libusb0_x64.sys + +[libusb_files_dll] +libusb0.dll + +[libusb_files_dll_wow64] +libusb0.dll + +[libusb_files_dll_x64] +libusb0.dll,libusb0_x64.dll + +;-------------------------------------------------------------------------- +; Device driver +;-------------------------------------------------------------------------- + +[LIBUSB_DEV] +CopyFiles = libusb_files_sys, libusb_files_dll +AddReg = libusb_add_reg + +[LIBUSB_DEV.NT] +CopyFiles = libusb_files_sys, libusb_files_dll + +[LIBUSB_DEV.NTAMD64] +CopyFiles = libusb_files_sys_x64, libusb_files_dll_wow64, libusb_files_dll_x64 + +[LIBUSB_DEV.HW] +DelReg = libusb_del_reg_hw +AddReg = libusb_add_reg_hw + +[LIBUSB_DEV.NT.HW] +DelReg = libusb_del_reg_hw +AddReg = libusb_add_reg_hw + +[LIBUSB_DEV.NTAMD64.HW] +DelReg = libusb_del_reg_hw +AddReg = libusb_add_reg_hw + +[LIBUSB_DEV.NT.Services] +AddService = libusb0, 0x00000002, libusb_add_service + +[LIBUSB_DEV.NTAMD64.Services] +AddService = libusb0, 0x00000002, libusb_add_service + +[libusb_add_reg] +HKR,,DevLoader,,*ntkern +HKR,,NTMPDriver,,libusb0.sys + +; Older versions of this .inf file installed filter drivers. They are not +; needed any more and must be removed +[libusb_del_reg_hw] +HKR,,LowerFilters +HKR,,UpperFilters + +; Device properties +[libusb_add_reg_hw] +HKR,,SurpriseRemovalOK, 0x00010001, 1 + +;-------------------------------------------------------------------------- +; Services +;-------------------------------------------------------------------------- + +[libusb_add_service] +DisplayName = "LibUsb-Win32 - Kernel Driver 03/20/2007, 0.1.12.1" +ServiceType = 1 +StartType = 3 +ErrorControl = 0 +ServiceBinary = %12%\libusb0.sys + +;-------------------------------------------------------------------------- +; Devices +;-------------------------------------------------------------------------- + +[Devices] +"TCC77x usb-boot mode"=LIBUSB_DEV, USB\VID_140E&PID_B021 +"TCC7801 usb-boot mode"=LIBUSB_DEV, USB\VID_140E&PID_B011 + +[Devices.NT] +"TCC77x usb-boot mode"=LIBUSB_DEV, USB\VID_140E&PID_B021 +"TCC7801 usb-boot mode"=LIBUSB_DEV, USB\VID_140E&PID_B011 + +[Devices.NTAMD64] +"TCC77x usb-boot mode"=LIBUSB_DEV, USB\VID_140E&PID_B021 +"TCC7801 usb-boot mode"=LIBUSB_DEV, USB\VID_140E&PID_B011 + + +;-------------------------------------------------------------------------- +; Strings +;-------------------------------------------------------------------------- + +[Strings] +manufacturer = "Telechips" diff --git a/utils/tcctool/tcctool-driver-win32/tcc_x64.cat b/utils/tcctool/tcctool-driver-win32/tcc_x64.cat new file mode 100644 index 0000000000..2ef39c526e --- /dev/null +++ b/utils/tcctool/tcctool-driver-win32/tcc_x64.cat @@ -0,0 +1,3 @@ +This file will contain the digital signature of the files to be installed +on the system. +This file will be provided by Microsoft upon certification of your drivers. diff --git a/utils/tcctool/tcctool-windows.txt b/utils/tcctool/tcctool-windows.txt new file mode 100755 index 0000000000..d116bfeefe --- /dev/null +++ b/utils/tcctool/tcctool-windows.txt @@ -0,0 +1,31 @@ +tcctool for Windows +------------------- + +Installation +------------ + +When you first attach your device in USB boot mode to your computer, +Windows should display the Found New Hardware Wizard. + +If this doesn't appear, and if you have previously used a firmware +recovery tool with your device, you will need to uninstall the USB +driver used by that application. + +Go into Control Panel -> System -> Hardware -> Device Manager, then +click on Universal Serial Bus Controllers, look for something like +"Telechips TCC77x VTC USB Driver", right-click on it and select +Uninstall. + +After doing this, disconnect and reconnect your device and the Found +New Hardware Wizard should appear. + +Select "No, not this time" to the question about connecting to Windows +Update, and select "Install from a list or specific location +(Advanced)" on the next screen. + +On the next screen, select "Search for the best driver in these +locations", unselect "Search removable media", select "Include this +location in the search:" and browse to the tcctool-driver-win32 +folder. + +You should now be able to run tcctool.exe