Difference between revisions of "User:Gordon/Optical Drive Testing Script/scratchpad"

From FreekiWiki
Jump to navigation Jump to search
Line 29: Line 29:
 
# Install all Ubuntu dependencies
 
# Install all Ubuntu dependencies
 
# cd to the dir where you want the virtualenv containing the code to live.
 
# cd to the dir where you want the virtualenv containing the code to live.
# <code>virtualenv --no-site-packages lazers</code>
+
# <code>virtualenv lazers</code> (I would prefer to use --no-site-packages but python-dbus/dbus-python doesn't play nice)
 
# <code>cd lazers</code>
 
# <code>cd lazers</code>
 
# <code>. bin/activate</code>
 
# <code>. bin/activate</code>

Revision as of 19:27, 9 January 2010

Dependencies

Ubuntu

  • python-setuptools (?)
  • python-virtualenv
  • python-pip
  • python-dbus (this won't install to a virtualenv based on 10 min of trying, so no-site-packages shouldn't be used when creating the virtualenv for lazers)
  • mercurial (won't be needed for a dpkg dependency, most likely)
  • hal (probably -- it probably has to be there to talk to via python-dbus)
  • cdrkit (probably)
  • dvd+rw-tools (probably)

Python

(Hopefully) see pip-requirements.txt once the project is closer to completion, and automatically install all these with pip.


Development installation

  1. Install all Ubuntu dependencies
  2. cd to the dir where you want the virtualenv containing the code to live.
  3. virtualenv lazers (I would prefer to use --no-site-packages but python-dbus/dbus-python doesn't play nice)
  4. cd lazers
  5. . bin/activate
  6. pip install -E . yolk (optional, but useful)
  7. pip install -E . cmdln
  8. pip install -E . nose (if you want to run the tests)
  9. mkdir src
  10. cd src
  11. hg clone http://bitbucket.org/gmfreegeek/lazers/

Optical drive examination procedure

  1. wodim dev=/dev/sr0 -prcap
    • Makes sure a drive is there
    • Gets a list of most capabilities
    • Does NOT distinguish DVD-R from DVD+R capability

or alternatively...

  1. hal-find-by-capability --capability storage.cdrom to get a udi
  2. lshal -u [udi] reveals the drive's capabilities one by one, including plusr, dvdram, etc. Dunno about lightscribe.