Foot And Leg Trajectory Step Test

(Notes on how to use the wing step input test, for complete testing procedures, see FootAndLegTrajectoryTestingProcedure)

Creating a .RC file (This text file holds all the trajectory settings)

  • TIP Note: It may be easier to use vi on the QNX RHex stack to edit step_test.rc, rather than going through the steps below.
  • This file should be securly copied to bailorgana, so its easiest to use Matlab on the Linux machines
  • Open Matlab and find a copy of the profile generating code
    • The latest versions are stored on chewie at /users/Software/LegTestCode/
    • FourBar_StepVel.m - allows you to select constant velocity and step parameters for the wing and crank motors
      • 1. Enter the velocity in hertz for the leg period
      • 2. Enter the step amplitude for the wing motor
      • 3. Enter the phase offset for the wing step input in seconds
      • 4. Enter the duration of the wing step input in seconds
      • 5. Enter the test duration
      • 6. Save the .RC file
      • The .RC file should be named step_test.rc to be used by the program step_test on the stack
      • Note: The step input is very abrupt and can easily damage something is not used properly
  • Copy the .RC file to bailorgana
    • Use the scp command to securely copy the .RC file to bailorgana
      • Usage: scp {filename} {username}@{hostname}:{folder}
      • Eg. scp step_test.rc rhex@bailorgana:users/amcclung/LegTestCode02
      • Edit the script copy2bailorgana.sh to automate the process and copy specific files

Start the test

  • Go to the directory with the test code on bailorgana
    • This is currently /home/rhex/users/amcclung/LegTestCode02
  • Switch users to the root user
    • To switch users, use su root or just su and then enter the password, type exit when you're done
  • (For fully automated version) Place the hard stops on the setup for calibration
    • You may want to edit the calibration variables to set your initial position (see below)
  • Execute the program from the current directory (ie. ./step_test)
    • STEP_TEST
      • This program gives a constant velocity to the crank motor. The tilt motor is given a step input.
      • This file reads step_test.rc for profile values
  • The calibration routine starts instantly and sets the motor to the initial position
    • Once the calibration is finished, the program will PAUSE and wait for user input
  • (For fully automated version) Remove the hard stops once the calibration is done
    • ALERT! If you do not REMOVE the stops, you can damage the leg setup
    • Press any key to continue to START the test, AFTER you remove the stops
  • After everything has been initialized (& calibrated) for the test, the progam PAUSES until the user presses a key.
  • The test profile is executed (looped) for the length specified by the related .RC file
  • ALERT! NOTE: Press Ctrl-C to stop the test at any time
  • ALERT! Latest versions: STEP_TEST_NOCALIB2, _STEP_TEST_NOCALIB3
    • Additions: Time based step input

  • Variables :
    • steptest_final_time - the length of the test [Units: sec]
    • steptest_period - the period for the trajectory [Units: sec]
    • steptest_leg_speed - the velocity of the CRANK [Units: rad/s]
    • steptest_amplitude - the amplitude of the wing step input [Units: deg]
    • [pre-VER 2] steptest_time_offset - the time from the beginning of the period for start of step [Units: sec]
    • [pre-VER 2] steptest_time_duration - the time length of the step [Units: sec]
    • [VER 2+] steptest_crank_angle_in - the CRANK angle where the step should start [Units: deg]
    • [VER 2+] steptest_crank_angle_out - the CRANK angle where the step should end [Units: deg]
    • reset_delay - the pause time after a test before reset [Units: sec]
    • reset_time - the time for the legs to reach the reset [Units: sec]
  • ALERT! Notes :
    • (For Calibration) - The motor voltages must be large enough to rotate the motors, otherwise a stall is instantly detected. 1.0V seems to be a reasonable amount.

Code Versions Notes
step versions  
STEP_TEST First working step input version (uses fully automated hard-stop based calibration
STEP_TEST_NOCALIB User places leg against the stops before testing, program moves it to initial position
Reads step_test.rc for variables
STEP_TEST_NOCALIB2 Same as VER 1, but step variables given relative to crank angle rather than time
Reads step_test_nocalib2.rc for variables
STEP_TEST_NOCALIB3 Same as VER 2, but returns to initial position after test, variable defined reset delay
Reads step_test_nocalib3.rc for variables
NOTE none yet

ALERT! NOTE: See FootAndLegTrajectoryTestingProcedure for complete testing details

-- AMcClung? - 06 Apr 2004

 
This site is powered by the TWiki collaboration platformCopyright &© by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback