ICT-4 bed-of-nails test fixture tending
harbor run -t reactive-labs/ict-fixture-tendingharbor download reactive-labs/ict-fixture-tendingHi,
Line 3's in-circuit tester ICT-4 has a Franka Panda on the bench in front of its bed-of-nails fixture, and we want the arm to tend the fixture on its own. Please write the controller. A rack holds three board carriers. Two carry current-revision boards to test. The third is an old-revision board that looks almost the same and goes to the hold shelf untested. For each board to test, the controller seats the carrier over the round and diamond tooling pins, brings the press lid down by its lever through the lock spring until the lock snaps over, reads the result lamp, lifts the lid and sends the board on. A green board goes to the outfeed and a red one to the fail bin. An amber board is reseated and retested by the rule on the cell sheet. Nothing reports where anything is: the arm has an overhead camera with depth, a colour camera on the wrist, its joint and finger readings and a hand force estimate. The fixture is bolted in a different place from rack to rack, and so is the rack. Things go wrong at the cell: a carrier catches on a pin as the lid comes down, the lever springs off the lock during a test, a carrier slips out of the fingers. The controller has to notice and put each of these right. If the gripper stops responding or the overhead camera freezes, it has to put down what it holds, stop, and say which of the two failed.
Everything is in /app:
REQUEST.md);CELL_SHEET.md);ATTEMPT_LOG.md);scene.xml, robot/) and the acceptance setup (task.py, gauntlet/);python3 /app/run_gauntlet.py --controller /app/controller.py --tiers T0,T1,T2,T3,T4 --episodes 2.The motion-planning, vision and sim-to-real skills our integrator uses are in /app/skills/.
Please write /app/controller.py with a Controller class (__init__(model_info), reset(obs), act(obs)).
act returns the 8 position commands (7 joints, then the finger opening in metres) or a status:
{"status": "done"} or {"status": "abort", "fault": "dead_gripper"} / "perception_freeze". Don't change
scene.xml, task.py or robot/panda.xml.
Thanks, Test engineering lead, Kestrel Ridge Electronics
/app/controller.py. It runs in its own process and receives only model_info (keys control_dt_s,
episode_s, timestep, joint_names, actuator_names, ctrl_low, ctrl_high, observed_bodies,
perception_hz, scene_xml, max_command_step_frac, arm_prefixes, cameras) and, every 20 ms, the
observation (keys time, qpos, qvel, ctrl, objects, objects_stamp, images, depth, camera_stamp,
io). qpos and qvel follow joint_names. ctrl echoes the commands as accepted, and a failed gripper still
echoes its command. images holds overhead and robot/wrist_cam, depth holds overhead, both updated twice a
second with camera_stamp. objects is empty. io holds ext_force_n and cycle_limit_s. The controller may
use numpy, mujoco and the files in /app. Wall-time limits per call and per run are in /app/gauntlet/harness.py.run_gauntlet.py runs them: 2 at T2, 6 at T3 (two per upset)
and 4 at T4 (two per fault), in the three layout bands of run_gauntlet.py --band. The groups are in
CELL_SHEET.md. Each run draws its own fixture place, rack place, carriers, which way round they lie, which one
is the old revision and the boards' results from task.py.CELL_SHEET.md) caps the run at the stages met before it, and at 0.5.