Announcement

Collapse
No announcement yet.

WPI robot samples NOT showing the popup "FRC Simulation DriverStation" box

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

  • WPI robot samples NOT showing the popup "FRC Simulation DriverStation" box

    Hello,

    I was testing both the C++ and Java versions of WPI sample robots as in

    https://wpilib.screenstepslive.com/s...ot-with-frcsim

    In C++ using Eclipse, Running Autonomous step does NOT show "FRC Simulation DriverStation" popup box. However, using Java, it does show the popup box. Has anybody seen this behavior before? If so, how do you make the popup box to show up?

    Also, are we able to use FTC's Logitech joystick to work with this FRCSim?

    Any help is appreciated. Thanks!

    FYI, here's my configuration:


    No apparent compilation error while choosing the "Simulate" option, as below:

    20:40:20 **** Incremental Build of configuration Simulate for project GearsBot-C++ ****
    make all
    Building file: ../src/Subsystems/Claw.cpp
    Invoking: GCC C++ Compiler
    g++ -I"/home/myaccount/workspace/GearsBot-C++/src" -I/home/myaccount/wpilib/cpp/current/sim/include -I/usr/include -I/usr/include/gazebo-3.2 -I/usr/include/sdformat-2.2 -O0 -g3 -Wall -c -fmessage-length=0 -MMD -MP -MF"src/Subsystems/Claw.d" -MT"src/Subsystems/Claw.d" -o "src/Subsystems/Claw.o" "../src/Subsystems/Claw.cpp"
    Finished building: ../src/Subsystems/Claw.cpp

    Building file: ../src/Subsystems/DriveTrain.cpp
    Invoking: GCC C++ Compiler
    g++ -I"/home/myaccount/workspace/GearsBot-C++/src" -I/home/myaccount/wpilib/cpp/current/sim/include -I/usr/include -I/usr/include/gazebo-3.2 -I/usr/include/sdformat-2.2 -O0 -g3 -Wall -c -fmessage-length=0 -MMD -MP -MF"src/Subsystems/DriveTrain.d" -MT"src/Subsystems/DriveTrain.d" -o "src/Subsystems/DriveTrain.o" "../src/Subsystems/DriveTrain.cpp"
    Finished building: ../src/Subsystems/DriveTrain.cpp

    Building file: ../src/Subsystems/Elevator.cpp
    Invoking: GCC C++ Compiler
    g++ -I"/home/myaccount/workspace/GearsBot-C++/src" -I/home/myaccount/wpilib/cpp/current/sim/include -I/usr/include -I/usr/include/gazebo-3.2 -I/usr/include/sdformat-2.2 -O0 -g3 -Wall -c -fmessage-length=0 -MMD -MP -MF"src/Subsystems/Elevator.d" -MT"src/Subsystems/Elevator.d" -o "src/Subsystems/Elevator.o" "../src/Subsystems/Elevator.cpp"
    Finished building: ../src/Subsystems/Elevator.cpp

    Building file: ../src/Subsystems/Wrist.cpp
    Invoking: GCC C++ Compiler
    g++ -I"/home/myaccount/workspace/GearsBot-C++/src" -I/home/myaccount/wpilib/cpp/current/sim/include -I/usr/include -I/usr/include/gazebo-3.2 -I/usr/include/sdformat-2.2 -O0 -g3 -Wall -c -fmessage-length=0 -MMD -MP -MF"src/Subsystems/Wrist.d" -MT"src/Subsystems/Wrist.d" -o "src/Subsystems/Wrist.o" "../src/Subsystems/Wrist.cpp"
    Finished building: ../src/Subsystems/Wrist.cpp

    Building file: ../src/Commands/Autonomous.cpp
    Invoking: GCC C++ Compiler
    g++ -I"/home/myaccount/workspace/GearsBot-C++/src" -I/home/myaccount/wpilib/cpp/current/sim/include -I/usr/include -I/usr/include/gazebo-3.2 -I/usr/include/sdformat-2.2 -O0 -g3 -Wall -c -fmessage-length=0 -MMD -MP -MF"src/Commands/Autonomous.d" -MT"src/Commands/Autonomous.d" -o "src/Commands/Autonomous.o" "../src/Commands/Autonomous.cpp"
    Finished building: ../src/Commands/Autonomous.cpp

    Building file: ../src/Commands/CloseClaw.cpp
    Invoking: GCC C++ Compiler
    g++ -I"/home/myaccount/workspace/GearsBot-C++/src" -I/home/myaccount/wpilib/cpp/current/sim/include -I/usr/include -I/usr/include/gazebo-3.2 -I/usr/include/sdformat-2.2 -O0 -g3 -Wall -c -fmessage-length=0 -MMD -MP -MF"src/Commands/CloseClaw.d" -MT"src/Commands/CloseClaw.d" -o "src/Commands/CloseClaw.o" "../src/Commands/CloseClaw.cpp"
    Finished building: ../src/Commands/CloseClaw.cpp

    Building file: ../src/Commands/DriveStraight.cpp
    Invoking: GCC C++ Compiler
    g++ -I"/home/myaccount/workspace/GearsBot-C++/src" -I/home/myaccount/wpilib/cpp/current/sim/include -I/usr/include -I/usr/include/gazebo-3.2 -I/usr/include/sdformat-2.2 -O0 -g3 -Wall -c -fmessage-length=0 -MMD -MP -MF"src/Commands/DriveStraight.d" -MT"src/Commands/DriveStraight.d" -o "src/Commands/DriveStraight.o" "../src/Commands/DriveStraight.cpp"
    Finished building: ../src/Commands/DriveStraight.cpp

    Building file: ../src/Commands/OpenClaw.cpp
    Invoking: GCC C++ Compiler
    g++ -I"/home/myaccount/workspace/GearsBot-C++/src" -I/home/myaccount/wpilib/cpp/current/sim/include -I/usr/include -I/usr/include/gazebo-3.2 -I/usr/include/sdformat-2.2 -O0 -g3 -Wall -c -fmessage-length=0 -MMD -MP -MF"src/Commands/OpenClaw.d" -MT"src/Commands/OpenClaw.d" -o "src/Commands/OpenClaw.o" "../src/Commands/OpenClaw.cpp"
    Finished building: ../src/Commands/OpenClaw.cpp

    Building file: ../src/Commands/Pickup.cpp
    Invoking: GCC C++ Compiler
    g++ -I"/home/myaccount/workspace/GearsBot-C++/src" -I/home/myaccount/wpilib/cpp/current/sim/include -I/usr/include -I/usr/include/gazebo-3.2 -I/usr/include/sdformat-2.2 -O0 -g3 -Wall -c -fmessage-length=0 -MMD -MP -MF"src/Commands/Pickup.d" -MT"src/Commands/Pickup.d" -o "src/Commands/Pickup.o" "../src/Commands/Pickup.cpp"
    Finished building: ../src/Commands/Pickup.cpp

    Building file: ../src/Commands/Place.cpp
    Invoking: GCC C++ Compiler
    g++ -I"/home/myaccount/workspace/GearsBot-C++/src" -I/home/myaccount/wpilib/cpp/current/sim/include -I/usr/include -I/usr/include/gazebo-3.2 -I/usr/include/sdformat-2.2 -O0 -g3 -Wall -c -fmessage-length=0 -MMD -MP -MF"src/Commands/Place.d" -MT"src/Commands/Place.d" -o "src/Commands/Place.o" "../src/Commands/Place.cpp"
    Finished building: ../src/Commands/Place.cpp

    Building file: ../src/Commands/PrepareToPickup.cpp
    Invoking: GCC C++ Compiler
    g++ -I"/home/myaccount/workspace/GearsBot-C++/src" -I/home/myaccount/wpilib/cpp/current/sim/include -I/usr/include -I/usr/include/gazebo-3.2 -I/usr/include/sdformat-2.2 -O0 -g3 -Wall -c -fmessage-length=0 -MMD -MP -MF"src/Commands/PrepareToPickup.d" -MT"src/Commands/PrepareToPickup.d" -o "src/Commands/PrepareToPickup.o" "../src/Commands/PrepareToPickup.cpp"
    Finished building: ../src/Commands/PrepareToPickup.cpp

    Building file: ../src/Commands/SetDistanceToBox.cpp
    Invoking: GCC C++ Compiler
    g++ -I"/home/myaccount/workspace/GearsBot-C++/src" -I/home/myaccount/wpilib/cpp/current/sim/include -I/usr/include -I/usr/include/gazebo-3.2 -I/usr/include/sdformat-2.2 -O0 -g3 -Wall -c -fmessage-length=0 -MMD -MP -MF"src/Commands/SetDistanceToBox.d" -MT"src/Commands/SetDistanceToBox.d" -o "src/Commands/SetDistanceToBox.o" "../src/Commands/SetDistanceToBox.cpp"
    Finished building: ../src/Commands/SetDistanceToBox.cpp

    Building file: ../src/Commands/SetElevatorSetpoint.cpp
    Invoking: GCC C++ Compiler
    g++ -I"/home/myaccount/workspace/GearsBot-C++/src" -I/home/myaccount/wpilib/cpp/current/sim/include -I/usr/include -I/usr/include/gazebo-3.2 -I/usr/include/sdformat-2.2 -O0 -g3 -Wall -c -fmessage-length=0 -MMD -MP -MF"src/Commands/SetElevatorSetpoint.d" -MT"src/Commands/SetElevatorSetpoint.d" -o "src/Commands/SetElevatorSetpoint.o" "../src/Commands/SetElevatorSetpoint.cpp"
    Finished building: ../src/Commands/SetElevatorSetpoint.cpp

    Building file: ../src/Commands/SetWristSetpoint.cpp
    Invoking: GCC C++ Compiler
    g++ -I"/home/myaccount/workspace/GearsBot-C++/src" -I/home/myaccount/wpilib/cpp/current/sim/include -I/usr/include -I/usr/include/gazebo-3.2 -I/usr/include/sdformat-2.2 -O0 -g3 -Wall -c -fmessage-length=0 -MMD -MP -MF"src/Commands/SetWristSetpoint.d" -MT"src/Commands/SetWristSetpoint.d" -o "src/Commands/SetWristSetpoint.o" "../src/Commands/SetWristSetpoint.cpp"
    Finished building: ../src/Commands/SetWristSetpoint.cpp

    Building file: ../src/Commands/TankDriveWithJoystick.cpp
    Invoking: GCC C++ Compiler
    g++ -I"/home/myaccount/workspace/GearsBot-C++/src" -I/home/myaccount/wpilib/cpp/current/sim/include -I/usr/include -I/usr/include/gazebo-3.2 -I/usr/include/sdformat-2.2 -O0 -g3 -Wall -c -fmessage-length=0 -MMD -MP -MF"src/Commands/TankDriveWithJoystick.d" -MT"src/Commands/TankDriveWithJoystick.d" -o "src/Commands/TankDriveWithJoystick.o" "../src/Commands/TankDriveWithJoystick.cpp"
    Finished building: ../src/Commands/TankDriveWithJoystick.cpp

    Building file: ../src/OI.cpp
    Invoking: GCC C++ Compiler
    g++ -I"/home/myaccount/workspace/GearsBot-C++/src" -I/home/myaccount/wpilib/cpp/current/sim/include -I/usr/include -I/usr/include/gazebo-3.2 -I/usr/include/sdformat-2.2 -O0 -g3 -Wall -c -fmessage-length=0 -MMD -MP -MF"src/OI.d" -MT"src/OI.d" -o "src/OI.o" "../src/OI.cpp"
    Finished building: ../src/OI.cpp

    Building file: ../src/Robot.cpp
    Invoking: GCC C++ Compiler
    g++ -I"/home/myaccount/workspace/GearsBot-C++/src" -I/home/myaccount/wpilib/cpp/current/sim/include -I/usr/include -I/usr/include/gazebo-3.2 -I/usr/include/sdformat-2.2 -O0 -g3 -Wall -c -fmessage-length=0 -MMD -MP -MF"src/Robot.d" -MT"src/Robot.d" -o "src/Robot.o" "../src/Robot.cpp"
    Finished building: ../src/Robot.cpp

    Building target: FRCUserProgram
    Invoking: GCC C++ Linker
    g++ -L/usr/lib/x86_64-linux-gnu -L/usr/lib/x86_64-linux-gnu/gazebo-2.2/plugins -o "FRCUserProgram" ./src/Subsystems/Claw.o ./src/Subsystems/DriveTrain.o ./src/Subsystems/Elevator.o ./src/Subsystems/Wrist.o ./src/Commands/Autonomous.o ./src/Commands/CloseClaw.o ./src/Commands/DriveStraight.o ./src/Commands/OpenClaw.o ./src/Commands/Pickup.o ./src/Commands/Place.o ./src/Commands/PrepareToPickup.o ./src/Commands/SetDistanceToBox.o ./src/Commands/SetElevatorSetpoint.o ./src/Commands/SetWristSetpoint.o ./src/Commands/TankDriveWithJoystick.o ./src/OI.o ./src/Robot.o -lWPILibSim -lgazebo -lgazebo_transport -lgazebo_msgs -lgazebo_common -lprotobuf -lboost_system -ldl -lpthread
    Finished building target: FRCUserProgram


    20:41:39 Build Finished (took 1m:19s.109ms)

  • #2
    Re: WPI robot samples NOT showing the popup "FRC Simulation DriverStation" box

    For what it's worth, I see the same thing. We intend to use C++, but I loaded the Java examples just to check out the simulator. The Java GearsBot example does nothing when I select Autonomous and click Enable, nor does it do anything in Teleop or Test modes. The Java PacGoat example doesn't even compile. I was really hoping we'd be able to use the simulator this year.

    Comment


    • #3
      Re: WPI robot samples NOT showing the popup "FRC Simulation DriverStation" box

      Originally posted by Steve King View Post
      For what it's worth, I see the same thing. We intend to use C++, but I loaded the Java examples just to check out the simulator. The Java GearsBot example does nothing when I select Autonomous and click Enable, nor does it do anything in Teleop or Test modes. The Java PacGoat example doesn't even compile. I was really hoping we'd be able to use the simulator this year.
      Hi, Steve, thank you so much for your feedback. In my case using Java for GearsBot, I can select Autonomous, Enable, and the robot picks up the can and place it on the table in front. This seems like it is supposed to do. In Teleop, I don't seem to be able to control it using FTC Logitech USB controller at all, and the robot makes a large circular motion on its own automonously (and soon it hits the table after a few large rotation). Test mode doesn't appear to do anything for me...

      Java PacGoat compiles ok in my VM. Autonomous mode seems to make the the robot move backwards to hit the wall, but it doesn't seem to be doing any useful work (?). I don't seem to be able to control robot on Teleop, either.

      In C++, both robots compile, but I don't see the Autonomous/Teleop popup box as I mentioned in the original post, so I don't seem to be able to get it working to test Autonomous/Teleop...

      Comment


      • #4
        Re: WPI robot samples NOT showing the popup "FRC Simulation DriverStation" box

        Originally posted by superninja777 View Post
        Also, are we able to use FTC's Logitech joystick to work with this FRCSim?
        FRCSim can use any joystick that Linux can detect. I did most my testing with Logitech controllers, so I would expect it to work. However, you may need to edit OI.cpp/OI.java if the Joystick buttons or axes need to be remapped.

        Originally posted by superninja777 View Post
        In C++ using Eclipse, Running Autonomous step does NOT show "FRC Simulation DriverStation" popup box. However, using Java, it does show the popup box. Has anybody seen this behavior before? If so, how do you make the popup box to show up?
        I haven't seen that behavior before, you can launch the simulation driverstation manually, but the fact that it's not showing up is likely the sign of a bigger issue. Can you paste the contents of your console when you run "WPILib C++ Simulation"?

        To run the driverstation manually, run the following in a terminal:
        Code:
        java -Djava.library.path=~/wpilib/java/current/sim/lib -jar ~/wpilib/java/current/sim/tools/SimDS.jar

        Comment


        • #5
          Re: WPI robot samples NOT showing the popup "FRC Simulation DriverStation" box

          Originally posted by Steve King View Post
          For what it's worth, I see the same thing. We intend to use C++, but I loaded the Java examples just to check out the simulator. The Java GearsBot example does nothing when I select Autonomous and click Enable, nor does it do anything in Teleop or Test modes.
          Are there any visible errors in the console, I just retested the Java gearsbot and it works for me. I'll test the C++ GearsBot shortly.

          The Java PacGoat example doesn't even compile. I was really hoping we'd be able to use the simulator this year.
          Can you post the error, it's currently compiling for me.

          Comment


          • #6
            Re: WPI robot samples NOT showing the popup "FRC Simulation DriverStation" box

            Originally posted by adhenning View Post
            Are there any visible errors in the console, I just retested the Java gearsbot and it works for me. I'll test the C++ GearsBot shortly.
            There is an issue with the C++ gearsbot order of initialization of environment variables which causes the DS to not start.
            Team 330 beta tester

            Comment


            • #7
              Re: WPI robot samples NOT showing the popup "FRC Simulation DriverStation" box

              Originally posted by jross View Post
              There is an issue with the C++ gearsbot order of initialization of environment variables which causes the DS to not start.
              Hello, your response was right on. I changed the build.properties file contents as follows, and I now see the DS to start as expected when running in C++. On the console, I was getting "SimDS.jar not found" which obviously meant something was not configured properly.

              # Simulation # ***** is your home directory
              simulation.world.file=/usr/share/frcsim/worlds/GearsBotDemo.world
              sim.exe=Simulate/${out}
              #wpilib.sim=${wpilib}/sim
              wpilib.sim=/home/*****/wpilib/cpp/current/sim
              sim.tools=${wpilib.sim}/tools
              sim.lib=${wpilib.sim}/lib

              Thanks so much for the info!

              Comment

              Working...
              X