play_arrow

Movement Execution

The primary control for executing robot motion. Use single click for incremental steps or the submenu for full automation. Double click on the play will perform the full automation as well.

skip_next Play next task
Plays the active arm's next task (Task Editor) and stops at its last posture: the move into the task's first posture (from the previous task's last posture with that posture's own settings, from anywhere else a free move), then its moves with their dwells, plugin actions, picks and drops, as in Play Full Sequence. The next click plays the following task; after the last task the first one comes again, with the picked objects back where they started. An object picked in one task and dropped in a later one stays on the tool in between. Play Full Sequence starts the cycle over with the first task.
fast_forward Play full
Executes all movements in the current array, ending with the move from the last posture back to the first (unless Close the loop is switched off in Settings).
arrow_back_2 Play back
Steps backward through your position history.
view_timeline Task Editor
Opens the Task Editor: the postures of every robot arm grouped in tasks, with a time line (see below).
animation Animation Editor
Opens the Animation Editor: the 3D objects of the workspace move, turn, vanish and fall on one time line with the robot arms' tasks; cameras, lights and the arm's tool can be put into it too (see below).
Playback Demo
view_timeline

Task Editor

The Task Editor (Play Controls menu) shows a row for every robot arm in the workspace. Each row is a sequence of task blocks; a task is a run of consecutive postures of that arm's posture queue, and the order of the blocks is the order of the queue. When an arm has postures, it starts with one Move task, Move-1, that holds all of them. Postures added later from the Posture Queue menu join the task of the posture before them.

Pre-defined Tasks at the top holds the blocks Move, Wait, Mill, Paint and Pick & Place (see below; it goes on a Move task only). Drag one into a robot row to add a task; it gets the block's name with a number (Move-1, Move-2, ...). Double click a task block to rename it. In a row you can:

A Wait task holds no postures. Its time (set in its row) is added to the dwell of the last posture of the task before it, so Play Full Sequence waits there. Mill and Paint are tasks like Move. Every kind of task has its own colour: Move blue, Wait amber, Mill purple, Paint red.

Click a task to select it (Shift+click selects more). A row below it shows its postures on the time line as circles: F free move, L line, A arc, C 3D curve, M milling program. An up arrow marks a pick posture, a down arrow a drop posture. The time line starts at posture 1 and uses the real move times of Play Full Sequence; an amber bar is a dwell. The velocity of each move is written on the line between two postures. The time axis fits the selected tasks. The mouse wheel zooms it, and Shift+wheel or dragging the axis moves it.

On a Mac, Ctrl+click does not open the browser's menu over the app (in the Task Editor, CAD Editor, 3D / Tools Editor and the 3D view); Cmd works like Ctrl in the Task Editor. Click a posture to show its x, y, z and Rx, Ry, Rz in the panel at the bottom; without a selected posture the panel shows the arm's manipulator as it moves. Double click a posture to move the arm to it.

Pick & Place. A pick posture has a green up arrow above its circle, a drop posture a red down arrow. Click a green arrow (or its red one) to select the pick: a white frame marks it, and the object it picks is selected in the Objects panel (its pose in the bottom panel). With the arrow selected, click another object in the Objects panel: after you confirm, the robot picks that object there instead (only 3D objects, solids or STL, can be picked; an object is picked once per arm). The Pick & Place block of Pre-defined Tasks can be dropped on a Move task only: it puts a pick on the task's second-last posture and a drop on its last one (the task needs at least two postures that have no pick or drop yet). Such a pick has no object yet - its arrows are dashed and it is not played - until you select its green arrow and click the object in the Objects panel. Drag an arrow onto another posture of the same robot to move the pick or drop there (the pick stays before its drop). Drag the green arrow out of the time lines (out of the window, or onto a panel) to remove the pick; after you confirm, its drop goes too. A warning in the window explains a move that is not possible.

Objects (the panel above the bottom panel) shows every workspace object (3D solid or STL) and every 2D entity / 3D curve as a green block. Click one to see its x, y, z and Rx, Ry, Rz in the bottom panel: an object's pivot (else its origin) and its rotation; a 2D entity's centre (rectangle, circle, arc, ellipse) or first point and the frame of its sketch plane. Double click the name to rename it; the Objects window and the 2D Entities & Curves list show the new name. Drag a block:

A pose the robot cannot reach is not applied.

The bottom panel shows x, y, z (mm) and Rx, Ry, Rz (degrees) of the selected posture, the selected object, or - with nothing selected (click an empty spot of a time line) - the arm's manipulator as it moves. Its lock is closed by default: the fields only show the values. Open the lock to edit them, then click Apply (or press Enter in a field): a posture gets that tool pose (the joints are solved, the arm moves to it), a 3D object is placed there (its pivot, else its origin, and its rotation), and with nothing selected the arm moves its manipulator there. With Relative checked the fields are a step instead, starting at 0: Apply adds it to the pose (Rx, Ry, Rz change by the step angles) and sets the fields back to 0. A pose the robot cannot reach is not applied. 2D entities are changed in the CAD Editor or their Properties.

From a plugin: the same actions by index - getTasks(robotIdx), addTask(type, index, name, robotIdx) (types from getTaskTypes(): 'move', 'wait', 'mill', 'paint'), removeTask(), moveTask(), duplicateTask(), renameTask(), setTaskWait(taskIdx, seconds); the time line with getPostureTimes(robotIdx) and setPostureTime(postureIdx, time) (sets the velocities like dragging, returns the time reached); swapPostures(a, b), movePostureToTask(postureIdx, taskIdx, copy, time, robotIdx, targetRobotIdx), replacePosture(src, dst, 'all' | 'position' | 'orientation', robotIdx, targetRobotIdx), movePostureRelative(postureIdx, [dx, dy, dz], [dRx, dRy, dRz], robotIdx, moveArm) getPostureWorldPose(postureIdx); the bottom panel's Apply with setPostureWorldPose(postureIdx, [x, y, z], [Rx, Ry, Rz], robotIdx, moveArm), setObjectWorldPose(objIdx, [x, y, z], [Rx, Ry, Rz]) and moveArmToWorldPose([x, y, z], [Rx, Ry, Rz], robotIdx); pick & place with getPickPlaces(robotIdx), addPickPlace(taskIdx, objIdx, robotIdx), setPickObject(pickPostureIdx, objIdx), movePickPlace(postureIdx, newPostureIdx, 'pick' | 'drop') and removePickPlace(pickPostureIdx); objects with getObjectWorldPose(source), addPostureFromObject(source, taskIdx, time, robotIdx), replacePostureFromObject(source, postureIdx, 'all' | 'position' | 'orientation', robotIdx), renameWorkspaceObject(objIdx, name) and renameSketchEntity(entityId, name) (source: a workspace object index or { entity: id }). See plugins/apiFunctions.js.

animation

Animation

Every 3D object of the workspace - a solid made in BRW or an imported STL object - can be animated: it moves and turns through keys, or it falls, slides and collides. Objects of a group (Create 3D Objects → Group) are animated as one body; the group's position is the pivot of its first object. The animation plays with Play Full Sequence and Play Next Task, and it is saved with the workspace (Undo / Redo cover it).

Animation parameters. Select an object: the Properties window has an Animation group with the button Animation parameters (the label beside it shows the object's transform mode). The window holds:

An object that is not placed in the Animation Editor plays its own parameters from the start of the simulation. Falling objects land on the floor (z = 0) and on every other visible object; the robot arms themselves do not push them.

Animation Editor (Play Controls menu, after the Task Editor). The top panel shows the objects of the workspace as blocks - a group as one block with its name - and a Wait block. Below it is one time line:

An object with blocks plays its blocks: before its first block it waits at that block's first key, between blocks it stays where the block before left it. The blocks of an arm's group follow that arm's run - they wait while the arm is paused or waits for a plugin action, they start again with every repeat (Settings → Simulation repeat), and with Play Next Task they go as far as the task. An object a robot arm carries (Pick & Place) belongs to the arm until it is dropped; a Dynamic object goes on falling from where it was dropped.

Tool. Drag Tool below a robot row: the tool attached to that arm gets a block (the first one turns it once about its axis). Its keys are a motion of the tool about its tip: x, y, z along and Rx, Ry, Rz about the tool's own axes (z is the tool's axis), 0 being the tool as it is mounted - so Rz 0 to 360 with Repeats -1 is a turning spindle, and a key with Visible off takes the tool away. The row's button opens its Animation parameters. The arm itself and its postures do not change.

Camera. Drag Camera below a robot row: a camera and its target are added to the workspace as two objects (they are in the Objects lists and in the top panel, and are moved with their gizmo like any object), and the camera gets a block. While a block of a camera plays, the workspace is seen through that camera; with several cameras the block that started last counts, so blocks one after the other cut from camera to camera. Outside the blocks the view is yours again. The camera always looks at its target. Its Animation parameters (Properties, or the row's button) show:

A camera, target or light moved by hand keeps the blocks whose keys all stand at one place with it - so drop the camera into the time line first and put it where it belongs afterwards. The target has its own Animation parameters (position, mouse pick, moving path) and can have its own blocks.

Light. Drag Light below a robot row: a light is added to the workspace with a block. Its Animation parameters show the Type - Point (shines all around), Spot (a cone at its target) or Directional (parallel light in the direction of its target; a spot or directional light has a target like a camera, with yaw and pitch) -, Position and Target with mouse pick, Colour and Intensity, Range (mm, where it has faded out; 0: it does not fade), the Cone angle of a spot, Light on (a light that is not Visible is off, so a key with Visible off switches it off), the line to its target and the moving paths. Default Light Level (%) is the workspace's own light, the same value as in Settings: lower it to see the lights better; at 0 only your lights light the scene. Up to 4 lights light the scene in the Standard and Realistic render quality; they cast no shadows.

From a plugin: getAnimationParameters(objIdx) and setAnimationParameters(objIdx, { transformMode, startPosition, startOrientation, endPosition, endOrientation, transitionTime, keys, physics }); the object's own keys with addAnimationKey(objIdx, time, key), setAnimationKey(objIdx, index, key), removeAnimationKey(objIdx, index); removeAnimation(objIdx); the Animation Editor's blocks with getAnimationBlocks(), addAnimationBlock(objIdx, robotIdx, startTime, keys), setAnimationBlock(id, { start, robotIdx, duration, keys }), removeAnimationBlock(id), addAnimationBlockKey(id, time, key), setAnimationBlockKey(id, index, key), removeAnimationBlockKey(id, index); a task's time with setTaskDuration(taskIdx, seconds, robotIdx); the world with getAnimationWorld() and setAnimationWorld({ gravity, floor }); the simulation with playAnimation(), pauseAnimation(on), stopAnimation(reset), seekAnimation(time) and getAnimationState(). A key is { time, position: [x, y, z], orientation: [Rx, Ry, Rz], mode: 'keyframed' | 'static' | 'dynamic', ease: 'linear' | 'smooth', visible }; repeats (1, 2, ... or -1) is a value of setAnimationParameters and setAnimationBlock; the tool of an arm is the object { tool: robotIdx } in these functions. Cameras and lights: addCamera(position, target), getCamera(objIdx), setCamera(objIdx, { position, target, yaw, pitch, roll, fov, focalLength, depthOfField, focusAuto, focusDistance, blur, showLine }), lookThroughCamera(objIdx), addLight(type, position, target), getLight(objIdx), setLight(objIdx, { type, position, target, color, intensity, range, angle, on }), getSpecialObjects(), setAnimationWorld({ sceneLight }), and a moving path with setAnimationPath(objIdx, points, time); getAnimationModes() and getCollisionShapes() list the names. Example: setAnimationParameters(0, { transformMode: 'keyframed', endPosition: [500, 300, 0], endOrientation: [0, 0, 180], transitionTime: 2 }), then playAnimation(). See plugins/apiFunctions.js.

texture

Materials

With Render Quality: Realistic (Settings) every 3D object - a solid made in BRW or an imported STL object - is drawn as the material it is made of: it mirrors the room and its lights, takes the lights of the scene (see Animation, Light) and throws its shadow. Standard and Wire draw the objects by their colour, as before. The material is saved with the workspace, and Undo / Redo cover it.

Material of an object. Select the object (several with Shift) and click Material in the Properties window. Material type:

Casts shadow (below the type, on by default): unchecked, the object throws no shadow, in every Render Quality. The light of the scene comes from above and from one side, so a roof or a wall of a hall would put everything in it into shadow - with Casts shadow off they are seen, and the scene inside is lit.

The panel says when the materials are not drawn because another Render Quality is set; Switch to Realistic changes it there.

Floor. Settings → Show floor grid lines hides the grid lines, and Floor texture puts an image on the floor - with its size on the floor, its transparency, a bump effect (the image as a relief) and the reflection level of the floor (from matt to a strong mirror). See Settings.

A workspace with its own look. A workspace made as a whole scene - a hall with production lines, for a video - can carry how it is to be shown. Its .brw file then has a scene entry in workspace: { renderQuality, floor: { gridLines, image, name, scaleU, scaleV, transparency, bump, reflection }, extent, near }. When such a workspace is opened, the Render Quality and the floor are set as it says, for as long as it is open; what this browser remembers is not changed, and the next workspace without a scene gets the own settings back. extent (mm) is how far the scene goes from the view center: shadows are found that far (otherwise only about as far as an arm reaches) and the floor reaches that far; near (mm) is the distance below which nothing is drawn, which keeps far surfaces apart in a large scene. Saved again, the workspace keeps its scene (with the Render Quality and floor it has then). The demo project car_factory_demo is made this way.

From a plugin: getMaterialTypes(), getObjectMaterial(objIdx) and await setObjectMaterial(objIdx, { type, shininess, transparency, brightness, shadow, texture: { image, name, scaleU, scaleV, repetitions, whole, faces } }) - image is a data URL of a picture, faces are face indices as in getSolidFaces(objIdx, true); the floor with getFloorOptions() and await setFloorOptions({ gridLines, image, name, scaleU, scaleV, transparency, bump, reflection }) (image: null removes the image).

list_alt

Posture Queue [0/0]

Manage the sequence of movements for the robot arm. The counter displays your active position versus total positions.

add_circle Add pose
Inserts position relative to current index.
first_page Add as first position
Inserts position at the start of the array; the others move up by one.
add_box Add as last position
Appends position to the end of the array.
conversion_path Path Pick
Adds postures along a 2D entity or an edge of a 3D solid: click the menu item, then the entity or the edge in the workspace (the edges of the solids light up under the mouse; Esc or Cancel stops). The queue needs at least one posture first: the path goes on from the current posture - every new posture keeps its tool orientation and is inserted after it, and the path starts at its end nearer to that posture's tool point (a closed path, e.g. a circle or a rectangle, starts where it was drawn from and ends there again). One posture is added for every point of the path, and the move from each one is the segment that follows it; a path end already at the current or the next posture (within 1 mm) adds no second posture there, so a curve from the current posture to the next one only changes the current posture's move: Line for straight pieces (lines, polyline and rectangle sides), Arc with the arc's radius, plane normal and direction for arcs and rounded corners (Long for an arc over 180°), Arc with Full circle for a circle (one posture on the circle with the full circle move, its starting angle set so that the centre is the circle's centre, and one more posture back at that point), 3D Curve with mid points for curves and ellipses. An edge of a solid is split into the lines and arcs it is made of; an edge that is a whole circle (e.g. the rim of a cylinder) becomes a full circle. A single 2D point adds one posture. When a point of the path cannot be reached with that tool orientation, nothing is added and the console names the point.
cancel Remove pose
Deletes the current posture from the queue.
sync_saved_locally Update posture
Overwrites the current posture with the arm's pose as it stands in the workspace (joints, and rail / table with external axes); the movement settings stay.
smart_toy Posture info
Movement type, dwell, velocity and plugin action of the current posture (see Interactive Controls → Movement Types).
Posture Queue Demo
carry_on_bag

Pick and Place Logic

Operational Flow

To interact with objects in the scene, follow this logic strictly:

  • 1. Create a standard position as a "safe start".
  • 2. Move arm to the object using Gizmos or IK.
  • 3. Use Add Position, then select your interaction:
carry_on_bag_checked Pick object
The current posture picks the selected object; with no object selected, click the object in the workspace (the prompt says so; Esc cancels).
carry_on_bag_inactive Drop object
restore Restore object
Returns object to original imported position.
mouse

Interactive Controls

Mouse And Keyboard

Direct Kinematics: Click and drag joints with the mouse.

Inverse Kinematics (IK): Hold SHIFT while dragging to solve for position.

Disable Selection: the pointer button with a stop sign in the icon column on the right (below Show Pivot) is off when the app starts. While it is lit, a click in the 3D view selects nothing - no object, 2D entity, face, edge or point, and no robot arm - nothing is dragged (joints, objects, the gizmo) and nothing lights up under the mouse: the mouse only turns, pans and zooms the view. Use it to look around a crowded scene, or while a simulation runs or is recorded. Objects can still be selected in the lists (Objects Explorer, 2D Entities & Curves), and a command that asks for a click in the view (Duplicate, Path Pick, Fillet ...) still gets its click. Click the button again to select as before. From a plugin: setSelectionDisabled(true) / setSelectionDisabled(false) and isSelectionDisabled().

Remove: the bin button in the icon column on the right (above the Measuring Tool) does what the Remove Object button of the Import / Create 2D / 3D Objects window does: it removes the selected object, or after a question all selected objects - and a selected 2D entity (Undo brings them back). It is greyed out while nothing is selected.

Measuring Tool: the ruler button in the icon column on the right (above Undo / Redo) opens the Measuring Tool window; the button stays lit while it is open (a second click or ✕ closes it). Choose Distance, Angle or Radius, and below Point-to-Point, Face-to-Face or Point-to-Face, then click in the 3D view: points snap to corners of objects and to 2D points within 10 px (else the point on the surface clicked), faces are the faces of solids and imported objects. The window says what to click next and shows the result (also written to the console); the measured value (the number, in mm or degrees) is copied to the clipboard as with Ctrl+C / Cmd+C, ready to paste with Ctrl+V / Cmd+V; the points and a dashed line with the value are drawn in the view. The next click starts a new measurement, Esc clears it; a click beside the objects turns the view as usual. Distance: two points (dX, dY, dZ); two faces - planar parallel faces: the distance of their planes, other faces: the shortest distance between them (with their angle); a point and a face - the normal from the point to the face (its nearest point; beside a face it ends on the face's edge). Angle: three points (the angle at the second); two faces (between their planes, for curved faces at the places clicked; also the angle between the normals); a point and a face (between the face and the line from the point to the place clicked on it). Radius: a curved face - a cylinder (with its axis) or a sphere is fitted to it, a flat face has none; or the circle through three points (Point-to-Point).

Undo / Redo: the two arrow buttons at the bottom of the icon column on the right (below Show Pivot), or Ctrl+Z and Ctrl+Y (also Ctrl+Shift+Z; Cmd on a Mac), take back and redo the last changes, up to 50: moving, turning, recolouring, hiding, creating, duplicating, importing and removing objects, the values of solids, Objects Explorer folders, 2D sketches, and adding, removing, updating or editing postures and their moves (Surface CAM and Path Pick results included). A drag counts as one step. In a text or number field the keys undo the typing in that field instead. Importing a workspace starts a new history; a playing sequence is not recorded.

Object Movement: With Show Pivot on, click any .stl or 3D object to reveal the 3D Gizmo for relocation (with Show Pivot off there is no gizmo; drag the object itself to move it). Its arrows are X red, Y green, Z blue, and it keeps the same size on the screen: about 10 % of the view height, whatever the zoom or the size of the object. The robot's gizmo keeps its fixed size.

Object size from a plugin: getWorkspaceObjectBoundingBox(objectIndex) returns the object's axis-aligned box in world coordinates, { min, max, size, center } in mm with its rotation and position applied, for example to place the tool above an object: center[2] + size[2] / 2 is its top. It returns null while a robot is carrying the object.

Zoom: Mouse wheel, or a two-finger pinch on a touch screen: spreading the fingers zooms in, bringing them together zooms out, in proportion to the finger movement.

Linear rail: Drag the rail carriage to slide the arm along the rail. Hold SHIFT while dragging and only the base moves: the manipulator keeps its exact world position (X, Y, Z) and orientation (Rx, Ry, Rz), the joints are re-solved for every step. Where the pose cannot be reached from the new base position inside the joint limits, the carriage stops instead of letting the tool drift.

View: Drag the background to orbit, use the wheel to zoom. Hold SHIFT and drag the background to move the view center in X / Y, hold ALT (Option on Mac) and drag for its height (Z); the scene follows the mouse. Adding a second arm centers the view between the arms, Center the view in Settings brings the center and the zoom back to their defaults, and the view center is saved with the workspace.

Joint Conventions

The simulator counts every joint positive counter-clockwise about its axis vector, with zero at the model's home pose. Real controllers differ in sign and zero, so each .rob row carries a mapping real = sign · sim + offset (columns 14 / 15: sign, offset in degrees). Every joint angle that crosses the plugin API - getCurrentJointAngles(), getHomeJointAngles() (the simulator's Home pose, all joints at 0 in the simulator's convention, as API angles), worldToJointAngles*(), jointAnglesToWorld*(), postures, trajectory deltas, limits - is in the real convention; getJointAnglesMapping() / setJointAnglesMapping() read and change the mapping at run time (e.g. [{sign: 1, offset: 0}, {sign: -1, offset: -Math.PI/2}, {sign: -1, offset: Math.PI/2}, …] for a KUKA whose home is the candle pose).

Joint Limits

Each robot's .rob file carries the manufacturer's joint angle range (columns 12 / 13, degrees, real convention) of every joint; the simulator derives its own limits through the mapping. Dragging a segment stops at its limit, the joint sliders span the limits, and IK solutions outside them are rejected (the pivot gizmo stops, Apply XYZ finds another solution or none). Plugins can read the limits with getRobotJointLimits(), check a posture with isPostureValid(), and simulateRobotMotion() refuses a trajectory that would leave them. Models whose limits are not the manufacturer's values report a warning in the console when loaded. A joint whose range is wider than one turn (KUKA A4 / A6 ±350°, Yaskawa T ±360°, ABB axis 6 ±400°, also KUKA A1 ±185°) is a multi-turn joint: its angle is an absolute axis value like on the real controller, so it can be set, saved in a posture and played beyond ±180° (J6 = 300° is a different state than −60°, cable twist included), and a move takes it to the exact value, never the shortest way round. Dragging the arm winds such a joint on past ±180° until its limit. Joints with a range of one turn or less move the shortest way, as before. The file also carries each joint's maximum speed (column 17, degrees per second, datasheet value), which caps the speed of every move (see Settings → Velocity).

Singularities: a plugin can check a Cartesian path before it is simulated with findTrajSingularity(path, q0, normal, robotIdx, K = 10). The path is solved point by point like worldToJointAnglesBatch(), and the conditioning of the arm's Jacobian at each solution is compared with the best point on the path. It returns null when the path is fine, otherwise [[index, K], …]: the path index and how many times worse that point is conditioned (0 = exactly singular, the arm loses a degree of freedom there, joints would have to spin). Points near the flagged indices should be moved, or the tool normal changed, before simulateRobotMotion(). The demo plugin shows the call.

Trajectory line: the drawn path is an anti-aliased line of constant pixel width (it does not grow with the zoom). Its width and colour are set in Settings → the palette button beside Show path (Path style window), which also holds the singularity marking: the heaviest line weight and the start / end colour of the gradient plugins use; defaults are 1 px (the grid line weight), teal, 3 px, light red to full red. A segment always has one width and colour, that of its styled end point; plugins read them with getTrajLineStyle(), change them with setTrajLineStyle(width, color), and can give single steps of the current trajectory their own width and colour with setTrajStepStyle([[stepIndex, width, [r, g, b]], …], robotIdx) ([] clears). The demo plugin colours the steps that findTrajSingularity() reports with the gradient and the weight from the Path style window (defaults: light red to full red, grid weight to 3 px), the worse the conditioning the redder and heavier the line. getTrajLineStyle() returns them as singularWidth, singularColorStart and singularColorEnd, and setTrajLineStyle(width, color, { width, colorStart, colorEnd }) changes them. A new trajectory starts with the defaults again.

Movement Types

Each posture in the queue carries how the arm travels from it to the next posture (Posture Queue → Posture Info): a Line set on posture 1 is the move between postures 1 and 2, and the last posture's type closes the loop back to the first. Free Move interpolates the joint angles with a trapezoidal velocity profile (the shortest way round, except a multi-turn joint, see Joint limits, which goes to its absolute angle); Line, Arc (radius, plane normal, short / long, CW / CCW; Full circle draws a whole circle of the radius from the start position back to it when both postures coincide, CW or CCW, with the centre in the direction of the tool normal at the start turned by the starting angle about the plane normal) and 3D Curve (a spline through user mid points) move the tool centre point exactly along that path in world space. The orientation changes smoothly on the way: the three wrist joints are interpolated between the two postures with the same trapezoidal velocity profile, the other joints are solved for every path point, and the move ends exactly on the saved posture (position and orientation). The arc's plane normal and the mid point fields of a 3D curve follow the manipulator while their lock chip is closed, like the read-out in Joint Control: the normal takes the manipulator's normal when Arc is chosen and whenever you move the arm afterwards (a playing simulation does not change it), and the curve point shows the tool position, so you teach a mid point by moving the arm and pressing Add. Open the lock to type values by hand; selecting a stored point in the list opens it for editing. While the move has no mid points, Convert to curve places the given Number of mid-points at equal distances along the free (joint) move between the two postures, as a starting shape. While the Curve Mid Points window is open, the curve, its two postures (squares) and the mid points are drawn over the 3D view: drag a point to move it in the plane facing the camera (hold SHIFT to change only its height), double-click the curve to insert a point there, double-click or right-click a point to remove it. Near a point the cursor snaps to it and the point is highlighted; the camera still turns when you drag elsewhere.

The same window sets per posture a dwell time (seconds the arm pauses at the posture before the move that starts there; dwells apply to Play Full Sequence only, which opens with the dwell of its first posture, not to single steps), a velocity 0..1 (ratio of the joints' maximum speed) for the move that starts at it (or "Use default" = the global velocity from Settings) and Plugin Action Execute: the action belongs to that posture. When the running simulation reaches a flagged posture it stops there, the plugin's async function userAction(robotIdx, postureIdx, velocity, dwellTime, gcodeString) is called, and the simulation continues (with the posture's dwell, then the next move) only after it has returned. A run that starts at a flagged posture calls its action first.

gcodeString is the text of the posture's G-Code or Custom Action box (enabled only with Plugin Action Execute), so a plugin can forward G-code lines or any custom command to a controller. For Line, Arc and 3D Curve the window offers two more settings: Align normal with the path makes the manipulator keep the relation it has to the curve at the start pose: its frame is carried along the path and turned only as the path's direction turns (a tool pointing at the centre of an arc keeps pointing at it), and whatever difference to the end posture's orientation remains is blended in over the last quarter of the path; it is solved with the full-orientation IK. On a full circle around the tool axis the tool turns once about its axis, so a wrist joint (usually joint 6) turns by 360°: the move then ends at the end posture's pose with that joint a full turn away from its saved angle, the console says so, and the next move turns it back. The wrist reaches every tool orientation in two ways (joints 4, 5, 6 turn about Z, Y, Z: Rz(θ4)·Ry(θ5)·Rz(θ6) = Rz(θ4 ± 180°)·Ry(−θ5)·Rz(θ6 ± 180°)), and which one a posture gets depends on where the arm came from. A full turn of joint 6 from 0° needs 360°, beyond a limit of ±350°, while from −180° it ends at +180°. So when a move with Align normal would take a wrist joint beyond its limit, the start posture (and the end posture when it is the same pose, as for a full circle) is changed to the other wrist configuration of the same pose if the move fits then: the tool pose does not change, the move into the posture turns the wrist on the way, and the console says so. Only when neither configuration fits is the move made without Align normal (the tool keeps its orientation on the path), with a console warning naming the joint and the angle it would need. Detect singularities with its threshold K (default 12): like every other setting it belongs to the move that starts at the posture. With the box checked on posture 1, the Cartesian move from posture 1 to posture 2 is checked like findTrajSingularity() and, in addition, for joint jumps (a joint turning in one step by more than 5° and more than eight times its usual step on that move, e.g. a jump to another solution near a posture); the singular steps and the jumps are drawn with the Path style marking (they are on the line when the arm has arrived and posture 2 is the active one), and console warnings name them; unchecked (the default) the check is skipped and the line stays plain. In moveParams / getPostureMoveType() these are dwell, velocity (null = default), pluginAction, gcodeString, alignNormal, detectSingularities and singularityThreshold. Everything is saved in the .brw workspace file.

Milling Program is the fifth type: the move that starts at the posture runs a Mill / Sculpt program (see the Mill / Sculpt section). The arm first travels with a free move (trapezoidal velocity profile, rail and table included) from the posture to the program's first state, then the program is played (arm, rail and table together, carving the workpiece), and from its last state a free move takes the arm on to the next posture. Postures before and after it are ordinary ones, so a sequence can be "home → milling → inspection pose → home". The panel shows which program the posture uses: choosing the type attaches the program generated in the Mill / Sculpt window; Use generated program re-attaches it after a new generation and Open Mill / Sculpt opens the window. Play back turns a milling move into a free move. The program itself is not written into the .brw file (it is far too large); after loading a workspace, generate it again or set it from a plugin, otherwise the posture falls back to a free move with a console warning. The program's steps draw no path line.

From a plugin: In the plugin API the type is the integer enum brwAPI.MoveType = { FREE: 1, LINE: 2, ARC: 3, CURVE: 4, MILL: 5 }: addRobotPosture(jointAngles, index, robotIdx, moveType = 1, moveParams) takes it as an optional fourth argument (default Free Move) with moveParams = { radius, normal: [x, y, z], long, cw, full, startAngle } for an arc, { points: [[x, y, z], …] } (world, mm) for a curve or { program } for a milling program, where program is { name, states: [{ jointAngles, rail, table, cut }, …] } (joint angles in the real convention, rail travel in mm, table angle in degrees counting turns, cut = { layer, cell0, cell1, radius } on the blank's grid or null) - the form getMillingProgram(index = -1, robotIdx) returns for the program generated in the Mill / Sculpt window (index -1) or attached to a posture, so a plugin can store, modify or build one; program: null (or no program) uses the generated one; addRobotPosture() returns true when the posture was added: it must lie inside the joint limits (an angle beyond a limit by a full turn, e.g. A4 = 360° with limits ±350°, is taken to its image inside the limits nearest to the preceding posture; anything else outside is refused with a console message and false); updateRobotPosture(index, robotIdx) overwrites a posture (default: the current one) with the arm's pose right now, keeping its move settings; getPostureMoveType(index, robotIdx) returns { moveType, radius, normal, long, cw, points } and setPostureMoveType(index, moveType, moveParams, robotIdx) changes an existing posture.

3d_rotation

Kinematics & Coordinates

Joint Control

Set specific angles for each robot joint within its physical range. The system uses inverse kinematics calculations to position the arm. The sliders always show simulator angles with zero at the model's home pose (see Joint Conventions for the mapping to a real controller). M+ stores the current joint angles on a stack and M- recalls and removes the last stored set (last in, first out); the XYZ windows have the same pair for positions.

Kinematic configuration type: each model's .rob header carries a type (9th value): 1 for a standard six-axis articulated arm (the default) and 2 for a Universal Robots type arm (UR3, UR5, UR10e). The direct and inverse kinematics use the type of the arm they are solving for; plugins can read it with getRobotConfigType(robotIdx).

home Home
Resets the arm to its initial '0' state.

Joint Lock / Unlock

Each joint in the 3D control panel can be toggled between two modes:

lock Locked
Joint angle values update automatically but cannot be changed manually.
lock_open Unlocked
Joint angles can be edited manually but will not update automatically.

XYZ Coordinates

Work in world coordinates relative to robot reach. Click any imported .stl object to use the from object option via the appearing gizmo; it takes the object's pivot (Set Pivot), or its origin when no pivot was set. With no object selected, it asks you to click one (Esc cancels).

XYZ & Orientation is a second window that adds the tool orientation as Rx, Ry, Rz (degrees, read from the arm's forward kinematics while the lock chip is closed) and solves position and orientation together with the full-orientation IK on Apply. Both windows have a Key/Mouse Input button: it opens a small window to type x, y, z and the normal or the angles. Its Click in Workspace first shows the plane window of the 2D entities (while it is open, the face under the mouse is shaded, on solids and on imported STL objects alike): choose XY, XZ or YZ (with an offset) or the selected face and then click the point on that plane, or click a face of a solid directly - that click is the point. With Take plane normal checked (the default), the plane's (face's) normal also fills the orientation, the tool pointing into the plane against its normal: Rx, Ry, Rz in the XYZ & Orientation window, the normal in the XYZ window. (The curve's Edit points window keeps the plain Click in Workspace: the next left click is the point.) Settings → Display cursor coordinates shows the world point under the mouse in a box above the console.

token XYZ controls

Access the XYZ coordinate window here. Note: All workspace windows are draggable and can be positioned anywhere in your browser.

precision_manufacturing

Robot Library

Choose from a growing library of professional robot arms. Selecting a model will instantly replace the active arm in the scene while maintaining your coordinate space; with several arms loaded, the other arms are untouched (see Multiple Robot Arms).

  • • Yaskawa / MotoMini
  • • KUKA Models
  • • Universal Robots & more
Playback Demo
folder_zip

Import / Export Workspace

Demo projects: the first link in the bar at the top, Demo Projects, downloads ready-made projects as one zip file (a window explains the steps first). Unzip it, then load a project with Import Workspace by choosing the project's folder, and click Play, or a User Command button for a project that holds only plugin code, such as the singularity demo. The first project, the car factory demo, is a car body shop with 20 robots - a welding line, a cell that mounts the hood, liftgate and doors, and a CNC cell - seen through two moving cameras for one minute: import it and click Play; for a full quality simulation set Render Quality to Realistic in the Settings menu. The collision avoidance demo shows the robot hitting a yellow box when played; Tools & Objects → Collision Avoidance with Precision 0 and Recalculate trajectory makes it pass around the box.

Save and restore your entire workspace including the robot configuration and all imported objects. The workspace is stored as a .brw file next to the STL files it refers to: every scene object, every tool of the library and every turntable workpiece (imported or generated in Mill / Sculpt, in its milled state), so a project started from scratch is complete after one export. While a workspace is imported, a progress window shows how far it is (the robots, then every object by name).

download Export workspace
Saves your current session - arm positions, queue, external axes, tools and all STL objects. In Chrome and Edge a folder picker opens: choose where to save (Downloads, for example) and a sub folder named after the robot and the time is created with the .brw and the STL files. In other browsers, or when the picker is cancelled, a single .zip with the same content is downloaded instead; unzip it into a folder.
save Save workspace
Writes all workspace data back into the folder it was imported from (.brw and STL files). It is grayed out until a workspace is imported. In browsers that cannot write into a folder (Safari, Firefox) a .zip named after the folder is downloaded instead; unzip it over the folder.
upload Import workspace
Choose the folder that holds the .brw file and its STL files to restore your full workspace and continue where you left off.

The name of the active workspace is shown at the top left, next to the left bar: the name of the imported folder (browsers do not reveal its full path), Untitled project* for a new one, or the exported name with an asterisk for a workspace that was exported but not imported. If you close the window with changes that are not saved or exported, the browser asks whether to leave; choose to stay and a window offers Save or Export Workspace, or to exit without it.

Import Export Demo
highlight

Object Highlighting

When manipulating objects in the scene, the active object is now visually highlighted so you can clearly see which item you are interacting with. This improves precision when working with multiple objects in close proximity. With Disable Selection on (the icon column on the right) nothing is highlighted under the mouse.

highlight_alt Active highlight
The currently selected object is outlined to distinguish it from surrounding scene elements.
Highlighting Demo
view_in_ar

Scene & System

Object Management

attach_file_add Import/Create 2D/3D Objects
Opens the object window: the workspace objects as chips (click one to select it, as in the viewport), the active object's position, rotation Rx / Ry / Rz and colour, Add Object to import STL files, Duplicate to copy the active object (100 mm along X, named after the original with a dash and the next number: "Box 1" → "Box 1-1", "Box 1-2"; the same for the copies of the 3D Editor's Copy and Array, and for copies of a renamed 2D entity in the sketch editor; a solid made here keeps its parameters and history, an imported object gets its own copy of the mesh) and Remove Object to delete the active one. The position shown is the object's pivot (Set Pivot), or its origin when no pivot was set. Position and rotation are editable once the lock chip is unlocked and apply at once. Below them, the panels Create 2D Entity and Create 3D Solid draw sketches and model solids, see the Create 2D / 3D Objects section.
view_in_ar External Axis
Linear rail and rotary table of the active arm, see the External Axes section.
carpenter Mill / Sculpt
Robot milling of a blank on the rotary table into an imported STL object, see the Mill / Sculpt section.
texture Surface CAM
Tool paths over a CAD surface / patch (U-Turn, Zig-Zag, Contour, Spiral, Raster, Edge) added to the posture queue, see the Surface CAM section.
safety_check Collision Avoidance
Finds collisions between the arm and the workspace objects along the posture queue and recalculates the moves around them, see the Collision Avoidance section.

Robot Library

Click precision_manufacturing to swap the active arm's model (KUKA, Yaskawa, etc.), add or remove arms and set their base positions.

The row with the base position also filters the gallery: the brand list (built from the names of the library's models, default All brands) and Payload > / Payload < in kg, empty by default. Every tile shows the model's payload; a model whose payload is not known stays listed while no payload limit is set.

Configuration

  • • Velocity [ratio of max velocity]: Control arm movement speed (default 0.35). The value is the ratio of every joint's maximum speed from the manufacturer's datasheet (stored in the model's .rob file, 180°/s where no value is published): at 1.0 a joint may run at its datasheet speed, at 0.35 at 35 % of it. The joint whose travel takes longest at its scaled speed sets the duration of a move, the others follow in sync. Two read-only rows under the slider show, for the active arm, the speed of every joint at the current ratio and the maximum from the .rob file (°/s). Moves are played in real time: a trajectory is computed with the measured frame interval, so its duration on screen does not depend on the frame rate.
  • • Joint acceleration: the ramps of the trapezoidal velocity profile of a free move, set separately for the joint groups J1-J3 and J4-J6 (all joints of a move still start and stop together). Ramp-up time (default 0.3 s) is the time in which a joint accelerates from rest to its peak speed, and the same time is taken to stop; the acceleration this needs is the peak speed divided by the ramp-up time. Accel. (default 5 rad/s²) is the acceleration a joint may use at most: a joint that would need more gets a longer ramp, and the whole move follows it. Accel. max (default 20 rad/s²) is the hard limit; a move whose ramp-up time would need more than that is still played with the longer ramp, and a console warning names the joint. A move too short to reach the peak speed accelerates with the same values and turns around earlier (a triangular profile). The values are remembered in the browser.
  • • Show Pivot/Path: Visualize the joint gizmos and the movement trajectory. The palette button beside Show path opens the Path style window (line weight, colour and the singularity marking, see Interactive Controls).
  • • Simulation repeat: how many times Play Full Sequence runs the whole queue in a row (1 to 1000, default 1). Every run starts like the first one: the objects picked and placed in the previous run go back to where they were (Restore Object) before the run starts; with the loop open the arm first returns to the first posture, which does not count as a run (nothing is picked or dropped on the way back). After the last run the objects stay where the sequence put them.
  • • Close the loop: on (default), Play Full Sequence ends with the move from the last posture back to the first, with the last posture's movement type, and the first posture is the current one afterwards; off, a full run plays the queue from the first posture and stops at the last one, which is then the current one (the counter and getRobotCurrentPostureIdx() say so); when the arm is not at the first posture, for example after the previous run, a click on Play Full only brings it there with a free move, and the next click plays the queue. Remembered in the browser.
  • • Display cursor coordinates: shows the world coordinates of the point under the mouse in a box above the console (on by default). This and Show path are remembered in the browser and restored when the application starts.
  • • Show right toolbar: shows or hides the icon column at the right edge (select modes, Edit sketch, 3D Editor, Show Pivot, Disable Selection, Show XY Grid / World Axis / TCP, Remove, Measuring Tool, Undo / Redo); on by default, remembered in the browser.
  • • Background color: the colour of the 3D view behind the floor (dark grey by default); remembered in the browser and restored when the application starts.
  • • Render Quality: how the 3D view is drawn; remembered in the browser. Standard (default) is the usual view. Wire draws robots and objects as wire models: their edges as lines in their own colour on the background colour, without the lines behind a part and without shadows; the floor is its grid lines. Realistic draws the scene like a studio shot: the objects in their materials (see Materials; the robot arms are metal), surfaces that reflect the room and its lights, smooth surfaces on robots and imported STL objects, soft shadows from a light that stays where it is in the room when the view turns, and a polished floor that mirrors the robots and objects. It has its own backdrop (Background color is for Standard and Wire), and solids are drawn without their outline edges in Wire and Realistic. Picking, the gizmo, paths and all commands work the same in every mode. Realistic costs some more graphics time per frame; on a machine that does not keep up (frames over 30 ms) it switches the floor's mirror image off by itself.
  • • Default Light Level: a slider from 0 to 100 % for the workspace's own light, in Standard and Realistic. 80 % (the default) is the light as it has always been, 100 % is a quarter brighter, lower values dim it. At 0 the workspace has no light of its own, so that only the lights you add (Animation Editor, Light) light the scene. The level is saved with the workspace and comes back when it is imported; a workspace saved without it opens with 80 %. From a plugin: getDefaultLightLevel() and setDefaultLightLevel(percent).
  • • Show floor grid lines: on by default; unchecked, the floor is drawn without its grid lines (in Wire the floor is then not drawn at all). Remembered in the browser.
  • • Floor texture: the button shows the name of the floor's image, none without one. It opens the Floor texture window: Select image file (a picture file; it is repeated over the floor), Scale U, V (mm: the size of one image on the floor along X and Y - smaller values repeat it more often), Transparency (0 the image alone, 1 the floor as it is without it), Bump effect (the bright and dark parts of the image as a relief that catches the light) and Reflection level (0 a matt floor without a mirror image, 0.5 as usual, 1 a strong mirror). Remove image takes the image away. The image shows with Render Quality Standard and Realistic, bump and reflection with Realistic. The values are remembered in the browser (the image too, if it is not too large), not in the workspace file. See Materials.
  • • Hide text outlines: on by default; the edges of a Text used with Push / Pull are not drawn: raised text, and the outline, walls and floor of engraved text. All other edges stay, and the faces and their picking are the same. Remembered in the browser.
  • • Show AI Assistant: shows or hides the AI Assistant panel at the right edge (see AI Assistant).
  • • Language: Multi-lang support (EN, DE, IT, FR, ES, ZH, JP).
  • • Dark Mode: Switch the interface between the light and dark themes.
  • • Account: the icon at the top right signs in with email and password; it is grey while signed out and coloured while signed in, with the user name below it. Click it again to see the account and to sign out. Not registered? Sign-Up below the icon opens the registration: user name, email, password (at least 8 characters) and the annual plan, FREE (US$ 0) or PREMIUM (US$ 599 per year: everything in FREE plus the full robot arm library, live collaboration, the AI Assistant and 24/7 email support). As a protection against spam, Create account can be pressed 10 seconds after the window was opened, and at most 100 accounts can be registered from one network. After Create account the window says Check your email: the account is activated by the link in the email sent to the address given (valid for 48 hours), which also signs the user in. Until then the account cannot sign in; the Sign-In window offers to send the activation email again. A PREMIUM registration stays payment pending until the payment is confirmed. The sign-in is remembered in the browser for 30 days.
draw

Create 2D / 3D Objects

The object window (attach_file_add Import/Create 2D/3D Objects) draws 2D sketches and models simple 3D solids directly in the workspace, without an external CAD program. Solids are workspace objects like imported STL files: they are selected, moved and rotated the same way, take part in collision avoidance and pick & place, and are saved with the workspace.

Base Plane

Every command first asks for a base plane. A small window at the bottom right, beside the select mode strip, shows the three main planes XY, XZ and YZ: click one of them (or its button), with an optional Offset in mm along the plane's normal. Instead, click a face of a solid in the workspace to work on that face. Esc or Cancel stops the command.

Create 2D Entity

Point, Line, Polyline, Rectangle, Rounded rectangle, Circle, Arc, Ellipse, Curve (a Catmull-Rom spline through the clicked points) and Text. After the base plane the sketch editor opens: the plane in 2D with a grid (mouse wheel zooms, the right or middle button pans). With only a left mouse button (or a trackpad), use Pan and Zoom in the toolbar (before Undo / Redo): while one is lit, dragging with the left button pans the view, or zooms it about the point where the drag starts - up zooms in, down zooms out, more gently than the wheel (100 px: about 1.35 times). Click the lit button again, press Esc or choose a tool to go back to drawing. Click the points, or type the values in the fields at the bottom (X / Y, length and angle, width and height, radius, start and end angle, corner radius, text height...) and press Enter or Apply. A polyline or curve ends with Enter or a double-click; C closes it. Properties (next to the ruler) opens a panel at the top left with the values of the entity selected in the sketch - the same fields as the workspace's Properties window (Visible, start / end / length, corner, width / height, centre / radius, angles, points, text...), applied while typing and followed by the drawing; it keeps showing the selection until it is closed (the button again or ✕). The orientation (Rx, Ry, Rz) and Plane offset are not there: in the sketch editor they belong to the whole sketch (change them in the workspace's Properties window). Measuring Tool (the ruler, before Pan and Zoom) opens a panel at the top right: choose Distance, Angle or Radius, and below Point-To-Point, Line-To-Line or Point-To-Line, then click (points snap as when drawing; lines and other entities are clicked on their outline). The result shows in the panel and in the drawing (dashed line and value), and the measured value (the number) is copied to the clipboard, to paste with Ctrl+V / Cmd+V; the next click starts a new measurement, Esc clears it. Distance: two points (with dX, dY and the direction angle); two lines - for parallel lines the distance between them, otherwise the shortest distance between the two entities (with their angle); a point and a line or any other entity - the length of the normal from the point to the entity (its nearest point, also on circles and arcs). Angle: three points (the angle at the second); two lines or curves (at the clicked places, curves by their tangent); a point and an entity (between the entity and the line from the point to the place clicked on it). Radius: a circle or arc (Line-To-Line or Point-To-Line: one click; an ellipse shows both radii), or the circle through three points (Point-To-Point). Undo / Redo (the arrows after Pan and Zoom, or Ctrl+Z / Ctrl+Y, Cmd on a Mac) take back and redo the changes made in the sketch editor - drawing, moving, deleting, trimming, a dragged grip (one step) ... - up to 100; while the editor is open these keys act on the sketch only, not on the workspace. Done makes the whole edit one step of the workspace's Undo; Cancel drops it. Circle has three options at the bottom (radio buttons, the last one used stays): Center (default) - click the centre, then a point on the circle or type the radius; 2-Point - click (or type) the two ends of a diameter; 3-Points - click (or type) three points the circle passes through (three points on one line make no circle: the status line says so and waits for another third point). The circle follows the mouse until the last click.

The edges of the solids and objects that lie in the sketch plane are shown in grey as reference - for a sketch on the top face of a box, the face's outline - and the snaps work on them too (their corners, the middle of straight edges, intersections, nearest point); they cannot be selected or changed in the sketch. Snaps (the Snap button - a magnet - in the toolbar opens their check boxes in a list below it; a click elsewhere closes it, and the magnet is teal while any snap is on): end point, mid point, centre and quadrant, intersection, tangent (circles and arcs), parallel, nearest point and grid. The snap found is marked at the cursor.

Select Modes

The vertical strip at the right edge of the workspace, above the cursor coordinates (left of the AI Assistant while that panel is open), sets what a click on a solid selects: Object select (the default: the whole object, which can then be moved and rotated as usual), Face select (the face under the mouse is shaded; a smooth face such as the side of a cylinder counts as one face), Edge select (a crease or border, e.g. a box edge or the rim of a cylinder) or Point select (the characteristic points of the solid: base, top and centre points, corners, the apex of a cone or pyramid). The Properties window names the selection: area and normal of a face, length and end points of an edge, world coordinates of a point. A selected planar face is offered as Selected face in the base plane window of the next Create command. The edges of all solids are drawn as lines, also on the selected solid.

Moving Faces And Edges

With Show Pivot on and a face (Face select) or an edge (Edge select) of the active solid selected, the gizmo stands on that face or edge: on a face its blue z axis is the face normal, on an edge its x axis runs along the edge. Drag an arrow to move the face or edge (it follows the mouse along the arrow; the faces around it stretch with it - pulling the top face of a box up makes it taller), or drag a rotation arc to turn it about its centre. The first such edit turns the solid into an editable Mesh: its parameters (or the NURBS faces of an imported STEP part) are not kept, which the console says - Undo brings the original solid back. With nothing selected, the gizmo moves the whole object as before; with Show Pivot off no gizmo is shown.

Edit Sketch

Double-click a 2D entity in the workspace, or click edit Edit sketch (in the select mode strip at the right edge of the workspace, below the select modes) and then the entity. In the editor, Select picks entities (Shift adds, a dragged window selects several); drag an entity to move it, drag its grips (end, mid, centre and radius points, the points of a polyline or curve) to change it, and double-click a point of a polyline or curve to remove it. Move and Rotate take a base point or centre and then a click or typed displacement or angle; Delete or the Del key removes the selection. Done keeps the changes, ✕ discards them. Outside the editor the sketches are drawn in their planes over the 3D view.

More commands in the editor's toolbar (after Move and Rotate):

  • Duplicate - select the entities, click a base point, then where the copy goes (or type dX, dY and Apply); every further click places one more copy, Esc ends.
  • Mirror - select the entities, then click two points of the mirror line. Keep originals (on by default) keeps them; off, they are replaced by their mirror images.
  • Array - select the entities. Rectangular: Columns, Rows, dX, dY, then Apply. Polar: Count and Total angle (360°: evenly round; less: the last copy at that angle), then click the centre.
  • Offset - type the Distance, click the entity, then click the side. Lines, arcs, circles and rectangles stay what they are (a rounded rectangle keeps rounded corners), a polyline gets mitred corners, an ellipse or curve becomes a curve. Offset stays on for the next entity.
  • Trim - click the part of an entity to cut away: it goes up to the nearest crossings with other entities (and with the edges of solids lying in the sketch plane) on both sides, or up to the entity's end. A circle needs two crossings and becomes an arc.
  • Break - click an entity at the first break point, then the second: the part between them goes (on a circle or closed outline: counter-clockwise from the first point). Clicking the same point again, or Enter, splits the entity there.
  • Join - the selected lines, arcs, open polylines and curves that meet end to end become one polyline; a chain that comes back to its start becomes a closed polyline, a profile for Push / Pull, Revolve and Sweep.

Create 3D Solid

Box, Cylinder, Sphere, Cone and Pyramid: choose the base plane, then click the base point on it (Enter takes the plane origin). Surface / Patch first asks for the number of grid points in X and Y and the size, then the plane and base point. Push / Pull extrudes and Revolve turns a closed 2D profile (rectangle, circle, ellipse, closed polyline or curve): click the profile in the workspace and enter the height, or the angle and the axis (the sketch's X or Y axis). The profile is used as it is now (also after changes in the sketch editor); repeated points (a polyline closed on its start point) and points in the middle of a straight side are left out. A negative height pushes the profile into the solids it overlaps and cuts a hole (a pocket) of that depth: draw the profile on a face of a solid (or a plane at the face) and enter e.g. −20; every solid it reaches becomes a Subtraction. Push / Pull also takes a Text: click it and the edges of its letters (in the font it is shown with, holes such as in O or B included) become the profiles, one solid for the whole text; a negative height engraves the text. The solid keeps the outline of the text at that moment; Fillet / Chamfer is not available on it. Fillet / Chamfer rounds or bevels the edges of the selected Box, Cylinder, Cone or Push / Pull solid (for Push / Pull the edges along the height).

3D curves are made with four Create 3D commands. Create 3D Curve: click points (a corner or 2D point nearby snaps, on an object its surface, elsewhere the horizontal plane of the last point; a drag on empty space turns the view) and press Enter; a smooth curve runs through them. Projection: click a 2D entity, a 3D curve or an edge, then a face or surface: a 2D entity is projected along the normal of its sketch plane (only the longest part over the face is kept), a 3D curve or edge onto the nearest points of the face. Join 3D Curves: click 2D entities, 3D curves or edges and press Enter: they are chained end to end into one 3D curve (gaps closed with straight lines, the originals stay); with a face selected in Face select, its outline and holes become 3D curves. Break 3D Curve: click a 3D curve where it should be broken: an open curve becomes two curves that meet at the click, a closed one becomes one open curve that starts and ends there (a smooth curve keeps its points; near the break its shape can change a little; the ends cannot be broken). Curve from Robot Path: the tool's path from the current posture to the next one, following that posture's movement type. The Properties window of a 3D curve has Closed and Smooth, the X, Y, Z of its points (up to 30 points) and Edit Curve, which opens a panel below: Control points sets how many points the curve has (it is resampled, as a smooth curve, from its shape before; going down and back up keeps that shape until a point is moved), and Edit by mouse shows the points, as for a curve move in Posture Info (at most 200): drag a point in the plane facing the view (Shift: only its height), double-click the curve to add a point, right-click or double-click a point to remove it. Closing the Properties window or deselecting the curve turns Edit by mouse off. A 3D curve can be used like a 2D entity in Path Pick, Sweep, Surface from Edges and Create Surface Hole; it is not opened in the sketch editor. Create Surface Hole (a Create 3D icon, also in the 3D Editor's toolbar next to Create Offset Surface) cuts a hole into a surface: click the surface - a face of a NURBS part or a Surface / Patch (a selected face or surface is taken at once) - then the 2D outline of the hole (a circle, rectangle, polyline, curve, ...; an open outline is closed from its end back to its start). The outline is projected onto the surface along the normal of its sketch plane and becomes a hole (an inner trimming loop) of that face; it has to lie fully over the surface. A Surface / Patch becomes the same surface in NURBS form. Several holes can be cut one after the other; Undo takes a hole back. Sweep (extrude along a path): click a closed 2D profile, then the path - another 2D entity (line, polyline, arc, circle, curve, ...) or an edge of a 3D solid - and enter Twist (°, the profile turns about the path from the start to the end) and End scale (the profile's size at the end; 1 = the same). The profile is carried along the path from its start without turning about it; at a corner of the path it is cut on the bisecting plane (a mitre), so the section keeps its size round the corner. When the path starts on the profile's plane, the profile keeps its place around that point (draw e.g. a circle on the YZ plane centred where a polyline on the XZ plane starts); otherwise its middle goes on the path. A closed path makes a ring without end caps. Twist and End scale stay editable in the Properties window. Path Pick on a smooth open 3D curve makes one 3D Curve move through its control points: its two ends are the postures, so 6 control points show as 4 points in Posture Info. A curve with many points, such as one from Curve from Robot Path that was not edited, uses up to 32 evenly spaced points. An Arc or 3D Curve move follows its path only when the arm starts at its posture; if the arm is elsewhere, for example after a click while it is still moving, Play Full first goes to that posture with a free move, and a single step goes straight to its target.

Surface from Edges makes a Surface / Patch from 2, 3 or 4 curves: click edges of solids or 2D entities (lines, arcs, polylines, curves, circles, ...) - the picked ones stay highlighted and the prompt counts them - and press Enter (after the fourth curve it goes on by itself; Esc cancels). Then choose the Points along the curves (and, for an outline, Points across). When 3 or 4 curves meet end to end in a closed outline (e.g. the four top edges of a box, or three lines forming a triangle), the patch fills that outline (a Coons patch: it runs along every curve; with 3 curves one side closes in the corner where the third curve ends). Otherwise - and always with 2 curves - the patch goes from curve to curve in the order picked: straight between two, smoothly through three or four; each curve is turned to run like the one before, so the patch does not twist. The curves are taken at equally spaced points; the patch's control points can then be edited like those of any Surface / Patch.

Boolean Operations

Union, Subtraction and Intersection (the last icons of Create 3D Solid) combine solids: click the first solid (A), then one or more others, and press Enter (Esc or Cancel stops). The result is A, changed: it keeps A's place in the object list, A's name and colour and everything linked to A - pick & place, material, animation, group and folder - while the other solids leave the workspace: A ∪ B (everything of both), A − B (A without what B covers, for holes and cut-outs), A ∩ B (only what both cover). The result is a solid like the others - selectable, movable, with its faces, edges and points for the select modes - and it keeps its inputs, so its Operation can still be changed in the Properties window, and it is saved with the workspace. The Properties window shows a solid's History: the solid itself and, for a Boolean result, the steps it was made of (for a box with a pocket: Subtraction, Box, Push / Pull (hole)), nested for results of results. Click a step to see and change its values - the box's width, depth and height, the depth of a hole, the operation of an inner step - and the solid is rebuilt from all its steps. The 2D entity a step was made from is a step too, below the step it made: the Text, Rectangle, Circle, Ellipse, closed Polyline or Curve of a Push / Pull (a solid or a hole), a Revolute or a Sweep, and the path of a Sweep - for a text engraved into a box: Subtraction, Box, Push / Pull (hole), Text. Click it to see the entity's own values (a text's position, wording and height, a rectangle's corner, width and height, a circle's centre and radius, the points of a polyline ...) and change them: the solid is rebuilt, while the entity in the workspace stays as it is. A change that would leave no solid (an outline that is no longer closed, an empty text) is not applied. The curves of a Surface from Edges are listed the same way, for reading only. A solid made in an earlier version, or from points by a plugin, shows the row (Text or 2D profile) without values. A hole cut from a solid's top face stays on that face when the solid's height changes. An object stays the same object when it is changed: a hole pushed into a box that an arm picks leaves the pick & place as it was, and the same holds for a solid that becomes an editable mesh (Scale, Convert to Mesh). A 2D entity keeps its id as well - through edits, Undo and Redo, and when the workspace is saved and opened again; of a broken 3D curve the first piece is still that entity. A result can take part in further operations. The meshes are combined with binary space partitioning (CSG); the result stays watertight. Booleans work on the solids made here, not on imported STL objects.

Group and Ungroup (after the Boolean icons): Group puts the selected objects (3D solids, STL objects - with none selected it asks for them: Shift + click adds one, then Enter or Group again) into a new folder Group-N in the folder they share (their own sub folders below it stay) and makes them act as one object, as the bodies of a STEP import of several parts: a click on one of them in the workspace selects them all, so they move and turn together (Shift + click adds or removes the whole group; a single component is still picked in the Objects list). A group can be grouped again; the outer group then acts as the object. Ungroup takes apart the group of the selected object (with none selected it asks for one) - or the folder it is in, for example a STEP import of several bodies: its objects, with their sub folders, move to the folder above it and the folder is removed; an inner group stays a group. Groups are saved with the workspace, and Undo works on both. From a plugin: breakCurve(entityId, [x, y, z]), groupWorkspaceObjects([indices]), ungroupWorkspaceObject(objIdx) and getWorkspaceObjectGroup(objIdx).

Properties

Selecting a 2D entity (a click on it in the workspace), a solid or an imported object opens the Properties window at the right edge of the app window (drag its title bar to move it elsewhere; it stays there). Its first row, Visible, hides or shows the selection: a hidden object, solid or 2D entity is not drawn and cannot be picked in the workspace (select it in the object list to show it again), and the setting is saved with the workspace. For an imported object the window has only that and the Transform / Rotate / Scale / Set Pivot / Bounding Box / Material buttons described below (position, rotation and colour are also in the object window). Only one thing is selected at a time: selecting an object deselects the 2D entity and the other way round, and Esc deselects. For a 2D entity the window has a field for everything that can be changed - start and end of a line (with its length), corner, width, height and, for a rounded rectangle, the Corner radius; centre and radius of a circle, start and end angle of an arc, the radii of an ellipse, the points and Closed of a polyline or curve, text and height of a text - then Rx, Ry, Rz, the orientation of the entity (its base plane, turned by the entity's own angle in the plane) with R = Rx·Ry·Rz as for objects: a rectangle drawn on the XY plane at 30° shows 0, 0, 30, and changing the values turns the entity and its plane about the entity's reference point (corner, centre or insertion point), so it can be stood up or tilted - and Plane offset: the offset of the entity's base plane as it was entered when the entity was drawn (along Z, Y or X for the XY, XZ and YZ planes; for a plane on a solid's face, its distance from the origin along its normal). Every change shows at once. With Show Pivot on (Settings, or the Show Pivot button at the bottom of the select mode strip, lit while it is on - both do the same; below it, Show XY Grid shows or hides the floor grid of the view and Show World Axis the X, Y, Z axes from the origin (off in the workspace when the app starts); below that, Show TCP draws the tool centre point of the active arm (a cross, TCP) and a rectangle around it across the tool axis: in the plane x = the TCP's x in the tool's frame (the flange at the origin, +X the tool axis - the plane offset of the tool editors' YZ plane), centred on the TCP, as large as the bounding box of the last joint or of the attached tool across the axis. It follows the arm in the workspace and the 3D Editor, sits in tool coordinates in the tool editors (Create / Edit Tool, Pick Tool Offset), and in the sketch editor it is shown as a reference when it lies in the sketch plane (e.g. YZ with that offset in a tool editor). It is not an object - it cannot be selected or deleted - but its corners and the TCP snap, in the 3D view (Pick TCP point, Measuring Tool) and in the sketch - in the 3D Editor both are the same as its toolbar's switches), the selected 2D entity has its own pivot: drag the red (X) or green (Y) arrow to move it in its plane, the blue (Z) arrow to move its plane along the normal (the Plane offset follows).

While a command asks you to click something (an object, a 2D entity, a face, an edge, a point, a surface), the click does not open a closed Properties window; click the object again afterwards to open it. The object clicked blinks twice to show it was taken, and is not left selected afterwards - except where the command goes on with it: the first solid of a Boolean (Union, Subtract, Intersect) and the solid of Fillet / Chamfer stay selected. Clicks on a face or an edge (Projection, Create Surface Hole, Path Pick, Surface CAM) select nothing; their object only blinks. A window that is already open stays open and follows the selection.

For a solid the window shows its characteristic values - width, depth and height of a box, radius and height of a cylinder, base and top radius of a cone, top scale of a pyramid, the angle of a revolved solid, edge type and size, and so on. A changed value rebuilds the solid at once. Position and rotation are set in the object window or with the mouse, as for every object.

Complexity (Low / High, below Visible, for solids and imported objects): an object with more than 10 000 vertices (distinct points, so a solid, its mesh and its STL count the same) is High, every other one Low; this is set when an object is imported, loaded with a workspace, created, copied or rebuilt, and the tooltip of the box shows the count. It can also be set here by hand (it then stays, and is saved with the workspace). The commands on an object of high complexity show the progress window while they work - the Transform / Rotate / Scale / Set Pivot buttons, Duplicate, Array (the share of the copies made), Convert to Mesh, Join, Create Offset Surface, Edit surface/patch and the Boolean operations; on objects of low complexity they run at once without it. Importing STL and STEP files always shows the progress window (per file and, for STEP, per body).

For objects and solids (one, or several selected with Shift) the top of the window has six buttons; each opens its panel below them (a second click closes it):

  • Relative values (a box at the top of Transform, Rotate and Scale, on by default): the values are a change - a distance, angles, factors - as described below. Unchecked, the fields show the current values and take the new ones: Transform the world X, Y, Z of the pivot (several objects: the middle of their bounding box), Rotate the angles Rx, Ry, Rz of the object (each object is turned to them about its own pivot), Scale the size X, Y, Z (mm) of the bounding box (with Uniform the other two sizes change in proportion).
  • Transform - dx, dy, dz (mm): Apply moves the selected objects by that much.
  • Rotate - Rx, Ry, Rz (°): Apply turns the selected objects about the world X, then Y, then Z axis through the pivot of the object (several objects: the middle of their bounding box), relative to how they are now; the object window shows the new angles.
  • Scale - factors X, Y, Z (1 = unchanged, 2 = double, 0.5 = half) along the world axes, about the pivot of the object (several objects: the middle of their bounding box). With Uniform (on by default) changing one factor sets the other two to the same value. The scale is built into the geometry: an imported (STL) object, a NURBS solid (STEP import, exact), a Surface / Patch and an editable mesh keep their kind; a solid made of parameters (Box, Cylinder, Cone, Push / Pull, Boolean, ...) becomes an editable mesh, as when a face of it is moved.
  • Set Pivot (one object) - the pivot is the point the object's gizmo sits on and turns it about, and the point Rotate and Scale use; by default it is the object's origin. Enter its world X, Y, Z or fill them in with a button - Box center, Bottom center, Top center, Min corner (points of the bounding box) or Object origin - and click Apply. Rx, Ry, Rz (R = Rx·Ry·Rz) turn the pivot's own axes: the axes of the gizmo, along and about which it moves and turns the object, and the orientation that From Object and the Task Editor (bottom panel, dragging an object onto a posture) use; until set they are the object's axes, and Object origin also fills them back in. With Relative on, the fields are steps from the current pivot (dx, dy, dz and dRx, dRy, dRz about the world X, then Y, then Z axis), the buttons fill in the step to their point, and the fields return to zero after Apply. With Move by mouse on (it also turns Show Pivot on), dragging an arrow of the gizmo moves the pivot along that axis while the object stays, and the X, Y, Z fields follow; the rotation arcs and dragging the object itself work as usual. Closing the Properties window, or deselecting the object, turns it off. The object window's position fields and list, and From Object in the XYZ and XYZ & Orientation windows, use this point; a position typed there moves the object so that its pivot gets there. The object does not move; the pivot moves with it from then on (also when it is scaled), and it is saved with the workspace.
  • Bounding Box - the size of the selection along X, Y and Z (mm) and its minimum, maximum and center point.
  • Material - what the object is made of when the view is drawn with Render Quality Realistic: Metal, Metal shiny, Plastic, Ceramic, Glass, Light (glowing) or Texture (an image on the whole object or on chosen faces), and whether it casts a shadow. See Materials.
  • Animation parameters (the Animation group below the buttons; the label beside it shows the object's transform mode: Static, Keyframed or Dynamic) - opens the animation parameters of the object, or of its group: transform mode, start and end position and orientation, transition time, repeats, keys and physical properties; for a camera, its target or a light also their own values. See Animation.

All these changes can be undone with Undo.

Surface / Patch

From a face: in the Surface / Patch window, Select Face takes the face selected in the Face select mode, or waits for a click on a face of a solid (the window moves aside; Esc cancels). Width and Depth are then off - the face gives the size - and Next creates the patch right away, with the Grid points X and Y as its control points, fitted to the face: a face of an imported STEP part over its exact surface, any other face from the plane that fits it best (its sides along the face's smallest bounding rectangle), so a face that bends back over itself (a whole cylinder) gives the half that faces that plane. The solid itself stays as it is. From a plugin: surfaceFromFace(objIdx, face, nx, ny).

The surface is the cross product of Catmull-Rom splines through its grid of control points (Resolution sets the number of segments between two points). When a surface is selected, its control points and the curves through them in X and Y are shown: drag a point to move it in the view plane, or hold Shift to move it only along the surface normal. Double-click a curve to add a point there; a point is added at the same place on all the curves of that direction, so the grid stays regular (a new column on an X curve, a new row on a Y curve, at most 30 in each direction). Right-click a point for Remove column (X) or Remove row (Y) (at least 2 stay). Changing the number of grid points in the Properties window resamples the shape as far as possible.

3D Editor

The 3D Editor button (below Edit sketch in the strip at the right edge) opens a view for modelling: the workspace camera from the start view, aimed at the middle of the object(s) selected at that moment (an imported STL object or a solid) or, with nothing selected, at the origin (0, 0, 0) in an empty view. Only those objects are shown, together with everything created meanwhile - no robots, paths, rails or tables. The mouse turns, pans and zooms as usual (the wheel zooms in steps, also close to a small part). Click the button again or ✕ at the end of the toolbar to go back: the workspace, its camera and the windows that were open come back as they were, the new objects stay. The messages of the editor's commands show in a line at the top, below the toolbar; their results (e.g. the deviation of a Join NURBS Faces surface, an offset, the triangles of a converted mesh, the copies of an Array, a duplicate) are written to the console as well, so they stay; hints such as "Select an object first" only show at the top.

  • Left menu - Create 2D and Create 3D (with Sweep) in place of the robot menus.
  • View cube (top right) - click a face (Front, Back, Top, Bottom, Left, Right) to look straight at that side in a parallel (orthographic) view: no perspective, so edges keep their true lengths and directions and 2D objects can be drawn and picked exactly. Zooming and panning keep the parallel view; turning the view - dragging in the view or dragging the cube - or the house below the cube (the start view, fitted to the selection or, with nothing selected, to all objects shown) goes back to the perspective view.
  • Toolbar, first group (switches, on when the editor opens): Show/Hide World Axis (the X, Y, Z axes from the origin, red, green, blue, with their names), Show/Hide CoordSys Planes (the XY, XZ and YZ planes from the origin, semi-transparent, 30 % of the view), Show XY Grid (the floor) and Show Pivot.
  • Second group: Duplicate (the selected object - or, with none selected, click the object - then click the point where the copy's pivot goes, on the horizontal plane through the object's pivot), Move, Rotate, Scale and Set pivot (they open that tool of the Properties window for the selection) and Show Bounding Box (a switch: the box of the selection with its size along X, Y and Z).
  • Third group: Edit surface/patch - a Surface / Patch shows its control points and parameters (drag the points, see Surface / Patch below); with a face selected in the Face select mode (or a NURBS part of one face) it first asks for the number of points and makes a Surface / Patch of that face. Join NURBS Faces - Face select comes on: click a face, Shift+click the others (faces of one part, e.g. two panels of an imported car body, or of several parts), then press Enter and choose the grid of the new surface (Grid points X, Y, 20 x 20 by default, up to 30 x 30; more points follow curved faces more closely). The faces become one new NURBS surface: a bicubic surface fitted to them (seen from their mean plane, by least squares, smooth across the gaps between them) and trimmed to their joint outline (the edges the faces share disappear, outer outline and holes stay), so it covers exactly their area as one face - e.g. for Surface CAM over several faces at once. The message gives the largest distance of the faces from it. By default the new face replaces the selected faces in their part: it goes into the part of the first face clicked, the selected faces leave their parts (a part left without faces is removed) and the edges they shared go with them - Undo brings them back. With Create a new surface checked, the surface becomes a new part of its own and the parts stay as they were (always so for faces of solids other than NURBS parts). The faces should face roughly one way: a fold of more than about 90° cannot be fitted this way. Esc cancels. With two or more parts (NURBS or Surface / Patch) selected in Object select, Join puts them together into one part with all their faces instead. Create Offset Surface - new surfaces at the given distance (mm, along the surface normal; negative: the other way) from the faces selected in the Face select mode (Shift+click adds a face or removes one; the selected faces are shaded orange) - one new part per part they belong to: exact offset surfaces trimmed like the faces for a NURBS part, an editable patch for a Surface / Patch, an open mesh for the faces of other solids and STL objects. With no face selected it offsets the selected Surface / Patch objects.
  • Fourth group: Convert to Mesh - the selected solids become plain triangle meshes like an imported STL (their parameters and history are gone; Undo brings the solid back). Array - copies of the selected objects: XY (columns along X, rows along Y, their spacing), XYZ (also layers along Z), Circular (a count around an axis X, Y or Z through a center point, over a total angle: 360° spreads them evenly, less puts the last one at that angle), Cylindrical (circular, repeated in levels along the axis with a level spacing) and Spherical (a count around the axis on rings that step by the ring angle towards the axis, as on a sphere about the center). With Rotate copies the copies turn with their place on the circle, otherwise they keep their orientation. At most 500 copies at once.

Objects Explorer

At the very top, 2D Entities & Curves lists every 2D entity and 3D curve under a Workspace folder, closed at first, with their number; click the folder to open it. A click on an entry selects it and opens its Properties window, also when its Visible is off (the entry is dimmed), so a hidden entity can be found and shown again. The checkbox column at the left shows and hides entities, as Visible in Properties does: an entry's box that entity, the Workspace folder's box all of them (checked: all shown, unchecked: all hidden, a dash: some of each); a click on a box selects nothing. While a command asks for an entity, a click on the list picks it.

Below it, the window shows the workspace objects as a tree: the workspace folder with its folders and sub folders (click the arrow, or double-click a folder, to fold it open or shut; the number is the count of objects inside) and the objects in them. Click an object to select it; click a folder to make it the selected folder and to select all objects in it and its sub folders. Several objects: hold Shift and click more objects - in the tree or in the 3D view - to add them to the selection (Shift + click on a selected one takes it out again), or Shift + click further folders to add their objects. All selected objects are highlighted; the last one clicked is the active one (the position, rotation and colour fields act on it). Moving with the mouse moves all selected objects together: drag a selected object (the point you grab stays under the mouse, in its horizontal plane), drag an arrow of the gizmo (they move along that axis as far as the mouse moves along the arrow), or drag a rotation arc (they turn by the angle the mouse sweeps round the gizmo; the other objects turn about the active one). With several selected, the Properties window shows their number and one Visible box for all of them (half checked when some are hidden), and Remove Object removes all of them after a question. Create folder adds a folder in the selected one and lets you type its name, Rename renames the selected folder (Enter keeps the name, Esc cancels), and Delete removes it with its sub folders and, after a question, the objects in them. Drag an object or a folder onto another folder to move it there. Add Object opens a small menu: Files (.stl, .step) imports the chosen files into the selected folder; Folder imports a whole folder: a folder of the same name is made in the selected one, with its sub folders, and every .stl, .step and .stp file in it is imported into the folder it lies in. The folders are saved with the workspace, and on export the STL of every object is written into the matching sub folder of the workspace folder (an import of that folder finds it there again). The checkbox column at the left shows and hides objects, as Visible in Properties does: an object's box shows or hides that object; a folder's box all objects in it and in its sub folders, for example all components of an imported STEP assembly (checked: all shown, unchecked: all hidden, a dash: some of each). A click on a box does not select anything.

STEP Import

Add Object also reads STEP files (.step / .stp, AP203, AP214 and AP242 B-rep geometry, the common exchange format of CAD programs). Every body of the file becomes a NURBS solid; an assembly gives one solid per part instance, named after its product, in its colour from the file. The solids go into a sub folder named after the file in the selected folder of the Objects Explorer; the parts of (sub)assemblies go into nested folders named after the assemblies (an assembly used more than once gets a number per instance). Planes, cylinders, cones, spheres, tori, surfaces of revolution and of extrusion, B-spline and rational B-spline (NURBS) surfaces and offset surfaces are read exactly; edges may be lines, circles, ellipses, B-spline curves or polylines. The length unit of the file (mm, m, inch, ...) is converted to mm. The parts keep their places relative to each other; the whole import stands with its bottom centre at x 800, y 0 on the floor - move it with the object window. The console reports the number of bodies and faces, and names anything that could not be read (e.g. an unsupported surface type: that face is left out). A large file (a whole robot of 60 parts) takes a few seconds: a progress window shows the file and the body being built; Cancel stops the import after the current body (the bodies read so far stay in the workspace). The same window shows the progress of Add Object with several files or a folder.

NURBS Solids

A NURBS solid consists of faces, each a NURBS surface trimmed by loops of edges: its faces and edges are the real ones of the model, so Face select picks a whole face (a planar face can be a base plane for sketches), Edge select and Path Pick follow its true edges, and Surface CAM can work on any of its faces. Each face is triangulated in its surface parameters; Tolerance (mm) in the Properties window is the largest distance of the triangles from the exact surface: smaller values give a finer mesh (a very fine one is coarsened automatically). The solid is saved with all its geometry in the workspace and rebuilt on import. From a plugin, createSolid('nurbs', { surface: { du, dv, ku, kv, cp, w } }) makes one NURBS surface and importStepText(text, fileName) imports the text of a STEP file.

Saving

The workspace (.brw) keeps the type and values of every solid and all sketches, so they stay editable after an import; an STL of every solid is written to the workspace folder as well.

precision_manufacturing

Multiple Robot Arms

A scene is no longer limited to one arm. Add as many robots as the cell needs, place each one at its own base position and program them side by side - from the interface or from a plugin. Below, two arms driven by one plugin, with the console reporting the run.

Two robot arms in one scene, driven by a plugin

Arms And Slots

Each arm is a slot with its own model, base position, posture queue, trajectory and pick & place state. Workspace objects are shared, so two arms can hand parts to each other.

Open precision_manufacturing Robot Model: the chips at the top of the window list the arms as 1: Model [x, y, z]. The outlined chip is the active arm - the one the joint / XYZ controls, the posture queue, pick & place and the plugin API act on. Click a chip, or click any part of an arm in the viewport, to make it active.

add Add Robot
Adds an arm with the active arm's model, offset along X so the two do not overlap. Pick another model in the gallery afterwards if needed.
remove Remove Robot
Removes the active arm. One arm always stays.
my_location Base position (mm) / rotation Rx Ry Rz (°)
World X / Y / Z of the active arm's base and its rotation about the X, Y and Z axes (composed as Rx · Ry · Rz, the same convention as the STL objects; Rz alone turns a floor-mounted arm, Rx / Ry tilt it for wall or ceiling mounting). Apply (or Enter) moves and turns the arm together with its gizmo, a carried object and its drawn path. Position, angles and the resulting 3×3 rotation matrix are saved with the workspace (.brw) and restored on import.

Working With Several Arms

  • 1. Pick a model in the gallery: it replaces the model of the active arm only.
  • 2. Queue postures per arm as usual; the [current/total] counter follows the active arm.
  • 3. Play Full Sequence runs every arm that has postures at the same time. Play Once and Play Back step the active arm only.
  • 4. Pick & place is per arm: select the object, then pick / drop on the active arm's postures. An object carried by one arm is drawn with that arm.
  • 5. XYZ coordinates, tool normals and every world position in the API are absolute scene coordinates, i.e. they include the arm's base position and base rotation; forward and inverse kinematics convert to and from the arm's own frame.

Workspaces (.brw, version 2.1) save all arms with their base positions, postures and pick & place. Older single-arm files still load as one arm at the origin.

From A Plugin

Robot-related API calls take an optional trailing robotIdx. Arms play concurrently, so start each one and they move together:

// second arm 1.5 m along X, same model as the active one
const b = await brwAPI.addRobotArm(-1, [1500, 0, 0]);

for (const k of [0, b])
{
  const q0    = await brwAPI.getCurrentJointAngles(k);
  const start = await brwAPI.getCurrentWorldPosition(k); // base included
  const path  = await brwAPI.worldToJointAnglesBatch(wpos(start), q0, null, k);
  await brwAPI.simulateRobotMotion(steps(path), k);       // returns at once
}
handyman

Tools

Attaching A Tool

Open view_in_ar Tools & Objects → Tools. Import Tool (3D) reads one or several STL or STEP (.stp / .step) files into the tool list (named after the file); a STEP file with one body becomes one NURBS solid in the file's own coordinates (its origin is the tool's attach point, +X its axis), and the tool stays that solid: Edit Tool and Pick Tool Offset open the exact NURBS solid, and the workspace saves its NURBS data in the .brw and rebuilds the tool from it on loading (its STL is still written, as a copy for other programs). A tool made of a 3D solid (Import from Workspace, Create Tool, Edit Tool) stays a solid in the same way; the tool list marks such tools solid, STL tools stl. A STEP file with several bodies, or several objects made into one tool, gives a tool of components (marked solid ×N, N components): each component is kept as it is in a STEP import to the workspace - its own NURBS solid (or solid, or for an STL object its triangles) with its name, its original colour and its sub folder (the assemblies of a STEP file, or the objects' folders) - and the arm draws each component in its own colour; the tool colour applies only to components without one. Edit Tool and Pick Tool Offset open the components in a folder named after the tool, each in its sub folder. Select a tool in the list and press Attach Tool: it replaces the arm's default end effector (the 7th part of the model) and the arm's tool point moves to the tool offset - dx / dy / dz from the flange, which take the place of the 7th row of the robot's .rob file. Kinematics, the XYZ read-out, the drawn path, the pivot gizmo and pick & place all work at the tool point. Detach Tool puts the original end effector and offset back. Remove takes the selected tool out of the list (and out of the exported workspace); a tool still attached to an arm must be detached first. Import from Workspace makes a tool of a workspace object - an imported STL object or a 3D solid: the selected one, or the one clicked next (Esc cancels); its pivot is the tool's attach point (the flange) and its orientation in the workspace the tool's (its +X is the tool axis), and the object stays in the workspace. With several objects selected (Shift + click, or a click on a folder in the Objects Explorer, e.g. the folder of a STEP import), they become one tool of components named after their folder; the pivot of the active object is the attach point. Create Tool opens the 3D Editor, empty, with a bar under its toolbar: model the tool as a 3D solid with the Create 3D commands - the origin is its attach point, +X the tool axis - and click Done; with several objects made, they all become the tool's components. The tool goes into the list (the objects leave the workspace) and can be attached like the others. Edit Tool (enabled when a tool is selected in the list) opens the 3D Editor with that tool at the origin, not selected (click it to select it): move, rotate or scale it (Properties), or change it otherwise, and click Done - the tool takes the new shape, also on every arm it is attached to. Every visible object in the editor then belongs to the tool: add an object and it becomes a component, hide or delete one and it is left out. Cancel or ✕ leaves everything as it was. Pick Tool Offset (with a tool attached) opens the 3D Editor with the attached tool (shown, not selected). Click Pick TCP point (on the bar, before Done), then the tool centre point: within 10 px it snaps to a 2D Point of a sketch or to a corner (vertex) of any object in the editor - the tool, a solid or a mesh - also beside the objects; elsewhere on an object it takes the surface point. A marker shows the snap target under the mouse (round when it snaps), a red cross the kept point, and the message its coordinates. The point is only kept: pick again to change it. Done puts the kept point into dx, dy, dz, applies the offset and closes the editor (without a picked point it asks for one). The editor's tools can be used meanwhile, e.g. to draw a 2D Point where the TCP should be. Cancel or ✕ leaves everything as it was; Esc only deselects, as everywhere. In all three tool editors (Create Tool, Edit Tool, Pick Tool Offset) the Create 2D commands and the sketch editor work as in the 3D Editor - for example for a profile to push / pull or revolve, or a 2D Point where the TCP should be - but those 2D entities are scratch: when the editor closes (Done, Cancel or ✕) they are deleted, and neither the workspace nor the tool keeps them. The workspace's own 2D entities are not shown in a tool editor and are back unchanged afterwards (a workspace saved meanwhile has them, not the scratch ones). Tools made from solids are saved with the workspace as solids (their parameters or NURBS data), with an STL copy. In pick & place, a 3D solid is carried like an imported object. A changed tool offset moves the tool point of every saved posture with it (the joint angles stay). Recalc postures (under the tool colour) gives the active robot's postures back the tool pose they had: the app remembers the tool offset the postures were made with (taken when the tool point first changes after postures exist: offset changed, tool attached or detached), and on the click the position and orientation of each posture's tool point with that offset are kept and the joint angles are solved for the current tool; rail travel, table angle and base position stay. The arm moves to its own pose with the current tool the same way, and the current offset becomes the reference. A posture that cannot be reached with the current tool keeps its joints, and the console names it. Click it after changing the tool and before teaching new postures with it.

Model a tool with its attach point at the origin and pointing along +X; on attach it is moved to the flange (the sum of the model's joint translations, rows 1 … 6). With no tool attached, the offset fields show the .rob values read-only; with a tool they and the colour picker edit the attached tool at once.

Saved With The Workspace

The tool list (names and STL file names) and each arm's attached tool with its offset and colour are written to the .brw; on import the STLs are read from the workspace folder by name, like the other objects, and re-attached. Keep the tool STL files next to the .brw. Solid tools and tools of components are rebuilt from the .brw itself (their solids, names, colours and folders); a tool of components is also written as one STL per component in a folder named after the tool (with the components' sub folders), as the objects of a STEP import are, for other programs.

From A Plugin

getToolNames() lists the imported tools, attachRobotTool(name, offset, color, robotIdx) mounts one (replacing a mounted tool), detachRobotTool() removes it, setRobotToolOffset() / setRobotToolColor() edit it and getRobotToolInfo() reads it back. A plugin cannot read files, so tools are imported in the Tools window or come with the workspace.

const tools = await brwAPI.getToolNames();          // e.g. ['gripper', 'welder']
await brwAPI.attachRobotTool('welder', [150, 0, 0]); // tool point 150 mm from the flange
// ... run the path ...
await brwAPI.detachRobotTool();
conveyor_belt

External Axes

Linear Rail

Open view_in_ar Tools & Objects → External Axis. The window works on the active arm and has two panels. The top one is a linear rail: base position (bottom of the rail, at its start, centred on the profile), the translation vector the carriage moves along, the profile width / height plus the length, and the carriage motion: Velocity max (mm/s), accel. (mm/s²) and ramp-up time (s), see Postures And Simulation. Add linear axis generates the rail base and its carriage and puts the arm on the carriage - the arm's base becomes the rail start, one rail height up.

Drag the carriage in the viewport to move it (the arm rides along); it stops at the rail ends (0 … L). Hold SHIFT while dragging to keep the manipulator where it is: the base slides along the rail, but the tool keeps its world position and orientation (the joints are re-solved each step, and the carriage stops where the pose would leave the joint limits or the reach). Each arm can have one rail; Remove axis takes it away and leaves the arm where it stands.

Rotary Table

The bottom panel adds a rotary table (external positioner): base position, rotation Rx / Ry / Rz of the table, radius and height, and the table motion: accel. (°/s²) and ramp-up time (s). Import workpiece STL puts a part on the turntable, one table height above the base, centred on the rotation axis. Select Workpiece does the same with an object already in the workspace: the list Workspace objects below the buttons shows all of them, click one (or the object in the viewport) and then Select Workpiece; the object keeps its orientation and a copy of it is put on the table (a CAD solid becomes a plain mesh there). With Delete the object from the workspace after Select Workpiece checked, the object itself is removed from the workspace, otherwise it stays where it is; the Workpiece row names the STL that sits on the table (or the Mill / Sculpt blank), and the colour picker sets its colour (saved with the workspace). Drag the turntable or the workpiece to turn them together; the table does not move the arm.

Once an axis exists its fields are read-only. The lock chip next to the arm name (as in Joint Control) unlocks them: every change is applied at once - the rail or table is rebuilt, the carriage keeps its travel and the arm stays on it.

Postures And Simulation

When an arm owns an external axis, a saved posture carries the rail travel, the table angle and the arm's base position along with the six joint angles. Playing the queue then moves the rail, the whole arm and the turntable together with the joints: every axis follows a trapezoidal velocity profile with the same ramp-up, cruise and ramp-down times, so they start and stop together. Each axis first gets its own profile: the joints from the velocity setting and the Joint acceleration settings (see Settings), the rail from the velocity setting times its Velocity max, with its own accel. limit and ramp-up time, and the table from the velocity setting times one turn per second with its own accel. and ramp-up time. The move then takes the longest ramp and the longest ramp plus cruise of all axes, so no axis moves faster or accelerates harder than it would alone; the slowest axis sets the pace. Line, Arc and 3D Curve moves pace the tool along the path with the same ramps. The drawn path follows the arm along the rail.

Rails and tables are saved in the workspace (.brw) and rebuilt on import; the workpiece STL is loaded from the workspace folder by name, like the other objects.

From A Plugin

addLinearRail() / addRotaryTable() create the axes (a rail has a base position and a rotation rot: [rx, ry, rz], composed Rx·Ry·Rz like the robot base; its travel direction dir is the rotated +X and is returned by getLinearRail(); the optional vMax (mm/s), accel (mm/s²) and ramp (s) set the carriage motion, a table takes accel (°/s²) and ramp (s); the robot is mounted on the carriage, so moving or rotating the robot base takes the rail along and rotating the rail turns the robot), setRailPosition() (mm) and setRotaryTableAngle() (degrees) move them, and simulateRobotMotion(jointSteps, robotIdx, railSteps, tableSteps) plays joints, rail and table together - one delta per step, rail in mm, table in degrees, shorter arrays padded with zeros. Postures from getRobotPostureArray() carry [j0..j5, travel, angle (rad), bx, by, bz] and trajectory steps from getRobotTrajData() carry the rail / table deltas as elements 6 and 7 when an axis exists; the workpiece STL can only be attached in the interface.

// rot = [rx, ry, rz] in degrees, or dir: [tx, ty, tz] instead;
// with neither the rail is aligned with the robot base
await brwAPI.addLinearRail({
  basePos: [0, 0, 0], rot: [0, 0, 0],
  W: 500, H: 300, L: 3000
});

const q0    = await brwAPI.getCurrentJointAngles();
const steps = 100;
const rail  = Array(steps).fill(2000 / steps);   // 2 m along the rail
const table = Array(steps).fill(90 / steps);     // a quarter turn

await brwAPI.simulateRobotMotion([], undefined, rail, table); // joints stay
carpenter

Mill / Sculpt

Setup

Robot milling of a blank on the rotary table. The active arm needs a rotary table (Tools & Objects → External Axis); a linear rail is optional. With a rail the arm's base moves along it to the best position for each layer or path; without one the base stays where it is, so the table must stand within the arm's reach, and Base distance to tool is disabled. Open carpenter Mill / Sculpt: Import target STL loads the object to be milled (it is centred on the table axis and set on the table top); a workpiece put on the turntable in the External Axis window (Import workpiece STL or Select Workpiece) is taken as the target as well, when the window opens or at once while it is open, and the newer of the two counts. Calc bounding box fills the box size W, D, H with the object's bounding box (whole millimetres, rounded up; edit the values to leave more material), and Create blank puts a box of that size on the table as the workpiece. Instead of a box, the blank can be any 3D object: choose 3D object under the panel title, then a workspace object in the Blank object list (with its present rotation) or Import blank STL; Create blank puts it on the table, centred on the axis and standing on the table top, with the layers spread evenly over its height (the box fields and Calc bounding box are off then). The blank is modelled like the target, as its outer radius around the table axis at every layer and angle, so holes, pockets and undercuts of the blank object count as material. Where the target sticks out of the blank, a warning says how much of its surface that is; there it simply stays as the blank. An object blank is saved with the workspace and restored on import. The target must fit inside the blank; the order does not matter, the target's profile is computed whenever both exist. Layer height and angular step are the resolution of the workpiece model; the tool diameter, the depth of cut per pass and the distance the rail keeps between the robot base and the tool line (with a rail) are the milling parameters. The Milling panel offers three ways of making the program: Basic sculpt, Artistic sculpt and Chamfer / deburr (see How The Program Is Made). No-mill offset top, bottom (mm) leaves a band at the top and at the bottom of the stock unmilled, e.g. where the part is clamped: only heights from the bottom offset up to the stock height minus the top offset are cut (0 and 0: everything). Basic sculpt and Chamfer / deburr have one pair; Artistic sculpt has one for each phase, Phase 1 for the roughing layers and Phase 2 for the finishing passes, so the finishing may go further up or stay further away from the clamp than the roughing. Material left at the top is above the tool's path to the lower layers: keep the top offset small or set the approach angle accordingly. Finish allowance is what the artistic roughing leaves for the finishing pass; Offset, depth are the chamfer passes' start outside the surface and end inside it. Tool approach angle tilts the tool from the horizontal (default 45°): it points at the table axis from above, so the tool body stays outside the material below the tip. Max table speed (°/s, at speed 1) limits the rotary table: near the axis one cell would otherwise pass under the tool in a single step. Creating the blank and importing the target show the progress popup as well.

How The Program Is Made

The workpiece is described as a radius for every angle and height around the table axis; the target object is converted to the same form by rays from the axis, so shapes with undercuts along the radius are milled to their radial silhouette. The tool points at the axis from one direction, tilted down by the approach angle, and the table turns the material under it: one turn mills one layer. Layers go top-down in passes of at most the depth of cut; between two cells the tool moves radially first when the radius grows and turns first when it shrinks, so every cell ends exactly at its target radius. For each layer a few rail positions are tried and the one with the best worst-case Jacobian conditioning inside the joint limits is used; the rail moves with the arm frozen, and the arm then travels to the new clearance pose with a joint move (trapezoidal profile). Steps are spaced by a constant travelled distance derived from the simulation velocity, so the surface speed stays near constant. When the program is ready, the active posture of the arm gets the Milling Program movement type with it (a queue without postures first gets the arm's current pose as posture 1).

Basic sculpt is this layer-by-layer program alone: the tool keeps the approach angle, so every surface is milled with the same tool attitude, as a roughing cut.

Artistic sculpt works like a sculptor: first the roughing of Basic sculpt, stopped a finish allowance (default 1 mm) short of the target, then surface passes with the tool axis normal to the surface, which remove the facets the layered roughing leaves. With Skip basic (phase 1) checked there is no roughing: the surface passes work down from the blank to the target, at most one depth of cut apart, and a pass only runs the paths that still have material in front of the tool. The fields of phase 1 (finish allowance, No-mill offset (Phase 1)) are disabled then. This leaves no layer steps at all, but the passes with the tool normal to the surface take much longer to generate and to run than the layers. Chamfer / deburr needs no blank: the imported target is the workpiece itself (placed on the table when the program is generated) and the same surface passes run on it, starting Offset millimetres outside the surface and ending Depth millimetres inside it, at most one depth of cut apart; the passes inside the material cut. With offset and depth both 0 the single pass runs on the surface: a polishing or deburring run without removal.

The surface passes are made the way robotic deburring and polishing CAM makes them, so that the tool orientation changes slowly and the arm stays away from its singularities:

  • 1. Sub-surfaces. The target surface is split into regions of similar normal (neighbouring cells whose normals differ by less than 20°, and by less than 45° from the region's first cell), so no path crosses an edge where the normal flips.
  • 2. Path direction. In each region the paths run in the direction in which the normal changes least per millimetre: around the axis (the table turns, one continuous path per layer, the usual choice) or, when the normal is clearly more constant along the axis, as meridians the tool drives up and down in turn.
  • 3. Orientation smoothing. Along a path the normal directions are averaged over about 20 mm, their turning rate is limited to 2° per mm, and the result may deviate from the true normal by at most the Tilt tolerance (default 30°); deburring and polishing tolerate such a tilt, a chamfer tool is symmetric about its axis.
  • 4. Singularity avoidance. Every pose is solved with the arm's configuration in view: the IK solution nearest to the current joint angles is used (never a flipped wrist or elbow), and a pose counts as near-singular when its conditioning is six times worse than the best one on the way, when the wrist's middle joint is within about 15° of zero (the tool axis in line with the forearm, where the two outer wrist joints spin), or when a single step would turn a joint by more than about 14°. The tool is then tilted in 6° steps, towards the approach direction, sideways along the path or upwards, inside the tilt tolerance (and beyond it, up to 50°, when nothing else helps), until the pose is sound. A point that still has no sound pose is skipped rather than flipping the arm. The status line reports how many points were tilted, how many beyond the tolerance, how many stayed near-singular and how many were skipped. The tool elevation is kept between 85° downwards and 40° upwards, so the tool always comes from above or the side.

Between paths the tool retracts to the clearance radius, the table brings the next path's start under it and the tool approaches again; neighbouring paths continue without lifting.

Simulation

Generate milling program shows a progress popup that advances one layer at a time and has a Cancel button. Start simulation remembers the arm, rail and table state of the first run (the pre-milling state); every run first returns there with a free move (trapezoidal velocity profile, the table by its shortest turn) - a run started again after Stop comes back from wherever it was interrupted - then moves to the program's first state and plays the program like Play Full Sequence, moving arm, rail and table together; the workpiece mesh is carved live, step by step, so at the end it is the target object. The generated program can also be the move of a posture in the queue: choose Milling Program as its movement type in Posture Info (see Interactive Controls → Movement Types). Layers are milled top-down, so at first only the top of the blank changes. Speed is the number of planned steps played per frame (1 keeps the planned surface speed; 5 or more makes the carving visible at a glance). The pause button pauses and resumes, stop ends the run, and the two arrows jump 10 % of the program backwards or forwards: the arm, rail and table are put into the state of that step and the workpiece is rebuilt from the blank up to it. The status line shows the step, the percentage and the share of the blank already removed. Programs are long (a 200 mm box to a 100 mm object is about a hundred thousand steps), so the path line is not drawn for them.

Limits

The tool cuts one layer per pass with a footprint half a diameter to each side, so features narrower than the tool are rounded; undercuts along the radius cannot be produced; this also bounds the surface-normal passes, whose normals come from the radial profile, so a flat top face is finished along its edge rather than across it. The blank exists only in memory: the name it shows (blank_W x D x H.stl) is the file name the workspace refers to. A workspace export writes the untouched blank under that name (whatever has been milled since) and the target STL next to it, and the table config keeps the blank's parameters; importing that folder restores the Mill / Sculpt window with the blank, the box fields and the target, so only the program has to be generated again (it is not saved, see Movement Types). Export workpiece STL downloads the workpiece as it is now: the blank under its name, or a milled state as milled_<name>. The rotary table's angle keeps counting turns during a program.

The workpiece on the rotary table is also a workspace object: it is in the Objects list and in the Task Editor's Objects panel, and it can be selected, moved and turned like any object and used for pick & place. While it is on the table it turns with the table and is milled there (Collision Avoidance does not treat it as an obstacle then). Moved by hand or by a pick & place, it is off the table and stays where it is when the table turns; put back exactly where the table holds it (for example when Play Full Sequence puts the picked objects back before a run), it is on the table again. Restore workpiece pos puts it back onto the table at the table's angle (not while a robot carries it), and a milling program puts it back by itself before it mills. It cannot be deleted in the Objects window - it belongs to the table. A workspace export keeps its place in the object list and its pose, on the table or not. From a plugin: getTableWorkpieceObject(robotIdx) gives its object index, restoreWorkpiecePosition(robotIdx) puts it back.

texture

Surface CAM

Setup

Tools & Objects → texture Surface CAM makes a tool path over a CAD surface / patch (Create 2D / 3D Objects → Surface / Patch) or over a face of an imported STEP part (a NURBS solid) for the active arm, e.g. for polishing, spraying, gluing or finishing. Select surface/patch takes the selected surface (or the face selected in the Face select mode), or, when none is selected, waits for a click on a surface or on a face of a NURBS solid in the viewport (Esc cancels); the line below names it with its size along U and V. Several surfaces: with several faces selected in the Face select mode (Shift+click) and / or several Surface / Patch objects selected (Shift+click), Select surface/patch takes them all; otherwise click a surface and Shift+click more (Shift+click on a picked one takes it off again), then press Enter. The line below then lists them. Generate trajectory lays the pattern on every surface in the order they were picked - with one pass spacing for all of them (the first surface's, from its pass count; the others get as many passes as fit) - and joins them: from the end of one surface the tool goes 50 mm up along its axis, across and down to the start of the next (the gun is off there and gets the Spray Gun Off G-code, like the Raster lift). The arm (and a rail) is solved for the whole chain. Spraying paints all of them: a spot over a seam paints each surface with the part of it that falls on that surface, and the coverage and film figures are over all of them by their area. The surfaces are saved with the workspace. On a trimmed face (one with holes or a curved outline) the pattern covers the face's parameter range, and the tool lifts 10 mm off the surface wherever the path leaves the face. TCP Offset (mm) is the distance of the tool tip from the surface along its normal. Tilt angle (°) leans the tool from the surface normal in the pass direction; the lean keeps one direction over the whole path, and both ways are tried, the one that keeps the arm furthest from the wrist singularity is taken (the status line says which, e.g. "Tool leaning -U"). The tool's turn about its own axis is left free (a round tool), so the wrist never has to turn just to keep it. Surface edge margin X, Y (mm) keeps the path that far from the edges along U and V. A negative margin lets the path run that far past the edges (over the surface's flat continuation at the edge, at the same TCP offset) - e.g. so that the U-Turn turns lie outside the part when spraying with Gun off at turns.

Pass Patterns

U-Turn: parallel passes joined by rounded turns of the U-Turn radius (at most half the pass spacing). Zig-Zag: a sawtooth - diagonal passes from one end to the other, each one ending one pass spacing further across, with a posture at every corner (Pass count = the number of corners). Contour: closed loops parallel to the margin, stepping inwards, every other loop the other way round. Spiral: one continuous rectangular spiral inwards. Raster: all passes in the same direction; between two passes the tool lifts 10 mm off the surface, travels back and plunges. Edge: one loop along the margin (the pass fields are off). Along U / Along V sets the pass direction for U-Turn, Zig-Zag and Raster; Contour and Spiral step in from all sides.

Pass Count, Overlap And Spacing

Pass Count and Pass Spacing (mm) belong together: enter one and the other is computed. The usable width is the surface length across the passes minus the two margins (along U: V length - 2 × Y margin; along V: U length - 2 × X margin; Contour and Spiral: half the smaller of the two). With N passes and overlap o (%), every pass covers a stripe of width / (N - (N - 1) · o) and the passes lie stripe · (1 - o) apart. A spacing entered is rounded to the next whole pass count and then recomputed from it.

Generate Trajectory

Generate trajectory lays the pattern on the surface (a point every 3 mm, following its curvature), sets the tool at every point and solves the arm's joints for the whole path from the last posture of the queue (or the arm's pose). Only when every point is reachable inside the joint limits is anything added: a posture at every corner of the pattern, each with a 3D Curve move to the next one that carries the path points between them with a tool orientation for each, and an end posture. U-Turn gets a posture at both ends of every pass (the rounded turn between two passes is one curve), Raster also at the lift, travel and plunge corners, Contour, Spiral and Edge at every corner of their loops. Ctrl pts per pass is the number of points the 3D Curve runs through over the surface's length along the pass direction (shorter pieces get proportionally fewer, at least their two ends; passes running past the edges with a negative margin proportionally more); its default is the number of control points of the surface along the pass direction, set again when the surface, the pattern or the direction changes. Between these points the curve may leave the exact offset path on a curved surface: after Generate trajectory, Max offset error (mm, read-only) shows the largest distance of all the curves from it - add points until it is small enough. The joints are solved along the curve itself, so the simulation runs exactly the curve that was measured. On a trimmed face, a piece that leaves the face keeps a point every 3 mm, so that the lift stays where the face ends. A flat or gently sloping surface is worked from above, a steep one from the side facing the robot. Then click Play Full Sequence. The joints solved for the points are kept with the move and played as they are while its start and end postures stay unchanged (after an edit the path is solved again on playback); they are saved with the workspace.

Arm on a linear rail: when the path cannot be reached from where the rail carriage stands, the rail travels with the tool. Its travel follows the tool's position along the rail (within the rail's length), so the arm keeps about the same pose over the whole path - e.g. an arm hanging from an overhead rail paints a whole car hood that is much longer than its own reach. A few offsets of the carriage from the tool (0, ±150, ±300, ±500 mm along the rail) are tried, and the one that keeps the wrist furthest from its singularity is used. Every posture gets its own rail travel, and the rail moves together with the joints along every curve, so the tool stays exactly on the path; the status line shows the travel range, e.g. "The rail follows the tool, travel 1079 .. 2625 mm". When the path can be reached without moving the rail, the rail stays where it is.

Spraying Simulation

The lower panel of the Surface CAM window simulates spraying (painting) along the generated trajectory: choose the Spray color, the Spraying area [mm²], the Spraying distance [mm], the Spray profile, the Paint flow (%) and the Full-coat speed [mm/s] and click Start spraying simulation. The sequence then plays as with Play Full Sequence, and wherever the tool's spray axis meets the selected surface while the tool is at its working distance (the TCP offset; not while it is lifted, e.g. the Raster travel), the surface takes the color - a soft-edged spot with a fine spray grain (a WebGL layer over the surface, only within a trimmed face). The size of the spot follows the tool's distance h to the surface: area = Spraying area × Spraying distance / h, so with the TCP offset equal to the spraying distance a spray held still paints the given area, nearer a larger, farther a smaller one. How much paint lands is set by three values together:

  • Spray profile - the shape, how the paint is spread over the spot: Solid even over the spot with a short soft edge, Soft with a wide soft edge, Gaussian full at the centre and fading out to the edges (also drawn with more blur). All three put about the same paint on the surface.
  • Paint flow (%) - the amount: 100 % is the gun's full flow, 0 % the gun is off. Profile and flow are independent, as with a real gun: Solid at 30 % gives an even, thin, translucent layer; Gaussian at 100 % full thickness at the centre fading out at the edges.
  • The robot's speed - one pass at the Full-coat speed with 100 % flow leaves one coat, a film of 20 µm; slower passes leave a thicker film, faster ones a thinner one (film ≈ 20 µm × flow × full-coat speed / TCP speed, and thinner when the spot is larger, as the same paint covers more area). Corners and slow-downs show darker. The TCP speed [mm/s] field shows the robot's speed during the run.
  • Gun off at turns (on by default) - the gun is off while the robot runs a turn between passes: the U-Turn turns and the steps from one Contour loop into the next. The robot slows down there and would otherwise leave thick paint at the pass ends; with it off the paint stops where a pass ends, so the turn area itself stays bare (a real gun is triggered the same way; a negative Surface edge margin moves the turns past the part's edge, so the passes cover it fully). Uncheck it to spray all the way through the turns.

The simulation adds up film thickness (µm) at every point of the surface, not color: passes over each other and further coats make the film thicker. How much the color hides the surface follows a saturation curve, opacity = 1 − e−t / t_hide (t the film), as on a real car body: the first coat is a big step, every further coat adds less, and the color comes ever closer to solid; a thin film is translucent with a visible spray grain. Coats to full hide (default 2) sets how many coats this color needs to hide the surface (95 % opacity; t_hide = coats × 20 µm / 3) - a well-covering color 1, a weak one (e.g. some reds, yellows, white) 3 or more. Coats (default 1) is how many times the whole surface is painted: the trajectory plays that many times over the same film (the status line shows the coat running; the spray is off on the way back to the first posture, and on any move outside the generated trajectory). When the run ends the status line gives the share of the surface at full hide, the average film and the thinnest point. Clear paint removes the paint; selecting another surface does too.

Metallic color (next to the spray color, off by default) shows the paint as a metallic finish: a darker base that brightens when seen head-on and darkens at grazing angles, the color-tinted reflection of sky and ground, a broad colored highlight with a sharp white clear-coat highlight on top, a brighter rim at grazing angles, and fine metal flakes that sparkle where they catch the light. The highlights follow the view: turn the camera to see them move over the surface. It changes only the look, not the film thickness or hiding.

Gun On/Off G-Code opens a window with two boxes, Spray Gun On: and Spray Gun Off: (4 lines each), for the commands that switch the spray gun of the real robot. What is entered is copied automatically into the G-Code (Posture Info → G-Code or Custom Action) of the generated postures: Spray Gun On into every posture whose move sprays (the passes), Spray Gun Off into the others - the turns between passes when Gun off at turns is checked, the lift, travel and plunge of the Raster pattern, and the last posture. It is copied while typing, when Gun off at turns changes and every time the trajectory is generated (text entered before generating goes to the new postures). A posture that gets G-Code also gets Plugin Action Execute, so the plugin's userAction() receives the text at that posture when the sequence plays; an empty box clears the G-Code and the flag. The texts are saved with the workspace. Postures edited by hand after generating are no longer updated (generate again).

Saved with the workspace: Export Workspace stores the Surface CAM window's values (spraying included), the selected surface or face and the generated trajectory. After Import Workspace the window shows them again and the trajectory is assigned to Surface CAM: Play or Start spraying simulation work at once, without generating again, and Generate trajectory replaces it as usual. The trajectory is stored only while its postures are still unchanged at the end of the arm's queue (after editing them by hand, generate again before exporting). The paint itself is not stored.

Wrist Singularity

When the tool lines up with the forearm (joint 5 near 0°) joints 4 and 6 must turn fast for a small change of direction; the status line warns when the path comes within 10° of it. The path is solved so that joint 5 passes through zero instead of joints 4 and 6 turning half a round. A path circling that point turns joint 4 a full round per lap: Contour therefore alternates its loops, while Spiral may wind joint 4 up to its limit and fail ("Try Contour"). A tilt angle, another position or orientation of the surface (or of the robot) avoids it.

safety_check

Collision Avoidance

What It Does

Tools & Objects → Collision Avoidance checks the moves of the active robot's posture queue against the objects in the workspace and, when a move comes too close to one, recalculates it so that the arm passes around the object. The check runs on the same trajectory steps Play uses, so Line, Arc and 3D Curve moves are tested along their real path.

Settings

  • • Avoid all objects in workspace (default) or Select objects to avoid: with the box unchecked, the button lists the objects with a checkbox each. Below the list, Add to selection and Remove from selection ask for an object: click it in the workspace and it is checked (or unchecked) in the list; Cancel on the prompt stops without a change. Objects an arm picks up and hidden objects (Visible off) are always left out, also when they are checked in the list.
  • • Avoid floor plane with its Z-offset (mm): the floor becomes an obstacle too, as the plane z = offset, which can be set above or below z = 0. The arm's first link, the column standing on the floor, is not tested against it. With the floor checked, a check is possible even without any object.
  • • Path: with Whole path (all tasks) checked (the default) every move of the queue is checked. Uncheck it to see, in queue order, the tasks of the active robot (Task Editor) and the transitions between them - e.g. Move-1 -> Move-2, the move from the last posture of Move-1 to the first posture of Move-2, and with the loop closed the move from the last task back to the first - each with a check box, all checked at first. Recalculate trajectory then checks and recalculates only the checked parts of the trajectory (a task's own moves, or a transition), against the chosen objects.
  • • Detect collisions only: nothing is changed; colliding moves are reported in the window and the console.
  • • Threshold distance (mm): the clearance the arm must keep. A move is a collision when the arm comes closer than this.
  • • Precision factor: at the minimum each object is its bounding box, which is fast and right for simple convex objects. Higher values add points sampled on the object's surface, up to several thousand at the maximum, so the arm can pass through the free space of a concave object, such as under a table top, at the cost of calculation time.
  • • Choose recalculate method: Insert New Postures puts new postures with free moves into the queue between the two postures of a colliding move; Insert Curve Points keeps the two postures and turns the move into a 3D Curve whose mid points lead the tool around the object.

Recalculate trajectory runs the check and the recalculation (a progress window shows the move being worked on and can cancel it). Back to original trajectory restores the postures and movement types as they were before the first recalculation. After a check, the colliding steps of every played trajectory are drawn red on the path (also a tool that runs along a part on purpose, closer than the threshold - the console names the object), until another workspace is loaded: a newly loaded workspace starts unchecked, with its path in the normal colours.

How It Works

The arm is modelled with capsules fitted to the mesh of every moving link: the link is cut into slices along its main direction and each slice gets a capsule of its own radius, so a link that is thick at the joint and slim along the arm is followed closely (an attached tool included). An object is its oriented bounding box, refined by the surface points when the precision factor is above the minimum. For every tested pose the distance from each capsule to each object is compared with the threshold.

A colliding move is replanned in joint space with a bidirectional rapidly-exploring random tree (RRT-Connect): two search trees grow from the two postures towards each other, only through configurations that are inside the joint limits and clear of the objects. The found path is then shortened to a few via configurations, which become the new postures or the curve points. The result is accepted only when the real trajectory steps pass the check; otherwise the search is repeated with a larger reserve.

From A Plugin

setCollisionAvoidanceParams(params) sets the settings like the window's controls, only the given ones: { avoidAll, objects, detectOnly, threshold, precision, method: 'curve' | 'postures', avoidFloor, floorZ }, and returns them as they are afterwards. setCollisionAvoidanceObjects([indices]) chooses the objects to avoid when not all are. recalculateCollisionAvoidance(robotIdx) runs the check and the recalculation and resolves with { ok, collisions, recalculated, unsolved, messages, error }; restoreOriginalTrajectory(robotIdx) brings the original queue back.

await brwAPI.setCollisionAvoidanceParams({ threshold: 20, precision: 0, method: 'postures' });
await brwAPI.setCollisionAvoidanceObjects([0]);            // only object 0
const r = await brwAPI.recalculateCollisionAvoidance();
brwAPI.logMessage(`${r.collisions} colliding move(s), ${r.recalculated} recalculated`);
// await brwAPI.restoreOriginalTrajectory();               // undo

Limits

The check covers the arm against workspace objects and, when checked, the floor plane. An object the arm picks counts as a part of the arm from its pick posture until its drop posture: it moves with the tool, fixed where it sits on the tool at the pick posture, and must keep the same distance from the objects to avoid as the arm and the tool (a collision of it is reported as carried and the object's name); while it is carried it is not an obstacle itself. Before its pick it is an obstacle where it stands, and after its drop where it was put down (for example the first box on a pallet when the second one is brought); at its pick posture the gripper may be on it, and so at its drop posture - that contact is no collision, the required clearance grows from it along the move. A carried object resting at its own pick or drop posture (on the floor, or a box on the box below it on a pallet) is no collision there either. When a move that starts or ends where the gripper meets a part - at a pick or a drop posture - cannot be planned otherwise, Insert New Postures adds an approach posture there: the same tool orientation, backed off along the tool axis (above the object for a pick from the top) by 80 to 400 mm, as far as needed to keep clear - the arm turns in free space and goes straight onto the part or into place, or straight off it. Objects another arm picks are not obstacles. At its own pick and drop postures it may stand on (or in) the floor plane - that is where it rests - so the floor is not tested for it there, only while it moves. Before the check, the picked objects are put back where they are picked up. The check does not cover the arm against itself (nor a carried object against the arm), other robot arms, or the rail and table parts. A posture of the queue may itself be closer to an object than the threshold, an approach pose beside a part for example: it is kept and reported, and the moves leave and reach it through a zone in which the required clearance grows from the posture's own clearance to the full threshold. A posture may also touch an object or the floor - a carried part standing on the floor at its pick or drop posture, or the gripper on a part: up to 30 mm into it is reported as touches and kept (the arm, the tool and carried objects are modelled a little bigger than they are). Only a posture farther inside an object cannot be used: move it or deselect the object. Insert Curve Points can fail where the tool path alone cannot keep the whole arm clear; Insert New Postures is the more reliable method. Inserted postures use free moves, so a Line or Arc move that collided becomes a sequence of free moves.

code_blocks

Plugin System

What It Is

Plugins let you drive the arm from your own JavaScript instead of clicking through the interface. Use them to generate toolpaths, batch postures, or run a whole routine unattended. Your code runs in a sandboxed Web Worker, so it has no access to the page; it reaches the application only through the injected brwAPI object.

Loading a Plugin

  • 1. Put brw-plugin.js in a folder, on its own or beside a .brw workspace.
  • 2. Open swap_vert Import / Export and select that folder.
  • 3. Run it with one of the three command buttons.
code_blocks User command 1 / 2 / 3
Calls userCommand(1), (2) or (3).

A workspace is optional. If you only want the plugin commands, a folder holding nothing but brw-plugin.js loads fine. Selecting a folder with neither file shows a message instead.

Entry Point

Your file must define userCommand. The argument tells you which button was pressed, so a single plugin can carry three separate routines:

async function userCommand(cmdId)
{
  brwAPI.logMessage('Plugin started');

  const q0    = await brwAPI.getCurrentJointAngles();
  const start = await brwAPI.getCurrentWorldPosition();
  const vel   = await brwAPI.getSimulationVelocity();

  if (cmdId == 1)
  {
    // ...build a path, then play it back:
    await brwAPI.simulateRobotMotion(simDataArr);
  }
}

Every brwAPI call is asynchronous. Each one is forwarded to the application and resolved back to the worker, so it must be awaited.

Install the BabaCAD Robotics VS Code extension for API auto-complete.

Running A Command

Pressing a command button runs your userCommand straight away, against the arm as it currently stands. Here command 1 traces a heart at the tool, with the console reporting each stage as it goes.

Nothing is queued into the posture list, so a plugin can be re-run as often as you like while you tune it.

Running user command 1 from a plugin

Saving Files From A Plugin

saveTextFile(fileName, text) writes a text the plugin generated, a robot program from a post processor (KUKA KRL, for example) or a report, to the user's computer. saveTextFile([{ fileName, text }, ...]) writes several files into the same folder, for example a KRL program's .src and .dat. In Chrome and Edge a folder dialog opens once and the files are written there; other browsers, or when the dialog cannot open, download them to the Downloads folder. It resolves with { saved, cancelled, folder, downloaded, fileName, fileNames }: cancelled is true when the user closed the dialog, downloaded when the download path was taken, fileName is the first file's name and fileNames all of them. Call it from a user command, since the folder dialog needs a user action.

const krl = '&ACCESS RVP\nDEF prog()\n  PTP HOME\nEND\n';
const r = await brwAPI.saveTextFile('prog.src', krl);
brwAPI.logMessage(r.saved ? `saved ${r.fileName}${r.folder ? ' in ' + r.folder : ' (Downloads)'}` : 'not saved');

// several files in one folder (the dialog opens once)
const r2 = await brwAPI.saveTextFile([
  { fileName: 'prog.src', text: krl },
  { fileName: 'prog.dat', text: '&ACCESS RVP\nDEFDAT prog\nENDDAT\n' }
]);
brwAPI.logMessage(r2.saved ? `saved ${r2.fileNames.join(', ')}` : 'not saved');

API Reference

Robot-related calls take an optional trailing robotIdx (the arm's slot index, 0-based); when omitted they act on the active arm. World positions and normals are absolute and include the arm's base position and rotation; addRobotArm(modelIdx, basePos, baseRot), getRobotBaseRot() and setRobotBaseRot() use [rx, ry, rz] in degrees. The ten *Robot* calls after getCurrentNormalVector() manage the arms themselves: count, active arm, model, add / remove and base position.

logMessage() worldToJointAngles() worldToJointAnglesXY() worldToJointAnglesBatch() findTrajSingularity() jointAnglesToWorld() jointAnglesToWorldBatch() getCurrentJointAngles() getCurrentWorldPosition() getCurrentNormalVector() getRobotCount() getActiveRobotIdx() setActiveRobotIdx() getRobotModelNames() getRobotModelIdx() getRobotConfigType() setRobotModelIdx() addRobotArm() removeRobotArm() getRobotBasePos() setRobotBasePos() getRobotBaseRot() setRobotBaseRot() getLinearRail() addLinearRail() removeLinearRail() getRailPosition() setRailPosition() getRotaryTable() addRotaryTable() removeRotaryTable() getRotaryTableAngle() setRotaryTableAngle() getToolNames() getRobotToolInfo() attachRobotTool() detachRobotTool() setRobotToolOffset() setRobotToolColor() getTrajLineStyle() setTrajLineStyle() setTrajStepStyle() getWorkspaceObjectPos() setWorkspaceObjectPos() rotateWorkspaceObject() getWorkspaceObjectRotationAngles() setWorkspaceObjectRotationAngles() getWorkspaceObjectTransformMatrix() setWorkspaceObjectTransformMatrix() getWorkspaceObjectNormal() setWorkspaceObjectNormal() findWorkspaceObjectsByName() getWorkspaceObjectName() getWorkspaceObjectCount() getWorkspaceObjectBoundingBox() setCollisionAvoidanceParams() setCollisionAvoidanceObjects() recalculateCollisionAvoidance() restoreOriginalTrajectory() pickWorkspaceObject() dropWorkspaceObject() addRobotPosture() removeRobotPosture() updateRobotPosture() getPostureMoveType() setPostureMoveType() getMillingProgram() playNextTask() getTaskTypes() getTasks() addTask() removeTask() moveTask() duplicateTask() renameTask() setTaskWait() getPostureTimes() setPostureTime() swapPostures() movePostureToTask() replacePosture() movePostureRelative() getPostureWorldPose() setPostureWorldPose() setObjectWorldPose() moveArmToWorldPose() getPickPlaces() addPickPlace() setPickObject() movePickPlace() removePickPlace() getObjectWorldPose() addPostureFromObject() replacePostureFromObject() renameWorkspaceObject() renameSketchEntity() simulateRobotMotion() getRobotJointLimits() isPostureValid() getJointAnglesMapping() setJointAnglesMapping() getHomeJointAngles() getRobotTrajData() getRobotPostureArray() getRobotCurrentPostureIdx() getSimulationVelocity() sendDataToSerialPort() saveTextFile() getRobotSegmentBoundingBox() getTableWorkpieceObject() restoreWorkpiecePosition() breakCurve() groupWorkspaceObjects() ungroupWorkspaceObject() getWorkspaceObjectGroup() getSolidTypes() createSolid() getSolidInfo() setSolidParams() getSolidHistory() setSolidHistoryStep() booleanSolids() pushPullProfile() pushPullText() getSolidFaces() getSolidEdges() importStepText() surfaceFromFace() createSketchEntity() getSketchEntities() setSketchEntity() removeSketchEntity() setSketchEntityVisible() duplicateWorkspaceObject() removeWorkspaceObject() setWorkspaceObjectVisible() isWorkspaceObjectVisible() setSelectionDisabled() isSelectionDisabled() addPosturesAlongPath() recalcPosturesForTool() scaleWorkspaceObject() setWorkspaceObjectSize() getWorkspaceObjectPivot() setWorkspaceObjectPivot() getWorkspaceObjectPivotRotation() getWorkspaceObjectComplexity() setWorkspaceObjectComplexity() offsetSurface() convertToMesh() joinFaces() surfaceFromEdges() arrayWorkspaceObjects() measure() addToolFromWorkspaceObject() removeTool() getToolCenterPoint() setTaskDuration() getAnimationModes() getCollisionShapes() getAnimationParameters() setAnimationParameters() addAnimationKey() setAnimationKey() removeAnimationKey() removeAnimation() getAnimationBlocks() addAnimationBlock() setAnimationBlock() removeAnimationBlock() addAnimationBlockKey() setAnimationBlockKey() removeAnimationBlockKey() getAnimationWorld() setAnimationWorld() playAnimation() pauseAnimation() stopAnimation() seekAnimation() getAnimationState() addCamera() getCamera() setCamera() lookThroughCamera() getLightTypes() addLight() getLight() setLight() getSpecialObjects() setAnimationPath() getMaterialTypes() getObjectMaterial() setObjectMaterial() getFloorOptions() setFloorOptions() getDefaultLightLevel() setDefaultLightLevel()

CAD From A Plugin

The 3D solids, their history and Booleans, the 2D entities and Path Pick have API calls of their own; they do what the Create 2D / 3D Objects window does. Object indices are the workspace object indices (as for the *WorkspaceObject* calls), angles are in degrees, lengths in mm. A plane is 'xy', 'xz' or 'yz' with an offset (e.g. 'xy', 100 = the XY plane at z = 100), { o: [x, y, z], n: [nx, ny, nz], u: [ux, uy, uz] } in world coordinates (origin, normal, X direction), or { objIdx, face } - a planar face of a solid from getSolidFaces().

// a box with a 100 x 60 pocket, 20 mm deep, then 40 mm deep
const box = await brwAPI.createSolid('box', { w: 200, d: 150, h: 100 }, { position: [700, -900, 0] });
const [res] = await brwAPI.pushPullProfile([[620, -950], [720, -950], [720, -890], [620, -890]], -20, 'xy', 100);
const steps = await brwAPI.getSolidHistory(res);   // '' Subtraction, 'a' Box, 'b' Push / Pull (hole)
await brwAPI.setSolidHistoryStep(res, 'b', { h: -40 });
// a circle on its top face, and postures along it
const top = (await brwAPI.getSolidFaces(res)).find(f => f.normal[2] > 0.99);
const c = await brwAPI.createSketchEntity('circle', { c: [30, 30], r: 20 }, { objIdx: res, face: top.face });
await brwAPI.addPosturesAlongPath(c);
// a cylinder as a tool: its pivot at the flange end, the tool axis +X
const cyl = await brwAPI.createSolid('cylinder', { r: 15, h: 120 }, { position: [0, 0, 0], rotation: [0, 90, 0] });
const tool = await brwAPI.addToolFromWorkspaceObject(cyl, 'Probe');
await brwAPI.attachRobotTool(tool, [120, 0, 0]);
// measure the radius of its side face
const side = (await brwAPI.getSolidFaces(cyl, true)).find(f => !f.planar);
const r = await brwAPI.measure('radius', [{ objIdx: cyl, face: side.face }]);   // r.value: 15
// a Text pulled out as a solid; the Text is a step of its history (':src', type 'entity'): change its wording
const t = await brwAPI.createSketchEntity('text', { p: [300, -900], text: 'AB', h: 60 }, 'xy');
const sign = await brwAPI.pushPullText(t, 10);
await brwAPI.setSolidHistoryStep(sign, ':src', { text: 'ABC' });

A complete worked example ships as plugins/brw-plugin.js. Commands 1 and 2 draw rectangles and circles in multiple passes down the Z-axis (with the singular poses of the path marked on the line), command 3 takes the milling program generated in Mill / Sculpt with getMillingProgram() and adds a posture that runs it (MoveType.MILL), and userAction() shows how a posture's plugin action receives the G-code text.

smart_toy

AI Assistant

AI-Powered BRW

BabaCAD Robotics Web is one of the first industrial robot simulation and programming applications with artificial intelligence built in. The AI Assistant sits beside the 3D workspace: you describe in plain language what the robot should do, or ask how something in the application works, and it answers with an explanation or with a ready program for the simulator.

How It Works

  • 1. You ask. For example: "Move the robot from the initial pose to [1000, 0, 0] with normal [0, 0, -1] along a line", or "How do I add a linear rail?"
  • 2. BRW adds what the model needs to know. With your question it sends the relevant parts of this documentation, the plugin API functions and a demo plugin, so the answer follows the real API of the application.
  • 3. The language model answers. The request goes to our own model server; a how-to question gets an explanation, a task gets JavaScript plugin code.
  • 4. The task becomes a simulation. With Save and run the code is saved as brw-plugin.js, loaded and run once: it defines the postures and movement types in the queue, and you press Play to watch the robot do it.

Type /demo to try a ready-made request, and /repeat to send the last request again.

The AI Assistant in BabaCAD Robotics Web: a task typed in plain language, the generated plugin code and the robot simulation

AI Credits (Tokens) And How To Get Them

The assistant is used with an activation code, and every code carries a balance of tokens, the AI credits. Each request spends tokens: your question, the knowledge sent with it and the answer all count, so a task that needs the API functions costs more than a short how-to question. The panel shows the tokens left and the cost of the last request; when the balance is used up, the assistant stops answering until the code is topped up.

The AI Assistant is in an experimental phase and currently available to educational institutions, mainly teachers and professors. To get an activation code with credits, or more credits for a code you have, click Activate... and then Request Activation Code, or write directly to support@babacad.com and tell us who you are and where you teach.

Fair Use

Requests are paced (a short pause between two requests and a limit per hour), and questions are limited in length. Violent or spam requests and bot-like request rates put a code on a blacklist, after which it cannot be activated. With your consent, given in the window shown after activation, your questions and ratings are collected to improve the assistant; without it they stay in your browser.

The Panel

The AI Assistant is docked at the right edge of the workspace. Click its header or the arrow to collapse it to the title bar, and the ✕ to hide it. Settings → Show AI Assistant shows or hides the panel (the ✕ unchecks it). By default the panel is visible but collapsed to its title bar; afterwards it remembers the state you left it in.

Which AI Answers

The list at the top of the panel chooses who answers: BRW AI (activation code), the integrated assistant described here, or an AI with your own API key - Claude (Anthropic), ChatGPT (OpenAI), Gemini (Google) or OpenRouter (one key for many other models). With your own key no activation code is needed: choose the provider, click API key..., paste the key (Get an API key opens the provider's page for it), pick the Model from the list the key gives (the best one is preselected; the ↻ button reads the list again, and a model name can also be typed), and click Save. The status then shows the model, and the token line shows what the last request used. The assistant sends that model the same instructions and all the BRW knowledge, and its answers are saved and run as plugins the same way. With your own key the assistant holds a conversation: each question goes with the earlier questions and answers, the plugin that is loaded now and a summary of the workspace (the arms, their tools and postures, the objects with their names and positions), so "now weld the other side" continues the task it wrote before. Type /new to start a new conversation; opening another workspace or choosing another provider starts one too. The large, fixed part of each request (the BRW knowledge) is kept by the provider for a while (Claude: an hour; the others decide themselves), so the questions after the first cost much less; the token line shows how much came from that cache. The key is kept in this browser only - in its storage when Remember on this device is checked, else until the page is closed - and is sent only to the provider you chose, never to BabaCAD; the provider charges the requests to your account there. Remove key forgets it. The choice is remembered, and the pause between requests is only a few seconds with your own key. Ratings of these answers are kept in this browser only.

Activation

Activate... at the top of the panel opens a window for your activation code. The code is sent with every request and the service checks it and counts the tokens used against it. It is kept for the current session only, unless Remember on this device is checked (then it is stored in this browser); Deactivate forgets it. Once the code is accepted a window suggests starting with the /demo prompt, a ready-made task request (type /demo and send it, or use its button); /repeat sends the last request again. Nothing is sent before a code is entered. Abusive use (violent or spam requests, bot-like request rates) puts a code on a blacklist: such a code cannot be activated, and a window names the reason and the support address. Request Activation Code, under the code field in that window, explains how to get one: the AI Assistant is an experimental feature, available to educational institutions (mainly teachers and professors), and a code is requested by email from support@babacad.com. Under the button the panel shows the tokens left for your code and the cost of the last request; the same line is in the activation window. The numbers come from the service with every answer, so they appear after the first request.

Asking

Type a question and press Enter or the send button (Shift+Enter starts a new line). The answer appears in the panel below your question; errors from the service, such as a wrong code or used-up tokens, are shown there as well. Code in an answer is shown in a box with a Copy button. Under each answer the panel asks, optionally, how the assistant is doing: 1 Bad, 2 Fine, 3 Good or 0 Dismiss (buttons, or the digit typed into the prompt; Dismiss hides the question for the session). Ratings stay in your browser unless you have allowed their collection: the window shown after activation asks whether your questions and ratings may be collected to improve the assistant, with a checkbox (unchecked by default, changeable any time through Activate...); only with it checked are ratings also sent to BabaCAD. An answer rated Good is remembered with its request, and when a later task resembles it, that answer is shown to the model as the pattern to follow, which makes answers to recurring tasks more consistent.

What The Assistant Knows

With every question the assistant reads three files and sends what the question needs to the model as its system prompt, in English: this documentation as the Markdown file docu/brw-help-ai.txt (made from this page by scripts/help2text.py, which drops the sections the assistant does not need, such as this one; brw-help.txt is the full page, and the page itself is converted in the browser when neither file is there), the plugin API functions with their syntax (plugins/apiFunctions.js) and the demo plugin (plugins/brw-plugin.js). A task (writing a plugin, making the robot do something) gets all API functions with their syntax and the demo plugin, plus the parameter descriptions of the functions the task touches; every question gets the documentation sections that match its words, and a how-to question that matches nothing (one not asked in English, for example) gets the whole documentation. It can therefore explain the application and write plugins: generated code uses the API syntax, follows the structure of the demo plugin and comes as JavaScript inside a code block. The panel says what was sent and how large it is, since it counts towards the tokens of the request. If the model's context window is too small for all of it, the assistant says so and asks again with the part the question needs: the API functions and the demo plugin for a task, the documentation for a how-to question.

Saving A Task As The Plugin

When an answer contains code for a task (for example "move the robot from the initial pose to [0, 1000, 0] along a line"), the panel asks whether to save it as brw-plugin.js and run it. Save and run writes the file, loads it as the application's plugin and runs the code once: that defines the task (the postures in the queue), and the panel answers Task is defined, just click the Play >> button to run the simulation. When you ask for a plugin or a user command explicitly, the panel instead asks which user command (1, 2 or 3) should run the code; Save and load plugin writes and loads the file, and clicking that user command runs it. The file goes into the workspace folder: after an export to a folder in this session it is written there directly; after an import the browser asks you to choose the workspace folder and to allow writing (a web page cannot write into a folder on its own); without a workspace you are asked for any folder. Browsers without folder access (Firefox, Safari) download the file instead and the plugin is loaded all the same. A plugin that was already loaded is kept: its commands that are not reassigned still run, and each saved task replaces only its own command. Code that does not compile is not saved. A workspace export now includes the loaded brw-plugin.js.

terminal

Console

Plugin Output

Anything a plugin passes to logMessage() is printed to the console docked along the bottom of the workspace, so you can follow a run without opening the browser's developer tools.

brwAPI.logMessage('Pass ' + i + ' of 4 complete');

Objects and arrays are formatted as JSON, everything else is printed as text. Each line is timestamped and the view follows the newest entry.

Controls

The console is always docked and starts collapsed to its title bar. Click the bar, or the chevron, to expand it.

expand_less Expand / minimize
Toggles the log view.
delete Clear
Empties the log.

While collapsed, incoming messages raise a counter on the title bar rather than opening the panel, so a running plugin never pulls focus from the scene. The most recent 500 lines are kept.

cable

Serial Port

Talking To Real Hardware

A plugin can push data out over a serial connection while the simulation runs, so the same routine that moves the arm on screen can drive a real controller, a gripper, or any device listening on the port.

Connecting

Open settings Settings and press Serial Configure to choose a port. Until a port is connected nothing is transmitted, and calls to the API are simply ignored.

cable Serial Configure
Pick and open the port.
Serial Configure in the settings window

Sending From A Plugin

One call does the work. It takes a string, so format the payload however the device on the other end expects, including any line terminator.

// stream the live joint angles out as degrees
const q   = await brwAPI.getCurrentJointAngles();
const deg = q.map(a => (a * 180 / Math.PI).toFixed(2));

await brwAPI.sendDataToSerialPort(`J ${deg.join(' ')}
`);

Combined with simulateRobotMotion, this lets a plugin play a path in the viewport and mirror it to hardware in the same pass.

settings

Global Settings & Support

Language Support

BabaCAD Robotics supports a wide variety of localizations, accessible via the language icon:

English French German Chinese Japanese Spanish Italian

Configuration & Info

Both are in the settings_alert menu at the bottom of the left bar. Settings has these options, from top to bottom; the details are in Scene & System → Configuration.

Velocity: the movement speed as a ratio of the joints' maximum speed (default 0.35), with the resulting and the maximum speed of every joint shown below it.

Joint acceleration: acceleration, its maximum and the ramp-up time, separately for J1-J3 and J4-J6.

Simulation repeat: how many times Play Full Sequence runs the queue (1 to 1000).

Close the loop: on (default), a full run ends with the move from the last posture back to the first.

Show Pivot: shows the gizmo of the active arm or the selected object.

Show Path: draws the trajectory; the palette icon next to it sets the path's width and colours.

Display cursor coordinates: shows the world coordinates of the point under the mouse.

Show right toolbar: shows or hides the icon column at the right edge (on by default).

Background color: the colour of the 3D view behind the floor.

Render Quality: Standard (default), Wire (robots and objects as wire models) or Realistic (materials, reflections, soft shadows, a mirroring floor).

Default Light Level: the workspace's own light, 0 to 100 % (default 80 %; at 0 only the lights you add light the scene); saved with the workspace.

Show floor grid lines: on by default; unchecked, the floor has no grid lines.

Floor texture: an image on the floor with its scale, transparency, bump effect and reflection level (see Materials).

Hide text outlines: on by default; the edges of a Text used with Push / Pull are not drawn.

Show AI Assistant: shows or hides the AI Assistant panel.

Dark Mode: switches the whole interface between the light and dark themes.

Serial Configure: chooses the serial port and its settings for a real robot (see Serial Port).

Center the view: resets the view center (to the origin for one arm, to the middle of the arms for several) and the zoom to the robot model's defaults.

Close all open windows: closes every open window and puts them back at their start places, which also brings back a window dragged out of reach.

Joint acceleration, Close the loop, Show Path, the cursor coordinates, the right toolbar, the background, Render Quality, the floor's grid lines and texture, Hide text outlines and Dark Mode are remembered in this browser.

About System (the info icon in the same menu) shows the version and authors, and links to the website, the Discord for support and support@babacad.com.