Tampilkan postingan dengan label How To. Tampilkan semua postingan
Tampilkan postingan dengan label How To. Tampilkan semua postingan

Simple yet powerful audio amplifier


Introducing Simple Amp!
This simple yet powerful audio amplifier is an ideal DIY electronics project. Using a minimum of four parts you can build an amplifier that will put commercial sound systems to shame. Not only is this amp powerful, but it is compact, able to fit in an Altoids tin with room to spare! Check out these instructions on how to build your own.
This is the same amplifier circuit that is used to power the large 8 ohm speaker in Salvius's head. It was very important for this project to have a speaker capable of being heard across a room with clarity. Salvius is designed to be able to interact with people and the quality of sound for the robot's speech plays an important role in the ability to do so.

Relay Polarity Thing

That's all I could think to call it. This small circuit uses diodes to turn on only one device based on the polarity of the power source. This can be very useful for some projects. I used this to control a large 12 Volt motor with a 9.5 volt receiver from an RC car.

Ubuntu USB webcam server using Motion


Motion is an open source webcam server for Linux operating systems. This software allows you to capture images from a camera connected to computer or server. Motion has many features that make it very versatile. You can set up your webcam server to take a picture every specified interval of time. You can also configure Motion to only take pictures when motion is detected. Motion can handle as many cameras as you need it to (within the reasonable limits of your server that is). If you connect your camera via USB 1 inputs they will only handle one camera. Cameras connected via USB 2 inputs may allow you to connect several cameras using a divider.

For my webcam server that I run on the robot I set it up so that the server continuously captures an image and overwrites the same file every time.

The first thing that you will need to do is prep your computer to compile the source code for motion.

Here you can download the tar package for Motion.
Or if you want to set this up the way that I did you can download my code from here.


Then extract the file to a directory such as /usr/local

cd /usr/localtar -xvzf /path/to/motion-3.2.X.tar.gz

Before you compile the code be sure to have build essential installed:

sudo apt-get install build-essential

You will now have created a directory called motion-3.2

Now change to the new directory

cd motion

Run configure. You can start with the defaults. If you need to modify the installation parameters you can read the next section.

./configure

Build the code

make

Install the code

make install

Replace the motion.conf, thread1.conf, thread2.conf located in /etc/motion/ with the ones that I have included in my zip file download.

To start motion open terminal and type:

sudo motion

To add Motion to startup automatically start with the server, just open “System” from the menu bar on the top of the screen, then “Preferences,” then “Sessions.” Create a new startup program type in a name for it and then type motion in the command section. Click“OK.” Then restart the server.

If you are modifying the motion.conf or thread.conf files you will have to restart motion after you make a change to them. To do this you can restart the computer or use the following command:

sudo /etc/init.d/motion restart

Also, if you only have more than a single webcam you will need one thread.conf file. For each additional camera that you use you will need to add another thread.conf file (thread1.conf, thread2.conf, thread3.conf) You will also need to add the links to these files at end of the motion.conf file.

More information about Motion:
http://www.lavrsen.dk/foswiki/bin/view/Motion/WebcamServer
http://manpages.ubuntu.com/manpages/precise/man1/motion.1.html

Troubleshooting your cam:
http://askubuntu.com/questions/57314/logitech-webcam-pro-9000-only-works-when-motion-is-run-as-root

Update: The following shoes the only changes that I currently have made to my Motion.config files:

target_dir /var/www/
snapshot_filename image
jpeg_filename image

How to Use a DC to DC Converter (Voltage Regulator)

I hooked this up in a few minutes in order to deliver a five volt power supply to the robot's audio amplifier. The source of power in this circuit is a 12 volt car battery. I used a voltage regulator rather than a resistor as an alternative to reducing the voltage from the car battery into an amount that the robot can use. A voltage regulator basically looks like a jumbo transistor. Voltage regulators can get hot when they are in use so I attached mine to a big heatsink that I had saved out of something I taken apart a while ago. I made fiberglass spacer to cover the voltage regulator's leads so that nothing would get shorted out. The voltage regulator that I used was marked 78M05A but any 7805 regulator will work just fine.


I also drew up a schematic that shows how to connect the 12V car battery to any 5V device.

Powering an Arduino off of 12 Volt Car Battery

5V car adapter charger for cell phones

I recently acquired a few old cell phone chargers that are designed to plug into cars. Theses small devices have turned out perfect for my robotics project because they are designed to connect directly to the 12 volt output of a car battery and convert it to about 5 volts. A 12 volt car battery will fry small electronic devices like an Arduino but if I wire these two cell phone chargers in series than I can have enough voltage to power an arduino off of the 12 volt car battery. This is an improvement because I am currently using a separate 9 volt battery to power the robot's Arduino.

The setup was very simple. To do this you don't even have to remove the plastic outer case of the charger like I did. Just connect the end of the charger to the positive battery terminal and one of the side connectors to the negative side of the battery. Then just cut and strip the wire on the end of the charger. There is 5V output between the red and black wire (red being positive +, and black being negative -). There is also about one volt between the red and the white wire. I thought this was a bit odd because electronics don't usually use a positive wire as a common line.
Older Post ►
 

Copyright 2011 robot recycled parts is proudly powered by blogger.com