Go to Post I personally find the time I spend developing FIRST teams and FIRST as a whole the most fulfilling thing I have ever done in my life. - PayneTrain [more]
Home
Go Back   Chief Delphi > Technical > Programming > C/C++
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
Reply
Thread Tools Rate Thread Display Modes
  #1   Spotlight this post!  
Unread 03-28-2014, 10:26 AM
Zach S. Zach S. is offline
Registered User
FRC #3307 (Luray Robodawgs)
Team Role: Programmer
 
Join Date: Feb 2012
Rookie Year: 2011
Location: Luray
Posts: 30
Zach S. will become famous soon enough
Changing digital module

In the robotics class I help teach we are trying to get the class to build a bot for their final project. We have an 8 slot crio available for them, however, slot 2 for the digital module is faulty and we MUST use slot 6 for it. I have tested the slot in lab view and know it works.

My question is how in C++ do I change the digital module slot for the robot drive motors?
__________________
Head of Computer Systems and Programming of Team 3307


Reply With Quote
  #2   Spotlight this post!  
Unread 03-28-2014, 10:54 AM
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,112
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: Changing digital module

Instantiate each of the drive motor controllers explicitly. Then, instead of giving PWM channels to the 'drive constructor, pass the motor controller objects.
Reply With Quote
  #3   Spotlight this post!  
Unread 03-28-2014, 12:47 PM
Zach S. Zach S. is offline
Registered User
FRC #3307 (Luray Robodawgs)
Team Role: Programmer
 
Join Date: Feb 2012
Rookie Year: 2011
Location: Luray
Posts: 30
Zach S. will become famous soon enough
Re: Changing digital module

Quote:
Originally Posted by Alan Anderson View Post
Instantiate each of the drive motor controllers explicitly. Then, instead of giving PWM channels to the 'drive constructor, pass the motor controller objects.
Okay! I've initialized the jaguars and plugged those into RobotDrive. The only issue now is when I run the code on the robot the forward works, yet when I try to go reverse the motor does not move. I can see that the jaguar IS getting the code (turns red on reverse as it should) just the motor does not move. Could this be an error with the motor itself, or possible to still be within the code?
__________________
Head of Computer Systems and Programming of Team 3307


Reply With Quote
  #4   Spotlight this post!  
Unread 03-28-2014, 12:54 PM
Zach S. Zach S. is offline
Registered User
FRC #3307 (Luray Robodawgs)
Team Role: Programmer
 
Join Date: Feb 2012
Rookie Year: 2011
Location: Luray
Posts: 30
Zach S. will become famous soon enough
Re: Changing digital module

Update: just tested with a different drive motor and still no reverse so the problem either lies in the jaguar or the code if I am correct
__________________
Head of Computer Systems and Programming of Team 3307


Reply With Quote
  #5   Spotlight this post!  
Unread 03-28-2014, 01:26 PM
Zach S. Zach S. is offline
Registered User
FRC #3307 (Luray Robodawgs)
Team Role: Programmer
 
Join Date: Feb 2012
Rookie Year: 2011
Location: Luray
Posts: 30
Zach S. will become famous soon enough
Re: Changing digital module

Update 2: it seems the jaguars we had were broken and don't go reverse, I hooked one of the drive ones from our main robot onto it and it worked fine. All is working now, thank you again!
__________________
Head of Computer Systems and Programming of Team 3307


Reply With Quote
  #6   Spotlight this post!  
Unread 03-28-2014, 01:44 PM
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,112
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: Changing digital module

If a Jaguar runs a motor in one direction but not the other, make sure both of its limit switch jumpers are correctly installed.
Reply With Quote
  #7   Spotlight this post!  
Unread 03-31-2014, 07:25 AM
Zach S. Zach S. is offline
Registered User
FRC #3307 (Luray Robodawgs)
Team Role: Programmer
 
Join Date: Feb 2012
Rookie Year: 2011
Location: Luray
Posts: 30
Zach S. will become famous soon enough
Re: Changing digital module

Quote:
Originally Posted by Alan Anderson View Post
If a Jaguar runs a motor in one direction but not the other, make sure both of its limit switch jumpers are correctly installed.
Okay, I'll take a look at those today as well!
__________________
Head of Computer Systems and Programming of Team 3307


Reply With Quote
Reply


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


All times are GMT -5. The time now is 09:16 AM.

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