Pages: [1]   Go Down
 Author Topic: Detecting distance travelled (Cartesian)  (Read 2368 times) 0 Members and 1 Guest are viewing this topic.
The Big Smoke
Offline
Sr. Member
Karma: 0
Posts: 260
Hacking and Slashing
 « on: October 12, 2009, 05:04:45 pm » Bigger Smaller Reset

Hey guys,

I've been working on a robtics project for quite a while now and I'm fairly happy with the fundamental "surivival" logic (dont hit walls, head towards light yada yada) but there's no real intelligence there.

Now I'm thinking it's time to invest in some hardware to estimate (hopefully accurately!) how far it has travelled in 2 dimentions.

I've had some success with a simple infrared optical mouse but it isn't accurate or reliable enough on most surfaces (which is fair enough, useless mouse when I had it!). I've read quite a lot on IMUs and I wanted to know if anyone had any suggestions for me.

Some sort of digital compass would be a must as I dont have any form of wheel encoders. Using a flakey mixture of sensors I can estimate distance travelled but it's not great.

What do you guys suggest?
 Logged

Norway@Oslo
Offline
Edison Member
Karma: 12
Posts: 2033
loveArduino(true);
 « Reply #1 on: October 13, 2009, 02:28:29 am » Bigger Smaller Reset

You can use rotary encoders, and wheels with a known diameter.

Use a number of IR LED beacons and a wiimote (used as an IR camera) and triangulate your position.

Accelerometers (and/or gyros), math and some luck.

I'm sure someone will have more and better ideas

If you can, you could make a grid of the area using black and white tape (for instance) and a color sensor to detect a passing of a grid.
You could have black/white along X, and red/blue along y. Then, each time a state changes [x from black to white or vice versa] | [y from red to blue or vice versa] you simply increment the position by the width of the grid. [/edit]

 « Last Edit: October 13, 2009, 03:04:44 am by AlphaBeta » Logged

The Big Smoke
Offline
Sr. Member
Karma: 0
Posts: 260
Hacking and Slashing
 « Reply #2 on: October 13, 2009, 04:27:28 am » Bigger Smaller Reset

I think rotary encoders maybe my answer. I'm not entirely sure how I'd fit them to the chassis I have. The wheels are based on rugged Tamiya RC kits.

I was considering the RF beacons, it definitely pandered to the geek in me but I want an entirely autonomous bot which doesn't require any major setups to pull off navigation.

If people can build UAV's then this technology must be reasonably available to hobbyists. You'd have to normalise the results across multiple sensors but I'm positive you could accurately measure inertia to provide X,Y and an angle (Other degrees of freedom don't concern me at the moment)
 Logged

North Yorkshire, UK
Offline
Karma: 104
Posts: 5531
 « Reply #3 on: October 13, 2009, 05:28:15 am » Bigger Smaller Reset

I recommend that you start with a sensor out of a better optical mouse if the vehicle is going to be travelling over flat surfaces...

You could use hall effect sensors on the wheel axles, this could be very accurate if done with the right sensors...

Regards,

Mowcius
 Logged

France
Offline
Karma: 36
Posts: 3448
There is an Arduino for that
 « Reply #4 on: October 13, 2009, 06:08:17 am » Bigger Smaller Reset

Measure on a driving axle is not accurate as the wheels may slip. You should use a free running wheel. But this will only be reliable in one axis.

To work in 2D the better is the mouse. For example if you have a ballcaster you can replace it with a modified mouse.

IMU is a really good answer to your problem but not the cheaper.

All those solutions are giving relative position. You should have some means aimed at giving a reference point to the robot and helped it correcting the IMU drift from time to time.
 Logged

The Big Smoke
Offline
Sr. Member
Karma: 0
Posts: 260
Hacking and Slashing
 « Reply #5 on: October 13, 2009, 07:17:18 am » Bigger Smaller Reset

Is triangulation the only answer for reference points. It seems like overkill to lay a bunch of base stations around.

Does anyone have any examples of such technies (especially in code!)
 Logged

North Yorkshire, UK
Offline
Karma: 104
Posts: 5531
 « Reply #6 on: October 13, 2009, 08:26:39 am » Bigger Smaller Reset

You could just use distance sensors to walls but it depends on what you want to do with this project...

Is it for travelling long distances? - Use GPS

Is it for in an enclosed room? - Use distance sensors

Is it for on a flat surface? - Use better modified mouse

Is it for a small flat surface? - Use reference points

Is it a tracked or 4 wheel device which does not have moving front axles? - Use hall effect senors on axles - the slip is minimal if it is not accelerating too fast or on soft ground...

Regards,

Mowcius
 Logged

The Big Smoke
Offline
Sr. Member
Karma: 0
Posts: 260
Hacking and Slashing
 « Reply #7 on: October 13, 2009, 09:55:36 am » Bigger Smaller Reset

At the moment it has 3x sensors (2 Infrared short-range, 1 Ultra sonic. Each can measure distance fairly accurate assuming the right surfaces).

I'm picking up a GPS but we're talking a small living room, not really outside (though it's not out of the question).

That's the base it'll sit on. So you'd suggest a more accurate mouse sensor - Do you, err, have any suggestions on a module? I find that they pretty much have to drag against the floor to be useful.
 Logged

North Yorkshire, UK
Offline
Karma: 104
Posts: 5531
 « Reply #8 on: October 14, 2009, 05:21:30 am » Bigger Smaller Reset

Quote
I find that they pretty much have to drag against the floor to be useful.

Yep they normally do... If it going to be on a flat surface then it would be ok. I would just gut a better mouse (a microsoft optical probably as they can run in ps/2 mode)

If it is going to be in that room then you could use more ultrasonic sensors...

If it's outside then perhaps the distance measuring doesn't have to be anywhere near as accurate and a GPS would do... The SIRF III chipset can be accurate to about 2.5m (massive distance indoors)...

What is the project for? If you can explain exactly why you want to measure the distance travelled then I could probably give some better answers but we're currently working in the dark here...

Mowcius
 Logged

The Big Smoke
Offline
Sr. Member
Karma: 0
Posts: 260
Hacking and Slashing
 « Reply #9 on: October 14, 2009, 05:34:47 am » Bigger Smaller Reset

Ah sorry mate, I'm half thinking aloud!

To answer your question, at the moment I'm working towards some sort of UAV but it's all fairly new to me. When I wrote my dissertation I spent a lot of time researching pathfinding (of known coordinates, without any form of triangulation) and positioning through WiFi which has led onto this thinking.

My short-term aim is to send a robot out into a unknown area and to map it out and from there to navigate around that area. Obviously I'm aware that the AVR probably can't mange this level of mapping so I'll probably modularise and offload some of the processing onto an ARM or maybe use a nearby laptop for the heavy lifting.

I appreciate some of the kit is quite expensive, it does turn you off when you're just a hobbiest. Though I dont want to spend a fortune I dont mind "investing" in the kit if it pays off - assumign what I'm buying isn't a rip off

After your comments I was researching IR beacons. That sounds quite interesting method in its own right and I'd be willing to give that a go. Do you know where you can pickup a module in the UK. Though saying that I presume it can't be to hard to build.

On a similar note, much of the beacon based position requires some form of triangulation or trilatertion. I've been looking around for details but if I'm honest most of the equations (even if the concept is simple) threw me. Searching for a library or some step by step intructions seem to leed nowhere - clearly I missed something in Math 101

Speaking of beacons, I presume you'd need to map the area of freedom to assign a beacon a static position for the idea to work. How do most people pull that off? Get the old tape measure out?

Society of Robots had some good information but most of their kit relied on encoders to estimate positioning.
 « Last Edit: October 14, 2009, 05:36:01 am by TeamMCS » Logged

The Big Smoke
Offline
Sr. Member
Karma: 0
Posts: 260
Hacking and Slashing
 « Reply #10 on: October 15, 2009, 05:19:14 am » Bigger Smaller Reset

For others interested, I found an interesting site which has provided code to trilaterate your position.

http://embedded.olin.edu/ultrasonic/software.php
 Logged

The Big Smoke
Offline
Sr. Member
Karma: 0
Posts: 260
Hacking and Slashing
 « Reply #11 on: October 16, 2009, 03:51:33 pm » Bigger Smaller Reset

I've been quite engrossed in this little project, I've built a demo for Trilateration you may view here http://milesburton.com/wiki/index.php?title=2D_Positioning_-_Trilateration_in_JavaScript

That's in two dimensions at the moment, now I need to include the third.
 Logged

0
Offline
Karma: 23
Posts: 3470
20 LEDs are enough
 « Reply #12 on: October 19, 2009, 05:35:33 pm » Bigger Smaller Reset

If you are not easily scared by higher math here is a starting point

I once read an article where NASA converted optical mice by means of suitable lenses for greater distance reading. Of course it will never work if you use only once mouse because you can not detect rotation around the sensor axis. But I always wondered (but not yet tried) if it would work using two or three mice. That way it would be possible to detect rotation and compensate for it.

 Logged

Chicago, IL, USA
Offline
Newbie
Karma: 0
Posts: 1
Eep opp ork ah-ah
 « Reply #13 on: July 01, 2010, 02:32:20 am » Bigger Smaller Reset

This thread has been dead for a while, but why not measure distance travelled with the mouse, and measure rotation/direction with a compass?
 Logged

 Pages: [1]   Go Up