Hi,
Still learning laying out board (and electronics )
. reading documentation on a SMT32 chip example to do this;
why use a mosfet in LED management ?? for such small size.
I could understand on large led(s) but here is a very small status ledâŚ
not sure why, can someone please explain ?
Could be just the habit, or personal prejudice, of the circuit designer.
Could be a need to conserve the drive capability of the âPC1â signal. MOSFETâs have lower steady-state drive requirements than BJTâs, but there should be a few hundred ohms of series resistance in the gate circuit to limit the capacitive inrush current.
More speculation here, microcontrollers not only have a per-pin current limit, but a total current limit. Perhaps using a mosfet here (which should have negligible gate current, that 1M resistor probably passes more current) is to preserve available total current available for other pins? Why waste power budget on an indicator light?
As @dchisholm mentions above, there could be many reasons, itâs difficult to comment on this particular example as we donât have the rest of the schematic. The STM can drive +/- 8 ma on itâs GPIO pins, and up to +/- 20 ma with relaxed Voh/Vol specifications, and the LED in this example draws less than 6 ma, so technically it would be possible to drive the LED directly. But there may be other things to consider. We donât know what âVINâ is but it is possibly the supply voltage before the regulator. In the case of many LEDs this would draw all of the LED current from the main supply and not add additional load to what might be a small LDO powering the STM32.
What is this on ? What is VIN vs MCU Vdd ?
Is it on an Eval PCB ?
Possible reasons :
To have the LED current draw from 5V, to allow accurate MCU current reading.
To allow the pin to be used as IN, without a LED loading.
If Vdd of the SMT32 chip is lower than Vin if the circuit, Vdd (the maximum logic high possible from the STM32) might be below the turn-on threshold of the mosfet. Thatâs all the caution means.
Yes, of course, but âVdd comes downâ is what doesnât make any sense. There is no Vdd on the schematic, if he his referring to Vdd of the STM32 it would have helped to be specific. But still, âcomes downâ? Vdd is what Vdd is and if it isnât constant then the Vgs of the MOSFET is the least of the problems.
He confirmed my suspicion. And it isnât like we were provided with a full schematic. Even you brought that point up. We donât even know which document the OP pulled that schematic part out of.
We are all speculating on very incomplete information. But thatâs what is fun, isnât it?
The circuit presented is perfectly valid if the components are properly selected. It could have been suggested that a BJT might be more applicable to this application but delving into a complete circuit analysis and component selection is not only not possible with the limited information but entirely beyond the scope of the OPâs question.
Hi guys thanks a lot for your help and many replies.
to add more details, itâs an evaluation board witch has an even more weirder âpower planâ
it manages the battery charging and output with a mosfet again âmore on that to come later.
the chip itself has pretty basic needs. but the evaluation boards schematic will help me make sure I give it what it needs to work properly.
Iâll draw the power part soon as I have other questions for it too
since itâs under nda I canât share the original and need to redraw my own before sharing.
but the VIN comes from a 3.3v LDO (that comes from either usb/battery/VCC)
I think I should really post it in two or tree questions as it might become complex to reply to each small parts. (and it will hopefully help other starters like me to better understand shematics)
Careful there. Sharing only parts of the design, even if you re-draw them, may still violate the NDA. Because the design is under NDA I think your questions should probably go to the designers, not to an outside group of people (us). They may be doing something quite clever that they are testing out while and/or prior to submitting patents.
Thanks for the heads up. I got an nda for general stuff with them but I think this part of the board design is not so critical. (thatâs part of their dev board)(witch I think if anyone asking about how to use it should receive a copy of what I have used to redraw and ask this questions) not so much about the main chip(witch is their bread and butter. but you are right. Iâll be careful. I`ll ask them tonight about what can be shared exactly.
I feel like they might laugh at me if I ask too much beginners questions and possibly loose interestâŚso I try to find my answers elsewhere first.
Of course that changes things. It also casts doubt on âVINâ being only 3.3 V. It more likely comes from the input of that LDO and is more likely to be 5V.