Skip to content

Commit

Permalink
DOC-1415: Add new rover fragments (#2385)
Browse files Browse the repository at this point in the history
  • Loading branch information
sguequierre authored Jan 12, 2024
1 parent ae3f249 commit f88cfa3
Show file tree
Hide file tree
Showing 4 changed files with 68 additions and 10 deletions.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
title: "Add the Viam Fragment to your Machine"
linkTitle: "Add the Viam Fragment to your Machine"
title: "Add a Rover Fragment to your Machine"
linkTitle: "Add a Rover Fragment to your Machine"
weight: 20
type: "docs"
tags: ["rover", "tutorial"]
Expand All @@ -10,30 +10,60 @@ aliases:
---

To be able to drive your rover, you need to configure it.
Viam provides a reusable {{% glossary_tooltip term_id="fragment" text="*fragment*" %}} for [Viam rovers](https://www.viam.com/resources/rover).
Viam provides reusable {{% glossary_tooltip term_id="fragment" text="*fragments*" %}} for [Viam rovers](https://www.viam.com/resources/rover).

## Prerequisites

- An assembled Viam Rover with a Raspberry Pi.
- An assembled Viam Rover.
For assembly instructions, see [Unbox and Set Up your Viam Rover](../rover-tutorial/)
- The Pi is connected to [the Viam app](https://app.viam.com).
- The board is connected to [the Viam app](https://app.viam.com).
To add your Pi to the Viam app, refer to [the rover setup guide](/get-started/try-viam/rover-resources/rover-tutorial/#control-your-rover-on-the-viam-app).

## Add the fragment

Follow the appropriate instructions for the model of rover and board you have:

{{< tabs >}}
{{% tab name="Viam Rover 2 (Pi)" %}}

Navigate to your machine in [the Viam app](https://app.viam.com/robots).
On the **Config** tab, click on the **Fragments** subtab.

{{<imgproc src="get-started/try-viam/rover-resources/fragments/fragments_tab.png" resize="1200x" alt="Fragments tab inside the Viam app">}}
On the **Fragments** tab, you can see the available fragments to add.
Find `ViamRover2-2024-rpi4-a` and click **Add** to add the fragment to your machine configuration:

{{<imgproc src="get-started/try-viam/rover-resources/fragments/fragments_list.png" resize="400x" alt="List of available fragments">}}

Click **Save Config** to save the new configuration.

The fragment adds the following components to your machine's JSON configuration:

- A [board component](/components/board/pi/) named `local` representing the Raspberry Pi.
- Two [motors](/components/motor/gpio/) (`right` and `left`)
- The configured pin numbers correspond to where the motor drivers are connected to the board.
- Two [encoders](/components/encoder/single/), one for each motor
- A wheeled [base](/components/base/), an abstraction that coordinates the movement of the right and left motors
- A webcam [camera](/components/camera/webcam/)
- An [accelerometer](/components/movement-sensor/mpu6050/)
- A [power sensor](/components/power-sensor/ina219/)

For information about how to configure components yourself when you are not using the fragment, click the links on each component above.
To see the configured pin numbers and other values specific to this fragment, [view it in the app](https://app.viam.com/fragment?id=7c413f24-691d-4ae6-a759-df3654cfe4c8).

{{% /tab %}}
{{% tab name="Viam Rover 1 (Pi)" %}}

Navigate to your machine in [the Viam app](https://app.viam.com/robots).
On the **Config** tab, click on the **Fragments** subtab.

On the **Fragments** tab, you can see the available fragments to add.
Find `ViamRover202210b` and click `Add` to add the fragment to your machine configuration.
Find `ViamRover202210b` and click `Add` to add the fragment to your machine configuration:

{{<imgproc src="get-started/try-viam/rover-resources/fragments/fragments_list.png" resize="1200x" alt="List of available fragments">}}
{{<imgproc src="get-started/try-viam/rover-resources/fragments/fragments_list.png" resize="400x" alt="List of available fragments">}}

Click **Save Config** to save the new configuration.

{{<imgproc src="get-started/try-viam/rover-resources/fragments/fragment_configuration.png" resize="1200x" alt="Fragment configuration">}}
{{<imgproc src="get-started/try-viam/rover-resources/fragments/fragment_configuration.png" resize="400x" alt="Fragment configuration">}}

The fragment adds the following components to your machine's JSON configuration:

Expand All @@ -57,7 +87,35 @@ Typically, this would suggest that they should be configured as enable pins, but
{{% /alert %}}

For information about how you would configure a component yourself if you weren't using the fragment, click the links on each component above.
To see the configured pin numbers and other values specific to this fragment, [see the Viam Rover fragment in the Viam app](https://app.viam.com/fragment?id=3e8e0e1c-f515-4eac-8307-b6c9de7cfb84).
To see the configured pin numbers and other values specific to this fragment, [view it in the app](https://app.viam.com/fragment?id=3e8e0e1c-f515-4eac-8307-b6c9de7cfb84).

{{% /tab %}}
{{% tab name="Viam Rover 2 (Jetson Nano and Orin Nano)" %}}

Navigate to your machine in [the Viam app](https://app.viam.com/robots).
On the **Config** tab, click on the **Fragments** subtab.

On the **Fragments** tab, you can see the available fragments to add.
Find `ViamRover2-2024-jetson-a` and click `Add` to add the fragment to your machine configuration.

Click **Save Config** to save the new configuration.

The fragment adds the following components to your machine's JSON configuration:

- A [board component](/components/board/pi/) named `local` representing the Jetson.
- Two [motors](/components/motor/gpio/) (`right` and `left`)
- The configured pin numbers correspond to where the motor drivers are connected to the board.
- Two [encoders](/components/encoder/single/), one for each motor
- A wheeled [base](/components/base/), an abstraction that coordinates the movement of the right and left motors
- A webcam [camera](/components/camera/webcam/)
- An [accelerometer](/components/movement-sensor/mpu6050/)
- A [power sensor](/components/power-sensor/ina219/)

For information about how to configure components yourself when you are not using the fragment, click the links on each component above.
To see the configured pin numbers and other values specific to this fragment, [view it in the app](https://app.viam.com/fragment?id=747e1f43-309b-4311-b1d9-1dfca45bd097).

{{% /tab %}}
{{< /tabs >}}

## See the components on the configuration page

Expand Down

0 comments on commit f88cfa3

Please sign in to comment.