Go to Post Finally I wish everyone here on ChiefDelphi good luck and more importantly a fun build season. - mechanicalbrain [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 08-02-2012, 00:41
el-zoroo el-zoroo is offline
Chief Operating Officer
AKA: Zuhair
FRC #2374 (Crusaderbots)
Team Role: Leadership
 
Join Date: Jan 2010
Rookie Year: 2009
Location: Beaverton, OR
Posts: 13
el-zoroo is an unknown quantity at this point
Initialize Module on Non-Default Slot

We have an extra Solenoid breakout we are trying to add. One is wired up for 24V and the other for 12V, and are having trouble initializing the second one. The first one is working perfectly fine. We encountered the same problem with the Analog breakout.

We initialize it like so, in Java:

Code:
Solenoid solenoid = new Solenoid(6,4); //Slot 6, Channel 4
Upon running the code, it immediately warns us that "Solenoid module 6 is not present" (or something to that effect). Subsequently, it throws an AllocationException.

Any help on initializing a module on its non-default slot?
  #2   Spotlight this post!  
Unread 08-02-2012, 00:42
Thad House Thad House is offline
Volunteer, WPILib Contributor
no team (Waiting for 2021)
Team Role: Mentor
 
Join Date: Feb 2011
Rookie Year: 2010
Location: Thousand Oaks, California
Posts: 1,094
Thad House has a reputation beyond reputeThad House has a reputation beyond reputeThad House has a reputation beyond reputeThad House has a reputation beyond reputeThad House has a reputation beyond reputeThad House has a reputation beyond reputeThad House has a reputation beyond reputeThad House has a reputation beyond reputeThad House has a reputation beyond reputeThad House has a reputation beyond reputeThad House has a reputation beyond repute
Re: Initialize Module on Non-Default Slot

Because of the new Module naming system, instead of slot number you need to call module number. so instead of 6 you would use 2.
__________________
All statements made are my own and not the feelings of any of my affiliated teams.
Teams 1510 and 2898 - Student 2010-2012
Team 4488 - Mentor 2013-2016
Co-developer of RobotDotNet, a .NET port of the WPILib.
  #3   Spotlight this post!  
Unread 08-02-2012, 00:48
el-zoroo el-zoroo is offline
Chief Operating Officer
AKA: Zuhair
FRC #2374 (Crusaderbots)
Team Role: Leadership
 
Join Date: Jan 2010
Rookie Year: 2009
Location: Beaverton, OR
Posts: 13
el-zoroo is an unknown quantity at this point
Re: Initialize Module on Non-Default Slot

Thanks for the quick reply!

I had a suspicion about that when I was looking at the Javadocs.

But, how does the channel numbering work then? In other words, how would it know which module to go to if there are 2 solenoid breakouts?
  #4   Spotlight this post!  
Unread 08-02-2012, 00:56
Thad House Thad House is offline
Volunteer, WPILib Contributor
no team (Waiting for 2021)
Team Role: Mentor
 
Join Date: Feb 2011
Rookie Year: 2010
Location: Thousand Oaks, California
Posts: 1,094
Thad House has a reputation beyond reputeThad House has a reputation beyond reputeThad House has a reputation beyond reputeThad House has a reputation beyond reputeThad House has a reputation beyond reputeThad House has a reputation beyond reputeThad House has a reputation beyond reputeThad House has a reputation beyond reputeThad House has a reputation beyond reputeThad House has a reputation beyond reputeThad House has a reputation beyond repute
Re: Initialize Module on Non-Default Slot

If using a 4 slot CRio, slot 1 is analog 1, slot 2 is digital 1, slot 3 is solenoid module 1. slot 4 is the second instance of whatever module you put in it. If using the 8 slot CRIO, 1,2 and 3 are the same as the 4 slot, and the slot 5 is analog 2, slot 6 is digital 2 and slot 7 is solenoid 2.
__________________
All statements made are my own and not the feelings of any of my affiliated teams.
Teams 1510 and 2898 - Student 2010-2012
Team 4488 - Mentor 2013-2016
Co-developer of RobotDotNet, a .NET port of the WPILib.
  #5   Spotlight this post!  
Unread 08-02-2012, 01:00
el-zoroo el-zoroo is offline
Chief Operating Officer
AKA: Zuhair
FRC #2374 (Crusaderbots)
Team Role: Leadership
 
Join Date: Jan 2010
Rookie Year: 2009
Location: Beaverton, OR
Posts: 13
el-zoroo is an unknown quantity at this point
Re: Initialize Module on Non-Default Slot

That makes a lot more sense!

Thanks!
  #6   Spotlight this post!  
Unread 16-02-2012, 15:05
Bpalms Bpalms is offline
Registered User
FRC #1729
 
Join Date: Feb 2012
Location: New Hampshire
Posts: 1
Bpalms is an unknown quantity at this point
Re: Initialize Module on Non-Default Slot

Yeah Thanks a lot I was having this problem and I was ripping my hair out over this and this got it working for me.
  #7   Spotlight this post!  
Unread 19-02-2013, 17:58
silvereagle silvereagle is offline
Registered User
AKA: Rob Eastmond
FRC #3405 (Maple Mountain Eagletronics)
Team Role: Coach
 
Join Date: Mar 2011
Rookie Year: 2010
Location: Utah
Posts: 2
silvereagle is an unknown quantity at this point
Re: Initialize Module on Non-Default Slot

We are having the same trouble with the solenoid module. We are using an 8 port CRio, so we have declared our solenoid as
Solenoid s1 = new Solenoid(1,1);
Solenoid s2 = new Solenoid(1,2);

We have the solenoid module plugged into port 8 of the Crio and wired for 24V. We get a power light on the solenoid breakout, but when we upload the Java code, we get the error Solenoid Module 1 is not present (4 times on one deploy). Should any of the 8 leds be on when we boot up to signal that the module has power?

Thanks for the help.
  #8   Spotlight this post!  
Unread 19-02-2013, 18:13
Mark McLeod's Avatar
Mark McLeod Mark McLeod is offline
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,801
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: Initialize Module on Non-Default Slot

On an 8-slot, Solenoid Modules go in cRIO chassis slots 3 & 7
__________________
"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


All times are GMT -5. The time now is 00:51.

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