|
|
|
![]() |
|
|||||||
|
||||||||
![]() |
|
|
Thread Tools | Rate Thread | Display Modes |
|
|
|
#1
|
|||
|
|||
|
optical mouse motion sensor thread
Throughout the years we have used a sensor to measure the distance that the robot moves. I have been playing with a couple of ideas to keep track of motion. My favorite idea is using an optical mouse I've found this information:
Cody's robot optical motion sensor I have some general questions that we can all learn from:
|
|
#2
|
|||
|
|||
|
Re: optical mouse motion sensor thread
This is something I have considered too (with mice, webcams, OpenCV, then various vision algorithms), but soon realized it was impractical because of the limitation of speed. Especially for mouse cameras, the resolution and (fast compared to standard video) framerate is too low for anything more then a foot per second (if you are lucky). Going back a generation of mice and using a ball/wheel with optical encoders is your best bet, and probably for the next few years. This years floor also poses a problem, there may not be enough contrast of the texture to track.
<ins>Wait, the floor is textured, so a good camera would be able to keep a lock on the floor texture with proper lighting. If you had a camera that could do the job.</ins> Last edited by Nibbles : 04-01-2009 at 23:24. Reason: The floor is in fact textured |
|
#3
|
|||||
|
|||||
|
Re: optical mouse motion sensor thread
In a definitely unscientific experiment I wiggled my mouse about 6 inches at a rate of 'there-and-back' four times a second - about 4 FPS - and it seemed to track OK. Maybe it only tracked the ends (where I was moving slower as direction reversed). The link groves provided implied that it could be used - with modification - at fairly high (for a robot) speeds.
|
|
#4
|
|||
|
|||
|
Re: optical mouse motion sensor thread
Quote:
Looking at some of the more advanced mice (that I could find numbers for... seems like only marketing buzzwords like "LASER" and "OPTICAL" matter) can go up to 45in/s. Likely, since the playing surface grains (variance in contrast the mouse can lock onto) are larger then that on a mouse pad, you can pull back the mouse and shrink the size 4-6 times, so you could get up to 18 feet a second (or 35ft/s absolute best case if the tech specs are to be believed). But, you would have to find a USB to serial converter, and that mouse doesn't support PS/2 output (mice that do ship with a USB to PS/2 converter support the connection natively, the converter doesn't do any actual conversion of data). Take a really cheap computer with USB2.0 and serial, do some (quite a bit) of programming, and feed the results into the cRIO. And of course this is only theoretical, I haven't actually done any testing. |
|
#5
|
|||||
|
|||||
|
Re: optical mouse motion sensor thread
We did some experiments a few years back with using an optical mouse to track motion on the FRC carpet. Wildstang's programmers determined the hardware hacking necessary to connect directly to the chip inside the mouse, and came up with the code to use an IFI controller to communicate with it. We did the optical design so it could handle the expected travel speeds and view the surface without having to drag on the floor, and made a pneumatically-activated test jig to determine repeatability.
The electrical, optical, and programmatical aspects all worked great. However, without an absolutely stable distance between the floor and the sensor, converting mouse counts to absolute motion was unreliable. The values changed significantly with a difference in height of a single millimeter. A typical FRC robot bounces a lot more than that in normal operation. With the slippery surface this year, maybe bouncing would be less of an issue -- except during collisions. |
|
#6
|
|||
|
|||
|
Re: optical mouse motion sensor thread
Quote:
![]() |
|
#7
|
||||
|
||||
|
Re: optical mouse motion sensor thread
No, at least not for FRC. Lasers are banned, without regard to the power output or the function.
|
|
#8
|
|||
|
|||
|
Re: optical mouse motion sensor thread
Quote:
The poster seemed to be saying that this work had been done. Namely direct hardware interface with the mouse DSP. |
|
#9
|
|||
|
|||
|
Re: optical mouse motion sensor thread
Quote:
I fixed your post for you. I'm sure that after looking around here a bit you'll find yourself joining or starting a team. There are a lot of interesting people and interesting ideas on this forum, and we are glad that you are joining it. |
|
#10
|
|||
|
|||
|
Re: optical mouse motion sensor thread
I looked at this year's ago with led mice. Allot of mice use chip sets that you can't find any spec's on. Some logitech mice use Avago chip sets that have published interface data sheets. With out a USB port on the RC the interface is a problem. The communication protocol with the chip set is SPI. The faster mouse engines must have the code loaded into the mouse chip. It's complicated but do able. This is probably a case where a coprocessor would be good. The coprocessor could interface with the serial port or the SPI port and just send the cleaned up x and y data. In the end the problem is optical. The vertical height must stay with in a very close tolerance. Modifying the optics can be very difficult. It can be done but this is going to take allot of work. I got it working on a vex bot. How ever the chip set is now obsolete. Optically the laser mice are much more tolerant. A USB HID to serial converter might be a way to go.
|
|
#11
|
|||
|
|||
|
Re: optical mouse motion sensor thread
I went to a training hosted by Team 340, one of the beta testers of the new control system and remember be told that the new Jaguar motor controllers have built in encoders. Though it takes the fun out of making encoders it should save us some time
-Ed |
|
#12
|
||||
|
||||
|
Re: optical mouse motion sensor thread
Those encoders don't mean a thing if the wheels are spinning.
|
|
#13
|
||||
|
||||
|
Re: optical mouse motion sensor thread
There are no encoders built into the Jaguars. There is a micro that can read an encoder through the CAN bus, but use of the CAN bus is against the rules this year.
|
|
#14
|
|||
|
|||
|
Re: optical mouse motion sensor thread
Good point on the spinning of the wheels Dan.
|
|
#15
|
|||
|
|||
|
Re: optical mouse motion sensor thread
Quote:
Interfacing one of the Avago (previously Agilent) mouse chips isn't extremely hard - I've done it before with my VEX controller. It requires only a digital IO pin and a bit of software. An oscilloscope and the datasheet go a long way. ![]() Quote:
Quote:
|
![]() |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Optical Mouse Navigation | phrontist | Programming | 60 | 14-03-2005 21:48 |
| External Lens for optical mouse | gnormhurst | Electrical | 4 | 07-01-2005 19:07 |
| Optical Mouse / Ball Mouse | Clark Gilbert | Chit-Chat | 26 | 22-07-2004 13:17 |
| optical sensor | majormusic2005 | Technical Discussion | 1 | 29-01-2003 07:39 |
| optical sensor | archiver | 2001 | 3 | 24-06-2002 02:55 |