@@ -613,6 +613,7 @@ async def get_status(self, components: Optional[List[ResourceName]] = None) -> L
613613
614614 # Get the status of the resources on the machine.
615615 statuses = await machine.get_status()
616+ resource_statuses = machine_status.resources
616617
617618 Args:
618619 components (Optional[List[viam.proto.common.ResourceName]]): Optional list of
@@ -713,7 +714,24 @@ async def transform_pose(
713714
714715 ::
715716
716- pose = await machine.transform_pose(PoseInFrame(), "origin")
717+ from viam.proto.common import Pose, PoseInFrame
718+
719+ pose = Pose(
720+ x=1.0, # X coordinate in mm
721+ y=2.0, # Y coordinate in mm
722+ z=3.0, # Z coordinate in mm
723+ o_x=0.0, # X component of orientation vector
724+ o_y=0.0, # Y component of orientation vector
725+ o_z=0.0, # Z component of orientation vector
726+ theta=0.0 # Orientation angle in degrees
727+ )
728+
729+ pose_in_frame = PoseInFrame(
730+ reference_frame="world",
731+ pose=pose
732+ )
733+
734+ transformed_pose = await machine.transform_pose(pose_in_frame, "world")
717735
718736 Args:
719737
@@ -741,12 +759,15 @@ async def discover_components(
741759 queries : List [DiscoveryQuery ],
742760 ) -> List [Discovery ]:
743761 """
744- Get the list of discovered component configurations.
762+ Get a list of discovered potential component configurations, for example listing different supported resolutions. Currently only works for some cameras.
763+ Returns module names for modules.
745764
746765 ::
747766
767+ from viam.proto.robot import DiscoveryQuery
768+
748769 # Define a new discovery query.
749- q = machine. DiscoveryQuery(subtype=acme.API , model="some model ")
770+ q = DiscoveryQuery(subtype="camera" , model="webcam ")
750771
751772 # Define a list of discovery queries.
752773 qs = [q]
@@ -756,10 +777,10 @@ async def discover_components(
756777
757778 Args:
758779
759- queries (List[viam.proto.robot.DiscoveryQuery]): The list of component models to lookup configurations for.
780+ queries (List[viam.proto.robot.DiscoveryQuery]): The list of component models to lookup potential configurations for.
760781
761782 Returns:
762- List[Discovery]: A list of discovered component configurations.
783+ List[Discovery]: A list of discovered potential component configurations.
763784
764785 For more information, see `Machine Management API <https://docs.viam.com/appendix/apis/robot/>`_.
765786 """
0 commit comments