Chief Delphi

Chief Delphi (http://www.chiefdelphi.com/forums/index.php)
-   Programming (http://www.chiefdelphi.com/forums/forumdisplay.php?f=51)
-   -   Feed back LEDS on OI (http://www.chiefdelphi.com/forums/showthread.php?t=25897)

bstempi 23-02-2004 16:25

Feed back LEDS on OI
 
Hey everybody.

I have 3 banner sensors on the front of my bot. They are hooked up to digital inputs 1, 3, and 5. I wanted to get some feed back from them without using dashboard and having to carry around a laptop. So, I decided that I wasnted to use the feedback LEDS on the OI. In the bottom of user_routines.c, i added a few lines like this:

SWITCH_1 = !(int)rc_digital_in01;

and modified it for each LED. I know i have the switch one variable wrong because i'm not looking at the code right now. Can anybody tell me what i'm doing wrong?
:ahh:

Phil_Lutz 23-02-2004 16:32

Re: Feed back LEDS on OI
 
Should read
Code:

    Switch1_LED = !(int)rc_dig_in01;
    Switch2_LED = !(int)rc_dig_in03;
    Switch3_LED = !(int)rc_dig_in05;

Remember you can always go back and look at the default code...

Hope this helps,

Phil

bstempi 23-02-2004 17:08

Re: Feed back LEDS on OI
 
Ok, I figured out my problem. My banner sensors were returning a low of 7 volts, and a high of 12 volts to the controller, indicating that it was always 1. Thanks for your help.


All times are GMT -5. The time now is 04:17.

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