Skip to content

Commit

Permalink
Merge pull request #1039 from ArmDeveloperEcosystem/main
Browse files Browse the repository at this point in the history
production update
  • Loading branch information
jasonrandrews committed Jun 26, 2024
2 parents 617456d + a681945 commit 99d36c4
Show file tree
Hide file tree
Showing 110 changed files with 2,227 additions and 257 deletions.
62 changes: 61 additions & 1 deletion .wordlist.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2907,4 +2907,64 @@ untar
xnn
xnnpack
xzf
MacBook
MacBook
AdaBoost
AndroidManifest
AppCompatActivity
CNNs
Caffe
CameraBridgeViewBase
CascadeClassifier
CheckBox
CvCameraViewListener
CvType
DNN
FaceDetection
Haar
IOException
ImageView
Imgproc
JavaCameraView
MatOfRect
Multibox
OpenCV's
OpenCVLoader
OpenCV’s
RGBA
TextView’s
UC
YOLO
buttonStartPreview
buttonStopPreview
cameraPermissionRequestCode
checkBoxProcessing
detectMultiScale
enableEdgeToEdge
enableView
faceCascade
facedetection
filesDir
findViewById
frontalface
getPath
grayFrame
grayscale
haarcascade
initLocal
isOpenCvInitialized
isPreviewActive
loadHaarCascade
onCameraFrame
onCameraViewStarted
onCameraViewStopped
onClickListeners
onCreate
openCV
openCvCameraView
opencvcamera
opencvfacedetection
setCameraPermissionGranted
setContentView
textViewStatus
thresholding
updateControls
4 changes: 2 additions & 2 deletions content/install-guides/aws-greengrass-v2.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@ title: AWS IoT Greengrass
author_primary: Michael Hall
additional_search_terms:
- iot
- cloud
- deploy
- AWS
- Greengrass

layout: installtoolsall
minutes_to_complete: 15
Expand Down
2 changes: 1 addition & 1 deletion content/install-guides/mdk.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ multi_install: false # Set to true if first page of multi-page articl
multitool_install_part: false # Set to true if a sub-page of a multi-page article, else false
layout: installtoolsall # DO NOT MODIFY. Always true for tool install articles
---
[Arm Keil MDK](https://developer.arm.com/Tools%20and%20Software/Keil%20MDK) is the complete software development environment for a range of Arm Cortex-M based microcontroller devices. MDK includes the µVision IDE and debugger, Arm C/C++ compiler, and essential middleware components. It supports more than 9,500 devices and is easy to learn and use.
[Arm Keil MDK](https://developer.arm.com/Tools%20and%20Software/Keil%20MDK) is the complete software development environment for a range of Arm Cortex-M based microcontroller devices. MDK includes the µVision IDE and debugger, Arm C/C++ compiler, and essential middleware components. It supports more than 10,000 devices and is easy to learn and use.

## Before you begin

Expand Down
8 changes: 4 additions & 4 deletions content/install-guides/openvscode-server.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,23 +55,23 @@ Download a release of OpenVSCode Server from the [GitHub release area](https://g
For example, use `wget` to download.

```bash
wget https://github.com/gitpod-io/openvscode-server/releases/download/openvscode-server-v1.79.2/openvscode-server-v1.79.2-linux-arm64.tar.gz
wget https://github.com/gitpod-io/openvscode-server/releases/download/openvscode-server-v1.90.0/openvscode-server-v1.90.0-linux-arm64.tar.gz
```

## Install

Install the download by extracting the file

```bash
tar xvfz openvscode-server-v1.79.2-linux-arm64.tar.gz
tar xvfz openvscode-server-v1.90.0-linux-arm64.tar.gz
```

## Start OpenVSCode Server

To start OpenVSCode Server run:

```bash
./openvscode-server-v1.79.2-linux-arm64/bin/openvscode-server
./openvscode-server-v1.90.0-linux-arm64/bin/openvscode-server
```

The server will print a URL to access VS Code in a browser. The URL is localhost URL. If your machine is a remote system or a Linux subsystem there are two options to connect using your local browser.
Expand Down Expand Up @@ -114,7 +114,7 @@ On ChromeOS you can use the Linux configuration settings to automatically do por
There are command line options to change the port, the token, and other configuration options. To see the options run:

```bash
./openvscode-server-v1.79.2-linux-arm64/bin/openvscode-server --help
./openvscode-server-v1.90.0-linux-arm64/bin/openvscode-server --help
```

If you are running all on a local machine the token can be eliminated using the `--without-connection-token` option.
Expand Down
12 changes: 9 additions & 3 deletions content/install-guides/porting-advisor.md
Original file line number Diff line number Diff line change
Expand Up @@ -126,6 +126,7 @@ Enter the Python virtual environment and install the required packages:
```bash
source .venv/bin/activate
pip install -r requirements.txt
pip install pyinstaller certifi
```

Confirm Porting Advisor runs as a script:
Expand Down Expand Up @@ -183,15 +184,20 @@ The Porting Advisor includes some small examples in the `sample-projects` direct
Run Porting Advisor on a Go sample with the executable:

```bash
./dist/porting-advisor-linux-aarch64 sample-projects/go-samples/incompatible
./dist/porting-advisor-linux-aarch64 sample-projects/java-samples/
```

The recommendations for this application will be printed along with links on where to get more details.

```output
Porting Advisor for Graviton v1.1.1
Report date: 2024-06-25 08:47:06
2 files scanned.
detected go code. min version 1.16 is required. version 1.18 or above is recommended. we detected that you have version 1.15. see https://github.com/aws/aws-graviton-getting-started/blob/main/golang.md for more details.
sample-projects/go-samples/incompatible/go.mod: using dependency library github.com/golang/snappy version 0.0.1. upgrade to at least version 0.0.2
detected java code. we recommend using Corretto. see https://aws.amazon.com/corretto/ for more details.
detected java code. min version 8 is required. version 11 or above is recommended. see https://github.com/aws/aws-graviton-getting-started/blob/main/java.md for more details.
Report generated successfully. Hint: you can use --output FILENAME.html to generate an HTML report.
```

Try out the other sample projects.
Expand Down
4 changes: 1 addition & 3 deletions content/install-guides/vscode-tunnels.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,11 @@ title: VS Code Tunnels
### Optional additional search terms (one per line) to assist in finding the article
additional_search_terms:
- ide
- vs
- vscode
- visual studio


### Estimated completion time in minutes (please use integer multiple of 5)
minutes_to_complete: 15
minutes_to_complete: 10

author_primary: Jason Andrews

Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
---
title: Build multi-architecture container images with Docker Build Cloud

draft: false

minutes_to_complete: 30

who_is_this_for: This is an introductory topic for software developers who want to learn how to use Docker Build Cloud.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
---
title: Build multi-architecture container images with GitHub Arm-hosted runners

draft: false

minutes_to_complete: 30

who_is_this_for: This is an introductory topic for software developers who want to learn how to use Arm-hosted runners for GitHub Actions jobs.
Expand Down
1 change: 0 additions & 1 deletion content/learning-paths/cross-platform/ipexplorer/_index.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
---
title: Custom software for simulation with IP Explorer
draft: false
minutes_to_complete: 60

who_is_this_for: This is an introductory topic for IP Explorer users using the software simulation platforms available.
Expand Down
77 changes: 48 additions & 29 deletions content/learning-paths/cross-platform/matrix/1-foundations.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ weight: 2
layout: learningpathall
---

In this section you will setup the structure for the Matrix processing library.
In this section you will setup the structure for the Matrix processing library.
At the end, you will be able to build the library and an application that uses the library on
all supported platforms: macOS, Linux, and Windows.

Expand All @@ -20,30 +20,42 @@ You will need the following tools, make sure they are available on your developm
- A build system: [GNU Make](https://www.gnu.org/software/make/) or
[Ninja](https://ninja-build.org/)
- A documentation generator: [Doxygen](https://www.doxygen.nl/)
- An IDE ([Visual Studio Code](https://code.visualstudio.com/) is a popular
choice) or a text editor ([Vim](https://www.vim.org/), [GNU
Emacs](https://www.gnu.org/software/emacs/), [Sublime
Text](https://www.sublimetext.com/) are popular choices).

On a Ubuntu machine, they can be installed with:

```BASH
sudo apt-get install build-essential clang ninja-build cmake doxygen -y
```

On top of those tools, you will also need an IDE (Integrated Development
Environment). [Visual Studio Code](https://code.visualstudio.com/) is a popular
choice, and you can install it by following the
[instructions](https://code.visualstudio.com/docs/setup/linux). Alternatively,
you can use a text editor like [Vim](https://www.vim.org/), [GNU
Emacs](https://www.gnu.org/software/emacs/) or [Sublime
Text](https://www.sublimetext.com/) which are also popular choices and all
support extensions that make C++ development easy.


## About configuring vs. building

When developing software, two separate but linked aspects must be
considered:
- How to configure the project
considered:
- How to configure the project
- How to build the source code

The first aspect is about configuring the project, which covers:
- The platform itself (Windows, macOS, Linux): each platform has specific
requirements and usage.
- Discovering what is available on the platform. For example, `libpng` might
be required by the project to process images in the PNG format, and it may or may not
be available on the platform. Alternatively, it might be available, but not with a
suitable configuration for the project needs. You may need to
maintain a custom version of required dependencies.
- Discovering what is available on the platform. For example, `libpng` might be
required by the project to process images in the PNG format, and it may or may
not be available on the platform. Alternatively, it might be available, but
not with a suitable configuration for the project needs. You may need to
maintain a custom version of required dependencies.
- Selecting project features: in some cases, projects might offer some degree of
configuration, for example to disable support for PNG format images when a
user knows that a feature will never be used. This is done to avoid bloating the
application with never used code and functionality.
user knows that a feature will never be used. This is done to avoid bloating
the application with never used code and functionality.

The second aspect is about building the project, which covers:
- Compiling the human readable source code to produce binaries (executables and
Expand All @@ -56,9 +68,9 @@ The second aspect is about building the project, which covers:
they spend most of their time in an edit-compile-run loop.

These two aspects are so common that tools are available to ease development and
cover all situations and platforms. The tool used for this project is
cover all situations and platforms. The tool used for this project is
CMake. CMake is available on all platforms and used by
numerous projects, from very small projects to large
numerous projects, from very small projects to large
projects like [LLVM](https://www.llvm.org) or [Qt](https://www.qt.io/).

## Directory structure
Expand Down Expand Up @@ -117,7 +129,7 @@ applications' source code will be located in `src/`.

## Add a demo application

There is nothing like creating the canonical `Hello, World!` application.
There is nothing like creating the canonical `Hello, World!` application.

Use your favorite text editor or IDE to
create the file `src/howdy.cpp` and add the following content to it:
Expand Down Expand Up @@ -187,7 +199,8 @@ CXX=clang++ cmake -G Ninja -B build -S .
-- Build files have been written to: .../chapter-1/build
```

To use the default build system, Unix Makefiles, you can just the `-G Ninja` above.
To use the default build system, Unix Makefiles, you can just omit the `-G Ninja`
from the command line.

Now that your project is configured, build it with:

Expand Down Expand Up @@ -243,27 +256,33 @@ Now, you can create a program that will make use of the

{{< include-code CPP "content/learning-paths/cross-platform/matrix/projects/chapter-1/src/getVersion.cpp" >}}

Finally, add the instructions below in the top-level `CMakeLists.txt`
to build the Matrix library, with `add_library`, and instruct CMake where the
Matrix library header files can be found with `target_include_directories` (and
specify along the way that C++17 is to be used for the Matrix library with
`target_compile_features`), and eventually compile our `src/getVersion.cpp` file
and link it to the Matrix library with `add_executable` and
`target_link_library` to produce the `matrix-getVersion` executable:
Finally, add the instructions below in the top-level `CMakeLists.txt`:

{{< include-code TXT "content/learning-paths/cross-platform/matrix/projects/chapter-1/CMakeLists.txt" >}}

Now build and run the program with:
The `add_library` instructs CMake how to build the Matrix library. The
`target_include_directories` specifies where the Matrix library header are
located, and the `target_compile_features` specifies that C++17 is the version
of the C++ language that is used by the Matrix library. The `matrix-getVersion`
executable is compiled from the `src/getVersion.cpp` source file with the
`add_executable` command and has to be linked with our Matrix library with the
`target_link_library` command.

```BASH { output_lines = "2-3,5" }
Now build the program with:

```BASH { output_lines = "2" }
ninja
[6/6] Linking CXX executable matrix-getVersion
```

and run it with:

```BASH { output_lines = "2" }
./matrix-getVersion
Using Matrix version: 0.1.0
```

Congratulations, you have constructed a library and a program to test it.
Congratulations, you have constructed a library and a program to test it.

## What have you achieved so far ?

Expand Down Expand Up @@ -301,7 +320,7 @@ to invoke the compiler, build libraries, and link with those libraries on each o
those platforms.

On top of hiding the platform specific details, CMake also does not force a
development environment onto project developers as you can use your favorite editor or IDE.
development environment onto project developers as you can use your favorite editor or IDE.
For example, Visual Studio Code can work seamlessly with CMake thanks to some plugins, and CMake can
generate project files for several popular IDEs, such as Xcode, Sublime Text, Eclipse,
CodeBlocks, and CodeLite. You can run `cmake --help` to get a
Expand Down
Loading

0 comments on commit 99d36c4

Please sign in to comment.