Go to Post Once you have a lathe you'll wonder how you ever got through life without one. - Wayne TenBrink [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

 
Closed Thread
 
Thread Tools Rate Thread Display Modes
  #1   Spotlight this post!  
Unread 04-05-2006, 17:34
intellec7's Avatar
intellec7 intellec7 is offline
108 programmer
AKA: Gustavo
FRC #0108 (SigmaC@ts)
Team Role: Programmer
 
Join Date: Sep 2005
Rookie Year: 2006
Location: Hollywood, Florida
Posts: 65
intellec7 is on a distinguished road
Send a message via AIM to intellec7 Send a message via MSN to intellec7
Vex start up code run PWM outputs without Rx

With the default startup code (the MPLAB project available at http://www.vexlabs.com/vex-robotics-downloads.shtml)

The PWM outputs are not updated when the Reciever unit is not plugged in/transmitter is off. If in Process_Data_From_Local_IO I try to set pwm01=255, nothing happens. I tried to call Process_Data_From_Master_uP(); every loop but that did not help. I would like to use my robot autonomously without having to have the transmitter on or the reciever plugged in.
Thanks.
  #2   Spotlight this post!  
Unread 04-05-2006, 17:53
billbo911's Avatar
billbo911 billbo911 is offline
I prefer you give a perfect effort.
AKA: That's "Mr. Bill"
FRC #2073 (EagleForce)
Team Role: Mentor
 
Join Date: Mar 2005
Rookie Year: 2005
Location: Elk Grove, Ca.
Posts: 2,355
billbo911 has a reputation beyond reputebillbo911 has a reputation beyond reputebillbo911 has a reputation beyond reputebillbo911 has a reputation beyond reputebillbo911 has a reputation beyond reputebillbo911 has a reputation beyond reputebillbo911 has a reputation beyond reputebillbo911 has a reputation beyond reputebillbo911 has a reputation beyond reputebillbo911 has a reputation beyond reputebillbo911 has a reputation beyond repute
Re: Vex start up code run PWM outputs without Rx

Quote:
Originally Posted by intellec7
With the default startup code (the MPLAB project available at http://www.vexlabs.com/vex-robotics-downloads.shtml)

The PWM outputs are not updated when the Reciever unit is not plugged in/transmitter is off. If in Process_Data_From_Local_IO I try to set pwm01=255, nothing happens. I tried to call Process_Data_From_Master_uP(); every loop but that did not help. I would like to use my robot autonomously without having to have the transmitter on or the reciever plugged in.
Thanks.
2 comments:
1) Search before posting.
2) This question comes up often.
__________________
CalGames 2009 Autonomous Champion Award winner
Sacramento 2010 Creativity in Design winner, Sacramento 2010 Quarter finalist
2011 Sacramento Finalist, 2011 Madtown Engineering Inspiration Award.
2012 Sacramento Semi-Finals, 2012 Sacramento Innovation in Control Award, 2012 SVR Judges Award.
2012 CalGames Autonomous Challenge Award winner ($$$).
2014 2X Rockwell Automation: Innovation in Control Award (CVR and SAC). Curie Division Gracious Professionalism Award.
2014 Capital City Classic Winner AND Runner Up. Madtown Throwdown: Runner up.
2015 Innovation in Control Award, Sacramento.
2016 Chezy Champs Finalist, 2016 MTTD Finalist
  #3   Spotlight this post!  
Unread 05-05-2006, 21:39
intellec7's Avatar
intellec7 intellec7 is offline
108 programmer
AKA: Gustavo
FRC #0108 (SigmaC@ts)
Team Role: Programmer
 
Join Date: Sep 2005
Rookie Year: 2006
Location: Hollywood, Florida
Posts: 65
intellec7 is on a distinguished road
Send a message via AIM to intellec7 Send a message via MSN to intellec7
Re: Vex start up code run PWM outputs without Rx

Actually I did search before I posted this message and I read that thread, if I understood correctly, that method was not for me. When I put in
Code:
   txdata.user_cmd = 0x02;       /* Tell master you want to be in auton mode. */
in user init, the autonomous code runs, but I want to maintain the normal program as it is, most of the code is in the function "Process_Data_From_Local_IO". As I look at the code, it appears as if the main loop is calling User_Autonomous_Code and it is never leaving that loop because the flag "autonomous_mode" is never being cleared. Is there another solution to this other than calling "Process_Data_From_Local_IO" from the autonomous loop?

[EDIT]: I have found another way by setting the autonomous loop to "0" is there a prettier way?

Last edited by intellec7 : 05-05-2006 at 22:18.
  #4   Spotlight this post!  
Unread 05-05-2006, 23:29
Mark McLeod's Avatar
Mark McLeod Mark McLeod is online now
Just Itinerant
AKA: Hey dad...Father...MARK
FRC #0358 (Robotic Eagles)
Team Role: Engineer
 
Join Date: Mar 2003
Rookie Year: 2002
Location: Hauppauge, Long Island, NY
Posts: 8,793
Mark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond repute
Re: Vex start up code run PWM outputs without Rx

If you want to run your regular code autonomously, but don't want to put it in the autonomous loop, you can bypass the autonomous loop by commenting out the call in main.c and arranging it so you just fall through your normal code.
__________________
"Rationality is our distinguishing characteristic - it's what sets us apart from the beasts." - Aristotle
Closed Thread


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
What is your most prefered programming language? Hailfire Programming 156 19-01-2005 21:42
Sourceforge for Code Repository and other stuff SilverStar Programming 9 15-01-2005 21:16
Assisance with Win98 mgreenley IT / Communications 19 08-10-2004 22:37
Using an Operator Interface with the 2004 EDU RC wirelessly Dave Flowerday Robotics Education and Curriculum 34 19-04-2004 19:06
heres the code. y this not working omega Programming 16 31-03-2004 15:18


All times are GMT -5. The time now is 18:28.

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