STM32 Intro Course announcement
1:58
C programming: double pointers
5:16
Пікірлер
@electronic-ebox6403
@electronic-ebox6403 2 күн бұрын
IS IT POSSIBLE TO IMPLEMENT THIS ON MULIPLE ADC CHANNELS? I AM USING FOR SING CHANNED BUT FAIL TO IMPLEMENT ON MULTIPLE ADC CHANNEL..
@steppeschool3629
@steppeschool3629 8 сағат бұрын
of course you can. Just create multiple instances
@electronic-ebox6403
@electronic-ebox6403 Сағат бұрын
@@steppeschool3629 okay. you mean fir_instance[12], fir_in_arm[12] and fir_out_arm[12] is only modification in program for 12 ADCs? or something more nedded? am I correct?
@hasanoktem8792
@hasanoktem8792 8 күн бұрын
the repository is not public
@user-ld9fi4ej6q
@user-ld9fi4ej6q 9 күн бұрын
nice tutorial, hello from Ukraine
@steppeschool3629
@steppeschool3629 8 күн бұрын
Thanks! Слава Украине!
@ApertureApex
@ApertureApex 9 күн бұрын
Excellent video! Thank you.
@steppeschool3629
@steppeschool3629 8 күн бұрын
Thanks a lot!
@batosato
@batosato 13 күн бұрын
Thanks for the video and a great tutorial. Could you do a video on how we use stm32 to make USB microphones? I would like to connect two or more microphones and record the multichannel sounds.
@steppeschool3629
@steppeschool3629 8 күн бұрын
Thanks a lot. I can make a tutorial about the USB microphone, but currently, I do not have much time.
@user-ox4qj7ue9x
@user-ox4qj7ue9x 14 күн бұрын
hey I have one doubt I want to connect more led stripes in parallel then i want use the different timer pwm but I have problem in the configuration DMA request another timer dma does not show that dma trigger option But I will change the code like that but my code run only single timer In my main c this for tim 2 reset_all_leds(leds, NUMBER_OF_LEDS); HAL_TIM_PWM_Start_DMA(&htim2, TIM_CHANNEL_3, (uint32_t*)leds, NUMBER_OF_LEDS1 * 24 + 24); HAL_Delay(300); set_all_leds(leds, NUMBER_OF_LEDS1); HAL_TIM_PWM_Start_DMA(&htim2, TIM_CHANNEL_3, (uint32_t*)leds, NUMBER_OF_LEDS1 * 24 + 24); and this one is same code tim 3 led_pos_counter++; if(led_pos_counter == NUMBER_OF_LEDS) { led_pos_counter = 0; } temp_neo_pixel = circular_pattern_led[led_pos_counter + NUMBER_OF_LEDS]; circular_pattern_led[led_pos_counter + NUMBER_OF_LEDS]; circular_pattern_led[2* NUMBER_OF_LEDS]; HAL_TIM_PWM_Start_DMA(&htim3, TIM_CHANNEL_1, (uint32_t*)&circular_pattern_led[led_pos_counter], NUMBER_OF_LEDS * 24 + 24); HAL_Delay(100); circular_pattern_led[led_pos_counter + NUMBER_OF_LEDS] = temp_neo_pixel;
@XuanpengZhao
@XuanpengZhao 18 күн бұрын
YOU ARE THE LIFE SAVER
@steppeschool3629
@steppeschool3629 8 күн бұрын
thanks!
@flowmeet
@flowmeet 21 күн бұрын
Excellent job man.
@steppeschool3629
@steppeschool3629 8 күн бұрын
Thanks!
@cglike
@cglike 26 күн бұрын
Here is a note in datasheet, `Low Byte of Gyroscope Y-axis data. To convert the output of the gyroscope to angular rate measurement use the formula below: Y_angular_rate = GYRO_YOUT/Gyro_Sensitivity` What is Gyro_Sensitivity ?
@steppeschool3629
@steppeschool3629 23 күн бұрын
You just define the full-scale range (250 dps, 500 dps, etc) using a register of the IMU senor. Based on that you can compute the gyro sensitivity. For the full info, you can refer to my course: www.steppeschool.com/courses/stm32-hal-orientation-estimation
@Vutung8988
@Vutung8988 27 күн бұрын
11:17 can you explain more about reg MAG_DATA_ONSET? why read 8 byte in that? many thanks!
@steppeschool3629
@steppeschool3629 23 күн бұрын
Sorry for the late reply. We just read 6 bytes for magnetometer data (2 bytes x 3 axes) and 2 additional bytes, so the magnetometer will update the readings. We just do serial read starting from MAG_DATA_ONSET. For full info, you can refer to my course: www.steppeschool.com/courses/stm32-hal-orientation-estimation
@Vutung8988
@Vutung8988 23 күн бұрын
@@steppeschool3629 is the address of MAG_DATA_ONSET same the MAG_ST1 (10h)?
@JohnJ-zj8ol
@JohnJ-zj8ol 28 күн бұрын
Thanks a lot! what is the rest of line 106? printf("frequency %f: %f ", ((float32_t)(i * SAMPLING_RAT) / FFT_LENGTH), out...
@steppeschool3629
@steppeschool3629 23 күн бұрын
just bracket with a semicolon
@venkygoud7421
@venkygoud7421 Ай бұрын
Nice video,great explanation
@steppeschool3629
@steppeschool3629 23 күн бұрын
Glad you liked it!
@emyemy7504
@emyemy7504 Ай бұрын
Great Job. How do I get to interface mpu6050 with stm32 so that I only get readings anytime there is an interrupt coming from the interrupt pin of the mpu6050 when there is linear or rotational movement?
@steppeschool3629
@steppeschool3629 Ай бұрын
The easiest solution will be using the timer update interrupt in STM32 MCUs. Every time this event occurs, you can sample the IMU sensor.
@steppeschool3629
@steppeschool3629 Ай бұрын
What if you use the external interrupt to trigger reading the IMU sensor?
@batosato
@batosato Ай бұрын
Thank you for the video and a great tutorial. If you don't want to remove the microphone from the board then switch to I2S3 instead and follow the tutorial. The recordings will be done without any hassle :)
@steppeschool3629
@steppeschool3629 Ай бұрын
Thanks for the info!
@reportimojega1522
@reportimojega1522 Ай бұрын
Do I need to solder with Nucleo-L412KB? Also how would I if I need to. Thanks.
@steppeschool3629
@steppeschool3629 Ай бұрын
I am sorry for the late reply. As far as I know, Nucle-l412kb does not have such functionality
@vix_s_hnu
@vix_s_hnu Ай бұрын
I got error " undefined reference to 'arm_rfft_fast_init_f32'. I imported the DSP library as you mentioned in the other videos. Why i am stille getting the error?
@amitchautmal
@amitchautmal Ай бұрын
How to store structure data to eeprome and read back
@mursalaboobacker3593
@mursalaboobacker3593 Ай бұрын
nice work. can i get all the files and code for your all videos when i join to steppeschool or i need to jion through patreon. which one i need to choose. cammant your answer please. i really like your videos and excited to making it my own.
@steppeschool3629
@steppeschool3629 Ай бұрын
Either works, but if join Patreon, you can write me direct messages
@subhamdas2491
@subhamdas2491 Ай бұрын
what is the perpose of filter out variable
@steppeschool3629
@steppeschool3629 Ай бұрын
Hi, 'filter out' is the output of the filter
@user-hu7iw5cp9j
@user-hu7iw5cp9j Ай бұрын
Great Explanation!
@steppeschool3629
@steppeschool3629 Ай бұрын
Thanks
@BroMalte
@BroMalte Ай бұрын
Hello Stepp School. I have everything setup as explained, yet im never able to enter the callback, i feel i have followed everything, do you have any idea as to what could be the reason as to why my callback is not working? I have enabled IT on my timer, i have run the HAL_TIM_Base_Start_IT(&htim2); and i have created a callback function with some actions to take during the interrupt. All i have in my main loop is a delay, and its just stuck in there, the interrupt never fires.
@steppeschool3629
@steppeschool3629 Ай бұрын
Hi, how do you check that the callback function is running? and what is the frequency of it?
@BroMalte
@BroMalte Ай бұрын
@@steppeschool3629 For now, i am just using the live expressions and breakpoints. i also have an oscilloscope set up to sniff what is happening on my board, regarding the pins i am working on. Right now the frequency of the function is 100ms, my idea is i have to set the interrupting timer to fire first at 100ms, make a change to my signal and set the next interrupt in 9,9seconds, so 10 seconds total, make another change and that is it, after that just stop the timer. However i tried something simple, just toggling a pin at 1000Hz, not seeing anything there either. i have used this in other programs, and worked just fine. I think im going to try to restart the entire project and start with just this functionality and see what is going on.
@janpribyslavsky1554
@janpribyslavsky1554 Ай бұрын
Thank you for this video. It saved me lot of time. Can I also ask how to detect the event of disconnecting the USB cable? Otherwise, in such event, the output buffer keeps playing with no new data coming which makes annoying sound.
@steppeschool3629
@steppeschool3629 Ай бұрын
There is another callback function for disconnection. Unfortunately, I cannot check it right now. Hopefully, I can check it after a couple of hours
@steppeschool3629
@steppeschool3629 Ай бұрын
Inside usbd_audio.c, there is a function USBD_AUDIO_IsoOutIncomplete. Most probably, this function is invoked when the USB cable is disconnected. You can check it by using breakpoints or printing some messages. If this is the case, you can signal the audio speaker to stop audio streaming.
@janpribyslavsky1554
@janpribyslavsky1554 Ай бұрын
@@steppeschool3629 This worked. Thank you again! I also discovered, that there are functions HAL_PCD_SuspendCallback() and HAL_PCD_ResumeCallback() in usbd_conf.c that can be used for this purpose as well.
@steppeschool3629
@steppeschool3629 Ай бұрын
@@janpribyslavsky1554 🤙👍👍
@janpribyslavsky1554
@janpribyslavsky1554 Ай бұрын
Thanks!
@steppeschool3629
@steppeschool3629 Ай бұрын
Thanks a lot!!! I greatly appreciate your donation
@anupriyavishnoi6548
@anupriyavishnoi6548 Ай бұрын
When i am copying hal_statustypedef in another c file then it is not coming as Library function , hal_ok is also coming as simple line not as function. Can you please help me why it is happening . There is syntax error coming.
@steppeschool3629
@steppeschool3629 Ай бұрын
Hi, I do not get your question fully. What do you mean by copying hal_statustypedef?
@jitendrasingh-ob8nk
@jitendrasingh-ob8nk Ай бұрын
Excellent work please tell me the motor voltage rating & rpm rating and torque and max current , also size of wheel diameter, in short please give the links for motor & wheels of pololu
@steppeschool3629
@steppeschool3629 Ай бұрын
Check this link. You should get all the info there: www.pololu.com/product/3073
@SimplementeNico
@SimplementeNico Ай бұрын
Hi, what is your main code? I've copied all the code you showed in the video, but I get no audio.
@dwieztro6748
@dwieztro6748 Ай бұрын
Hii can you use stm32f030 to read ppm and work with servo pwm?
@lohikarhu734
@lohikarhu734 2 ай бұрын
I figured that diff gain also increases response speed to perturbations of the motor speed, so that it may be possible to reduce the P gain... In your demo, it seems that you are showing the response from an uncontrolled state to a controlled state, rather than response to a perturbation of the load? Or? But, I'm just some old guy, who never did learn the mathematics part, more of a "hands-on" and conceptual driver.... 😀
@lohikarhu734
@lohikarhu734 2 ай бұрын
It would be interesting/useful, to show, on the graph of the motor speed, the PWM value that is applied, so that we could see the action of the differential and proportional functions make the quick response of the PWM, and the slower changes due to the integral part... Hmmm... Possibly also show the values of each of the three correction terms? But, maybe that's in the next video?
@steppeschool3629
@steppeschool3629 2 ай бұрын
It could be really interesting to show that using an oscilloscope, which I do not have currently😀
@rabboud556
@rabboud556 2 ай бұрын
I am not sure but I think your convolution formula should be y[n]= sum of (x[n-k] x h[k]) with k=0 to k=N ( N order of the filter). not sum of(x[n-k] x h[n]). I am sorry, I may be wrong!
@jonathanrodriguez8219
@jonathanrodriguez8219 2 ай бұрын
Nice!! a lot learned!
@steppeschool3629
@steppeschool3629 2 ай бұрын
Glad to hear it!
@lohikarhu734
@lohikarhu734 2 ай бұрын
Pay to play... I guess it's a way of getting actual income for the work
@lohikarhu734
@lohikarhu734 2 ай бұрын
Looks like nice way to handle "edge conditions".... I haven't read the timer information, yet, so I was surprised to see overflow on such a low speed operation. Thanks!
@noebrasseur3062
@noebrasseur3062 2 ай бұрын
Hello, thank you for your video, but i have a major problem, when i go to debug configurations and try to enable the SWV, i can tick the option... would you have an idea about how to resolve this problem and why it occures ?
@noebrasseur3062
@noebrasseur3062 2 ай бұрын
I am not working on an Nucleo but on a STM32F303 dicovery, might it be the problem ?
@steppeschool3629
@steppeschool3629 2 ай бұрын
check the user manual of your discovery board. There might be some jumper to solder. Which board exactly are you using?
@kalyanijog
@kalyanijog 2 ай бұрын
Trace become disable while debugging , what to do?
@steppeschool3629
@steppeschool3629 2 ай бұрын
Hi, I do not get your question fully. What is the problem?
@kalyanijog
@kalyanijog 2 ай бұрын
I debug the code and open window panel and click on swv viewer and ticket the Bo bit ,then click on ok , then click on trace button and click on resume run code but " trace button gets disabled" and program shut down unexpectedly what to do
@christianlabanca5377
@christianlabanca5377 2 ай бұрын
Hi, how did you calculate the Covariance matrices?
@steppeschool3629
@steppeschool3629 2 ай бұрын
There is an arm math cmsis library that allows us to do linear algebra operations within the MCU. You can get full information on my course: www.steppeschool.com/courses/stm32-hal-orientation-estimation
@danielya8634
@danielya8634 2 ай бұрын
Filter coefficients are initialized from double literals and casted to float32_t. Assuming float32_t is float this should give warning
@domdom1941
@domdom1941 2 ай бұрын
Best tutorial for the printf() function in STM32 IDE I have found! I love how easy the setup was and it worked on first try. Some note for all who want to use it: You can create new .c files and use the printf() function. Just make sure you add #include <stdio.h> because only then the printf() function is declared.
@steppeschool3629
@steppeschool3629 2 ай бұрын
Glad it helped!
@michaelalex5235
@michaelalex5235 2 ай бұрын
This is really useful. I've gone through the difficulty of using external EEPROMs to hold calibration constants and offsets for my STM32 projects, but the method you show is much more convenient. Thank you!
@steppeschool3629
@steppeschool3629 2 ай бұрын
Glad it helped!
@incxxxx
@incxxxx 3 ай бұрын
In other words - the same what you obtain in SWV window (same kind of saw) I would like to see on the oscilloscope. What more I should do ?
@steppeschool3629
@steppeschool3629 3 ай бұрын
You can use the Master clock Output (MCO) pin to generate a clock signal. Check this link below for more detailed information: community.st.com/t5/missing-articles/how-can-i-output-a-clock-signal-to-the-stm32-s-mco-pin/td-p/49583 Another solution is to generate a PWM signal: www.steppeschool.com/pages/blog/stm32-pwm-stm32cubemx For sawtooth signal generation, you can use Digital-to-analog Converter (DAC)
@woldecosgrove
@woldecosgrove 3 ай бұрын
Hello nice work! i like your video very much, but i cant find the code, i am already accessable to your web page, please advise the website to your code...thx
@incxxxx
@incxxxx 3 ай бұрын
Nice work!
@steppeschool3629
@steppeschool3629 3 ай бұрын
Thanks!
@user-hu7iw5cp9j
@user-hu7iw5cp9j 3 ай бұрын
Thank you! Your videos are always informative and unique!
@steppeschool3629
@steppeschool3629 3 ай бұрын
Glad you like them!
@1975nacgul
@1975nacgul 3 ай бұрын
3:52 why it get 6?
@steppeschool3629
@steppeschool3629 3 ай бұрын
because I get access to global_temp_value in another file using extern keyword and increment it within print_global_var function.
@1975nacgul
@1975nacgul 3 ай бұрын
@@steppeschool3629 can we use static in interupt handler?
@cagedgandalf3472
@cagedgandalf3472 3 ай бұрын
Which is better Kalman or Complementary filter? For orientation estimation
@steppeschool3629
@steppeschool3629 3 ай бұрын
In terms of precision, of course Kalman Filter is better. But the Complementary filter is easy to implement and does not require much computational power. So you can implement it in simple microcontrollers.
@farziverse4209
@farziverse4209 3 ай бұрын
I think HAL_TIM_IC_CaptureCallback is wrongly mentioned as a fn which calculates the pulse width. It just detects the rising and falling edges of the PWM signal. You need to change its CCER Register Value to make it detect the signal
@kratomleaf8937
@kratomleaf8937 2 ай бұрын
wdym? isn’t that what he said in the video?
@incxxxx
@incxxxx 3 ай бұрын
Very, very helpful. Thank you. But there is also one thing interesting for me. How connect TIM1 to pin, for example pin PA8. I would like to see signal on oscilloscope.
@steppeschool3629
@steppeschool3629 3 ай бұрын
Thank you for your comment. But what do you mean by connecting the timer to pin? Like generating a PWM signal in a certain pin of the microcontroller?
@incxxxx
@incxxxx 3 ай бұрын
@@steppeschool3629The frequency of the Nucleo MCU is 80MHz. How to see the signal of such frequency on the oscilloscope?
@incxxxx
@incxxxx 3 ай бұрын
@@steppeschool3629 Just to see the output signal on pin PA1 of TIM2 having prescalar 72-1, ARR 65535, so I should see on the pin about 15kHz, but I see nothing. Do I have to make pwm on this pin or something more? Clock is ok 72MHz, Input Capture direct mode I have on Channel2 then I see pin PA1 is activated (green) on Pinout view - TIM2_CH2. So what more I shoud do???
@steppeschool3629
@steppeschool3629 3 ай бұрын
Check this article on my website: www.steppeschool.com/pages/blog/stm32-pwm-stm32cubemx Hope this helps for you
@johnfrancis923
@johnfrancis923 3 ай бұрын
Why did you disable the clock source? In my case, I am using an external oscillator to generate the system clock. However, I'm not finding an option to select the external clock as the source. What should I do in this situation with cubeMX tool?
@lamnhatoan9944
@lamnhatoan9944 3 ай бұрын
Great explanation!
@DevSmartContract
@DevSmartContract 3 ай бұрын
Can you share your libary cs43l22? Thank you.
@steppeschool3629
@steppeschool3629 3 ай бұрын
You can find the library on my Hackaday project: hackaday.io/project/195461-stm32-audio-codec