FIRST Robotics Competition Discussions

cancel
Showing results for 
Search instead for 
Did you mean: 

How do you enable the 2nd Analog Module channels.

We are trying to use  a second analog module but we cannot get the Robot code to enable the channels. Analog 0 is in slot 1 and Analog 1 is in slot 4. 

We've swapped units and know that both work.

I've tried numerous ways to get the code to enable the channels but to no avail. 

Is there a key place to turn on the additional channels?

Are they intentionally turned off?

0 Kudos
Message 1 of 11
(5,575 Views)

The second analog module belongs in slot 5 of the cRIO FRC and slot 4 of the cRIO FRC 2. You should only need to have the module installed when you boot the controller. Does the Imaging tool show the module as installed?

0 Kudos
Message 2 of 11
(3,430 Views)

Hi

Yes,  The analog modules are in slots 1 and 4 of the cRIO FRC II unit.

The Imaging tool shows both so I assume that means that both are working. (its so frustraitng).

I dont see any tutorials that deal with a second analog module or how to enable the channels.

Thanks

Rich.

0 Kudos
Message 3 of 11
(3,430 Views)

I think you need to specify "analog slot 2" when programming the 2nd analog module (perhaps you are specifying the physical slot, 4).

geoff

--
Geoff Schmit
Huskie Robotics, FIRST Team 3061 Lead Mentor
http://team3061.org/
@team3061
0 Kudos
Message 4 of 11
(3,430 Views)

No  there is no place in the robotics framework code that would allow me to select module 4

I believe the problem is in the Build Dashboard VI. or the DashboardEnables.ctl file

No matter how the boolean enable buttons are set they always get changed to false on Analog Module 2.

Please tell us how it gets changed back to false. 

Also  why is there a module enable switches for the digital and solenoid modules but the analog modules are only selected at the channel level?

Thanks

Rich

0 Kudos
Message 5 of 11
(3,430 Views)

Hey Rich,

Which binary enable switches are you referring to? Is the issue just that you don't get the correct values on the dashboard? If you read the analog values in one of your VI's -like periodic tasks or teleop do you see the correct values update there?

Kevin Fort
Principal Software Engineer
NI
0 Kudos
Message 6 of 11
(3,430 Views)

I have a feeling you are not trying to actually get the analog module working in your robot code, but rather are just expecting the dashboard to show you the values.  There is a fair chance that the default robot code does not send the values of the second analog module.  It is simply meant as a starting point for teams to add what they care about, not to send everything and slow down robot code for what most teams don't want.  I recommend you try using the analog channels in your code.

0 Kudos
Message 7 of 11
(3,430 Views)

Kevin

It seems to be a matter getting the enable booleans to set to true.

Setting them in DashboardEnable.ctl does not seem to change the setting in the BuilddashBoard VI

I managed to overide the inputs with Constants set to True and now I see the analog data.

Now I can see the data. 

Its not an elegant solution but it lets me observe values and make sure that my sensors are working.

Rich

0 Kudos
Message 8 of 11
(3,430 Views)

I see, so you don't know how to help.

Thanks anyway

0 Kudos
Message 9 of 11
(3,430 Views)

Hey Rich,

If you are setting them in DasboardEnable.ctl then after you set them you need to right click and select to make the current value default. Then your selection should persist.

Kevin Fort
Principal Software Engineer
NI
0 Kudos
Message 10 of 11
(3,430 Views)