SSH Login to my Ubuntu 8.04 machine was slow. (It would delay about 5 seconds after I issued the ssh command for the remote machine to request a password.) I believe this is because the remote machine is on my home network, and I have set up it’s hostname using host entries instead of having a true DNS name.
I edited the /etc/init.d/sshd_config file and added the single line:
UseDNS no
which fixed this problem as soon as I restarted the SSH server, with
sudo /etc/init.d/ssh restart
Compiz keybindings in Ubuntu 9.04
Ubuntu 9.04 comes with some visual effects from Compiz turned on by default. This post contains a list of the key combo’s used to active some of them. Compiz also offers many other “cool” effects. If you install the compizconfig settings manager you can enable/disable all of the neat effects (most of which are eye-candy, and not really useful).
Continue reading
Encrypted home partition for Ubuntu 9.04
Following the directions on Lars’ blog, I set up an encrypted home directory on Ubuntu 9.04 using LUKS.
The following commands were all executed with root permissions. Add “sudo” to the front of the commands if you are not running with root permissions. Continue reading
Acer Aspire One D150 – Ubuntu 9.04 Jaunty Linux
Installing Ubuntu 9.04 (Jaunty) on an Acer Aspire One (Model D150) worked quite well. I had to use an external USB CD-Rom Drive as the Aspire One does not have a built in drive, but after enabling the “Press F12 to choose boot device” menu in the system BIOS I was able to boot off of the external USB CD-Rom drive.
Ubuntu worked well with all the major hardware (video, wifi,wired-ethernet, soundcard, and webcam) and the only hiccup was with the built in microphone, which did not work out of the box (the microphone jack would work, just not the built in microphone.)
To get the built in microphone working, I had to install the latest version of the ALSA driver following the instructions I found in post 28 on this thread, as copied below:
So I downloaded alsa-driver-1.0.20.tar.bz2 from
http://www.alsa-project.org/main/index.php/Main_Page
I unzipped the package, I entered into the main directory of the package and then I typed:
sudo apt-get install build-essential ncurses-dev
./configure –with-cards=hda-intel
make
sudo make installThen I edited /etc/modprobe.d/alsa-base.conf and I added at the end of file the line:
options snd-hda-intel model=acer-aspireAfter the reboot I adjusted the audio preferences in this way:
Device: HDA Intel (Alsa mixer)
Preferences: The first 3 items and last 2 items (Front Mic is disabled!!!)
Input Sources is set as default at Mic (not Front Mic!!!).Finally check that System->Preferences->Sound->Sound Capture is set to “HDA Intel ALC272 Analog(ALSA)” not “ALSA”
Homebrew bicycle battery bracket
I created a battery holder (bracket) for my two 5 Ah gel cell batteries using more schedule 40 PVC pipe. I cut four 2 and 7/8 inch sections and three 3 and 5/8″ sections. Using four 90 degree elbows and two “T”‘s I arranged it to hold the two batteries. Continue reading
Electric Bicycle power circuit
Bolting a DC motor to the front basket of a bike and running a chain to the front wheel takes care of the mechanical linkage needed to make an electric powered bicycle, but you also need to provide power to the motor, and control that power in some way.
Luckily, the same place that sold me the 250 watt motor also sold a 40 amp speed controler. (It cost $33, or more than any single other part of my e-bike project.)
The speed controler is controlled by most standard e-bike throttles, such as this one from Currie Technologies. I also attached two 12v 5AH batteries in series to provide 24 volts. Because I calculated that my 250 watt motor running at 24 volts would draw approximately 10 amps, (250/24 = 10.4), I added a 15 amp fuse to the circuit. (The first 15A fuse was replaced by a second 15 amp fuse after it saved my speed controler from damage when I accidentally reversed the polarity on the power…)
Continue reading
Adding an electric motor to a bicycle
I purchased a surplus 250 watt motor with a matching wheel hub and 90 tooth sprocket. The motor has an 11 tooth sprocket, and both the motor’s sprocket and the hub’s 90 tooth sprocket are designed for #25 motor chain, which is slightly smaller than standard bicycle chain.
To get the hub and 90 tooth sprocket on the wheel, I had to remove the existing hub and rebuild the wheel on the new hub. Luckily the two hubs were close enough in size that I could re-use the existing spokes. Following the instructions on Sheldon Brown’s website, and also refering to this website I was able to re-spoke the wheel.
Continue reading
Setting Netflix / Silverlight bandwidth usage
The netflix watch on demand video player uses Microsoft Silverlight. Silverlight has an “adaptive playback” mode which attempts to choose one of multiple bandwidths for your video (and switch on the fly if your internet connection has more ore less bandwidth over time).
To see what it is currently using, press the Control, Alt, Shift and D keys all at the same time.
CTRL-SHIFT-ALT-D gives diagnostic information on-screen.
If you would like to force netflix to use a specific bandwidth (typical sizes are 500, 1000, and 1500 KBps, or 50, 100, 150 kilo-bytes a second), press the Alt, Control, Shift and S key at the same time.
CTRL-SHIFT-ALT-S allows you to manually force silverlight/netflix player to use a specific bandwidth for playback.
This can be useful if you want the absolute best quality (and are willing to pause the movie every so often to let it buffer), or if you are willing to use a lower quality than your full network connection supports so that some extra bandwidth is available for other users or applications.
NOTE: I was unable to get the key-combos above to work in full-screen mode. I had to have the netflix player in a browser window for them to work. In addition, sometimes I had to click within the siliverlight window (for example, by pressing the play/pause button) before the key combination would work.
Currie Technologies 6 pin Diaganostic throttle pin-out
I purchased a surplus Currie Technologies “Diagnostic” throttle. (Which includes 3 LED’s labeled as 1/3, 2/3 and full charge indicators) It has a six pin (7 cable) connector with no pin-out diagram.
After opening it up, it appears that the blue, black, and red wires are connected to the throttle sensor itself, while the other four wires (White, Gray, Yellow, Green) connect to the LED circuit board.
The pin-out ordering is as follows, from the bottom of my picture up:
- Red/White (Throttle/LED, sharing a pin, + voltage)
- Black (to throttle, I assume Ground)
- Blue (from throttle, I assume signal)
- Green (Full LED)
- Yellow (2/3 full LED)
- Gray (1/3 full LED)
I connected the Red/Black/Blue wires to a motor speed controller that had a 3 wire throttle connection (matching them up to the Red/Black/Green wires from the controller) and it worked great!
The LED pin-out is as follows:
White (positive / Vcc)
Gray – 1/3 empty LED
Yellow – 2/3 full LED
Green – Full LED
Note that I was able to get the LED’s to light up with a 3V source, but I believe their forward voltage is less than 3V and you should use a current limited supply so that you do not burn the LED’s out.
Electric Scooter Power Usage Details
I purchased a used Navajo Turbo Z 24volt electric scooter. The person I bought it from had installed two brand new 12V 7.0Ah batteries, similar to the battery in this data sheet. Note that because the scooter will discharge the batteries in less than an hour, the pack’s usable capacity is closer to 4Ah. Because the batteries are sealed lead-acid, they are heavy, approximately 6lbs each, and the pair make up approximately 35% of the scooter’s 34lb total weight. (Most of the rest of the weight comes from the hefty all-steel frame, and the 5lb 200-watt motor.)
Continue reading