by Simon Schiele & Yannick Krieger, SG-Lib Toolbox: SolidGeometry 5.6 - Modeling function
, Creation date: 2020-10-02, Last change: 2025-09-14
SG=SGrobot([phi])
phi: | list of angles in rad; default is [0 0 0 0] |
SG: | Cell list of 5 solids |
SGrobot([-pi/6 pi/6 pi/6])
SGrobot([pi/6 pi/6 pi/6])
This algorithm is a MATLAB function named SGrobot that models the geometry and kinematics of the MIMED-LCL Robot. It is part of the SG-Library and was developed by Simon Schiele and Yannick Krieger.
[0 0 0 0]. This parameter represents the joint angles of the robot.SGrobot is called with a variable number of input arguments (varargin).getfuncparams is used to extract the first input parameter, phi, from varargin. If no input is provided, it defaults to [0 0 0 0]. The function ensures that phi is a list of angles.phi is not NaN, a NaN is prepended to the list. This is likely done to align the input with the expected format for further processing.LCL_robot.mat, which contains the robot's data, into a variable named LCL.SGTchain is called with LCL and phi as arguments. This function likely computes the kinematic chain of the robot and returns the geometry as a cell list of solids, stored in SG.nargout == 0), the function proceeds to visualize the robot:SGfigure(-30,30): Sets up a figure for plotting with a specific view angle.SGplotalpha(SG): Plots the geometry of the robot.SGTframeplot(SG): Plots the frames of the robot's kinematic chain.view(-30,30): Adjusts the view angle of the plot.To use the function, you can call it with different sets of angles:
SGrobot([-pi/6 pi/6 pi/6]): This call sets the joint angles to -pi/6, pi/6, and pi/6.SGrobot([pi/6 pi/6 pi/6]): This call sets the joint angles to pi/6, pi/6, and pi/6.