Commit 21a58beb authored by David Brown's avatar David Brown Committed by David Brown
Browse files

samples: rust: Add README for rust hello world

Create a Readme for this sample, explaining how to build and what it
does.

Signed-off-by: default avatarDavid Brown <david.brown@linaro.org>
parent 42b25cce
Loading
Loading
Loading
Loading
+35 −0
Changes for samples/rust/hello_rust/README.rst: 35 added lines, 0 removed lines.
Original line number Diff line number Diff line
.. _hello_rust_world:

Hello Rust World
################

Overview
********

A simple :ref:`Rust <language_rust>` sample that can be used with many
supported boards and prints a Hello World message to the console.

Building and Running
********************

Once the proper rust toolchain has been installed.  This configuration
can be built and executed on QEMU as follows:

.. zephyr-app-commands::
   :zephyr-app: samples/rust/hello_rust
   :host-os: unix
   :board: qemu_riscv32
   :goals: run
   :compact:

To build for another board, change "qemu_riscv32" above to that
board's name.

Sample Output
=============

.. code-block: console

   Hello world from Rust on qemu_riscv32

Exit QEMU by pressing :kbd:`CTRL+C`