Go to Post If people really want to see "better" refereeing, they should see what they can do to help FIRST make better. - petek [more]
Home
Go Back   Chief Delphi > Technical > Programming
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
 
 
Thread Tools Rate Thread Display Modes
Prev Previous Post   Next Post Next
  #9   Spotlight this post!  
Unread 02-02-2008, 20:13
Alan Anderson's Avatar
Alan Anderson Alan Anderson is offline
Software Architect
FRC #0045 (TechnoKats)
Team Role: Mentor
 
Join Date: Feb 2004
Rookie Year: 2004
Location: Kokomo, Indiana
Posts: 9,113
Alan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond repute
Re: Relay program?

Quote:
Originally Posted by team877 View Post
here is our code you asked for....
Code:
void operatorControl ( void )
{
	unsigned char x;

	while ( 1 )
	{
		SetPwm ( 2 , x ) ; //  We’re setting are variable to the motor we want it to measure
		if ( 125 < x && x < 129 ) 
		{ // We want this relay to engage between these speeds
			SetRelay ( 1 , 1 , 0 ) ;
		}
		else
		{ // And if not turn the relay off
			SetRelay ( 1 , 0 , 0 ) ;
		}
	}
}
I don't see anything that sets the value of x. Did you forget the line that reads the joystick value?

(Is there a reason you posted it as a Word document containing a picture, instead of just copying the text? I don't use Word, and it was inconvenient to convert your file to a readable form.)
 


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Instance relay Team_486 Programming 0 28-03-2007 09:56
Relay Commands Matt Krass Programming 6 18-02-2006 23:03
Relay Assignments MulletFish Programming 9 27-01-2005 14:15
Relay fault archiver 2000 2 23-06-2002 23:36
Relay Outputs OddOne Technical Discussion 3 01-02-2002 19:52


All times are GMT -5. The time now is 20:45.

The Chief Delphi Forums are sponsored by Innovation First International, Inc.


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