You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by "lupyuen (via GitHub)" <gi...@apache.org> on 2024/08/08 01:01:30 UTC
[PR] risc-v/qemu-rv: Add Build Config for leds64_rust [nuttx]
lupyuen opened a new pull request, #12862:
URL: https://github.com/apache/nuttx/pull/12862
## Summary
This PR adds a new Build Config `rv-virt:leds64_rust` that builds the Rust App `leds_rust` for QEMU RISC-V 64-bit. The build requires the [Rust Target `riscv64gc-unknown-none-elf`](https://github.com/apache/nuttx/pull/12858):
```bash
rustup target add riscv64gc-unknown-none-elf
```
### New Files
`boards/risc-v/qemu-rv/rv-virt/configs/leds64_rust/defconfig`: Add new Build Config `rv-virt:leds64_rust`
### Updated Docs
`applications/examples/leds_rust/index.rst`: Add `leds_rust` example app
`platforms/risc-v/qemu-rv/boards/rv-virt/index.rst`: Add `rv-virt:leds64_rust` config
## Impact
No impact on existing code, since `rv-virt:leds64_rust` is unused by the current code.
`leds_rust` will be compiled for every run of NuttX CI. This will validate whether Rust Apps are built correctly for QEMU RISC-V 64-bit. We have added the Rust Target `riscv64gc-unknown-none-elf` to the Docker Image for NuttX CI: https://github.com/apache/nuttx/pull/12858
## Testing
We tested the `leds_rust` example app on `rv-virt:leds64_rust` (QEMU RISC-V 64-bit): [Test Log](https://gist.github.com/lupyuen/e44e8db4cd1a0ab67dad741aa1b314dd#file-nuttx-rust-leds64-log-L456-L472)
```text
$ tools/configure.sh rv-virt:leds64_rust
...
NuttShell (NSH) NuttX-12.4.0
nsh> uname -a
NuttX 12.4.0 e0432cfc75b Aug 8 2024 08:57:51 risc-v rv-virt
nsh> leds_rust
Hello, Rust!!
Opening /dev/userleds
Set LED 1 to 1
board_userled: LED 1 set to 1
board_userled: LED 2 set to 0
board_userled: LED 3 set to 0
Sleeping...
Set LED 1 to 0
board_userled: LED 1 set to 0
board_userled: LED 2 set to 0
board_userled: LED 3 set to 0
```
We also tested `rv-virt:leds64_rust` on the Docker Image for NuttX CI: https://github.com/apache/nuttx/pull/12858
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@nuttx.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] risc-v/qemu-rv: Add Build Config for leds64_rust [nuttx]
Posted by "xiaoxiang781216 (via GitHub)" <gi...@apache.org>.
xiaoxiang781216 merged PR #12862:
URL: https://github.com/apache/nuttx/pull/12862
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@nuttx.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org