| 1 |
libnetmd.py - A python implementation of NetMD protocol. |
| 2 |
|
| 3 |
DISCLAIMER |
| 4 |
In short: If it break, you get to keep the pieces. |
| 5 |
|
| 6 |
This library implements a proprietary, non-documented protocol. |
| 7 |
Some methods are not tested [enough], so they might just not work, or cause |
| 8 |
data loss, or brick your NetMD. Use at your own risk. |
| 9 |
|
| 10 |
REQUIREMENTS |
| 11 |
libusb1 |
| 12 |
python2.4 or later (not compatible with python 3.x), ctypes (required by |
| 13 |
python-libusb1, included here) |
| 14 |
A NetMD minidisc player. |
| 15 |
An USB cable. |
| 16 |
|
| 17 |
Linux: |
| 18 |
Your distro should package everything you need (python2.4 + ctypes). |
| 19 |
|
| 20 |
Windows: |
| 21 |
As of this writing, Windows XP, 2003, Vista & later are supported by |
| 22 |
libusb-1.0, both in 32 and 64 bits. |
| 23 |
- Go here: |
| 24 |
http://code.google.com/p/libusb-winusb-wip/downloads/list |
| 25 |
and download: |
| 26 |
- latest libusb release (libusb_2010.10.14.7z as of this writing) |
| 27 |
- zadig.exe |
| 28 |
- Extract libusb-1.0.dll to your system32 folder (should be something like |
| 29 |
C:\windows\system32). |
| 30 |
- Plug your NetMD via USB |
| 31 |
- Run zadig.exe, and select your inidisc in the drop-down list, then click |
| 32 |
"install". You will be prompted for confirmation that you really want to |
| 33 |
install this non-certified driver, then installation will happen. |
| 34 |
If you get errors, it might mean a driver is already installed for this |
| 35 |
device, you should uninstall it and retry installing zadig's driver. |
| 36 |
- If prompted, reboot. |
| 37 |
- Run python NetMD tools (example: c:\Python26\python.exe lsmd.py) |
| 38 |
Note: wait for the driver to be loaded before running commands, otherwise |
| 39 |
you will get errors, like "LIBUSB_ERROR_NOT_SUPPORTED". |
| 40 |
|
| 41 |
Note: by default, python does not package the Crypto package, required to |
| 42 |
download track to NetMD devices. (TODO: add Crypto URL here.) |
| 43 |
|
| 44 |
For dump_md.py: |
| 45 |
sox (and plugins to access your audio system) |
| 46 |
A sound card with analog input. |
| 47 |
An audio cable. |
| 48 |
|
| 49 |
FILES |
| 50 |
Libraries: |
| 51 |
libnetmd.py Python implementation of NetMD protocol. |
| 52 |
libusb1.py Ctypes-based python wrapper around libusb1. |
| 53 |
usb1.py Object definitions for libusb1.py functions. |
| 54 |
|
| 55 |
Utils: |
| 56 |
lsusb.py Sample implementation of lsusb command using usb1.py. |
| 57 |
mdctl.py Stupid pdb-based command line to test libnetmd.py methods. |
| 58 |
lsmd.py Display disc title, tracks, ... of connected NetMD. |
| 59 |
dump_md.py Play tracks on a connected NetMD and record them to files. |
| 60 |
|
| 61 |
NOTES |
| 62 |
You need to be root to access a device on the USB bus (or at least, to have |
| 63 |
read/write permission on the /proc/bus/usb/*/* corresponding to your NetMD). |
| 64 |
|
| 65 |
dump_md.py contains some Works-For-Me values, it might require some tweaks |
| 66 |
for tracks to be properly recorded (depends on noise level, minidisk player |
| 67 |
reactivity...). |
| 68 |
|