@viamrobotics/sdk 0.3.1-next.1 → 0.3.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -48,9 +48,6 @@ export type DialConf = DialDirectConf | DialWebRTCConf;
48
48
  *
49
49
  * If connecting via WebRTC fails, then this function will automatically
50
50
  * re-attempt to connect via gRPC directly.
51
- *
52
- * @privateRemarks
53
- * We should add an example that is not viam-specific.
54
51
  */
55
52
  export declare const createRobotClient: (conf: DialConf) => Promise<RobotClient>;
56
53
  export {};
@@ -1,6 +1,6 @@
1
1
  import type { RobotClient } from '../../robot';
2
2
  import type { GeoObstacle, GeoPoint, Options, Pose, PoseInFrame, ResourceName, StructType, Transform, WorldState } from '../../types';
3
- import { type Constraints } from './types';
3
+ import { type Constraints, type MotionConfiguration } from './types';
4
4
  import type { Motion } from './motion';
5
5
  /**
6
6
  * A gRPC-web client for a Motion service.
@@ -15,8 +15,7 @@ export declare class MotionClient implements Motion {
15
15
  private get service();
16
16
  move(destination: PoseInFrame, componentName: ResourceName, worldState?: WorldState, constraints?: Constraints, extra?: {}): Promise<boolean>;
17
17
  moveOnMap(destination: Pose, componentName: ResourceName, slamServiceName: ResourceName, extra?: {}): Promise<boolean>;
18
- moveOnGlobe(destination: GeoPoint, componentName: ResourceName, movementSensorName: ResourceName, heading?: number, obstaclesList?: GeoObstacle[], linearMetersPerSec?: number, angularDegPerSec?: number, extra?: {}): Promise<boolean>;
19
- moveSingleComponent(destination: PoseInFrame, componentName: ResourceName, worldState?: WorldState, extra?: {}): Promise<boolean>;
18
+ moveOnGlobe(destination: GeoPoint, componentName: ResourceName, movementSensorName: ResourceName, heading?: number, obstaclesList?: GeoObstacle[], motionConfig?: MotionConfiguration, extra?: {}): Promise<boolean>;
20
19
  getPose(componentName: ResourceName, destinationFrame: string, supplementalTransforms: Transform[], extra?: {}): Promise<import("../../gen/common/v1/common_pb").PoseInFrame.AsObject>;
21
20
  doCommand(command: StructType): Promise<StructType>;
22
21
  }
@@ -1,5 +1,5 @@
1
1
  import type { GeoObstacle, GeoPoint, Pose, PoseInFrame, Resource, ResourceName, StructType, Transform, WorldState } from '../../types';
2
- import type { Constraints } from './types';
2
+ import type { Constraints, MotionConfiguration } from './types';
3
3
  /**
4
4
  * A service that coordinates motion planning across all of the components in a
5
5
  * given robot.
@@ -41,23 +41,10 @@ export interface Motion extends Resource {
41
41
  * the robot's location.
42
42
  * @param obstaclesList - Obstacles to consider when planning the motion of
43
43
  * the component.
44
- * @param heading - Compass heading, in degrees, to achieve at destination
45
- * @param linearMetersPerSec - Linear velocity to target when moving.
46
- * @param angularDegPerSec - Angular velocity to target when moving.
44
+ * @param heading - Compass heading, in degrees, to achieve at destination.
45
+ * @param motionConfiguration - Optional motion configuration options.
47
46
  */
48
- moveOnGlobe: (destination: GeoPoint, componentName: ResourceName, movementSensorName: ResourceName, heading?: number, obstaclesList?: GeoObstacle[], linearMetersPerSec?: number, angularDegPerSec?: number, extra?: StructType) => Promise<boolean>;
49
- /**
50
- * Move a single component.
51
- *
52
- * @param destination - Destination to move to, which can a pose in the
53
- * reference frame of any frame in the robot's frame system.
54
- * @param componentName - Component on the robot to move to the specified
55
- * destination.
56
- * @param worldState - Avoid obstacles by specifying their geometries in the
57
- * `WorldState`. Augment the frame system of the robot by specifying
58
- * additional transforms to add to it for the duration of the Move.
59
- */
60
- moveSingleComponent: (destination: PoseInFrame, componentName: ResourceName, worldState?: WorldState, extra?: StructType) => Promise<boolean>;
47
+ moveOnGlobe: (destination: GeoPoint, componentName: ResourceName, movementSensorName: ResourceName, heading?: number, obstaclesList?: GeoObstacle[], motionConfiguration?: MotionConfiguration, extra?: StructType) => Promise<boolean>;
61
48
  /**
62
49
  * Get the current location and orientation of a component.
63
50
  *
@@ -3,5 +3,7 @@ export type Constraints = pb.Constraints.AsObject;
3
3
  export type LinearConstraint = pb.LinearConstraint.AsObject;
4
4
  export type OrientationConstraint = pb.OrientationConstraint.AsObject;
5
5
  export type CollisionSpecification = pb.CollisionSpecification.AsObject;
6
+ export type MotionConfiguration = pb.MotionConfiguration.AsObject;
6
7
  /** Convert a Constraints object to a Protobuf Datatype. */
7
8
  export declare const encodeConstraints: (obj: Constraints) => pb.Constraints;
9
+ export declare const encodeMotionConfiguration: (obj: MotionConfiguration) => pb.MotionConfiguration;
@@ -1,3 +1,3 @@
1
1
  export type { Motion } from './motion/motion';
2
- export type { Constraints, LinearConstraint, OrientationConstraint, CollisionSpecification, } from './motion/types';
2
+ export type { Constraints, LinearConstraint, OrientationConstraint, CollisionSpecification, MotionConfiguration, } from './motion/types';
3
3
  export { MotionClient } from './motion/client';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@viamrobotics/sdk",
3
- "version": "0.3.1-next.1",
3
+ "version": "0.3.1",
4
4
  "description": "",
5
5
  "main": "./dist/main.umd.js",
6
6
  "module": "./dist/main.es.js",