Driver station error -44037

We are using LabView. the freshmen are all trying to make a program in command and control that will move the robot forwards until a limit switch is triggered. all of their code should be working, but the error 44037 (PWM channel has already been allocated. WPI_MotorControlOpen Talon.vi). we went to the specified vi, and changed the PWM. When we did that, a large amount of the wires in the code broke. we found out that a normal roboRIO project works fine. if any team has encountered/fixed this issue in the past, any help would be greatly appreciated.

Don’t ever modify standard library functions. You’ll only break the library.
The problem is in your higher level user calls to those functions.
So, you’ll find a duplicate PWM specified in the vi where you setup your devices.

That should be under Framework in Begin.vi

I checked through the begin.vi, there are no duplicates. everyone’s code is identical for the begin.vi code. initialize 2 motors, and then initialize 4 motors.

So, six unique PWM inputs are being specified (2+4)?
If you didn’t explicitly specify all of them, then the default values would be duplicates.

To help find where the duplicate got added we’ll probably have to see all of your code then, since it’s in there somewhere.
If you want to zip up the project folder located in documents->LabVIEW Data->project name
some of us could take a look and help you find it. Just post it here.

2 Likes

You can also use the Find»Callers option in the Project Explorer for the WPI_MotorControlOpen Talon.vi (it should be under Dependencies in your project). It will give you all the places where that VI is used. Knowing these, go to each one and ensure there are no repeated values.

All the best,

here it is limitswitchCandC.zip (343.9 KB)

So the problem is that in Begin you do your motor opens and then also at the beginning of your Drive subsystem you also do a 2 motor open. A search of the PWMs didn’t catch it as they used integer constants to assign the PWM values. Remove that at the beginning of the drive subsystem and you should be good!

1 Like

Another note I (and I think most would agree) am not a fan of opening motors and such in begin when using command and control. One of the biggest benefits of C&C is you are self containing everything in that subsystem such that it is reusable. If you do the opens in begin that you have a file that is cross populated from whatever subsystems happen to be on this bot and that doesn’t port well to another.

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.