Skip to main content
Filter by
Sorted by
Tagged with
3 votes
1 answer
107 views

I'm trying to build a simple app using riscv-rt for a riscv32imac target by following the steps from https://docs.rs/riscv-rt/0.14.0/riscv_rt/. What I need is a couple of external interrupt handlers. ...
Valeriy Kazantsev's user avatar
1 vote
1 answer
45 views

I am learning embedded rust by trying to recreate microbitV2 library using nrf52833_hal but got stuck. pub struct LedMatrix { col: [Pin<Output<PushPull>>; 5], row: [Pin<Output&...
Rom Rakharb's user avatar
0 votes
1 answer
87 views

I configure the RCC for 48 MHz as follows: rcc.cr.modify(|_, w| w.hseon().on()); while rcc.cr.read().hserdy().is_not_ready() {} println!("{:b}", rcc.cr.read().bits()); ...
Raul Alimbekov's user avatar
0 votes
1 answer
86 views

I have set RCC on STM32F767ZI to 48 MHz (when setting to a higher frequency an error occurs, although in CubeMX with the same settings there is no error). rcc.cr.modify(|_, w| w.hsebyp().set_bit())...
Raul Alimbekov's user avatar
0 votes
1 answer
94 views

I wrote my code based on this topic, but it is not work. I'm using the stm32f7xx_hal crate, but I think the logic of my program is similar to the code from the example. My problem is that the duty ...
Raul Alimbekov's user avatar
0 votes
1 answer
270 views

Duty-cycle behaves strangely at high frequencies. While at 20 KHz the error is barely noticeable PWM of 20 KHz At 6 MHz it becomes obvious PWM of 6 MHz I use the STM32F11ce6 microcontroller. Clock ...
Raul Alimbekov's user avatar
0 votes
1 answer
170 views

I am using rust with #![no_std]. I want to use ufmt::uwriteln!(&mut serial, "Hello world\r").unwrap(); in function. I need to pass &mut serial to this function, but don't know how to ...
MadMike's user avatar
  • 1,439
1 vote
0 answers
322 views

I'm working on a small embedded Rust project based on the https://github.com/Rahix/avr-hal-template.git for AVR cpus. I want to add some unit tests, so I removed the test = false line from the Cargo....
Niels Reijers's user avatar
1 vote
0 answers
318 views

I'm trying to write an embedded stm application in rust. In this particular application I'm using the sx127x_lora crate. However this requires a delay as a parameter so I pass the delay from cortex_m::...
CvR_XX's user avatar
  • 99
0 votes
1 answer
124 views

Currently, I am redefining the same variable (dp) multiple times to make the program work. However, this feels wrong, and I would think there would be a much better way to do this. For context, I am ...
user avatar
1 vote
1 answer
341 views

I am quite new to Rust and are diving into the relatively complicated embedded programming, perhaps thats my problem, please bear with me... I use the RPi Pico, with an SH11106 display over i2c, using ...
d850b's user avatar
  • 61
0 votes
1 answer
266 views

I'm trying to translate the following code from the Arduino IDE Into Rust using the avr_hal crate to make a passive buzzer play notes: #include "pitches.h" // notes in the melody: int ...
JasterV's user avatar
  • 17
1 vote
1 answer
362 views

I want to set alternate mode for AP10 of stm32f411 by rust HAl. My code looks like this: let rx_pin = gpioa.pa10.into_alternate(); But it has multiple impl: = note: multiple `impl`s satisfying `...
tuanti1997qn's user avatar
4 votes
2 answers
3k views

I started making a program in rust, and I want to be able to get the elapsed time since some instant. Here's how the std library does it. use std::time::{Duration, Instant}; use std::thread::sleep; ...
Hardware's user avatar
2 votes
0 answers
751 views

My setup: The signal is connected to the analog input of the STM32F767. ADC sampling rate should be at least 192kHz because input signal frequency is between 1Hz and 40kHz. Also STM32 connected to ...
anton lobanov's user avatar
0 votes
0 answers
293 views

I’m trying to implement ADC conversion from gpio analog input at the sample rate of 192 kHz. Then I want to send the array of samples over tcp to the client. My question: How to implement ADC ...
anton lobanov's user avatar
1 vote
0 answers
634 views

I’m trying to implement ADC conversion in a non blocking mode using DMA from gpio analog input at the sample rates: 192kHz. My questions: How to be implemented ADC in non-blocking mode (DMA). ...
anton lobanov's user avatar
0 votes
1 answer
1k views

I declared pointers (memory addresses) and I am able to read values like that in Rust: let psram = 0x60000000 as *const u32; let psramh = 0x60000000 as *const u16; let psramb = 0x60000000 as *const u8;...
Adrien Chapelet's user avatar
2 votes
1 answer
171 views

For embedded/IO use case in Rust, I need to build a lib to receive/transmit messages using a small fixed size buffer (must not exceed it). The messages themselves will be defined by the user of the ...
Yuri Astrakhan's user avatar