Chief Delphi

Chief Delphi (http://www.chiefdelphi.com/forums/index.php)
-   Programming (http://www.chiefdelphi.com/forums/forumdisplay.php?f=51)
-   -   Edu Robot Multiple Inputs (http://www.chiefdelphi.com/forums/showthread.php?t=31384)

jrmarenda 22-11-2004 01:18

Edu Robot Multiple Inputs
 
I am having some serious problems with our innovation first Edubot. For touch and IR sensors, we can get the code to work with one sensor just fine, but if we try and use two inputs then we get weird results. I was wondering if anyone else has experienced this same problem? If so, what did you do to fix it? if anything? Thanks for you help.

Mike Betts 22-11-2004 08:58

Re: Edu Robot Multiple Inputs
 
Check the initialization to make sure that the inputs you are using are, in fact, inputs.

jerry w 24-11-2004 13:22

Re: Edu Robot Multiple Inputs
 
Quote:

Originally Posted by jrmarenda
I am having some serious problems with our innovation first Edubot. For touch and IR sensors, we can get the code to work with one sensor just fine, but if we try and use two inputs then we get weird results. I was wondering if anyone else has experienced this same problem? If so, what did you do to fix it? if anything? Thanks for you help.

I saw a similar problem when experimenting with sensors. the A/D converter uses a multiplexor. at each selection, the software must wait for the input to reach the voltage of each sensor. when using high impedance devices, the charge time takes longer.
I extended the wait time in the code, from 10 to 30 and the wierdness went away.

(see function Get_Analog_Value)

note, there is a warning in ...
* FILE NAME: ifi_utilities.c
* USAGE:
* The user should NOT modify this file, so that if a new version is released

Jerry W


All times are GMT -5. The time now is 02:51.

Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi