Work at SourceForge, help us to make it a better place! We have an immediate need for a Support Technician in our San Francisco or Denver office.

Close

Problems with the Vacuum actuator (KR60Arm)

MatijaB
2012-04-21
2012-12-14
  • MatijaB
    MatijaB
    2012-04-21

    After I've added the Vacuum Actuator to the KR60Arm, I can't seem to succesfully push commands to it. I've been using Matlab to connect to UDK, but here I'll just post USARSim's code. I did as follows:

    1) Open UDKUSAR.ini (UDKGame\Config folder) and do the following:

        Find the USARBot.KR60 declaration (around line 271)
        Below it, add:
        "
        AddParts=(ItemClass=class'USARActuator.VacuumGripper',ItemName="MyGripper",Parent="Joint7",Position=(X=1.57,Y=0,Z=-2.2),Direction=(x=0,y=0,z=0))"
        Now you've defined the gripper addition. Done!

    2) Run ExampleMap (located in USARRunMaps folder)

    3) Open one instance of Iridium for the World Controller, press the raw button to type commands in, and execute:

    INIT {ClassName USARBotAPI.WorldController} {Location 0,0,1.724}
    CONTROL {Type Create} {ClassName USARPhysObj.WCCrate} {Name Crate0} {Scale 0.5,0.5,0.135}{Location 0,1.34,1}{Physics RigidBody}
    CONTROL {Type Create} {ClassName USARPhysObj.WCCrate} {Name Crate1} {Scale 0.5,0.5,0.5}{Location 0,1.34,1}{Physics RigidBody}
    

    4) Open another instance of Iridium for the KR60 control, go to raw command input and execute:

    INIT {ClassName USARBot.KR60} {Location 0,0,2.044} {Rotation 0,0,0}
    ACT {Name KR60Arm} {Link 0} {Value -1.57}
    ACT {Name KR60Arm} {Link 4} {Value 0.56}
    ACT {Name KR60Arm} {Link 1} {Value -0.25}
    ACT {Name KR60Arm} {Link 2} {Value -0.73}
    SET {Type Vacuum}{Opcode Close}
    (here, I also tried VacuumGripper as Type)
    ACT {Name KR60Arm} {Link 1} {Value -0.2}
    ACT {Name KR60Arm} {Link 2} {Value -0.68}
    

    The problem is seen here, as the gripper doesn't respond to the SET command, nothing is displayed in the console and moving the KR60Arm after setting the gripper doesn't move the box.

     
  • Teddy Weisman
    Teddy Weisman
    2012-04-23

    The Type you should be using is Gripper, not Vacuum or VacuumGripper (since the vacuum responds to Open and Close commands the same way a regular gripper does). That should let you operate the vacuum, although you might need to also check that the vacuum force is high enough to pick up the object without losing its grip.

     
  • MatijaB
    MatijaB
    2012-04-25

    Everything works now! Thank you for the help.