00:00
Slide 1 of 18

Lab 5: Offline Robot Programming

Digital Twins & Offline Workflows with OCTOPUZ

OCTOPUZ digital twin simulation interface with UR5e and FANUC CR-7iA/L robots in a shared virtual workcell, showing programmed motion paths and collision detection overlays
OCTOPUZ ยท Digital Twin ยท Multi-Robot OLP

Master the art of simulating and programming industrial robots without touching the physical hardware. Program the UR5e and FANUC CR-7iA/L in a virtual cell.

Why Offline Programming (OLP)?
OLP allows companies to program robots while production continues on the factory floor. It minimizes downtime, allows for complex path planning, and provides a safe environment for collision testing.

๐ŸŽฏ Learning Outcomes

What you will master in this session

๐Ÿ“‚

OCTOPUZ Workflow

Load project files, navigate the workcell, and use the simulation environment to build robot programs.

๐Ÿ“

Coordinate Frames

Understand World, Base, and Tool frames โ€” the geometric foundation of all robot motion.

๐Ÿ”„

Multi-Robot OLP

Program a UR5e (6-axis) and a FANUC (7-axis with linear slider) for pick-and-place tasks.

Perspective: In this lab, you aren't just "teaching" points; you're building a software-defined manufacturing process.

๐Ÿ“ Robot Programming Basics

How robots "see" 3D space

1
World Coordinate System: The main reference for the entire workcell. Everything (robots, tables, parts) is placed relative to this (0,0,0).
2
Robot Base Frame: Located at the center of the robot's base. The robot calculates its joint angles based on positions relative to this frame.
3
Tool Center Point (TCP): The point on the gripper or tool that the robot actually controls. This is the "pen tip" of the robot.
๐Ÿ’ก Study Tip for Quiz:
Think about which coordinate system remains constant even if you move the robot's physical mounting position. (Hint: It's the one that "contains" the entire room).

๐Ÿ“ Tool Center Point (TCP)

The most critical point in robotics

The TCP defines the exact location that follows the programmed path.

Defining the TCP:

  • Must account for the length of the gripper or tool.
  • Must account for the weight (mass) and center of gravity.
  • Incorrect TCP offsets lead to "collisions" in reality that don't show in simple sim.

๐Ÿ” Technical Insight

If the TCP is defined incorrectly in OCTOPUZ, the software will calculate correct motions for a wrong tool. This means every pick-and-place point will be shifted on the real robot.

๐Ÿ’ก Study Tip for Quiz: Think about the impact of TCP errors. Can a robot "automatically" fix an incorrect TCP definition once the program is loaded? (Hint: No, because the robot assumes your definition is truth).

๐Ÿ—๏ธ The Base Frame

The foundation of robot geometry

The Base Frame is the origin (0,0,0) for the robot's internal kinematics. Every move command you write is a set of coordinates offset from this point.

Why it matters: If you move the robot 10cm to the left on the table in reality, but don't update the Base Frame in OCTOPUZ, your simulation is no longer valid.

๐Ÿ” Pro Tip

The Base Frame is essential because it allows the software to transform 3D CAD paths into real joint positions. Every Downstream calculation (reach, collision) depends on it.

๐Ÿ’ก Study Tip for Quiz: Why do we need the base frame in OLP? Is it just for rendering, or is it required for the math that generates robot motions?
๐Ÿ’ก Study Tip for Quiz:
If the TCP is calculated incorrectly, will the robot's joint angles be wrong, or will its spatial accuracy be wrong? (Hint: The robot moves the TCP, not just its joints).

๐Ÿš€ Motion Types: PTP vs. Linear

Choosing how the robot moves between points

Point-to-Point (PTP / MoveJ)

Each joint moves independently at its fastest speed. The path of the tool is unpredictable (curved).

Use for: Long moves in open, clear spaces.

Linear (MoveL)

The robot forces the TCP to follow a straight line between points.

Use for: Precise approaches, retracts, and picking parts.

Selection Rule: Never use PTP for the final 10cm of an approach. An unpredictable arc could cause the gripper to smash into the fixture.
๐Ÿ’ก Study Tip for Quiz: Which motion type defines a path as a predictable, straight Cartesian line? This is key for avoiding collisions near objects.

๐Ÿ› ๏ธ Setup & VLAB Access

Getting your workspace ready

1. VLAB Connection

  • Use VM Horizon Client to log in.
  • Search for "OCTOPUZ" in the start menu.
  • Ensure you have a stable internet connection.

2. Project Files

  • Download the Lab 5 CAD files and OCTOPUZ project.
  • Open the `.octz` file to load the workcell.
  • Verify both robots are visible.

โš ๏ธ Preparation Check

This prep takes ~30 minutes. Do not wait until the lab session starts to install the software or download the files. Your lab time is for programming.

๐Ÿ”ญ OCTOPUZ Interface

Your window into the digital twin

Viewport

The 3D space where you see the robot, fixtures, and parts. Left-click/drag to rotate.

Robot Tab

Tools for jogging the robot, setting the TCP, and checking joint limits.

Program Tree

The timeline of your program. This is where you add Move, Set, and Wait commands.

Hot Tip: Use the "Reachability" overlay to see if your robot can actually touch the point you just picked. If it turns red, move the point!

๐Ÿค– Part A: The UR5e Program

Automating a 11-step pick and place cycle

Home
Safe starting position clear of all obstacles.
App.
Approach: Position directly above the part (Linear move).
Pick
Move down, Close Gripper, Wait 0.5s.
Ret.
Retract: Move straight up back to Approach height.

Repeat this logic for the Place position at the assembly fixture.

๐Ÿ› ๏ธ UR5e Programming Details

Avoiding the common pitfalls

The "Wait" Command

Physical grippers take time to actuate. If you move the robot immediately after the Set DO command, the robot will lift before it has a grip on the part. Always add a 0.5s - 1.0s Wait.

Program Export

When done, you will export a .urp file. This file contains the script that the real UR5e controller reads.

๐Ÿฆพ Part B: The FANUC CR-7iA/L

Programming the yellow collaborative arm

The FANUC setup is slightly different. Instead of a gripper, you are using a Vacuum System to pick up acrylic coasters.

  • Vacuum ON: Activates the suction.
  • Vacuum OFF: Releases the part.
  • Requires same Approach/Retract logic as the UR.

๐Ÿ”ฆ Note on Logic

FANUC programs are often exported as .LS files (readable text) and then converted to .TP (Teach Pendant) binary files for the robot.

โ›“๏ธ The 7th Axis (Linear Slider)

Extending the robot's work envelope

The FANUC robot in this lab is mounted on a track. This is your 7th degree of freedom.

Strategic Use: You don't just move the robot's arm; you move the entire robot. Use the slider to reach parts on distant tables that would otherwise be out of reach.

Coordinate Check:

The 7th axis position is usually programmed as an External Axis value in your waypoint data. OCTOPUZ manages this automatically when you jog the slider.

๐Ÿ’ฅ Collisions & Singularities

Visual warnings in the simulation

๐Ÿ”ด

Red Overlay

Collision! The robot or tool has hit an object. You must adjust your waypoints.

๐ŸŸก

Yellow Overlay

Singularity Risk! The robot's joints are aligning in a way that creates "infinite" speed requirements. Adjust orientation.

The Goal: Your simulation should run perfectly with NO red or yellow flashes for the entire cycle.

โฑ๏ธ Path Optimization

Saving time = Saving money

Once your program runs, look at the Cycle Time estimator in OCTOPUZ.

Reduce Cycle Time:

  • Shorten the distance between waypoints.
  • Switch PTP to Linear only where needed.
  • Adjust the speed (%) of non-critical moves.

Keep it Safe:

  • Don't compromise clearances for speed.
  • Ensure "Home" is truly a safe parking spot.

๐Ÿ“ค Exporting and Transfer

From the virtual world to the real robot

Robot File Format Transfer Path
Universal Robots (UR) .urp USB Drive โ†’ Load Program on Teach Pendant
FANUC .LS / .TP Export .LS โ†’ Convert in ROBOGUIDE โ†’ Load .TP

โš ๏ธ TA Verification

You MUST have your simulation verified by a TA before you export the files for physical deployment. One small mistake in sim = a broken robot in reality.

๐Ÿšจ Emergency & Safety

Review before entering the floor

Emergency Stop

Know exactly where the red E-Stop button is located for BOTH the UR and FANUC robots.

NUPD Emergency

Dial 3333 or 617-373-3333. Use the SafeZone app for immediate help.

๐Ÿšซ Pro Tip: Stay Out

Never place any part of your body inside the robot's guard or work envelope while it is powered on. If you must enter, ensure the robot is in ESTOP or Manual/T1 mode with the deadman switch.

๐Ÿšœ Physical Robot Deployment

The final test of your OLP work

1
Zeroing: Ensure the real workbench matches the simulation exactly.
2
Cold Run: Run at 10% speed. Keep your hand on the E-Stop.
3
Observation: Watch the gripper action. Is the delay (Wait) long enough?
Reality Check: If the robot misses the part in reality but hit it in sim, check your TCP and Base Frame offsets first.

โœ… Lab 5 Summary

You are now an OLP Programmer!

Core Takeaways:

1. Think Geometry: TCP & Base are the foundation.
2. Linear for Precision: Always MoveL near the part.
3. Wait for Hardware: Don't rush I/O commands.
4. Simulation = Safety: Get a GREEN light in OCTOPUZ before reality.

Next Step: Complete your lab report and ensure all exported programs are backed up to your OneDrive.