Skip to content

adding a dedicated getting started guide #1975

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 56 commits into from
May 23, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
56 commits
Select commit Hold shift + click to select a range
54a3b52
adding a dedicated getting started guide
GDJose May 21, 2024
c8e4889
fixing linter issues
GDJose May 22, 2024
8e04eab
fixing linter issues
GDJose May 22, 2024
964ffef
fixing spell check
GDJose May 22, 2024
9e59318
fixing linter issues
GDJose May 22, 2024
3e33053
fixing linter issues
GDJose May 22, 2024
ff13fe0
Update content/hardware/08.edu/solution-and-kits/alvik/tutorials/gett…
GDJose May 22, 2024
b8fe5b1
fixing small issues
GDJose May 22, 2024
3f4bd02
Update content/hardware/08.edu/solution-and-kits/alvik/tutorials/gett…
GDJose May 22, 2024
0d8e4ce
Update content/hardware/08.edu/solution-and-kits/alvik/tutorials/gett…
GDJose May 22, 2024
84db113
Update content/hardware/08.edu/solution-and-kits/alvik/tutorials/gett…
GDJose May 22, 2024
2c47639
Update content/hardware/08.edu/solution-and-kits/alvik/tutorials/gett…
GDJose May 22, 2024
95a8161
Update content/hardware/08.edu/solution-and-kits/alvik/tutorials/gett…
GDJose May 22, 2024
d2bf378
Update content/hardware/08.edu/solution-and-kits/alvik/tutorials/gett…
GDJose May 22, 2024
a1cf56b
Update content/hardware/08.edu/solution-and-kits/alvik/tutorials/gett…
GDJose May 22, 2024
5d05159
Update content/hardware/08.edu/solution-and-kits/alvik/tutorials/gett…
GDJose May 22, 2024
4429597
Update content/hardware/08.edu/solution-and-kits/alvik/tutorials/gett…
GDJose May 22, 2024
7a3fdda
fixing issues with list numbes
GDJose May 22, 2024
85de9ad
Merge branch 'JGD_new-getting_started' of https://github.com/arduino/…
GDJose May 22, 2024
7d59fe3
fix bad merge
Matteo-it May 22, 2024
abdfdac
fixing linter issues
GDJose May 22, 2024
d6d9021
fixing linter issues
GDJose May 22, 2024
962fccf
fixing spell check
GDJose May 22, 2024
726f23d
fixing linter issues
GDJose May 22, 2024
7c5a9de
fixing linter issues
GDJose May 22, 2024
dd0b3a6
Update content/hardware/08.edu/solution-and-kits/alvik/tutorials/gett…
GDJose May 22, 2024
d2b6579
fixing small issues
GDJose May 22, 2024
4770efc
fixing issues with list numbes
GDJose May 22, 2024
7cc15d9
Update content/hardware/08.edu/solution-and-kits/alvik/tutorials/gett…
GDJose May 22, 2024
7e41b6c
Update content/hardware/08.edu/solution-and-kits/alvik/tutorials/gett…
GDJose May 22, 2024
4688ac1
Update content/hardware/08.edu/solution-and-kits/alvik/tutorials/gett…
GDJose May 22, 2024
4c3e633
Update content/hardware/08.edu/solution-and-kits/alvik/tutorials/gett…
GDJose May 22, 2024
606edc2
Update content/hardware/08.edu/solution-and-kits/alvik/tutorials/gett…
GDJose May 22, 2024
85f03c4
Update content/hardware/08.edu/solution-and-kits/alvik/tutorials/gett…
GDJose May 22, 2024
23daec9
Update content/hardware/08.edu/solution-and-kits/alvik/tutorials/gett…
GDJose May 22, 2024
746acb5
Merge branch 'JGD_new-getting_started' of https://github.com/arduino/…
GDJose May 22, 2024
42c6104
updating code
GDJose May 22, 2024
8a466d0
fixing linter issues
GDJose May 22, 2024
ac5df75
fixing linter issues
GDJose May 22, 2024
e6d4cf3
Update content/hardware/08.edu/solution-and-kits/alvik/tutorials/gett…
GDJose May 22, 2024
a0cba16
Update content/hardware/08.edu/solution-and-kits/alvik/tutorials/gett…
GDJose May 22, 2024
1ce607b
Update content/hardware/08.edu/solution-and-kits/alvik/tutorials/gett…
GDJose May 22, 2024
b8da424
Update content/hardware/08.edu/solution-and-kits/alvik/tutorials/gett…
GDJose May 22, 2024
5cb80cb
Update content/hardware/08.edu/solution-and-kits/alvik/tutorials/gett…
GDJose May 22, 2024
4cd2c54
applying suggestions
GDJose May 22, 2024
9eb649d
Merge branch 'JGD_new-getting_started' of https://github.com/arduino/…
GDJose May 22, 2024
9d8cd5c
Grammar fixes, linter error fixes
jcarolinares May 23, 2024
3681090
fixing linter
GDJose May 23, 2024
f6a6ab4
Merge branch 'JGD_new-getting_started' of https://github.com/arduino/…
GDJose May 23, 2024
6ca830f
Update content/hardware/08.edu/solution-and-kits/alvik/tutorials/gett…
GDJose May 23, 2024
f500197
Update content/hardware/08.edu/solution-and-kits/alvik/tutorials/gett…
GDJose May 23, 2024
be5f8f6
Update content/hardware/08.edu/solution-and-kits/alvik/tutorials/gett…
GDJose May 23, 2024
1532e3f
Update content/hardware/08.edu/solution-and-kits/alvik/tutorials/gett…
GDJose May 23, 2024
561310d
upating User manual title
GDJose May 23, 2024
e27edb1
Merge branch 'JGD_new-getting_started' of https://github.com/arduino/…
GDJose May 23, 2024
246e104
fixing link
GDJose May 23, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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.
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.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Original file line number Diff line number Diff line change
@@ -0,0 +1,111 @@
---
title: "Getting Started with Alvik"
difficulty: beginner
description: "Take your first steps with Arduino® Alvik."
tags:
- Robot, MicroPython, Education
author: "Jose Garcia"
---
## Getting Started With Alvik

Arduino® Alvik is a powerful and versatile robot specifically designed for programming and STEAM education.
![Alvik's Robot](assets/alvik_main.jpg)

Powered by the Arduino® Nano ESP32, Alvik offers diverse learning paths through different programming languages including MicroPython, the Arduino language, and block-based coding; enabling different possibilities to explore Robotics, IoT and Artificial Intelligence.

### Unboxing Alvik

![Selecting one of the ready-to-go examples](assets/select-examples.gif)

Your Alvik robot is equipped with three ready-to-go examples. To choose one of the examples, just turn your Alvik ON, move the switch located at the bottom right corner of the robot to the right, wait until the LEDs turn blue and use the Up and Down buttons to pick one color, then hit the "tick" confirmation button. It's that easy!

- **Red Program (Touch Mode):** Use the arrows to tell your robot what to do: up and down for moving forward and backward by 10 cm, and left and right for turning 90 degrees in each of the directions. The robot will collect instructions until you press the "tick" confirmation button. Once you press it, the robot will execute all the actions in order.

- **Green Program (Hand Follower):** Your robot will keep a steady 10 cm distance from your hand or any object you put in front of it. Press the "tick" confirmation button again to make the robot start following your hand. You can stop the robot at any moment by pressing the "X" cancel button.

- **Blue Program (Line Follower):** Your robot will glide along a black line on a white surface. Press the "tick" confirmation button again to make the robot follow the line. You can stop the robot at any moment by pressing the "X" cancel button. **The recommended size for the "black line" to follow is between 2-3 cm wide.**

Now that you have played with Alvik and have seen it moving, it is time to know more in-depth how it is built and how to program Alvik to do amazing things.

### Let's Start Coding Alvik

Alvik is intended to be programmed with MicroPyton. We recommend you to install the [Arduino Lab for MicroPython](https://labs.arduino.cc/en/labs/micropython) editor. Follow the instructions next to the download link to install it and open the IDE

Now that all the previous steps have been set, let's see how to make Alvik moving across your room while avoiding objects! Let's create custom program for Alvik that:

* Move forward until detecting an object in front of it
* Dodge the object by turning on
* Continue on its way by moving forwards again

***Alvik does not have its own parachute! Be careful avoid using Alvik on your table or it could fall over the edge!***

**1. **Create an Alvik folder in your computer and set it as the path of the Arduino Lab for MicroPython IDE.

![Adding Alvik folder path to the IDE](assets/alvik_folder_path.png)

**2. **Create a new file "obstacle_avoider.py" in your local folder.

![Creating obstacle_avoider.py file](assets/creating_file.png)

**3. **Double-click on the file to open it. Once it is opened, erase the text on it and add the following code.

![Adding custom code](assets/adding_custom_code.gif)

``` python
from arduino_alvik import ArduinoAlvik
from time import sleep_ms
import sys

alvik = ArduinoAlvik()
alvik.begin()
sleep_ms(5000) # waiting for the robot to setup
distance = 12
degrees = 45.00
speed = 10.00

while (True):

distance_l, distance_cl, distance_c, distance_r, distance_cr = alvik.get_distance()
sleep_ms(50)
print(distance_c)

if distance_c < distance:
alvik.rotate(degrees, 'deg')
elif distance_cl < distance:
alvik.rotate(degrees, 'deg')
elif distance_cr < distance:
alvik.rotate(degrees, 'deg')
elif distance_l < distance:
alvik.rotate(degrees, 'deg')
elif distance_r < distance:
alvik.rotate(degrees, 'deg')
else:
alvik.drive(speed, 0.0, linear_unit='cm/s')

```

**4. **Connect Alvik to your PC using the cable included in the box, under the tray.

![Connecting Alvik to the PC](assets/connecting_alvik.gif)

***As a good practice, to prevent the Alvik from falling off the table, turn it OFF when you are programming it.***

***For Alvik to be recognized by your computer, it must be turned OFF.***

**5. **Once Alvik is connected to the PC, connect it to the Arduino Lab for MicroPython and open the _main.py_ file in the Alvik folder. Once the file is opened let's replace the `import demo` statement with `import obstacle_avoider`.

![Connecting Alvik to the IDE](assets/connecting_alvik_ide.gif)

***If you want to go back to the out of the box experience where you could select between red, green and blue programs, you only need to modify the _main.py_ again replacing the `import obstacle_avoider` statement by `import demo`.***

**6. **The last step is to move the _obstacle_avoider.py_ file from the local repository to Alvik's memory.

![Moving file from local to Alvik's memory](assets/local2memory.gif)

You are now all set, disconnect Alvik from the computer, put some obstacles around Alvik, turn it ON, and see how Alvik navigates around your room avoiding them.

### Next Steps

* There is a set of already built examples that will help you to better understand how Alvik works, you can download them from [this link](https://github.com/arduino/arduino-alvik-mpy/archive/refs/tags/0.2.0.zip), unzip them in your already created _alvik_ folder and you will be able to see them straight away in the Arduino Labs for MicroPython IDE.
* If you want to learn more about how Alvik is built or which functions you can use to program it, visit the documentation in the [Docs space for Alvik](https://docs.arduino.cc/hardware/alvik/) and follow the respective [Alvik's User Manual](https://docs.arduino.cc/hardware/alvik/user-manual) to know more about how to build incredible projects with your robot!
* If you want to follow step-by-step guided projects following an educational approach to learn MicroPython and robotics topics with Alvik, follow the [Explore Robotics in MicroPython](https://courses.arduino.cc/explore-robotics-micropython/) course.
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.
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
---
title: "Getting Started with Alvik"
title: "Alvik User Manual"
difficulty: beginner
description: "Discover how to use and program Alvik's robot"
description: "Discover how to use and program Arduino® Alvik's robot"
tags:
- Robot
author: "Paolo Cavagnolo"
Expand All @@ -15,22 +15,6 @@ Powered by the Arduino® Nano ESP32, Alvik offers diverse learning paths through

In this tutorial you will find useful information to get started, test and maintain Alvik.

## Alvik's First Use

![Selecting one of the ready-to-go examples](assets/select-examples.gif)

Your Alvik robot is equipped with three ready-to-go examples. To choose one of the examples, just turn your Alvik ON, wait until the LEDs turn blue and use the Up and Down buttons to pick one color, then hit the "tick" confirmation button. It's that easy!

* **Red Program (Touch Mode):** Use the arrows to tell your robot what to do: up and down for moving forward and backward by 10 cm, and left and right for turning 90 degrees in each of the directions. The robot will collect instructions until you press the "tick" confirmation button. Once you press it, the robot will execute all the actions in order.

* **Green Program (Hand Follower):** Your robot will keep a steady 10 cm distance from your hand or any object you put in front of it. Press the "tick" confirmation button again to make the robot start following your hand.

* **Blue Program (Line Follower):** Your robot will glide along a black line on a white surface. Press the "tick" confirmation button again to make the robot follow the line. You can stop the robot at any moment by pressing the "X" cancel button. __The recommended size for the "black line" to follow is between 2-3 cm wide.__

***The product is sensitive to electrostatic discharge, observe ESD-safe handling procedures when working with it***

Now that you have played with Alvik and have seen it moving, it is time to know more in-depth how it is built and how to get much more than the out-of-the-box experience from it.

## Alvik in Detail

![Unboxing Alvik](assets/unboxing.jpg)
Expand Down
Loading