smoltcp
embassy
smoltcp | embassy | |
---|---|---|
10 | 85 | |
3,957 | 6,401 | |
1.5% | 3.9% | |
8.7 | 9.9 | |
17 days ago | 6 days ago | |
Rust | Rust | |
BSD Zero Clause License | Apache License 2.0 |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
smoltcp
- LwIP – Lightweight IP Stack
-
Implementing TCP in Rust
There is also the Rust TCP/IP stack https://github.com/smoltcp-rs/smoltcp which is not mentioned as reference (and it's probably more useful to have a look there than querying ChatGPT).
- RFC2217 implementation written in Rust
-
Create TCP connection with Pnet
Trying to dig out a link for you, will edit when I find it; TCP and Layer 4 raw sockets do not play nicely together on many platforms. You’ll probably have to send at the datalink layer and/or use something like https://github.com/smoltcp-rs/smoltcp
-
Introduction to TCP and Sockets
This seems close to what you're asking for: https://github.com/smoltcp-rs/smoltcp
A small-ish tcp/ip stack, in rust.
- smoltcp is a standalone, event-driven TCP/IP stack that is designed for bare-metal, real-time systems. Its design goals are simplicity and robustness.
-
Rust embedded and networking
You can look into smoltcp
-
What are some low level networking libraries that y'all recommend?
smoltcp
-
Kerla: Monolithic kernel in Rust, aiming for Linux ABI compatibility
This here is a kernel including a memory-safe TCP/IP stack (https://github.com/smoltcp-rs/smoltcp/), and not having it crash or be full of security vulnerabilities due to preventable memory corruption is a quality beyond personal language preferences.
-
Let's suppose for a minute that I've COMPLETELY lost my mind
Oh, and you also probably want to check out smoltcp, a userspace/"no operating system required" networking stack that we often use in embedded rust.
embassy
-
Rust on the RP2350
Embassy got _some_ support for rp2350 for quite some time now
https://github.com/embassy-rs/embassy
- Zlib-rs is faster than C
- Embassy: Modern embedded framework, using Rust and async
- Rust async framework for embedded systems
-
Pebble smartwatch firmware released as open-source
TL;DR: No. Maybe? Depends.
It's probably reasonable to make a distinction between "Real Time" desktop/server OS (on CPUs) vs "Real Time" embedded hardware OS (on MCUs).
(Even aside from any hard-/soft- real time distinction.)
On the embedded side, in addition to FreeRTOS (upon which Pebble OS is built), I'm aware of others with reasonably high profile such as:
* Zephyr (Linux Foundation, C): https://en.wikipedia.org/wiki/Zephyr_(operating_system)
* NuttX (Apache Software Foundation, C & C++): https://en.wikipedia.org/wiki/NuttX
In addition, there's also some "up & coming" Rust language projects which fall somewhere along the "framework" to "OS" spectrum (in part, via https://arewertosyet.com):
* Tock: https://github.com/tock/tock
* Embassy: https://github.com/embassy-rs/embassy
* Hubris: https://hubris.oxide.computer
On the desktop side, I seem to recall in the past, OS such as BeOS & QNX have been presented as a possible future for real time desktop OS that hasn't arrived.
As someone else already mentioned, PREEMPT_RT being merged for Linux is a recent development somewhat in this space which could have impact on both desktop & "embedded" situations but suitability varies dependent on, say, whether you're wanting to use it for audio production versus controlling some 10 tonne robot operating next to humans.
Hope this at least goes some way to answering your question. :)
- Embassy: Replacing RTOS with a Rust async scheduler
-
Apple is Killing Swift – A great language strangled by governance
The other comment implied it but I think it's worth pointing out that:
> embedded applications that can't have asynchronous execution
Is most definitely not the case.
They can't have the same type of async runtime that would be optimal for a web server or the likes (and I'm not sure all desktop applications and web servers are going to always benefit from the same runtime in the same way), but that's a point in favour of Rust's model imho
If you're interested this is an embedded async runtime that's expected to run in no-std and no-alloc environments
https://embassy.dev/
-
Impl Snake For Micro:bit - Embedded async Rust on BBC Micro:bit with Embassy
In this article, I will guide you through creating a Snake game in embedded Rust on the BBC Micro:bit using the asynchronous framework Embassy.
-
A review after using Rust on embedded in production for over a year
Rust solved this by autogenning code from mfgr published device xml descriptors. Eg https://embassy.dev/
Better than any C(++) embedded hal I've used
- Building a GATT Server on Pi Pico W
What are some alternatives?
tock - A secure embedded operating system for microcontrollers
rtic - Real-Time Interrupt-driven Concurrency (RTIC) framework for ARM Cortex-M microcontrollers
mosys
rust-raspberrypi-OS-tutorials - :books: Learn to write an embedded OS in Rust :crab:
nrf-hal - A Rust HAL for the nRF family of devices