Counter Circuit Needed
RogerInHawaii
Posts: 87
I need a circuit designed which interfaces to the Parallax Stamp circuit board. This circuit will consist of a 16-bit counter which is incremented by a 12 GigaHertz clock. From the Stamp’s standopint it needs to have a control line to zero the counter, one to start and stop the counter, and a means to read the contents of the counter.
Is there anyone who could assist me in this?
- Roger Garrett
Is there anyone who could assist me in this?
- Roger Garrett
Comments
Have a look at the SX and the Propeller both of which would be fast enough to handle sub-microsecond control functions.
Thanks fo rthe response. I will indeed take a look at the SX and the Propeller boards. But I wasn't thinking of using the clock of the Stamp itself to drive the counter. I was expecting to have an additional clock circuit to drive the 16-bit counter, which would let me have a clock rate tuned specifically tomy application.
So, I need some help in selecting the right counter (capable of high clock speeds) and in designing the needed circuitry.
- Roger Garrett
Germane to Mike's comment: 12Ghz / 65536 = 183KHz. This is the rate at which your 16-bit counter would make one complete cycle. That's every 5.5uS. Even if the BASIC Stamp were able to read such a counter, it would have cycled multiple times during a single read instruction. I seriously doubt the reading would have any meaning, except perhaps as a random number. What is it you're trying to do at such speeds?
-Phil
Designing a 12GHz counter is a very specialized need with very specialized experience needed. It's really way beyond the scope of these forums. Once you decide on a counter design, that will determine how the counter has to interface to the microcontroller.
This couldn't be a MIR project is it?
An MIR project? Well, I could answer that if I knew what an MIR project was.
Phil and Mike,
I see what you mean. Yes, there would be problems with overrun of the counter. I could explain more precisely what my needs are outside of this forum, if you'd be willing to contact me directly (RogerInHawaii@aol.com) and maybe you could poiint me in the right direction.
- Roger
I'm happy to make suggestions in the forums. Private discussions are not very useful to others trying to learn and I really have little experience working with stuff in this frequency range.
Mike
If you need more resolution you could use hardware counters outside the stamp but your start and stop would have to be driven with an external trigger. Unless you use assembler and an chip you can know the time it takes to start and stop the counter so you can subtract the time between it actually starting and stopping. Once the timer is stopped you would read in as many bits of resolution you want from the hardware counters. but i don't have a clue what kinds of components would run at that speed.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Think Inside the box first and if that doesn't work..
Re-arrange what's inside the box then...
Think outside the BOX!
The start and stop triggers will have to come from your external device (laser pulser and receiver?), and will have to exhibit virtually zero uncertainty in the picosecond range to get the kind of resolution you're after. Given this, it should be no problem for a Stamp to read a stopped clock.
But, seriously, most sportsman's laser rangefinders that sell for around $200 are accurate to a yard or two. Achieving sub-inch resolution will be an order of magnitude (or two) more difficult — assuming that's even what you're trying to do, of course!
-Phil
The sample rate is still limited to the speed of the Stamp of course.
This is assuming your need is to determine the exact frequancy of the signal you are testing. Otherwise... Never mind.
More details would help.
Post Edited (LilDi) : 10/21/2007 7:03:52 PM GMT
From prior comments on this topic it's clear I'd need a 32-bt counter, since the 16-bit counter would no doubt cycle several times during the full process.
So, does this sound reasonable?
That would be like trying to measuring the width of a molecule with a yard stick. Before the stamp at either end can even begin to execute a line of MPU micro code, the 12ghz signal will have traveled to the object many hundreds of times.
I'm not real sure on this, but I think dopler sensors may be able to measure the distance to an object with this high of a frequency.
Good Luck,
If you find a solution I'm sure others here would like to here about it. Keep in touch!
Post Edited (LilDi) : 10/21/2007 7:40:33 PM GMT
No, it doesn't sound remotely reasonable. It's simply impossible for a BASIC Stamp to respond with the picosecond accuracy your app requires. LilDi's simile, "That would be like trying to measuring the width of a molecule with a yard stick," is apt.
-Phil
I could be wrong but I think those laser rangefinders are actually Interferometers which work with beat frequencies and not frequency counters.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Have Fun
TR
· Is there any possiblity of using ultrasonics ? That would make the project much more manageable / practical. And still be able to get 1" resolution.
· Check out the Parallax Ping sensor http://www.parallax.com/detail.asp?product_id=28015
Bean.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
My goal is to live forever...Or die trying.
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
www.hittconsulting.com
·
Another issue, along with Bean's thinking, Frequencies that high tend to penetrate objects rather than reflect off the surface. That would give you inaccurate readings depending on the density of the object. That's closer to a MIR (micro power inpulse radar) that can see through objects and reflect back an image of the inside or on the other side of an object.
My initial idea was for some kind of transponder on the target object, a simple receiver/transmitter that would operate in receive mode and, when it detected an incoming transmission with a particular encoded value (e.g. to identifiy which transponder was being "queried" for its range) would respond by transmitting back with another encoded value. The device doing the querying would be the one with the counter circuitry; it would zero the counter, start it counting, send out a coded value via its radio transmitter, wait for the return coded transmission, stop the counter, read the value of the counter, subtract the appropriate amount from that value (which is due to "processiong time") to arrive at the total actual transmission time, i.e. how long the radio wave took to get from the transmitter, to the transponder, and back to the receiver, divide by two and get the range between the objects.
When I came across the Stamp (Propeller/SX) I thought maybe it would simplyify the design and reduce how much cicuitry I had to have designed and built. But maybe not. Maybe I need to go back to mostly specially-built circuitry. So, I guess I need someone who could handle that kind of design.
Any suggestions?
- Roger
In any tuned circuit time-of-flight system such as you're proposing, the uncertainty in a wave pulse's time of arrival will be inversely proportional to its carrier frequency. What this implies is that your carrier frequency will have to be several times greater than the 12GHz counter frequency in order to keep the time-of-arrival uncertainty within specs. Also, in non-line-of-sight situations, there will be multi-path issues, wherein the arriving wave pulses can be distorted by having traveled over different routes, due to reflections along the way.
A system that might hold some promise would use ultrawideband (UWB) transmissions, which consist of coded, picosecond bursts, whose energy is spread over a wide spectrum. (Zigbee is an example of UWB radio.) By syncing to these coded bursts, you may be able to get the accuracy you're after. But I have no idea what devices are available to do this or how it might be implemented. If you Google uwb transponder, you will get a host of links.
-Phil
Thanks to one and all for your comments on this issue. I really appreciate your taking the time to consider my posting and provide feedback.
Let me explain what it really is that I’m trying to do, and maybe it will prompt some ideas or alternative approaches…
My brother has over fifty acres of Christmas trees. The grass between the trees needs to be mowed about every three weeks. That’s a tremendous amount of labor, so I was trying to come up with an automated robotic mower that could handle the work for him. I’m a software engineer, and am pretty certain I can come up with a comprehensive approach to the robot control (software) issues.
The one prime problem is letting the robot know where it is as it traverses the field, maneuvering between the trees. A random walk / bump-and-turn approach isn’t suitable since a random walk (as is so often used with small yard mowing robots) is incredibly inefficient and, although bumping into the trunk of a mature (four-to-five year old) tree would do no harm to the tree, the field also has thousands of seedlings (one-to-two year old trees) which are only a foot or so high and are indistinguishable, to any bump-detection hardware, from the grass and weeds, so it would simply mow right over the seedlings. No optical system exists that could actually “see” and recognize the trees. Indeed, even when my brother is doing the mowing it’s sometimes difficult for him to see the seedlings amongst the weeds and grass.
So, I figured I needed some form of positioning system, so that I could define the boundaries and also define the position of each and every tree in the field. That might sound like an incredibly labor-intensive job, but it would actually take no more labor than one complete mowing of the field, walking through each row and electronically recording the position of each tree (with a suitable position recording device).
GPS is the “obvious” first thought. But GPS only has a resolution of about three to four feet. Since the trees are only six feet apart that simply won’t do. I figured I needed some kind of LPS, Local Positioning System, with some form of beacons or otherwise stationary posts from which the robot can determine its position. Laser pointers and sonic approaches won’t work because the line-of-sight to the beacons would generally be obstructed by the trees. (MAYBE the position detector could be mounted on a tall shaft on the robot so that it’s taller than the tallest tree, about ten feet, but I’m concerned that the uneven motion of the robot would cause the shaft to wobble so much that it would make position-determination very difficult and unreliable). Sonic detection would suffer from the same trees-in-the-way problem, as well as the distance to the beacons (several hundred feet).
So, I thought of radio. I had hoped that radio would be less suseptable to intereference by obstructing trees. But it seems that, in order to get the needed resolution (at most a foot resolution, ideally an inch resolution, but perhaps suitably a half-foot resolution) the radio frequency needs to be in the microwave range. Since microwaves are notoriously obsorbed by water my positioning system would be more likely to cook the Christmas trees than to provide any meaningful position information. Again, I suppose it’s possible to position the detector on a tall shaft on the robot and simply go over-the-heads of the trees.
Phil notes that uncertainty in a wave pulse’s time of arrival is inversely proportional to the carrier frequency, meaning that the longer the wavelength the more uncertain is the measurement of its arrival, so if I’m trying to determine the robot’s position to within an inch, but the uncertainty is a foot, the measurement cannot be relied upon. I think I’m here but I’m really there, mowing down another seedling. So I’m thinking. Maybe all I need to do is perform a whole slew of measurements at a given position and average them. Well, no. If the uncertainty described a nice uniform Bell curve that might work. But I suspect that the shape of the “uncertainty curve” is significantly dependent upon way too many factors (e.g. the trees between the robot and the beacon) to be of any use.
Then again, if I have a large number of beacons and take measurements from each one, the uncertainty might get sufficiently low to become a reliable measurement. Maybe?
Or maybe there’s some incredibly cheap device (an RFID chip) that I could place on each tree trunk that could be detected by the robot ???
Suggestions are welcome !
- Roger
-Phil
It would be coded similar to a "line following robot".
Bean.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
My goal is to live forever...Or die trying.
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
www.hittconsulting.com
·
Using a buried wire might be one approach. But for fifty acres of fields laying out the track between rows of trees six feet apart that's an awfully lot of wire and a tremendous amount of labor (and I'm guessing a lot of energy to power the wire). In addition, as the years go by and trees are cut down and new ones planted, the new rows do not necessarily line up with the old rows, meaning pulling up old wire and burying new wire.
- Roger
- Roger
What's wrong with the high precision GPS (other than cost maybe?) It sounds like it could give you the accuracy you need and would come ready-made.
Well, I've found a few companies that describe their high performance GPS instruments for agricultural applications. Although they don't lst their prices, their descirptions and intended applications (HUGE farms) give me the impression that they are VERY expensive. My hope was not just for using it at my brother's farm but making something marketable to similar "small" agricultural operations.
If I can actually find some prices I'll be able to make a better decision on that.
- Roger
Please explain.