Announcement

Collapse
No announcement yet.

Joystick mapping issues with Labview, programming the buttons

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Joystick mapping issues with Labview, programming the buttons

    When we run the FCS, the motor voltages are being mapped to the arrow keypad rather than the joystick knob. How do you change this?
    How do you program the buttons in Labview, say to operate an arm. There doesn't seem to be a 'If' statement in Labview.
    thanks,
    elaine
    team 4241

  • #2
    Well, you can use the d-pad instead of the left joystick by pressing the "mode" button on the controllers, but I'm not sure if that's your question or not. FCS won't register when you press any other button besides the 10 main controller buttons (if you press the joysticks down they are buttons, too, but I'm not sure if FCS recognizes them or not).

    In Labview, the "case structure" is the "if statement." To program a button, you first drag the "read joystick.vi" block from the FTC Toolkit into your program. Then you wire it up to the "Read buttons.vi" block from the FTC Toolkit. Then under the "structures" submenu under the NXT Programming tab of the functions palette. You should see when you drag a wire from the "read buttons.vi", it will be green. Attach this to the green question mark of the case structure, which will be the condition to check. You can choose whether to run it when it's true or false, and you can edit the cases for both of them.

    Hope this helps!
    -T-REX team 2944
    http://www.sonoranacademy.org/t-rex2944

    Comment


    • #3
      could you post a picture of what this looks like, i'm having trouble understanding. thanks for your help if you can.

      Comment


      • #4
        Sure.
        -T-REX team 2944
        http://www.sonoranacademy.org/t-rex2944

        Comment

        Working...
        X