Shop OBEX P1 Docs P2 Docs Learn Events
Time of Flight Laser Project - Page 4 — Parallax Forums

Time of Flight Laser Project

12467

Comments

  • Laser DeveloperLaser Developer Posts: 140
    edited 2011-08-26 14:25
    What impact will this have one the design? I suspect that the specific part selected can have a large impact, changing a critical part may trigger a complete redesign.

    This is a really good question.

    Every part that I've chosen has an almost identical alternate (usually from a different manufacturer) and every module can be designed in different ways without adversely affecting performance.

    This is one of the big advantages of using a modular design approach - each module can be redesigned independently of the others. However, to make it work properly, the interfaces between the modules have to be chosen carefully. That is one of the reasons why I like to use differential signals between circuit boards - it offers higher speed and less interference than single ended signals.

    Once this first design is finished I'd like to make a different laser module (75W version), a different receiver module (PIN diode version) and shorter range optics (smaller). The real test of this design will be making changes to each module without having to make changes to any of the others.
  • Laser DeveloperLaser Developer Posts: 140
    edited 2011-08-29 06:46
    Working on the laser and receiver modules. The electronic designs are starting to make sense and I've been able to add a few more features without much extra cost. The mechanical parts will be relatively simple with one part for the laser module that allows it to be focused and another part for the receiver module that allows for both focus and optical alignment.

    Laser and receiver PCBs.JPG


    The picture shows paper cutouts of the boards, the smaller board is for the laser and the larger board is for the receiver. Unfortunately I've had to use TSSOP packages for some of the parts (availability problems) so these boards aren't going to be hand soldered (at least not by me).

    The laser module has worked out better than I expected. The laser can be hand soldered onto the board and the board will drive both the 14W and the 75W lasers without any modifications. A limitation is that the 75W laser will only produce about 30W but that's still quite powerful. I will design a different laser module that can produce the full 75W later.


    The receiver bandwidth is 0.5GHz and has lots of gain adjustment.

    The bandwidth is high enough for accurate distance measurement because we will add corrections into the software. This works by extracting the return signal strength from the timer chip and then applying a correction to the time of the signal in order to compensate for the less-than-ideal electronics.

    The gain control is included because at this stage I don't know what the noise characteristics of the final system will be. Noise limits the maximum amount of usable gain as does poor circuit layout that can lead to oscillations.

    Also, if the signal is too strong or over-amplified then the circuits will saturate and cause distortion. This means that the front and rear edges of the return signal will be in the wrong place for accurate timing.

    With this receiver design, the voltage gain of the signal can be controlled from +5dB to +70dB without significant timing distortions. This gives us a very wide operating range meaning that we should be able to find weak signals that are far away yet not get timing errors from strong signals that are up close.

    It will still take some time before I have all the parts and can get the boards made. I want to finish all three boards (laser, receiver and timer) before sending them out for manufacture.
    320 x 240 - 22K
  • Laser DeveloperLaser Developer Posts: 140
    edited 2011-08-30 12:03
    A whole day looking at power supplies and, once again, the solution is unexpected.

    There are choices of step-up or step-down regulators of either linear or switch mode types. For the three low voltage rails (1.5V, 3.3V and 9V) that makes 12 permutations. It should be fairly simple to select the correct combination of power supply components. But the real issue is not simply choosing power supplies. It's about designing a system that can be used in many different applications.

    The modular concept that has been part of the structure up to this point is valuable because it allows each module to be upgraded without having to redesign all the other modules. In choosing power supply components, this philosophy has to remain consistent. Having the right power supply can make the difference between a plug-and-play system and one that's just a pain to use.

    The problem can be restated in terms of what would happen to a selected power supply if the main power source was different or a component in the system was altered. Would our selection of a particular power supply remain the same or would it change?

    For example, we could select a linear, step-down regulator for the 1.5V rail in a design that will run off a 4.8V battery. This regulator is inexpensive, small and easy to use. But what happens if 4.8V is not available? Suppose that the main power source is a 12V car battery instead. The right solution would then be to use a switch mode, step-down regulator, not the linear regulator originally chosen. This is because the power dissipation of the linear regulator would make it too hot when powered from 12V.

    The problem becomes further complicated when components within the modules are changed. Changing from a 14W to a 75W laser requires the addition of an extra 20V power supply (if maximum laser power is to be achieved). Similarly, the choice of a different APD runnning off a negative bias rail instead of a positive one affects the design of the high voltage supply.

    In the end, there is no way of selecting a single set of power supply components that will be ideal for different power sources or usable with different modules and components. The inevitable conclusion is that the power supplies themselves must become a separate module. This way, different power modules can be made for different applications without having to redesign the other modules.

    So there are now five modules:

    1. Power supply
    2. Propeller
    3. Timer
    4. Laser
    5. Receiver

    Back to the drawing board...
  • Laser DeveloperLaser Developer Posts: 140
    edited 2011-09-06 08:38
    It's been a week of laying out PCBs and there's still a long way to go.

    I've been avoiding the fine pitch and BGA packages so that it will be easy to change parts on the prototype if (when) necessary. Unfortunately there are two parts that use the TSSOP package so the boards will need professional assembly. The laser and APD can be hand soldered and all external connections are standard 0.1" pitch.

    The laser board is 30mm x17mm and carries the driver components for an Osram, 14W SPL LL85 laser.

    The receiver board is 45mm x 35mm and carries the pre-amps and gain control cuircutry for a Hamatsu S2381 APD. The only reason why the board is so big is because of the optical alignment system (part of the board) and provision for an optical filter in front of the APD.

    The laser and receiver PCBs will be mounted onto the optical module with flat cables running to the timer board. The power supply and processor boards stack directly onto the timer board to make a "compact" module - 60mm x 40mm x 25mm. This module could be squeezed much smaller but then things would get too complicated for a prototype.

    The timer board that carries the timer chip (DS00VQ100) has only a few other parts on it and is quite simple. The complexity is in the timer chip itself making the PCB layout much easier.

    The power supply board has been designed to run from a 4V to 7V DC (still to be tested) so that a 4.8V or 6V battery can be used. It's got a mixture of linear and switch mode supplies including a 250V DC supply for the APD.

    Finally, the processor board has a Propeller chip along with the usual programming circuitry (Mini USB). There are some indicator LED's as well as external connections for servos or other accessories. The servos might be used to make a scanning laser system that moves the optics - rather like an eyeball. Measurements from the scanning laser could be used to create a 3D image of the environment.

    It will be a few more weeks before the boards are finished and then some time to get all the parts and have the boards made.
  • vanmunchvanmunch Posts: 568
    edited 2011-09-07 14:20
    Thanks for the update. Very exciting.
  • Laser DeveloperLaser Developer Posts: 140
    edited 2011-09-07 23:41
    Thanks for the support vanmunch. I love your work with agricultural robots.

    Some years ago I had an inquiry from a local fruit farming organization. They wanted to improve the efficiency of spraying fruit tress against pests. The method that they were using involved driving between the trees with a tractor towing a tank of pesticide. A pump continuously sprayed the trees on both sides. The idea that they had for improving the efficiency involved putting a solenoid control valve between the pump and the spray nozzles. The valves would open when a tree was detected by a laser rangefinder that was aiming perpendicular to the direction of travel.

    The idea was that where there was a tree missing or a gap between the trees then the pesticide would not be wasted. The system operated independently on each side and an exact dose was delivered to each tree. They estimated that they could save more than 30% on the cost of the pesticide using this system.

    At the time the laser rangefinders were too expensive and even though the system worked perfectly it never became a commercial product. Maybe it's time to look at the idea again?
  • rpascoalrpascoal Posts: 6
    edited 2011-09-08 04:20
    Nice effort, hope it is a success. Interesting how inexpensive tof rangefinders have been so hard to get to the hobby market.

    since the beginning of this year I have gp2 tdc chips from Acam, some MAX3806 from Maxim, SPL PL90 laser and SFH203PFA pin from Osram, mosfets and gate drivers.

    was hoping to get it all together in a symmetric circuit (transmit receive using the same layout) and to add the necessary high speed comparators from Linear Tech. and a microcontroller for interface but most are very small package (TQFN), pcb boards are expensive and time is short :( so I just had to halt after spice simulation of the pulse generator + laser driver and receiver and some pcb layout work.

    best wishes to your project!
  • Laser DeveloperLaser Developer Posts: 140
    edited 2011-09-08 08:16
    Awesome to see what you've been trying rpascoal! Thanks for the support.

    Your selection of components is really good but you have hit the same problems as many people before you. The design of a complete LRF using pulsed laser technology is full of complexities that take lots of time to figure out.

    The TDC chip from Acam is an obvious place to start but as you have noticed, using the QFN package makes hand assembly of the PCB very tricky. Also, the Acam chip manages the timing but doesn't help with the design of the rest of the system (like the laser driver). I've not used it before so I don't know how easy it is to get it to work.

    The MAX3806 is a new and interesting chip. I was tempted to use it in this design because of the claim that it is designed specifically for pulsed lasers and it has a high transimpedence. However, the bandwidth is very low (<100MHz) and in my experience, somewhere between 250MHz and 500MHz provides a better balance between gain and speed.

    Your selection of the SFH203PFA PIN for detection is very good because it has a daylight filter and it is really fast. However, I've had problems with detectors that have a lens on the front like this one has. They work fine on their own but adding larger optics (for increased range measurement) is quite tricky. Detectors with a flat window are easier to use with external lenses. Also, in designs using PIN diodes, problems with noise and interference can be hard to deal with using conventional PCB layout. Many suppliers will build the pre-amp into the PIN diode package for you to overcome these problems - for a price! In comparison, APDs give a signal that is 100 to 1000 stronger than a PIN which becomes much easier to amplify. Of course APDs are more expensive but sometimes it's just better to make the design work than it is to try and cut corners with critical components.

    The SPL PL90 laser from Osram is a brilliant component. I think I've used more than 20 000 of them in various products. They need a well designed driver to get optimum performance (as you know from your simulations). One of the easiest ways to drive them is with the avalanche BJT from Zetex (FMMT413) running at about 120V and discharging 2nF. It's a very reliable circuit and makes a nice pulse shape without any fancy layout. The problem then becomes one of creating the high voltage. The chip discussed in this thread (DS00VQ100) has control lines for a simple inductive, fly-back charge pump that is synchronised with the laser fire pulse. It creates short, voltage spikes on the discharge capacitor just before the laser fires - very efficient. Using a low voltage FET (as in your design) is much trickier to get right because the pulse becomes quite wide. I am trying the laser with a built-in FET for this design because I think it will give a better pulse. Even so, I'm going to hit the FET as hard as possible (3A gate current) to make sure that it avalanches as fast as possible.

    The design of a laser range finder is an interesting thought experiment, even if you can't get it to work in the end. It challenges so many conventional ideas about electronics and stretches our understanding about what can be made practically, rather than just on paper. It is my hope that by showing people how to make an LRF that soon a hobby version will become available.
  • vanmunchvanmunch Posts: 568
    edited 2011-09-09 08:25
    Hi Laser developer,
    Yes, I’m sure that they would see a significant financial benefit. If anything, I’m sure that the product that they’re applying has only gone up in price and solution is even less expensive.

    This probably wouldn’t work, but would it be possible for the laser rangefinder that you’re building to have an “add on” and be able to scan an area like a barcode scanner does? Some barcode scanners are even able to go across and up and down. The reason why I’m asking is that having a tool that can quickly sweep an area for objects would be very useful for ground or air robots. I’ve thought about a range finder mounted on a pan and tilt system, but it has a number of drawbacks compared to the barcode scanner mechanism: size, weight, much slower, vibrations, accuracy.

    Dave
  • rpascoalrpascoal Posts: 6
    edited 2011-09-09 09:34
    Hi again, Laser developer thanks for the nifty pointer on the SFH lens :), hadn´t noticed and according to Murphy's Law will certainly be a pain.

    Anyway PIN yeah cheap, I wasn't expecting to detect at large distances. I did calculate some stuff based on power, lens, atmospheric attenuation... it was a good paper http://maxwell.uncc.edu/gboreman/publications/Burns_OE_30_1991.pdf and 30 m range was ok, more than enough for what I need.

    Just want to navigate a robot in small indoor spaces and figured this setup would be a good starting point because the high speed problems and ringing are all there.

    I was going to use relatively wide pulses (40ns) and so I didn't get too upset with the 3806 bandwidth but it may of course be a problem.

    As for barcode type of stuff for the agricultural application, won't that be a problem because of sunlight? It's a continuous systems isn't it? just the mirror is rotating and the light levels on the detector are processed to determine if there's a valid sequence...

    Anyway, can't wait to see some of the results from Laser developer's project, sort of like http://www.raspberrypi.org/, nice... make sure to post when it goes commercial.
  • Laser DeveloperLaser Developer Posts: 140
    edited 2011-09-09 14:26
    Hi Dave,
    If anything, I’m sure that the product that they’re applying has only gone up in price and solution is even less expensive.
    To some extent I have to agree. Certainly the technology that is available today is far superior and less expensive to that available even a few years ago. Perhaps the problem is that so few companies offer products that use the specific components needed for a TOF LRF that a price war has not yet happened. This means that there is no pressure to drop prices to a more acceptable level.
    would it be possible for the laser rangefinder that you’re building to have an “add on” and be able to scan an area like a barcode scanner does?
    A fast laser scanner is certainly possible. I have seen many that use a moving mirror (similar to a bar code scanner) but for some reason they are mostly very expensive (more than $100,000). This might be because of the kinds of market that they are used in - precision survey work.

    The design that is being discussed in this thread may be used for 3D scanning in two ways. Firstly, by moving a mirror in front of the laser beam to steer it around. Alternatively, because the optical system will be made entirely of plastic (very light weight) and is connected to the electronics using flexible-flat-cable (FFC), a simple servo will be able to move the laser/receiver and optics around in a scanning pattern.

    The timing chip discussed here (DS00VQ100) can deliver about 100 measurements per second. Whilst this may not seem very fast, it is more likely that the "image" processing would be slower than the data collection rate.

    The images below were created by a laser scanner with similar capabilities to the one that we are discussing. The area covered is about 300 square meters. The first image is a "point cloud" of raw XYZ data. These "Cartesian" coordinates were calculated from the "polar" coordinates collected from the measured distance and the angles estimated from two servo drivers. The second image is of the triangulated surface created from the data points (turned the other way around). There is a lot of data processing needed to reach this resolution - removal of irrelevant data, fixing holes in the surface etc. Interestingly, one of the guys who worked on this project was a Russian applied mathematician who had previously worked on the Russian space shuttle program (http://en.wikipedia.org/wiki/Buran_(spacecraft)).

    3D Scans.jpg
    603 x 254 - 26K
  • Laser DeveloperLaser Developer Posts: 140
    edited 2011-09-09 15:38
    Hi rpascoal,
    thanks for the nifty pointer on the SFH lens
    My pleasure.
    30 m range was ok, more than enough for what I need.
    This looks correct for the parts that you have specified - as long as your PCB layout is good and the optics are well aligned for the distance.
    the high speed problems and ringing are all there.
    Are you talking about speed and ringing problems of lasers or ultrasonic detectors?
    I was going to use relatively wide pulses (40ns) and so I didn't get too upset with the 3806 bandwidth but it may of course be a problem.
    It worries me that the datasheet of the Max3806 shows a lot of information about gain but says nothing about time delays within the amplifier.

    A possible problem may be with the accuracy (not the range) of the design you have proposed. Using the higher gain amplifier at the expense of bandwidth means that the response time of the amplifier will be relatively slow. This leads to delays between the arrival of the optical return signal and the corresponding electrical movement of the amplifier output. So whilst the outgoing laser pulse may be fixed at 40ns wide (optical, half power points), there will be a significant difference in the "electronic" position and width of a strong, close up signal compared with a weak, far away signal. This difference in width means that the front edge of the "electronic" return signal will be in a different place when measuring to a reflective target compared with a dark target at the same distance.

    If the laser is producing a roughly triangular pulse then I would expect that the difference in the timing of the front edge of a strong and weak signal could be as much as 40ns (assuming that a comparator with a fixed threshold is used). That equates to a possible measuring error of 20 feet (7m). There would need to be a very good compensation system to correct for this delay difference, which demonstrates one of the difficulties with a TOF LRF - it is easy to make it measure long distances, but hard to make it measure close up with any accuracy.
    As for barcode type of stuff for the agricultural application, won't that be a problem because of sunlight? It's a continuous systems isn't it? just the mirror is rotating and the light levels on the detector are processed to determine if there's a valid sequence...
    In the agricultural application where the fruit trees were being sprayed, the LRFs were fixed, pointing outwards from the tractor towards the trees. There was no scanning (with mirrors) necessary because the tractor was moving. This linear motion created an artificial "2D camera" where the X-axis was the position of the tractor and the Y-axis was the distance to the trees. All that was necessary to trigger the valves was that the distance to the trees was cose enough for the pesticide spray to reach.

    However, you raise an extremely important point about the effects of background light. There are a number of different things that can to be done to reduce its effect. Firstly, the amplifiers should be AC coupled because the return signal is very fast compared with changes in the background light. Next, it is important to use a "daylight filter" of some sort. You have selected a PIN detector with this built-in which is a great way to solve the problem. Ideally, the daylight filter should have a very narrow, optical bandwidth. This will block almost all the sunlight from hitting the detector but will allow most of laser light through. With these solutions in place, background light cannot be "seen" by the detector and amplifier and so does not cause problems. (I hope that answers your questions - my writing is not always clear.)

    In the design for the LRF discussed in this thread, there is space for a daylight filter on the front of the receiver module. If the LRF is to be used outside then the filter can be added. It won't be necessary for indoor use.
  • prof_brainoprof_braino Posts: 4,313
    edited 2011-09-09 20:06
    background light. ... a number of different things that can to be done to reduce its effect.

    I have heard of a technique of "active filtering" where the ambient signal is continuously read and "subtracted" from the sensor.
    An example is an audio recording where the guitar was sent directly to the board, and the drums were mic'ed. The drum track picked up the guitar. To remove the "noise" signal, the guitar track was inverted, and played back with drum tracked, canceled the guitar, resulting in a clean drum track. Could this be applied, perhaps reading ambient light between pulses, and actively adjusting the sensor reading in software?
    How big a component of our laser's frequency is in sunlight? Are there artificial sources that have this?
  • Laser DeveloperLaser Developer Posts: 140
    edited 2011-09-10 02:28
    Noise cancellation at the frequencies that light waves oscillate is rather tricky. If the noise is a single frequency (color) and is coherent (all the photons are in phase with each other) then cancellation can be done using destructive interference. This involves mixing a reference beam of the same frequency and intensity but with a 180 degree phase shift.

    In practice, the light from background sources, either the sun or artificial lighting, is neither monochromatic (a single color) nor coherent (all photons in phase). This means that destructive interference can't be used. Perhaps an analogy would be like recording the "noise" but when you play it back later and try to subtract it from the background noise, you would find that the background noise has changed so much that there is no cancellation. Instead, the two noise sources would "add" and make things worse.

    The way that an optical filter works is by doing a "bulk" attenuation of all frequencies that are not close to the laser frequency. Think of it as the ultimate pair of sunglasses. With the laser switched off, the room looks completely dark. With the laser switched on, everything lights up in exactly one color (deep red). The attenuation of the non-laser colors is more than 10,000:1 whilst almost all of the laser light passes through the optical filter.

    The sun shines in wide range of colors, from ultra-violet to infra-red. At the laser wavelength (850nm or 905nm) there is significant light energy from the sun, even after the optical filter is in place. However, this background light produces a "DC" signal on top of the laser signal. This can easily be removed by AC coupling the amplifiers.

    There remains some electrical noise in the detector produced by the energy of the background photons. This electrical noise can be at the same frequencies as the electrical signals that are being measured. Ultimately, this limits the performance of the LRF to conditions where the return signal is bigger than the electrical noise. The good news is that the strength of the return signal can be increased WITHOUT increasing the background noise simply by making the receiver optics bigger. That's why in our design there is a large receiver lens (50mm) but a small laser lens (20mm).
  • prof_brainoprof_braino Posts: 4,313
    edited 2011-09-10 06:34
    Thanks for the detailed explanation. I'm learning more from your posts than I ever could have on my own (based on the last 20 years). Did you ever teach this subject?
  • Laser DeveloperLaser Developer Posts: 140
    edited 2011-09-11 00:21
    Glad you're getting some interest from the posts prof. No, I've never been a teacher but I was very influenced by my teachers at school - good teacher = good marks, bad teacher = bad marks. I think that if you can't explain something in simple, easy to understand terms then you don't understand it yourself. This thread is continually challenging me to question what I think I know and for every point I am researching and double checking my facts.
  • Laser DeveloperLaser Developer Posts: 140
    edited 2011-09-13 09:11
    A quick update on the progress of the PCBs - in the process of ordering parts before finalizing the boards. The reason why I'm ordering the parts before finishing the boards is so that I can be sure that the right footprints are available. If a part is only available in an alternative footprint then there is time to change the layout before the boards are printed. This has happened with the FT232 (USB interface from FTDI) - I could only get the RL version, not the RQ version so I have changed the layout to suit.

    The picture below shows paper cut-outs of the five boards (full size) alongside the optical parts. The smallest PCB is the laser driver with the receiver next to it. The three larger boards are the timer, power supply and processor respectively. They stack on top of one another (not separately as shown here).

    Paper PCBs.JPG
    320 x 240 - 27K
  • Laser DeveloperLaser Developer Posts: 140
    edited 2011-09-16 03:32
    The first parts to arrive are the Osram, SPL LL85 lasers. I sourced these directly from the Osram agent, even though they are available from RS Components. The agent offered me a price that was about half of that from RS.

    A few items look to be on long lead time - I will review the design and see if there is another part more readily available.


    Lasers.JPG
    320 x 240 - 23K
  • rpascoalrpascoal Posts: 6
    edited 2011-09-16 04:52
    Are you talking about speed and ringing problems of lasers or ultrasonic detectors?

    the ringing of signals in the high speed circuits, due to parasitic inductance and capacitance.
    It worries me that the datasheet of the Max3806 shows a lot of information about gain but says nothing about time delays within the amplifier.

    I was going to use a symmetric layout, where the start pulse is also going through the PIN and Max3806. Don't know if that solves the problems you mention, since the delay occurs in both channels.

    You are building at a quick pace, nice :), hope you market it as a kit and cheap :)

    I attach what I was doing up to some months ago :)
  • Laser DeveloperLaser Developer Posts: 140
    edited 2011-09-16 07:06
    That's very exciting stuff rpascoal. I think that we are using diametrically opposite principles to achieve the same objective. It is quite likely that both approaches will work!

    Laser Circuit
    Your laser driver is very good and should produce a nice pulse. You are using a stand-alone laser and are adding the high power driver circuit to it. This takes careful layout of the PCB and one of the difficulties with this approach is that the driver tends to emit lots of RF that interferes with the detector circuit. Often, the laser driver has to be buried in EMI shielding (as does the receiver).

    My interest in using a hybrid laser with a built-in driver is to reduce the amount of RF that the laser driver circuit emits. The lower RF comes about because the high current discharge path inside the hybrid laser is very short (about 5mm). For this design, where short range measuring capability is important, I would rather have a "quiet" laser driver than a perfectly shaped laser pulse. As a result my laser driver is very simple - copied straight from the Osram app notes.

    Receiver Circuit
    You have used a single chip amplifier going straight into the timer. Using low cost PIN diodes, your receiver circuit is clean and simple. Even the addition of the parallel channel for the start pulse makes sense and is nice and elegant. I cannot fault the logic of the design although I warn about the effects of background light on the zero PIN detector - bright bockground lighting might change the response of the zero circuit and introduce timing errors. This is one of the reasons why I have stopped using optical zero detectors.

    In contrast, my receiver solution is very complex. The circuit uses high voltages to bias a very expensive APD. There is a two stage amplifier - one with a transimpedence structure and the other with digitally adjustable gain. It is designed to work with a narrow-band optical filter and has a 500MHz bandwidth and is relatively expensive.

    Receiver PCB.jpg


    Why the Differences?
    Firstly, let me say again that both approaches will work. There is nothing specifically "better" about one design with respect to another. Instead, the designs will have different limitations.

    rpascoal's focus has been on firing the laser and he has spent considerable effort designing the laser driver. For the receiver and timing circuitry, he has relied on other circuit designers to solve these problems. In contrast, I have relied on the laser manufacturer to drive the laser for me and have tried to design the receiver to give the best possible signal to noise ratio and very high gain.

    If I might take the liberty of paraphrasing our different design philosophies - rpascoal is generating lots of laser light and is hoping for a large return signal whilst I care little about how much laser light is generated but am very worried about how weak the return signal will be.

    This difference in philosophy will show up in the performance of the finished LRF. rpascoal's LRF will work well indoors, will be low cost and small. Mine should reach hundreds of meters, outdoors. Different designs, different possible applications.
    912 x 661 - 36K
  • prof_brainoprof_braino Posts: 4,313
    edited 2011-09-16 07:45
    So, let me see if I understand this so far:

    rpascol design is bright, works well indoors, Range? (Will range be more appropriate for shorter indoor distances?), accuracy? (will accuracy be greater and therefore appropriate for shorter range?), strongly affected by ambient bright lights (have trouble with bright lights or daylight?). Cost? Will this likely be a relatively lower cost solution?

    Laser Developer design is not so bright, but uses a very large brief pulse from a very powerful laser; will work well outdoors over longer ranges, Will have several range selections (meters, tens of meters, hundred of meters, with an accuracy of 1 to 6 cm depending on range selected. Cost? Cost will be in hundreds of dollar for the complete system, is it likely that this will be the higher cost solution?

    As a further comparison, Joe Grand's design is coming out soon, and will cost about $129 per Ken's post on the thread. Joe's design has a range of 6 inches to six feet, and uses optical displacement of the laser spot for distance measurement.

    It seems our choices for laser ranging are going from zero to three in 2011! Did the planets align differently this year?
  • Laser DeveloperLaser Developer Posts: 140
    edited 2011-09-16 08:17
    Not a bad insight prof!

    Joe's design (and others like it) have influenced my decision to go for longer range with the time-of-flight technology. Let me start a technology list for robot applications:

    1. Optical proximity - 1" to 6"; collision avoidance; low cost.
    2. Ultrasonic (short range) - 1" - 2'; proximity sensing; low cost.
    3. Joe's laser - 6" - 6'; range sensing; indoors; precise aiming; medium cost.
    4. Ultrasonic (long range) - 1' - 20'; range sensing; indoor/outdoor; medium cost.
    5. TOF laser (medium range) - 1" - 30'; range sensing; indoors; precise aiming; medium cost.
    6. TOF laser (long range) - 1" - >150'; range sensing, indoor/outdoor; precise aiming; high cost.

    It would be fun to put together an experiment to compare the real performance differences between all the available technologies - maybe in the context of the environment in which they are to be used (indoor bots and outdoor rovers)...
  • Laser DeveloperLaser Developer Posts: 140
    edited 2011-09-19 00:56
    The circuit board layouts are finished and I'm waiting for parts before sending them out for manufacture. About half of the components have arrived but it will be a few more weeks before all of them get here.

    The picture below shows a mock-up of the PCB "stack" - the bottom board is the timer, the middle board is the power supply and the top board is the processor (the background picture is for dramatic visual effect only). The reason for using this stack is to keep the design modular.

    PCB stack mock-up.JPG


    As mentioned earlier in this thread, the processor is a Propeller. After discussions with prof_braino, the idea is to write the drivers for the LRF in Forth. I know that the prof is a Forth fan so there is some bias in this decision, but after reading up on the subject, I think that it would be fun to be able to interact directly with the hardware of the LRF.

    There are some cool features in the timer chip that are normally hidden from the user and Forth will give access to these features.

    For example, the APD gain is usually managed by an automatic software routine. Forth will allow users direct access to the APD gain control hardware in the timer chip and they could manually "push the limits" of the LRF. Forcing the APD to have very high gain dramatically increases the range of the LRF. Whilst this also increases the noise beyond the level that the timer chip can handle, this noisy signal could easily be analysed by the Propeller using a seperate software routine. Alternatively, the Propeller could transmit a video image so that the user can see where the return signal is.

    Perhaps an interesting educational project would be to analyse the noise characterisitics of the LRF when used beyond the recommended gain, then to develop a software filter to clean up the return signal. This sounds like the sort of thing that nglordi might be interested in.
    320 x 240 - 22K
  • Laser DeveloperLaser Developer Posts: 140
    edited 2011-09-21 01:11
    Whilst waiting for parts I have done a design review during during which every component has been re-analyzed in the hope of locating design mistakes before the boards are assembled. A few interesting things have come out of this (apart from the obvious fact that I don't know how to lay out circuit boards).

    On the processor board I've added a reset push button. This is not something that industrial products normally have so it seems an unnecessary addition. However, from what I've read about using Forth on the Prop, it might be useful.

    The EEPROM on the processor board has also been increased to 64K x 8 so that there is enough space to run Forth.

    There was a miscalculation on the impedance matching of the FFC cables. The system uses differential signals so the matching resistor has to be twice the value of the single line impedance. For a typical cable impedance of 100 ohm, there needs to be a 200 ohm termination.

    The laser voltage has been dropped a little from 9V to 7,6V. This is because 9V is given as the absolute maximum operating voltage on the data sheet and I don't want to run too close this limit for reasons of reliability.

    The heat dissipation of the power supply components has been recalculated. The system will definitely run from 4.0V to 6.5V and, depending upon the final load measurements, may even work all the way up to 12V.

    Finally, there is now a provision for an EEPROM on the timer board. This can be used to store calibration data so that the LRF will stay calibrated if the processor board is changed. I've used a common footprint for this memory chip so that an FRAM can be used instead of a Flash device. This makes "fast" writing of data possible without having to wait for the usual Flash write cycle.
  • prof_brainoprof_braino Posts: 4,313
    edited 2011-09-21 06:09
    ... design review during during which every component has been re-analyzed in the hope of locating design mistakes before the boards are assembled.

    The EEPROM on the processor board has also been increased to 64K x 8 so that there is enough space to run Forth.

    Comments:
    1) forth will run with 32k EEPROM, 64k EEPROM allows using the extra as a file and data storage, and the extra is appreciated.
    2) is there a possibility of allowing forum members to participate in the review cycle? The communicity always finds stuff, it might be useful to hear it now before the boards are assembled. I always advise "another pair of eyes" when ever possible. Whether or not any given item is actionable is of course left up to you. If you don't want wo post the intitial design in public, PM me and I will make a list of folks that I have in mind and you could communicate directly with them.
  • rpascoalrpascoal Posts: 6
    edited 2011-09-26 02:52
    Hello Laser Developer

    looks like you chose only top grade components, hopefully it will make things easier to debug.

    I have a few comments, hope they are constructive, and also some questions.

    I notice you are connecting the S2382 to 200V, which is the absolute maximum breakdown voltage. Gain has very steep curves and dark current quickly grows to several nA at around 150V (typical breakdown), I would probably have a second look at the power supply for this component and maybe include a temperature sensing element close to the APD for future closed loop bias voltage control.

    The APD is connected directly to the MAX3665. I'm not sure if that's a good idea, because the background noise is going to be amplified as well and any problem with the APD circuit may damage the amplifier.

    I'm not sure what the NC7S7175 is meant to be doing, looks a bit strange :), could you hint on that?

    I notice you're going to control receiver gain with the AD VGA, are you going to include an AGC circuit in the future? Does it behave well with pulsed signals? That is, you are going to receive high frequency content pulse but at only 100 Hz.

    looking good! best regards.
  • Laser DeveloperLaser Developer Posts: 140
    edited 2011-09-26 04:35
    Hi rpascoal, thanks for the feedback and questions.
    looks like you chose only top grade components, hopefully it will make things easier to debug.
    The idea is to start with a design that has a good chance of working, even if it is over designed a little. If things work out then we can gradually reduce the specifications of the parts to reduce cost.
    you are connecting the S2382 to 200V, which is the absolute maximum breakdown voltage
    The circuit diagram is a bit unclear on this point (and thanks for finding a description error on the power supply board, CON1 drops down to the timer board, not up to the processor board). 200V is the maximum operating voltage of the APD bias supply circuit, it will not be the normal operating voltage of the APD. The switch mode supply (on the power supply board) that creates the bias voltage is driven by a signal that comes from the timer chip. This signal is controlled by the amount of noise in the return signal, forming a feedback loop. The idea is that the APD runs at a voltage that is just below the point at which noise begins to climb out of control. This system doesn't need a temperature sensor because it automatically adjusts the APD bias to give maximum available gain. It also corrects for noise induced by background light and handles the problem of different APD's having very different breakdown voltages.
    The APD is connected directly to the MAX3665. I'm not sure if that's a good idea, because the background noise is going to be amplified as well and any problem with the APD circuit may damage the amplifier.
    Decoupling the APD (using a capacitor) will add stray capacitance that will reduce bandwidth and, unfortunately, will not block the noise from being amplified. Instead, the circuit relies on the auto-zeroing feature of the MAX3665 pre-amp to keep the output away from saturation when there is a small amount of noise coming from the APD. The APD bias circuit also has 110k ohm resistors in series with the HV power supply to prevent accidental current overload on the input to the pre-amp.
    I'm not sure what the NC7S7175 is meant to be doing, looks a bit strange :smile:, could you hint on that?
    The NC7S7175 is not strictly necessary, I only added it in because there was some discussion about using the LRF for 3D scanning. Scanning requires fast measurement updates and there are often rapid changes in background light conditions. This means that there is very little time for the noise feedback loop to keep control of the APD bias voltage.

    The timer chip deals with this by briefly raising the APD bias a few volts BETWEEN laser shots (via the NC7S7175). This brief increase in voltage injects noise into the system which is measured by the timer chip and used to control the lower, distance measuring bias (where there is no noise). This "noise injection" system allows the bias voltage used for measuring distance to be set a few volts below the bias point at which noise is seen, making the return signal quieter and the noise control more stable at the same time.

    This isn't the only way to control APD noise. A simpler approach is to use alternating measurement cycles - a high bias cycle to measure the noise followed by lower bias cycle to take the distance reading. This is obviously slower and doesn't work quite as well with scanning systems.
    are you going to include an AGC circuit in the future? Does it behave well with pulsed signals? That is, you are going to receive high frequency content pulse but at only 100 Hz.
    The AGC is not intended for a production design - it's not necessary. The reason for having it now is to find out what is the optimum post-amp gain. This is hard to calculate because my circuit board layouts are so crummy that I suspect that parasitic capacitance will dominate the design. That said, the part that I've chosen (AD8369) has excellent "group delay" characteristics. This means that the time that it takes for signals of all different frequencies (and all different gains) to travel through the chip is the same to within 200ps. This group delay is a more useful indicator of the pulse handling performance of an amplifier than the delay specified at a single frequency. This is because it is the fourier components of our pulsed signal that need to be preserved in order to keep accurate timing edges.

    FYI - most of the parts have arrived. I'm now setting up a workshop with a 'scope, soldering iron, power supply and anti-static matting in readiness for experimentation to begin. The boards should be at the printers by the end of the week - just finalising the Gerbers (reading the manual!).
  • Laser DeveloperLaser Developer Posts: 140
    edited 2011-10-01 10:17
    With the hardware design now complete (just waiting for two more parts) I've started looking at the software in more detail. As a starting point I've been defining high level interfaces (human and machine) that would make convenient entry points for testing or using the LRF. I was thinking of structuring a mnemonic system where ASCII codes could be used to access all the available features. These codes could be typed in from a terminal (over USB) or sent from a host uP directly to the UART. Codes would be terminated by <CR> and would be case insensitive.

    Typical codes would be structured like this:

    RMD = read measured distance => returns [value]
    RAN = read APD noise => returns [value]
    SAG [value] = set amplifier gain => returns <ack>
    SAV [value] = set APD voltage => returns <ack>
    CTP [code] = configure test points => returns <ack>
    CRM [code] = configure run mode => returns <ack>

    Some of the mnemonics, like RMD (read measured distance), would access high level functions that manage the complete measuring process. Other mnemonics would access lower level functions that allow the user to experiment with the internal setup. The LRF would also have different modes of operation than can be set using the CRM (configure run mode) mnemonic. These modes would set a group of internal parameters to optimise specific performance capabilities such as speed, range or resolution.

    One of the things that I have tried to achieve with this design is maximum performance flexibility. This will, hopefully, make the LRF more interesting to a wider audience. The minimum and maxium performance settings are summarised below:

    Range
    Minimum: 0m to 15m [49']
    Maximum: 0m to >350m [1150']

    Update rate
    Minimum: <1/sec
    Maximum >100/sec

    Resolution
    Best <1cm [0.4"]
    Worst >6cm [2.4"]

    Not all the maximum performance capabilites can be achieved at the same time. For example, increasing the maximum range will decrease the update rate. This is why I think it is important for users to have access to the internal settings so that they can tweak the performance to suit their application. It may also be possible to string together groups of low level mnemonics to create custom performance "macros". For a robot this may be something like starting with a fast "sweep" around an area at maximum update rate, using this information to locate a distant target object, switching to medium speed/medium resolution whilst approaching the target, finally switching to high resolution as the target gets close.
  • vanmunchvanmunch Posts: 568
    edited 2011-10-02 16:09
    It may also be possible to string together groups of low level mnemonics to create custom performance "macros". For a robot this may be something like starting with a fast "sweep" around an area at maximum update rate, using this information to locate a distant target object, switching to medium speed/medium resolution whilst approaching the target, finally switching to high resolution as the target gets close.

    This is going to make so many things possiable. I just have a couple of projects that I need to finish before I start to think about how to use something like this.... :)

    Dave
Sign In or Register to comment.