2018-11-23 10:53 PM
Hey!
i just jumped from AVR8bit MCU's to STM32 and obviously i'm having issues with just about everything when it comes to design PCB, i try to keep it short.
I guess that was all i was wondering for now, Thx to anyone who takes the time to answer my questions!
2018-11-23 11:18 PM
> Boot0 and Boot1 pins should be jumpered to give me access to bootloader right?(regardless if i need it)
As a plan B, you might need it one day, especially if this is your first design. BOOT0 is a dedicated pin, but BOOT1 is a GPIO so you may want to use it as an output so that in case you'd need to use the bootloader you don't need to fight with some external device trying to drive it to the opposite level Later on, as you gain confidence, you may stick BOOT0 to the given inactive logic level (here: ground) hard, and use BOOT1 as you wish.
> "HFE Bypass" as clock source, Do i just wire the oscillator clock out pin to the correct clock in pin of mcu with load capacitor? (SiT2024)
No load capacitor. And then in software set HSEBYP together with HSEON in RCC_CR
> VSSA and VDDA, can these be "shorted" with their digital counterparts? there is no need for high precision ADC with this project.
There is no high precision ADC in 'F4 even with properly filtered VSSA/VDDA, these ADCs (quite understandably) suffer from lots of noise from the digital surroundings, so at the end of the day they are barely better if at all than the 10-bit ADC of the AVRs. But generally, yes, you can connect VSSA/VDDA to VSS/VDD. You still want proper power supply/regulator design, maintain good GND/VCC design (short wide tracks, planes if possible, avoiding loops and cuts in planes, etc.), and pay attention to decoupling (as close to the pins as possible). Mind, megahertzs digital signals edges means peak currents in the supply with harmonics well into gigahertzs, and you don't want them to be conducted too far from the mcu.
> VBUS sensing, the pin on MCU is 5v tolerant so i can just directly wire USB vcc to that?
Yes. A humble series resistor can do wonders as a protection device. You may want to consider protection devices, on the USB data lines, too.
JW
2018-11-24 01:51 AM
Thx!
> As a plan B, you might need it one day, especially if this is your first design.
Yeah that's what i thought, that it would be smart to have jumpers on BOOTx pins just incase if(when) i do something i was not supposed to do.
> No load capacitor. And then in software set HSEBYP together with HSEON in RCC_CR
Cool, that saves some board space near the MCU. The clock source i did choose does have something they refer as "Programmable Drive Strength" which is why i started wondering this, there is different rise/fall times based on cLoad.
> You still want proper power supply/regulator design, maintain good GND/VCC design (short wide tracks, planes if possible
I'm going for 4-layer PCB with dedicated power planes for 3v3 and ground. Bypass caps on bottom side just under the MCU itself, don't know if that is the best design, but i got huge stock of 0805 size caps which are too huge to be placed near pins on front side. (Or maybe i'm just trying to place those way too close of the MCU thinking i have to get it so close)
> Yes. A humble series resistor can do wonders as a protection device. You may want to consider protection devices, on the USB data lines, too.
Almost forgot that resistor on the VBUS, only had ferrite!