Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

First Project (Air Mouse/Pc Light Gun)(&First Post)

Status
Not open for further replies.

Sim

New Member
I been pretty interested in electronics lately. Looking at how to do fancy things with electronics such as remote control cars, airplanes or boats, but something I wanted to do befor all that was a PC Gun that worked like a mouse.

Not sure if anyone has heard of the act-labs PC light gun.
http://www.act-labs.com/scripts/proddetails.asp?pid=92


I came across a air mouse where you can just wave it around in the air and it would be like your mouse which isnt much different then a optical mouse.


So I took my optical mouse apart and now trying to figure out some way to make it move threw air.


I once seen on a website about being able to tell the direction the sensor is moving, but that site is no longer online.


If anyone has any other suggestions to how to create a air mouse type project, or could help me with this. I would apreciate it muchsize.

Thanks.
 
The light guns you are talking about look at the lines being drawn on the CRT each frame.

The mice you move through the air use gyroscopes I think.

Optical mice use a little camera with built in image processing to detect movement. Making one of these work correctly for motion high off a surface isn't practical. Its very important that the camera image be in focus for the sensor to work correctly.

If you just want to fiddle with optical mice you can type the part number (its printed on the IC) of the camera IC into google and it will give you the data sheet. These chips usualy have a simple quadrature outputfor x and y thats easy to see if you have a scope. You could also try hooking some buffers and LED's to the quadrature outputs and watch tham flash as you move the mouse. This might make a neat visual display if you had them shining out of the mouse.

Hope this helps
Brent
 
You would need at least a 2 axis accelerometer. Personaly I've done some playing around with the ADXL202AE from Analog Devices. With the accelerometer you could calculate which direction the mouse was moving in 2 dimensions. I'm not certain how precise it will be.
 
All that stuff is very confusing. I dont think I should try this yet unless someone is willing to help me out. Could anyone recommend me some good projects to start for a beginner. I hardly know anything about electronics. I know how electricity works, but thats about it.
 
You should get a cheap microcontroller development kit and learn about microcontrollers. Zilogs Z8Encore kit is 39$. Atmel has a good dev kit for its AVR. And there are a million PIC kits out there. Its worth spending a bit of mony to buy a kit.

If you want to laern about analog circuits buy some opamps and build a few simple amplifier circuits.

Brent
 
is a micro controller like a pc chip that I program and can use it to print to an lcd screeN?


i did a google search for Zilogs Z8Encore and found no results. Could you give me a link to that kit?
 
Sim said:
is a micro controller like a pc chip that I program and can use it to print to an lcd screeN?


i did a google search for Zilogs Z8Encore and found no results. Could you give me a link to that kit?
You can buy the Z8e kit from www.mouser.com or www.digikey.com. I'm sure you can get the AVR kit from both of those as well.

I just started a few months ago with the Z8e kit and I love it. It comes with everything you need including the development board, the programmer and a nice C compiler/assembler and development environment included.

Yes, a microcontroller is like a little PC. It has ROM and RAM built into one chip and you can control each pin with either general purpose IO or specialized functions like UART, or IRDA, or Analog to Digital converter.

This is what I was talking about right here. This is a board I made up to house the ADXL202AE accelerometer. (Sorry the picture is so blurry, I took it fast and the board is very small) The accelerometer is the squarish thing in the bottom right. The black chip is a tiny SSOP 20 pin Z8e chip. The accelerometer has 2 outputs. It measure forces in 4 directions, so if I moved the board in any direction, except up and down, it will register the forces acting on it. So if I moved it 2 inches to the left, it would register the moving force and the stopping force, you could calculate the rate of movement and distance moved based on the force alone, which would allow you to make a mouse that needs no surface.

**broken link removed**

I made this board for a racecar datalogger, which does exactly the same thing on a larger scale. I can take the force data taken from driving around the track and replot exactly where the car moved relative to it's starting position with that data alone.

5 or 6 months ago, I had just about zero knowledge of electronics. Watch out, cause it can get addictive. I wrote a small page, there's a short writeup on how to setup a 40pin Z8e chip on a broadboard with the programmer, when you get beyond the development kit. Also you can check out the z8Encore Yahoo mailing list.

**broken link removed**

AVR and PIC are both more popular microcontrollers (the Zilog is brand new) and good choices as well. I haven't had any experience with the AVR, but I found the PIC to be too confusing and the mass of cheap flaky programmers and assembly language just turned me off. I still have some PIC chips and a couple old programmers lying around here.

Well, I've written a novel. I'll go away now.
 
Z8E00101ZDH - is not the Encore.

Z8ENCORE000ZAC - is just the programming cable. If you don't want the development board and want to jump straight into programming your own chips, you can get just this. It comes with the compiler and development environment as well.

Z8F08200100KIT - 4k/8k development board
Z8F64200100KIT - 16k/64k development board

Zilog has seperated the product line into the 4k/8k small chip line, and the 16k to 64k larger chip line. Really, you would probably just get the 16k/64k development system. The programming cable and development system are exactly the same, so whichever one you get, you can still program both sets of chips. In fact the smaller chips are pretty much exactly the same as the larger, just smaller pin counts and reduced functionality.

The board I showed above has a 4k chip on it, and this board I'm using to test out a tachometer with an RC-servo controller uses a basic 16k 40pin chip.

**broken link removed**

With fairly routine setup, just about any microcontroller can display data on an LCD or LED display.

**broken link removed**
 
I should mention that Graham at ECROS has created a development board as well. You can buy the programming cable that comes with the compiler and get the ECROS development kit. Graham is writing some truely excellent programming tutorials. The tutorials are based around his development board, but his development board isn't necessary to get everything out of the tutorial.

https://www.ecrostech.com/
 
Status
Not open for further replies.

Latest threads

New Articles From Microcontroller Tips

Back
Top