Import code to Visual Studio: Difference between revisions
(4 intermediate revisions by the same user not shown) | |||
Line 1: | Line 1: | ||
Back to [[Basebot]] | Back to [[Basebot]] | ||
== | == Open code == | ||
Visual studio can import an Arduino project. | Visual studio can import an Arduino project. | ||
Line 35: | Line 35: | ||
Using PlatformIO "QUICK ACCESS" -> "PIO Home" -> "Libraries" to add the following libraries: | Using PlatformIO "QUICK ACCESS" -> "PIO Home" -> "Libraries" to add the following libraries: | ||
MPU9250_asukiaaa | |||
Adafruit GFX library | Adafruit GFX library | ||
[[file: | [[file:MS_Visual_Studio_Code_library_import_2.png | 500px]] | ||
Type the name of the library; there are too many to browse. | |||
Click on the library to add the library to the project. | |||
[[file:MS_Visual_Studio_Code_library_import_3.png | 500px]] | |||
The the same with the other library. | |||
[[file: | [[file:MS_Visual_Studio_Code_library_import_1.png | 500px]] |
Latest revision as of 08:18, 1 September 2024
Back to Basebot
Open code
Visual studio can import an Arduino project.
This will make a copy of the Basebot code as a new PlatformIO project.
Open the "Visuel Studio Code" and press the PlatformIO icon .
Using PlatformIO "QUICK ACCESS" -> "PIO Home" -> "Open" and here press "Import Arduino project"
Select Teensy 4.1 as the board type:
The browse to where you saved the Basebot code:
Press "import"
You now get something like this:
Note that the project gets a name with a timestamp and "Teensy 4.1" (in the side panel). This is important if you have imported it multiple times or want to find the code copy.
The file browser shows the configuration file "platformio.ini"; here, we must add the needed libraries.
Add Arduino Libraries
Using PlatformIO "QUICK ACCESS" -> "PIO Home" -> "Libraries" to add the following libraries:
MPU9250_asukiaaa Adafruit GFX library
Type the name of the library; there are too many to browse.
Click on the library to add the library to the project.
The the same with the other library.