Skip to content

Conversation

purplenicole730
Copy link
Member

@purplenicole730 purplenicole730 commented Jul 3, 2023

Ticket: RSDK-3379
This PR updates the docs to include directions on how to add a modular resource using the Python SDK.

Please note that there is another ticket RSDK-3836 that aims to make this doc to be more parallel to the one we have in our actual docs.

@github-actions
Copy link
Contributor

github-actions bot commented Jul 3, 2023

Warning your change may break code samples. If your change modifies any of the following functions please contact @viamrobotics/fleet-management. Thanks!

component function
base is_moving
board gpio_pin_by_name
camera get_image
encoder get_position
motor is_moving
sensor get_readings
servo get_position
arm get_end_position
gantry get_lengths
gripper is_moving
movement_sensor get_linear_acceleration
input_controller get_controls
audio get_properties
pose_tracker get_poses
motion get_pose
vision get_classifications_from_camera

@purplenicole730 purplenicole730 changed the title RSDK-3836 - add modular resource docs RSDK-3379 - add modular resource docs Jul 3, 2023
@purplenicole730 purplenicole730 marked this pull request as ready for review July 6, 2023 17:07
@purplenicole730 purplenicole730 requested a review from a team as a code owner July 6, 2023 17:07
@purplenicole730 purplenicole730 requested review from njooma and cheukt July 6, 2023 17:07
Copy link
Member

@cheukt cheukt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

seems good, though I do think we should maybe move the new additions up, should naomi or matt d be a reviewer for this?

@purplenicole730 purplenicole730 requested a review from npentrel July 6, 2023 20:02
Copy link
Member

@njooma njooma left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would suggest moving the module section above the create custom components section, since that's the most likely use case. And if you move it up above the custom components section, i would also move the Operations section into the modular components section

@purplenicole730 purplenicole730 requested a review from cheukt July 6, 2023 21:11
@cheukt
Copy link
Member

cheukt commented Jul 11, 2023

@purplenicole730 can you also change the instance of from typing import Self to from typing_extensions import Self

Copy link
Contributor

@Fahmina Fahmina left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a lot better now!
Going to approve this because my outstanding comments will be adressed by https://viam.atlassian.net/browse/RSDK-3941 and https://viam.atlassian.net/browse/RSDK-3836

@purplenicole730 purplenicole730 removed the request for review from npentrel July 11, 2023 18:58
@cheukt
Copy link
Member

cheukt commented Jul 11, 2023

its in examples/module/src/arm/my_arm.py

Copy link
Contributor

@andf-viam andf-viam left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @purplenicole730 this is awesome! I've left a few tiny language suggestions, but otherwise LGTM. Thanks!

"source": [
"## Create custom remotes\n",
"\n",
"While the main RDK is written in golang, you can create custom components in python and connect them to a robot as a `remote` component. This allows you to extend the functionality of a robot, or even create an entire robot exclusively in python.\n",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

and some hardware! 😂

purplenicole730 and others added 8 commits July 11, 2023 17:42
Co-authored-by: andf-viam <132301587+andf-viam@users.noreply.github.com>
Co-authored-by: andf-viam <132301587+andf-viam@users.noreply.github.com>
Co-authored-by: andf-viam <132301587+andf-viam@users.noreply.github.com>
Co-authored-by: andf-viam <132301587+andf-viam@users.noreply.github.com>
Co-authored-by: andf-viam <132301587+andf-viam@users.noreply.github.com>
Co-authored-by: andf-viam <132301587+andf-viam@users.noreply.github.com>
Co-authored-by: andf-viam <132301587+andf-viam@users.noreply.github.com>
Copy link
Member

@njooma njooma left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I assume we're leaving out custom resource types in modules from this doc on purpose?

@purplenicole730 purplenicole730 requested a review from njooma July 12, 2023 16:09
Copy link
Member

@njooma njooma left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

NICE thanks for all the fixes

@purplenicole730 purplenicole730 merged commit 80098c8 into viamrobotics:main Jul 12, 2023
@purplenicole730 purplenicole730 deleted the RSDK-3788-add-getkinematics-functionality branch July 12, 2023 17:16
@npentrel
Copy link
Contributor

Apologies for the lack of input - this does look great!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants