Home > On-Demand Archives > Workshops >
Rust for C Programmers
Jacob Beningo - Watch Now - EOC 2023 - Duration: 02:19:55
If you plan to attend and work through the hands-on materials, we recommend that you set up the following tools prior to the class:
1) Visit https://rustup.rs/ and follow the instructions to install Rust
2) Visit https://docs.rust-embedded.
- itmdump
- cargo-binutils
- arm-none-eabi-gdb
- OpenOCD
The C programming language has been a staple of embedded software development for 50 years. Many languages like Ada, C++, and others have attempted to usurp it, only to fail. Rust is a memory-safe systems programming language that has been gaining interest across a wide variety of industries. This workshop will introduce the Rust programming language for experienced C programmers.
The focus will be on highlighting the similarities and differences between the two languages, with an emphasis on showing how Rust can provide improved memory safety and performance without sacrificing the low-level control that C programmers are accustomed to. Attendees will learn the basics of Rust's syntax and standard library, as well as best practices for writing safe and efficient code in Rust. By the end of the workshop, participants will have a solid understanding of Rust and will be able to start using it in their own projects.
Example topics covered in this workshop include:
- Similarities and differences between C and Rust
- An introduction to the Rust toolchain
- Memory mapped I/O
- How to utilize peripheral access crate (PAC) and HAL crate
- Best practices for developing embedded applications in Rust
Examples and code walk throughs will use the STM32F3 Discovery board
11:03:18 From Stephane to Jacob Beningo(Direct Message) : Make sure to record from your side as well 11:06:31 From Stephane : Direct link to slides: https://s3.amazonaws.com/embeddedonlineconference/eoc/sessions_slides/Rust_for_C_Programmers.pdf 11:08:50 From Jacob Beningo : How much experience do you have in Rust? 11:08:54 From Jacob Beningo : None 11:08:58 From Jacob Beningo : Some 11:08:59 From Jacob Beningo : Expert 11:09:04 From Cameron : Reacted to "None" with ๐ 11:09:05 From Jeroen : Reacted to "None" with ๐ 11:09:06 From Sally Schupbach : Reacted to "None" with ๐ 11:09:06 From alaraujo : Reacted to "None" with ๐ 11:09:07 From Wayne F. : Reacted to "None" with ๐ 11:09:07 From Thomas Schaertel : Reacted to "None" with ๐ 11:09:07 From Lucas Mateus Castro : Reacted to "None" with ๐ 11:09:08 From BarrieC : Reacted to "None" with ๐ 11:09:08 From Max Proskauer (he/him) : Reacted to "Some" with ๐ 11:09:08 From Vishwa Perera : Reacted to "None" with ๐ 11:09:08 From doolittl : Reacted to "None" with ๐ 11:09:08 From Chris : Reacted to "None" with ๐ 11:09:09 From Julian Krรคmer : Reacted to "None" with ๐ 11:09:09 From John : Reacted to "None" with ๐ 11:09:09 From John Schofield : Reacted to "Some" with ๐ 11:09:10 From robin : add ๐ 11:09:10 From Chase Weimer : Reacted to "Some" with ๐ 11:09:10 From Mikael Albertsson : Reacted to "None" with ๐ 11:09:10 From Agustin : Reacted to "None" with ๐ 11:09:11 From Adam P : Reacted to "None" with ๐ 11:09:11 From Miguel Angel Moreno : Reacted to "None" with ๐๐ผ 11:09:12 From alex.ribero : Reacted to "None" with ๐ 11:09:13 From Cody : Reacted to "None" with ๐๐ผ 11:09:13 From ferst : add ๐ 11:09:13 From Nathan O. : A rรฉagi ร "Some" avec ๐ 11:09:13 From Steve Wheeler : Reacted to "None" with ๐ 11:09:14 From Dan Rittersdorf : Reacted to "None" with ๐๐ป 11:09:14 From Emil : Reacted to "None" with ๐ 11:09:15 From Steve L. : Reacted to "None" with ๐ 11:09:17 From Herman Roebbers : Reacted to "None" with ๐ 11:09:18 From Gonzalo : Reacted to "None" with ๐ 11:09:18 From Andrea : Reacted to "None" with ๐ 11:09:19 From Troy : Reacted to "None" with ๐ 11:09:20 From Markus (Sรธnderborg) : Reacted to "None" with ๐ 11:09:20 From David Potter : Reacted to "None" with ๐ 11:09:21 From YolandeC : Reacted to "None" with ๐ 11:09:22 From Charles Miller : Reacted to "Some" with ๐ 11:09:24 From Scott Donelan : Reacted to "None" with ๐ 11:09:25 From Puru Patil : None ๐๐ผ 11:09:28 From maria : Reacted to "None" with ๐ 11:09:28 From Jozef Franzen : Reacted to "None" with ๐ 11:09:34 From Herman Roebbers : Removed a ๐ reaction from "None" 11:09:34 From BobF : I know WD40 ..... so none ! 11:09:38 From Aaron Olowin : Reacted to "Some" with ๐ 11:09:41 From Jeroen : Reacted to "I know WD40 ..... so..." with ๐ 11:09:42 From Ross K. : Reacted to "None" with ๐ 11:09:49 From jost-5 : Reacted to "None ๐๐ผ" with ๐ 11:09:49 From Carlos : ๐ 11:09:54 From Vishwa Perera : Reacted to "I know WD40 ..... so..." with ๐ 11:09:59 From Vishwa Perera : Reacted to "I know WD40 ..... so..." with ๐ 11:09:59 From Max Proskauer (he/him) : Reacted to "I know WD40 ..... so..." with ๐ 11:10:01 From Thomas Schaertel : Did you use Rust for a real project? 11:10:09 From Brandon Michelsen : Reacted to "Some" with ๐ 11:10:10 From Miguel Angel Moreno : Reacted to "I know WD40 ..... so..." with ๐คฃ 11:10:14 From Michael Kirkhart : Reacted to "None" with ๐ 11:10:17 From jost-5 : none 11:10:48 From BarrieC : Does rust have any support for OOP? 11:10:54 From robin : can you link in rust modules into C? 11:11:39 From Tomasz : add ๐ 11:12:20 From Wayne F. : Is there a graph like this available specifically for embedded applications? 11:15:06 From John : Reacted to "Is there a graph l..." with ๐ 11:15:32 From John Schofield : Can other people see the slides? I am just seeing a black screen 11:15:41 From Agustin : I can see 11:15:44 From John : Im seeing slides. 11:15:50 From Aminul Haq : I can see 11:15:51 From alex.ribero : Replying to "Can other people see..." We can see the slides ok 11:16:05 From BarrieC : Reacted to "Does rust have any..." with ๐ 11:16:06 From Dan Rittersdorf : Is there any talk yet about an ISO standard for Rust? Stick a pin in it and we'd be more interested in considering it for real projects. It sounds like the community around rust is diametrically opposed to doing that (yet). 11:17:35 From Dan Rittersdorf : Are you talking about "Ada"? long A, not short A. It's a woman's name. 11:18:39 From Charles Miller : Ada Lovelace, actually. https://en.wikipedia.org/wiki/Ada_Lovelace 11:18:56 From Wayne F. : Replying to "Is there a graph l..." The language popularity line graph I mean 11:19:12 From Bill Toner : any concerns about the recent Rust organization's policies about using the workd "Rust", some feel are very overbearing and harmful to the community, causing issues in use of it for Embedded? 11:19:51 From Charles Miller : Just as long as Alex Baldwin doesn't start running the organization... 11:20:20 From Dan Rittersdorf : Reacted to "Ada Lovelace, actual..." with ๐๐ป 11:22:45 From Frรฉdรฉric Boivin : It's mostly a problem for open-source and content creators 11:27:06 From Thomas Wagner : I always see this example and never quite understand how this can be close to a real-life case of exploit... it looks like you can hardly get anything without completely messing up the system you are operating on. But I might be oblivious to the obvious :) 11:28:27 From John : The parts that are safe vs not safe, is it very clear which constructs are safe and which are not? Like in the docs, lang definitions? 11:29:38 From Michael Kirkhart : This will probably be shown later in the workshop, but to do an "unsafe" operation, you actually need to declare the operation to be unsafe. 11:30:00 From Michael Kirkhart : There is a keyword in the language called "unsafe". 11:30:08 From Miguel Angel Moreno : โ The Rust for Linux project was announced in 2020 in the Linux kernel mailing list with goals of leveraging Rust's memory safety to reduce bugs when writing kernel drivers. In October 2022, a pull request for accepting the implementation for Rust for Linux was approved by Torvalds, making Rust now one of the official Linux kernel programming languages. โ 11:30:15 From alex.ribero : Replying to "I always see this ex..." That 11:31:15 From John : Reacted to "This will probably..." with โค๏ธ 11:31:35 From alex.ribero : Replying to "I always see this ex..." That's exactly what a hacker would like: Denial of service. The overreading would allow reverse engineer the application as well. 11:32:21 From jost-5 : can you focus on the content and not all language details? 11:35:22 From Gonzalo : does that error of overflow is only shown at runtime? it would be better to see it at compile time too, I think 11:35:56 From jost-5 : Reacted to "does that error of o..." with ๐ 11:36:03 From Chris : Reacted to "does that error of o..." with ๐ 11:36:16 From Michael Kirkhart : Agreed with the idea of compile time checks - always easier to debug compile time errors than run time errors! 11:36:24 From William : What would happen by default if you had an out of bounds error on a microcontroller? 11:36:47 From Mikael Albertsson : Replying to "I always see this ex..." With the C example? I would assume that the example simply aims to show the mechanism by which you can trigger unexpected behavior (reading/writing outside the array) rather than show you an exploit. You need more than a hello world to find something interesting to read or write that would give you an actual exploit. Problem is that that would not fit on a slide and would risk overshadowing the problem you're trying to highlight. 11:46:43 From Puru Patil : STM32F411 discovery kit eval board ok? 11:47:09 From Frรฉdรฉric Boivin : I have a 446 nucleo and openocd worked fine 11:47:34 From Frรฉdรฉric Boivin : you just have to use the right debugger config for your core 11:49:58 From Puru Patil : I have a 446 nucleo and openocd worked fine ๐๐ผ 11:56:21 From Chase Weimer : Does the lock file need to be version controlled if this is a shared codebase? 11:57:19 From Jacob Beningo : Have you successfully ran the last size command? 11:57:20 From Jacob Beningo : Yes 11:57:21 From Jacob Beningo : No 11:57:23 From alex.ribero : cargo size is not working 11:57:24 From Luke Moll : Reacted to "Yes" with ๐ 11:57:24 From Emil : Reacted to "Yes" with ๐ 11:57:25 From Chris : Reacted to "Yes" with ๐ 11:57:26 From David Potter : yes 11:57:27 From ferst : add ๐ 11:57:28 From robin : add ๐ 11:57:28 From Nathan O. : A rรฉagi ร "Yes" avec ๐ 11:57:28 From BarrieC : Reacted to "Yes" with ๐ 11:57:29 From Scott Donelan : Reacted to "Yes" with ๐ 11:57:29 From Jeroen : Reacted to "No" with ๐ 11:57:30 From Adam P : Reacted to "Yes" with ๐ 11:57:30 From alex.ribero : Reacted to "Yes" with ๐ 11:57:30 From Wayne F. : Reacted to "Yes" with ๐ 11:57:31 From shawn : Reacted to "Yes" with ๐ 11:57:34 From Gonzalo : Reacted to "No" with ๐ 11:57:34 From Agustin : Reacted to "Yes" with ๐ 11:57:34 From Miguel Angel Moreno : Reacted to "Have you successfull..." with ๐๐ผ 11:57:34 From Tomasz : add ๐ 11:57:35 From Lucas Mateus Castro : Reacted to "Yes" with ๐ 11:57:36 From Jozef Franzen : Reacted to "Yes" with ๐ 11:57:37 From John Schofield : Reacted to "Yes" with ๐ 11:57:39 From Miguel Angel Moreno : Removed a ๐๐ผ reaction from "Have you successfull..." 11:57:40 From Puru Patil : Yes ๐๐ผ 11:57:40 From Thomas Schaertel : Reacted to "Yes" with ๐ 11:57:44 From Miguel Angel Moreno : Reacted to "Yes" with ๐๐ผ 11:57:45 From Scott Donelan : Which extensions do you recommend installing in vscode for rust? 11:57:46 From Steve L. : Reacted to "Have you successfull..." with ๐ 11:58:10 From Dan Rittersdorf : Reacted to "Yes" with ๐๐ป 11:58:12 From Cody : Reacted to "Yes" with ๐๐ผ 11:58:21 From alex.ribero : Removed a ๐ reaction from "Yes" 11:58:30 From alex.ribero : Reacted to "No" with ๐ 11:58:40 From Charles Miller : Jacob, please send the email for those of us who forgot to click on "add to agenda"...thanks! (Will follow along later with the recording.) 11:58:41 From Dan Rittersdorf : Reacted to "Yes" with ๐ 11:58:46 From Dan Rittersdorf : Removed a ๐๐ป reaction from "Yes" 11:58:53 From Gonzalo : Reacted to "cargo size is not wo..." with ๐ 11:58:57 From Steve Wheeler : I couldnโt run it from a VSCode terminal, but it does work from an OS terminal window 11:59:05 From Jeroen : which version of cargo needed to be installed? 11:59:55 From Vishwa Perera : I see a 'Open Notebook.onetoc2' file with the ls command. What is this file? 12:00:28 From PURU_PATIL_SAN_DIEGO : PS C:\rustForC\test-size> cargo size Finished dev [unoptimized + debuginfo] target(s) in 0.01s text data bss dec hex filename 117531 44440 0 161971 278b3 test-size.exe 12:00:39 From PURU_PATIL_SAN_DIEGO : so it looks different on windows VScode 12:02:15 From Miguel Angel Moreno : This is the size on aarm64 Linux ( similar in size to macOS-arm ): Finished dev [unoptimized + debuginfo] target(s) in 0.09s text data bss dec hex filename 267374 10488 328 278190 43eae test-size 12:03:32 From Chris : How do you get to the IDE? 12:04:17 From Adam P : Replying to "How do you get to th..." https://code.visualstudio.com/download 12:08:31 From Frรฉdรฉric Boivin : on linux, you may have to install pkg-config 12:08:55 From Luke Moll : `no such command generate` 12:09:26 From Frรฉdรฉric Boivin : run "cargo install cargo-generate" 12:09:30 From Nathan O. : Rรฉpondre ร "`no such command g..." cargo install cargo-generate 12:09:34 From Luke Moll : Reacted to "run "cargo install..." with โค๏ธ 12:09:41 From Thomas Wagner : cargo generate is not an available function in my install... 12:09:48 From Thomas Wagner : ??? 12:09:49 From Dan Rittersdorf : Oh noes! "error: failed to run custom build command for `openssl-sys v0.9.87`" 12:10:19 From Frรฉdรฉric Boivin : need to install libssl-dev too 12:10:24 From Thomas Schaertel : Replying to "run "cargo install c..." it takes a long time โฆ 244 builds! 12:10:37 From John Schofield : try: cargo install cargo-generate 12:10:54 From John Schofield : Reacted to "need to install li..." with ๐ 12:11:00 From Thomas Wagner : Thanks! 12:13:26 From Dan Rittersdorf : Reacted to "need to install libs..." with ๐ 12:14:25 From Michael Kirkhart : I would argue you want the stack overflow protection 12:14:45 From Dan Rittersdorf : Replying to "need to install libs..." sudo apt-get install libssl-dev # on Linux mint did the trick. Thanks! 12:14:46 From Michael Kirkhart : Is there a way to manually bring that in? 12:15:00 From Jeroen : Reacted to "need to install libs..." with ๐ 12:15:52 From John : "use" is also used :) in VHDL. 12:22:29 From Aaron Olowin : How easy is it to separate generic application code from the hardware? Would that be built as a separate rust library? 12:22:53 From Luke Moll : Do windows users need to install qemu? or can this be done through cargo? 12:25:26 From Carlos : cargo readobj --bin qemm-hello-rust -- --file-headers 12:26:01 From Frรฉdรฉric Boivin : for linux: sudo apt install qemu-system-arm 12:26:05 From Michael Kirkhart : https://www.qemu.org/download/#windows (change windows to linux or macos for the download/install instructions for linux or macos). 12:26:20 From David : For linux, I think this: https://docs.rust-embedded.org/book/intro/install/linux.html 12:27:27 From PURU_PATIL_SAN_DIEGO : does chat section gets recorded as well 12:28:14 From Frรฉdรฉric Boivin : typo on slide 34 to run qemu: the command should be "qemu-system-arm -cpu cortex-m3 -machine lm3s6965evb -nographic -semihosting-config enable=on,target=native -kernel target/thumbv7m-none-eabi/debug/qemu-hello-rust" 12:28:22 From Herman Roebbers : cargo install cargo-generate fails with error: failed to run custom build command for `libz-sys v1.1.9` 12:28:45 From Herman Roebbers : On windows 11 12:28:55 From Frรฉdรฉric Boivin : in the output it tells you which library you're missing 12:30:12 From Herman Roebbers : cargo-warning=Could not run `"pkg-config" "--libs" "--cflags" "zlib"` The pkg-config command could not be found. Most likely, you need to install a pkg-config package for your OS. 12:30:29 From Jacob Beningo : Has everyone installed QEMU? 12:30:30 From Jacob Beningo : Yes 12:30:30 From Jacob Beningo : No 12:30:36 From Frรฉdรฉric Boivin : yes 12:30:37 From alex.ribero : Reacted to "No" with ๐ 12:30:41 From Troy : Reacted to "Yes" with ๐ 12:30:43 From robin : add ๐ 12:30:45 From Andrea : Reacted to "Yes" with ๐ 12:30:45 From BarrieC : Reacted to "No" with ๐ 12:30:48 From Nathan O. : A rรฉagi ร "Yes" avec ๐ 12:30:50 From Wayne F. : Reacted to "No" with ๐ 12:30:50 From ferst : add ๐ 12:30:50 From shawn : Reacted to "Yes" with ๐ 12:30:50 From Scott Donelan : Reacted to "Yes" with ๐ 12:30:52 From Lucas Mateus Castro : Reacted to "Yes" with ๐ 12:30:52 From Steve L. : Reacted to "No" with ๐ 12:31:01 From Mikael Albertsson : Reacted to "Yes" with ๐ 12:31:03 From Dan Rittersdorf : Reacted to "Yes" with ๐ 12:31:05 From Luke Moll : Reacted to "No" with ๐ 12:31:41 From Herman Roebbers : Reacted to "No" with ๐ 12:31:43 From Herman Roebbers : Removed a ๐ reaction from "No" 12:31:44 From Herman Roebbers : Reacted to "No" with ๐ 12:32:13 From Chris : yes, but cargo build gives like 150 errors 12:32:21 From ashtonNg : yes 12:32:36 From Dan : add ๐ 12:32:59 From Dan Rittersdorf : Don't forget to 'rustup target add thumbv7m-none-eabi' I got a lot of errors before I noticed that in the slides. 12:33:01 From Luke Moll : Reacted to "Yes" with ๐ 12:33:03 From David : The errors are because you are using the target, I think. Make sure you've got .cargo/config set correctly to M3, not M4 as in the slides. 12:33:17 From Vishwa Perera : Replying to "yes, but cargo build..." did you execute: rustup target add thumbv7m-none-eabi 12:33:33 From Luke Moll : cargo run shows "Timer with period zero, disabling", but no hello world 12:34:21 From alex.ribero : Reacted to "Don't forget to 'rus..." with ๐ 12:34:36 From Chase Weimer : Was there something specific we did to target QEMU? You mentioned in the info for the binary that it compiled for UNIX running on ARM. 12:34:40 From Chris : Replying to "yes, but cargo build..." Sure didn't; missed that apparently. Builds now. 12:34:41 From Vishwa Perera : Reacted to "Don't forget to 'rus..." with ๐ 12:34:50 From Vishwa Perera : Reacted to "Sure didn't; missed ..." with ๐ 12:35:02 From Luke Moll : Ah! Thanks 12:35:06 From David : I got it all working. Make sure to use Frederic Bolvin's run command for qemu 12:35:44 From Frรฉdรฉric Boivin : Chase, yes, you have to uncomment the runner in config.toml 12:35:54 From Chase Weimer : Reacted to "Chase, yes, you have..." with ๐ 12:35:56 From Frรฉdรฉric Boivin : the first one 12:35:58 From John Schofield : It runs! 12:37:04 From David : @jacob, On the plus side, we now know how to install all the tools ourselves haha. 12:37:12 From Nathan O. : Not sure making people on Windows use Docker is really that easier than getting the cargo / rust tools though :p 12:37:18 From Scott Donelan : Reacted to "@jacob, On the plus ..." with ๐ 12:37:22 From Luke Moll : Reacted to "Not sure making pe..." with ๐ 12:37:30 From Steve Wheeler : I installed emu, but get a โno such fileโ error on the qemu-system-armโ command. 12:37:57 From David : Steve, try:โจqemu-system-arm -cpu cortex-m3 -machine lm3s6965evb -nographic -semihosting-config enable=on,target=native -kernel target/thumbv7m-none-eabi/debug/qemu-hello-rust 12:40:20 From Dan Rittersdorf : How do you stop it running in qeum? 12:40:47 From Steve Wheeler : Replying to "Steve, try:โจqemu-sys..." Thanks, David. That gave me an informative error message, and that got me to where itโs working. 12:40:49 From Troy : Its a PATH issue, add the path to qemu 12:41:26 From David : Dan, You probably didn't add the hello-world application. See slide 33. That was my problem. To quit I had to kill the terminal. 12:41:27 From Dan Rittersdorf : Replying to "How do you stop it r..." qemu -- sorry -- I ran the empty loop version. need a way out. 12:42:33 From David : If you're on linux, probably can also kill qemu through the "System monitor" rather than killing the terminal 12:47:36 From Dan Rittersdorf : Reacted to "Dan, You probably di..." with ๐ 12:48:02 From Michael Kirkhart : Slightly off-topic: here is a link to a discussion on how to do stack overflow protection when "no_std" is specified: https://users.rust-lang.org/t/how-to-do-stack-overflow-protection-in-no-std/81055 12:48:02 From Dan Rittersdorf : Replying to "Dan, You probably di..." kill -9 โฆ qemu app worked. Sledgehammer! 12:49:19 From Michael Kirkhart : It appears rust does make use of stack canaries (something that modern C/C++ compilers support). 12:51:12 From Michael Kirkhart : Use tab completion? 12:51:23 From McDonald Adede : check the directory 12:51:54 From robin : check your current working dir ? 12:51:55 From BarrieC : Perhaps your cwd is not correct 12:51:55 From Aaron Olowin : I don't think you're in the right top level directory 12:51:57 From Michael Kirkhart : I assume the terminal windows in VSCode support tab completion (I am completely dependent on tab completion on linux). 12:52:05 From David Pastl : So is rust actually solving a fundamental flaw in C++? From a little bit of reading it sounds like it's roughly equivalent, if perhaps a minor improvement. Perhaps I'm missing something 12:53:06 From Frรฉdรฉric Boivin : missing a v7 I think 12:53:23 From Frรฉdรฉric Boivin : in your target 12:55:11 From Frรฉdรฉric Boivin : I'm getting a Error: open failed 13:02:10 From Michael Kirkhart : svd2rust is an interesting (and likely useful) tool 13:09:23 From BarrieC : Anything on multi-tasking OS's for Rust? 13:09:57 From Hamid Wasti : Thank you for an excellent talk on why "forget about it" is the right answer to the junior developers agitating for Rust. 13:10:10 From prasanna : Thank you!!! 13:10:14 From Troy : Thanks that is interesting! don't have the rust bug yet, but I will check it out further 13:10:19 From LEE : Thanks. 13:10:26 From ashtonNg : thanks 13:10:32 From John Schofield : Thank you, that was most helpful. 13:10:34 From Aaron Olowin : Thank you Jacob. 13:10:39 From Dan : Great talk. Thanks! 13:10:39 From Steve Wheeler : Thank you. It was quite interesting. 13:10:44 From shawn : thanks 13:10:45 From sandeep gill : thank you jacob 13:11:09 From David Potter : Does rust provide mechanism, for Real Time 13:11:17 From Frรฉdรฉric Boivin : Check RTIC for multitasking 13:11:18 From Dan Rittersdorf : Thank you! I'll need to blink an LED before I'll feel finished, but I followed well enough despite the installation glitches. 13:11:39 From Dan Rittersdorf : Thanks to all who helped navigate the glitches! 13:11:42 From Miguel Angel Moreno : โ The Rust for Linux project was announced in 2020 in the Linux kernel mailing list with goals of leveraging Rust's memory safety to reduce bugs when writing kernel drivers. In October 2022, a pull request for accepting the implementation for Rust for Linux was approved by Torvalds, making Rust now one of the official Linux kernel programming languages. โ 13:11:46 From Gonzalo G. : thanks 13:12:52 From Luke Moll : Is there a good tutorial for learning how to set up on a specific device? The rust-embedded book is good but assumes you have an F3, and doesn't show you how to set up the things that it provides for you. 13:13:11 From Michael Kirkhart : When you are young, the world looks black and white. As you get older, things look greyer. 13:13:22 From David Pastl : So true 13:13:33 From Charles Miller : Reacted to "When you are young, ..." with ๐ 13:14:06 From Nathan O. : When you see the number of people still using C99 I don't have much hope for Rust in the next few years at least 13:14:46 From Jim Norton : Go Embedded COBOL! 13:14:55 From Luke Moll : Replying to "Is there a good tu..." Having the example set up for your hardware is good for learning the language, but a big part of the embedded experience is setting up a new target. 13:14:58 From Michael Kirkhart : LOL! Embeded COBOL! 13:15:21 From Vishwa Perera : So, in my understanding, having a good background in C makes it easy to make use of Rust. You can get the best of both C and Rust. 13:15:36 From Nathan O. : Rรฉpondre ร "Go Embedded COBOL!" Some people are still trying to push Forth on MCUs 13:15:39 From Dan Rittersdorf : Replying to "How do you stop it r..." @David Pastl yeah, but I hate to kill my terminals when killing qemu would do the trick. Once you get to a folder, you hang onto a terminal. :-) 13:16:03 From David Pastl : FORTRAN is where it's at. 13:16:05 From Dan Rittersdorf : Reacted to "LOL! Embeded COBOL!" with ๐ 13:16:14 From Jim Norton : Reacted to "FORTRAN is where it'..." with ๐ 13:16:20 From Jim Norton : Reacted to "Some people are stil..." with ๐ 13:16:28 From Dan Rittersdorf : Reacted to "When you see the num..." with ๐ 13:16:48 From David Potter : I will have to look up difference between crates and containers 13:16:49 From Nathan O. : Knowing both C and Rust will enable to work on connecting the dots when some libs / driver get released to Rust 13:17:10 From BobF : Looks like we need to disassemble a few things in the industry! 13:17:52 From Charles Miller : Replying to "When you are young, ..." Just as long as it doesn't get dimmer... 13:19:12 From Jim Norton : Potential for Zig? 13:19:35 From Hamid Wasti : Replying to "When you see the num..." People are using C99? 13:19:51 From Nathan O. : Jacob: If some people are interested : I managed to get the hello world code running on Renode 13:19:52 From Hamid Wasti : Replying to "When you see the num..." I am sticking to C90 ๐ 13:19:58 From BobF : Zag ? 13:19:58 From Jim Norton : Replying to "When you see the num..." At my job we are. 13:20:04 From Luke Moll : Reacted to "Zag ?" with ๐ 13:20:09 From David Pastl : It's also so often the case that we don't choose things because they're better but because they're newer, so I'm always very skeptical. It's certainly interesting because of all the hype, but I'm not convinced yet that Rust is the best option. 13:20:17 From Miguel Angel Moreno : After my adventures with MicroPython, where the lack of โofficialโ support by MCU and board vendors really killed my team when trying to get the hardware to โperform reliably at the very eastโ โฆ So now our OFFICIAL direction is to use ONLY an embedded language that is OFFICIALLY supported by our MCU / board vendors โฆ 13:20:19 From Luke Moll : Reacted to "Jacob: If some peo..." with ๐ฎ 13:20:59 From Jim Norton : I really miss Turbo Pascal. Let's bring Pascal back. :-) 13:21:09 From Miguel Angel Moreno : Reacted to "I really miss Turbo ..." with ๐๐ผ 13:21:12 From Dan Rittersdorf : I was pleasantly surprised to find a matching Discovery board in my closet from like 10 years ago, so it felt good to be able to participate on the hardware portion! 13:21:28 From David Pastl : That's on my list to learn for programming my Powerbook 180. 13:21:30 From Vishwa Perera : Is there a way to connect with people who attended the conference. 13:21:43 From Jim Norton : Reacted to "That's on my list to..." with ๐ 13:21:54 From Luke Moll : Thanks for the workshop, I would be interested in a more "theoretical" comparison between C and Rust 13:21:54 From Hamid Wasti : It was a joke: "People are using C99? I am sticking to C90" 13:21:58 From Charles Miller : Replying to "I really miss Turbo ..." Or Modula-2... 13:21:58 From Jim Norton : Thanks Jacob! 13:22:00 From David Pastl : Thanks Jacob!! 13:22:04 From Herman Roebbers : Excellent, Jacob, thanks!
Thanks for presenting this session. I was able to get to the point where I have some code running on the STM32F3 discovery board, and so am now up and running with Rust!
I'd agree with your reflection that for future sessions it would be better to have a Docker container with all the tools loaded. I'm a big fan of vscode & docker containers for development environments.