Skip to main content
Have a personal or library account? Click to login
Machina.NET: A Library for Programming and Real-Time Control of Industrial Robots Cover

Machina.NET: A Library for Programming and Real-Time Control of Industrial Robots

Open Access
|Aug 2019

Figures & Tables

Code Sample 1

A simple Hello Robot program.

Figure 1

The four main motion actions of the Hello Robot program (Code Sample 1) executed on an ABB IRB 1200 robot – MoveTo(400, 300, 500), Rotate(0, 1, 0, –90), Move(0, 0, 250) and AxesTo(0, 0, 0, 0, 90, 0).

Table 1

Main motion control actions in Machina.

InstructionDescriptionRelated Action
Move/ToChange the position of the TCP maintaining its orientation.ActionTranslation
Rotate/ToChange the orientation of the TCP maintaining it position.ActionRotation
Transform/ToChange the position and orientation of the TCP.ActionTransformation
Axes/ToChange the rotational values of the robot’s axes.ActionAxes
ExternalAxis/ToChange the values of one the external axis attached to the robot.ActionExternalAxis
WaitHalt program execution for an amount of time.ActionWait
DefineToolDefine Tool properties on the robot.ActionDefineTool
AttachAttach a Tool to the robot’s flange.ActionAttach
DetachDetach all tools from the robot.ActionDetach
WriteDigitalWrites a value to a digital out.ActionIODigital
WriteAnalogWrites a value to an analog out.ActionIOAnalog
ExtrudeTurns extrusion on/off in 3D printers.ActionExtrude
MessageDisplay a message on the device’s screen.ActionMessage
CommentInsert a custom comment on a compiled program.ActionComment
CustomCodeInsert a custom line of code on a compiled program.ActionCustomCode
DoApplies an Action object to the Robot.N/A
Table 2

Main settings actions in Machina. Note that all state changes caused by these actions can be buffered and reverted with the use of PushSettings and PopSettings.

InstructionDescriptionRelated Action
MotionModeSet the motion type for future motion Actions, like linear or joint.ActionMotion
Speed/ToChange the TCP speed value new Actions will be executed at.ActionSpeed
Acceleration/ToChange the TCP acceleration value new Actions will be executed at.ActionAcceleration
Precision/ToChange the TCP smoothing radius value new Actions will be executed at.ActionPrecision
Temperature/ToChange the working temperature of one of the device’s parts.ActionTemperature
ExtrusionRate/ToChange the extrusion rate of filament for 3D printers.ActionExtrusionRate
PushSettingsBuffers current state settings.ActionPushPop
PopSettingsReverts the settings to the previous state buffered by PushSettings.ActionPushPop
Table 3

Main management methods in Machina. These instructions have no actions associated to them, as they are related to setup rather than execution.

InstructionDescriptionRelated Action
Robot.CreateCreate a new instance of a Robot object.N/A
ControlModeSets the control type the robot will operate under, like offline or online.N/A
ConnectionManagerDefines who is responsible for setting up the controller for connection, Machina or the user.N/A
ConnectConnects to a remote controller.N/A
CompileCreate a program in the device’s native language with all the buffered Actions.N/A
Figure 2

Overall architecture of the Machina.NET library and an extension sample for ABB robots.

Code Sample 2

Actions in the Hello Robot example stringified to a human-readable program.

Code Sample 3

Actions in the Hello Robot example serialized into instruction calls.

Code Sample 4

The Hello Robot example rewritten for offline mode.

Code Sample 5

The Hello Robot program compiled to RAPID language by the code in Code Sample 4.

Code Sample 6

The same Hello Robot program in Code Sample 4 compiled to URScript.

Figure 3

Sample scheme of a Machina application-driver communication exchange.

Figure 4

Life cycle of a Machina Action. MoveL represents a move instruction in the device native’s language executed by the driver.

Figure 5

Layered machine states. This diagram shows the different stages of asynchronous execution and Cursor representations for the Hello Robot program.

Code Sample 7

Whenever the robot has no pending actions left to execute, a new block of actions is issued, generating an infinite motion program.

DeviceOfflineOnline
ABB RobotsYesYes
Universal RobotsYesYes
KUKA RobotsYesNo
Zmorph 3D PrinterYesNo
DOI: https://doi.org/10.5334/jors.247 | Journal eISSN: 2049-9647
Language: English
Submitted on: Sep 19, 2018
Accepted on: Jul 5, 2019
Published on: Aug 13, 2019
Published by: Ubiquity Press
In partnership with: Paradigm Publishing Services
Publication frequency: 1 issue per year

© 2019 Jose Luis García del Castillo y López, published by Ubiquity Press
This work is licensed under the Creative Commons Attribution 4.0 License.