|
|
|
![]() |
|
|||||||
|
||||||||
![]() |
|
|
Thread Tools | Rate Thread | Display Modes |
|
|
|
#1
|
|||
|
|||
|
Re: FRCsim problem in the environment build
I was able to find a workaround that seems to resolve the issue.
I discovered that there are alternate versions of the simulation code: http://first.wpi.edu/FRC/roborio/mav...on/simulation/ so I deleted the simulation directory and then recreated it using the most recent version simulation-2017.2.1.zip mkdir ~/wpilib/simulation unzip ~/Downloads/simulation-2017.2.1.zip -d ~/wpilib/simulation after I moved the files to the new simulation directory, I attempted to rebuild gz_msgs it wouldn't work with gazebo6 so i installed gazebo7 and then rebuilt the gz_msgs sudo apt-get install gazebo7 move to ~/wpilib/simulation/gz_msgs mkdir build cd build cmake .. make install I opened Eclipse. I deleted my GearsBot project and recreated it. Everything worked! |
|
#2
|
||||
|
||||
|
Re: FRCsim problem in the environment build
I have been able to work through the issues with the script.
See below. Dave Frederick Team 1895 - Manassas VA =============================================== Issues with the current FRCSIM installation script. Mainly permission errors. The current script creates folders under the users home directory (/home/robot) which are owned by root and cannot be accessed by the script (even with sudo). There is a similar error when the models are unzipped under the /tmp folder. The file permissions prevent a move. In addition, the model.zip file expands out to "frcsim-gazebo-models-4" and not "frcsim-gazebo-models" as expected in the script. Below are the corrective actions. Dave Frederick ===================================== ## Change 1 ## - Change the ownership of all of the files under the user "robot" home directory to robot with group robot chown -R robot:robot /home/robot/* ## Change 2 ## - Make all of the files under the /tmp folder readable and deletable by robot. chmod -R /tmp/* 777 unzip /tmp/models.zip -d /tmp cd ~ chown -R robot:robot /home/robot/* chmod -R /tmp/* 777 mv /tmp/frcsim-gazebo-models-4/models ~/wpilib/simulation/models mv /tmp/frcsim-gazebo-models-4/worlds ~/wpilib/simulation/worlds ============= install-eclipse-plugins install-gz_msgs install-eclipse install-desktops install-models change-ownership ## Change 3 ## - Change the ownership of all of the files under the user "robot" home directory to robot with group robot chown -R robot:robot /home/robot/* ## Change 4 ## - Create copies of the plugins so the match the expected values. cp /home/robot/wpilib/simulation/plugins/libclock.so /home/robot/wpilib/simulation/plugins/libgz_clock.so cp /home/robot/wpilib/simulation/plugins/libdc_motor.so /home/robot/wpilib/simulation/plugins/libgz_dc_motor.so cp /home/robot/wpilib/simulation/plugins/libencoder.so /home/robot/wpilib/simulation/plugins/libgz_encoder.so cp /home/robot/wpilib/simulation/plugins/libgyro.so /home/robot/wpilib/simulation/plugins/libgz_gyro.so cp /home/robot/wpilib/simulation/plugins/liblimit_switch.so /home/robot/wpilib/simulation/plugins/libgz_limit_switch.so cp /home/robot/wpilib/simulation/plugins/libpneumatic_piston.so /home/robot/wpilib/simulation/plugins/libgz_pneumatic_piston.so cp /home/robot/wpilib/simulation/plugins/libpotentiometer.so /home/robot/wpilib/simulation/plugins/libgz_potentiometer.so cp /home/robot/wpilib/simulation/plugins/librangefinder.so /home/robot/wpilib/simulation/plugins/libgz_rangefinder.so cp /home/robot/wpilib/simulation/plugins/libservo.so /home/robot/wpilib/simulation/plugins/libgz_servo.so |
|
#3
|
|||
|
|||
|
Re: FRCsim problem in the environment build
Thanks for the update 2017.2.1 simulation code, dreckner. Just curious though; when you say it worked, were you using Java or C++? I encountered the same issue as described previously in the thread in Java, but I'm curious about C++. In the FRCSim I installed in January, it seemed that the C++ wpilib had pre-2017 code. I base that statement on the fact that 1) somewhere in the "New for 2017!" ScreenSteps instructions it stated that the frc namespace had been introduced and 2) I was able to build the Getting Stated C++ project in FRCSim provided I removed all the namespace references.
|
|
#4
|
|||
|
|||
|
Re: FRCsim problem in the environment build
FYI, you can rebuild the wpilibjSimulation.jar file yourself without to much trouble. The source code is located at https://github.com/wpilibsuite/allwpilib
git clone https://github.com/wpilibsuite/allwpilib.git cd allwpilib git tag --list ( this command will show the release tags available ) git checkout v2017.2.1 ( or whatever the latest release tag is ) ./gradlew -PmakeSim :wpilibj:wpilibjSimJar cp wpilibj/build/libs/wpilibjSimulation.jar ~/wpilib/simulation/jar/ The benefit of building it yourself is fixing any issue you see such as simulated motor controllers not having a setInverted method. |
![]() |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|