To LUGNET HomepageTo LUGNET News HomepageTo LUGNET Guide Homepage
 Help on Searching
 
Post new message to lugnet.roboticsOpen lugnet.robotics in your NNTP NewsreaderTo LUGNET News Traffic PageSign In (Members)
 Robotics / 11647
11646  |  11648
Subject: 
Re: Sonar x Batteries
Newsgroups: 
lugnet.robotics
Date: 
Tue, 6 Jun 2000 19:15:10 GMT
Reply-To: 
nospam-dcchen@NOSPAMpacbell.net-nospam
Viewed: 
827 times
  
I too noticed that the battery usage went way up.  I got around this by
using trains of IR Pulses (like 10 Pulse IR/Check IR level pairs in a
row)
followed by a rest period for let's say 100msec then checking IR again.
This creates a lower (approx 20%) "Duty Cycle" that conserves battery
power.
Doesn't seem to effect range much either.  You can play with the
settings to
optimize to your environment.

Dave

Code as follows (in NQC):

DEFINE ONCYCLES 10   <--How many times in a row to Ping for an obstacle
with IR
DEFINE OFFTIME 100   <--How many msec to give it a rest
IR_THRESHOLD    70   <--In Percent mode, your mileage may vary.  Adjust
as needed.

task Ping
{
  while(true)
  {
    repeat(ONCYCLES)
    {
      maxlight = IN_2;
      if(maxlight > IR_THRESHOLD)
      {
        *** DO YOUR COLLISION AVOIDANCE STUFF HERE ***
        break;
      }
      SendMessage(maxlight);
    }
    Sleep(OFFTIME);
  }
}

Mauro Vianna wrote:

Hi, people!
I built a sonar-like feature as other people here had done already. The
robot is using the RCX to send IR messages and a light sensor to detect the
IR reflections. It sends messages continually while moving and detection
works fine. It works better with red obstacles.
But it seens that this feature consumes the batteries fast. Can somebody
confirm that?
If true, did somebody already use any workaround as an external IR emitter
connected to external batteries?

Best regards,

Mauro Vianna



Message is in Reply To:
  Sonar x Batteries
 
Hi, people! I built a sonar-like feature as other people here had done already. The robot is using the RCX to send IR messages and a light sensor to detect the IR reflections. It sends messages continually while moving and detection works fine. It (...) (24 years ago, 4-Jun-00, to lugnet.robotics)

4 Messages in This Thread:


Entire Thread on One Page:
Nested:  All | Brief | Compact | Dots
Linear:  All | Brief | Compact
    

Custom Search

©2005 LUGNET. All rights reserved. - hosted by steinbruch.info GbR