Go to Post A well-designed shifting transmission, controlled by an experienced driver (or a clever bit of software), is an advantage. - Alan Anderson [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
  #1   Spotlight this post!  
Unread 12-02-2008, 21:58
niagra127 niagra127 is offline
Registered User
FRC #1785
 
Join Date: Jan 2008
Location: Missouri
Posts: 6
niagra127 is an unknown quantity at this point
Code error?

Alright our team has been trying to run a motor through a pwm with the buttons on the joystick.

Code:
if (p1_sw_aux1 = 1 && p1_sw_aux2 = 0)
	{
		pwm10 = 255
	}
else if (p1_sw_aux1 = 0 && p1_sw_aux2 = 1)
	{
		pwm10 = 0
	}
else
	{
		pwm10 = 127
	}
This returned nothing on the motor and we are positive the motor runs.
We also tried just using pwm10 = 255 to see if anything would happen and we got absolutely nothing in return. The motor just constantly sits there, we think its an electrical problem but we are still getting told its a programming error. If this is true can anyone tell us what it is we are doing wrong?
 


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
Code Error? darkdwarven Programming 1 08-02-2008 00:42
Error in code light on, trouble finding error Bryan Herbst Programming 16 12-10-2007 21:59
Code error on RC after downloading "bells and whistles" version of Kevins camera code DanDon Programming 6 10-01-2006 18:07
Error w/ FRC code JamesBrown Programming 2 08-01-2005 16:17
C++ Code Error? Adam Shapiro Programming 9 20-01-2003 13:24


All times are GMT -5. The time now is 12:26.

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