#5 ARM STM32 Microcontroller Tutorial - The 4 Basics to Control ALL!!

preview_player
Показать описание
Purchase my new book: Arm Microcontroller Programming and Circuit Building Volume 1

This video has the must-know basics!!

Links to the software:
STM32CubeIDE:
STM Studio:
STM32CubeMonitor:

Parts you will need in your prototyping environment:

Kits to get you up to speed quickly:

If you already have the microcontroller, here are some breakout boards to use:

STM-Link V2 Programmer:

Prototyping Breadboards:

Resistor Assortment Kit:

Solid core hook-up wire 22 AWG:

LEDs and Displays:

Trimmer potentiometers:

The Dynamixel servo I will be using in the USART videos:

Microfarad Capacitor Assortment:
Electrolytic Capacitor Assortment:

Рекомендации по теме
Комментарии
Автор

I really appreciate the effort (and humour!) you put into these videos, it's great!

Since your videos are aimed at folks starting out with this type of programming I wanted to offer my 2 cents -- not criticism at all, just a couple of things that can trap "young players" as EEVBlog might say :)

Early in the video you talk about testing a register's value with a 'bit number' using the '&' C operator. This may trip up some because you don't really want to use the bit *number* here but its *mask* value instead. If the bit number is 7 for example you wouldn't want to compare with 7, you would want to use (1 << 7) instead. The vendor's header files (ST Micro in your case) usually do a great job of making this easy by providing pre-defined symbols to use in your code as you show in this video, so many folks might not encounter this subtlety but it is there.

At 5:08 in this video you say that the condition in the 'while' test could be either != 0 or == 1 but this is actually not the case. This is a common mistake I see all the time when programming at this "bit level." Using != 0 is correct in this example, comparing to 1 would be incorrect (it would not give the result you want) because we're dealing with bit masks here. If ADC_CR_ADCAL (the mask you're testing for) has a value anything other than 1, testing for == 1 will never be true and your while loop would never end.
It might be clearer to write 'while (ADC1->CR & ADC_CR_ADCAL)'. Some people feel this is more explicit than comparing to zero, I prefer it because it seems easier to read.

waymamma
Автор

This is awesome. Do you have a pdf we could purchase. I don’t have kindle and paperback doesn’t give me the search function a pdf allows.
Thank you.

idus
Автор

Thanks, it is another great video! I am used to spend time in PM0214
(Programming manual) for the flow of operations looks like your book is becoming my go-to reference ;-)
You just demystified bits manipulation. For people coming from higher level language, this is unavailable! Thanks 👍

mic
Автор

Hi, I'm a fan of your videos and glad to see you continuing to make more! So, I'm coming more from the software side. My electronics knowledge is very weak. Do you have any recommendations for how to build that knowledge for a microcontroller-embedded system emphasis? I find that going through an entire basic circuits book is not practical because my goal isn't to really learn all the integrals and whatnot. Its to learn the key aspects of microelectronics that do come up when I'm reading datasheets or trying to program features of an IC or possibly trying to design an embedded system (I know some parts of what i'm saying are contradictory). If you can provide me any direction for developing hardware knowledge, I'd greatly appreciate it. Thank you.

classyjohn
Автор

Sir, it's hard to see the editing code from my phone chell, if... larger font it will be great, aniway this is great video, loved it so much & sure, I'll check it out on my laptop for biger screen. Thank you for dis amazing lesson.

TheJavaSync
Автор

Great video, but I have to correct something...
(register & bitnum) == 1 will most likely never be true. Example:
1111 & 0100 = 0100, which equals 4, not 1. You can test if it's not zero, but you can't test if it's 1.

rikkardo
Автор

That's a whole lot of code and research just to blink an LED.

marinehm
Автор

I am having a problem with the ST-LINK V2. STM32CubeIDE keeps saying I need to update the firmware for the ST-Link and won't let me program the chip

tytytyty
Автор

Thanks for the video.
BTW: Your book is very difficult to read on Kindle, unfortunately. It has a very fine and light gray writing, so that you have to strain very much if you want to read it.

WolfgangEgger
Автор

sorry to say but, number 5 Tutorial the 'the 4 basics to control all' is out of focus when looking at program.

MikeRub
Автор

I know these video's have been out for a while however, Why when typing in code is the screen so much bigger? Secondly you say for beginners then charge off leaving them behind. Make up your mind, for begginers like me, or for those already up the ladder.
It would be great if you did another, skip the IDE you did that well, but remember idiots like me, trying to grasp it, before charging off, with a screen so tiny and possibly a little out of focus. In saying that, when you show the chip data sheet it's great.
All in all bless you for trying at least, I have found trying to find a good Youtube course frustrating & proliferated by Asians speaking poor & broken English. Keep on trying. Thankyou. Sam

SamLee-lkpn
visit shbcf.ru