To LUGNET HomepageTo LUGNET News HomepageTo LUGNET Guide Homepage
 Help on Searching
 
Post new message to lugnet.robotics.handyboardOpen lugnet.robotics.handyboard in your NNTP NewsreaderTo LUGNET News Traffic PageSign In (Members)
 Robotics / Handy Board / 3852
3851  |  3853
Subject: 
important update to Handy Board standard libraries.
Newsgroups: 
lugnet.robotics.handyboard
Date: 
Wed, 20 May 1998 00:18:12 GMT
Original-From: 
Fred G. Martin <FREDM@stopspammersMEDIA.MIT.EDU>
Viewed: 
1205 times
  
Hi all,

There has been a bug lurking in the Handy Board standard library files
since the dawn of time (well, 1996, when the HB got started).

The bug can happen when you are using multi-tasking, and more than one
IC task is performing analog sensor readings, or if you have loaded
drivers that may perform analog conversions (e.g., the shaft encoder
utilities).

In the subroutine in lib_hb.c which performs analog readings
(_raw_analog), it is possible for another process (either an IC
process or an assembly language driver) to interrupt the analog
conversion, in between the time when the analog channel is selected
and the result is read back.  If the interrupting process performs an
analog conversion of its own, when the interrupted subroutine gets
control back, it reports the later reading rather than the one it
started.

I've posted an updated version of the libraries that fix this problem.
A short assembly language driver performs the basic analog read
function.  Interrupts are disabled during the span between the
selecting the analog channel and reading the result.

I recommend that everyone download and install these new drivers.
Aside from fixing this intermittent bug, the new driver is faster and
smaller.

To download, please see the Handy Board home page:

  http://el.www.media.mit.edu/projects/handy-board/

Let me know if you have any questions or concerns.


Fred

P.S.  Thanks to Ericson Mar and Rick Freuler for noticing and
reporting this problem.



Message has 3 Replies:
  Re: important update to Handy Board standard libraries.
 
Fred, How does the fix affect IC3.2? Jun Nolasco nolasco@inx.net (...) (26 years ago, 20-May-98, to lugnet.robotics.handyboard)
  Re: important update to Handy Board standard libraries.
 
Will this new lib_hb.c also replace the Smooth PWM lib_hb.c released by Newton Labs? It appears not. What is the easiest way to consolidate the Smooth PWM routines with your improved analog code? Cheers, Skye. +---...---+---...---+ | Skye Legon | (...) (26 years ago, 20-May-98, to lugnet.robotics.handyboard)
  Question about Sharp IR demodulators
 
Hi everyone, First, sorry for the blank message just now -- hit the send button instead of the cancel. I'm working on a project where I've got robots hunting targets equipped with a 40 kHz oscillator circuit which is continuously pulsing an IR LED. (...) (26 years ago, 10-Jun-98, to lugnet.robotics.handyboard)

7 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