Exemplo n.º 1
0
        public com.robotraconteur.robotics.tool.ToolInfo ToRRInfo()
        {
            var info = new com.robotraconteur.robotics.tool.ToolInfo();

            CopyTo(info);
            return(info);
        }
Exemplo n.º 2
0
 public void CopyTo(com.robotraconteur.robotics.tool.ToolInfo info)
 {
     info.device_info       = device_info?.ToRRInfo();
     info.tool_type         = tool_type;
     info.tool_capabilities = (uint)(tool_capabilities?.Aggregate((x, y) => x | y) ?? 0);
     info.tcp            = tcp?.ToRRInfo() ?? new Transform();
     info.inertia        = inertia?.ToRRInfo() ?? new SpatialInertia();
     info.actuation_time = actuation_time;
     info.close_position = close_position;
     info.open_position  = open_position;
     info.command_min    = command_min;
     info.command_max    = command_max;
     info.command_close  = command_close;
     info.command_open   = command_open;
     info.sensor_type    = sensor_type;
     info.sensor_min     = sensor_min ?? new double[0];
     info.sensor_max     = sensor_max ?? new double[0];
     info.extended       = extended?.ToDictionary(x => x.Key, x => x.Value?.value);
 }