STM32 ESC PCB Schematic Design - KiCAD ESC Project (DeepDrive v1.0)

แชร์
ฝัง
  • เผยแพร่เมื่อ 29 ต.ค. 2024

ความคิดเห็น • 54

  • @i70da_12
    @i70da_12 15 วันที่ผ่านมา +1

    I am so fortunate to have found this helpful video. I was completely overwhelmed by the lack of videos covering this topic.
    Thank you, Khaled.

    • @khaledmagdy
      @khaledmagdy  15 วันที่ผ่านมา +1

      Thanks for your kind words, really appreciate it and glad you found it helpful!
      Wish I had the time to follow up on lots of projects, this one included.

  • @DeMaxize
    @DeMaxize ปีที่แล้ว +8

    amazing , waiting for more !
    this type of videos are gonna blow up , very good

  • @retronexusnet
    @retronexusnet 7 หลายเดือนก่อน +2

    amazing content! I hope you will produce more videos like this

  • @dhairyapanchal7887
    @dhairyapanchal7887 8 หลายเดือนก่อน

    I'm developing ESC for ebike and found your video its very helpful and guided through my mistakes and helps me a lot if I just changed the FETs to drive at higher voltage along with power sections it's possible to implicate same configuration of your circuit for my project.
    Waiting for your follow-up video related to drivers and testing 😊

  • @mustafa_mah
    @mustafa_mah 4 หลายเดือนก่อน +1

    ما شاء الله عليك يا خالد
    ربنا ينفع بك ويوفقك ❤

  • @Fadelabdalkhalik
    @Fadelabdalkhalik 8 หลายเดือนก่อน

    Finally Eng Khaled is back

  • @kulaniscap
    @kulaniscap 3 หลายเดือนก่อน

    Give us more videos - this is really good work.

  • @davidbalderrrama
    @davidbalderrrama ปีที่แล้ว +1

    Amazing video. Thank you for posting this!

  • @amerhk4245
    @amerhk4245 2 หลายเดือนก่อน

    An Amazing video!! waiting for more similiar videos.

  • @rizqokarim7093
    @rizqokarim7093 9 วันที่ผ่านมา

    hello, do you know about the sizing of capacitor and inductor for the bridge filter and bulk capacitor? thanks

  • @abdelrahmantawfik9504
    @abdelrahmantawfik9504 8 หลายเดือนก่อน

    very very useful, keep going ❤❤❤❤

  • @maazsiddiqui6324
    @maazsiddiqui6324 ปีที่แล้ว +2

    great work, keep it up;

  • @eelcohoogendoorn8044
    @eelcohoogendoorn8044 8 หลายเดือนก่อน

    Thanks, this is a really excellent level of detail, very educative for the level of knowledge I am at. Would be great to see someone go over firmware written for educational purposes as well. As much as I like VESC I cant say the code was very much written to be read.

  • @MehmeterTem5534
    @MehmeterTem5534 ปีที่แล้ว +1

    Awesome lesson

  • @prasanthchigurupatii
    @prasanthchigurupatii ปีที่แล้ว +1

    Thank you sooooooooomuch ......your videos help a lottttt❤

    • @khaledmagdy
      @khaledmagdy  ปีที่แล้ว

      I'm very glad to hear this!

  • @kumaylmoosavi9353
    @kumaylmoosavi9353 9 หลายเดือนก่อน

    Amazing guide to BLDC motor driver. Thankyou!
    I just have a some small questions, any way you can guide would be very much appreciated
    a) What maximum current rating of a BLDC motor this driver can drive?
    b) What changes would you suggest I look into to make it a 24V DC supply operated system
    c) Can you share or make a video on the firmware that you developed in this video at the end for the six step commutation system? Did you use an FOC algorithm?

    • @khaledmagdy
      @khaledmagdy  9 หลายเดือนก่อน +1

      I'm really glad you found it helpful!
      a. This should handle up to 30A DC. I've tested it for 15A and it didn't show any sign of developing any heat.
      b. The protections, buck circuit, mosfet devices, and voltage feedback attenuators. Not so many changes actually.
      c. I did complete the bringup back then when i received the boards, tested it with an FOC implementation as well. It worked so well despite the fact that i'm itching to optimize it (in terms of HW) more so it becomes more accessible to people when the design is released. I wasn't able to take the time to document this work and shoot some videos to show the progress. I hope this comes out in the near future!

  • @nimasalehi5197
    @nimasalehi5197 5 หลายเดือนก่อน

    is there any software coding design video released yet for this project? will you do it?

  • @nimasalehi5197
    @nimasalehi5197 5 หลายเดือนก่อน

    that was awesome, thank you

  • @ahmedkamil7655
    @ahmedkamil7655 ปีที่แล้ว +1

    Very good Work

  • @giantbee9763
    @giantbee9763 6 หลายเดือนก่อน

    Hello! How's the project going? :) Any updates? :D Thanks for the video comprehensively walking through your thought process!

  • @mohamedsafy305
    @mohamedsafy305 7 หลายเดือนก่อน

    Amazing content as always and looking forward to hear about the consolidated version for cheap skates folks LOL !
    I had a question tho regarding the shipment, duty fees and taxes on such boards in Egypt, and was it a smooth process importing such board ?

    • @khaledmagdy
      @khaledmagdy  7 หลายเดือนก่อน +1

      Thanks! Really glad you found it helpful, unfortunately, the economic version of this project has been on my to-do list for ages, and never had the time to complete it, I hope I will get back to it soon.
      Regarding the boards' import clearance, it was a total nightmare! I would have given up on it and let them take it if I hadn't promised the sponsor of this video to create it.
      It went through all sorts of inspections (national security, explosions committee, NTRA, ...). Each inspection of those has its own fees + some misc fees + voice call with someone literally negotiating with me for the maximum fees I'm willing to pay to clear my shipment.
      All in all, it was chaotic! I had to pay about 170$ just to receive my order which costs 160$ on its own. Keep in mind, all of this was back in 08/2023 before "floating", now the custom's USD price has skyrocketed and maybe some new fees have been added because why not! xD

    • @mohamedsafy305
      @mohamedsafy305 7 หลายเดือนก่อน +1

      @@khaledmagdy Just what I've expected, maybe if the board and components were imported separately it wouldn't be as difficult ? after all in the eyes of the government you're importing an unregulated device/product.
      I'm thinking about ordering a pcb board lately and my planned approach is : PCB -> JLCPCB Components -> Mouser, as I've heard that they deal with all of this mess + free shipping & duty for 60$+ orders ! although I'd have to pay for double shipment and of course soldering the parts (hot air rework for the rescue!).

    • @khaledmagdy
      @khaledmagdy  7 หลายเดือนก่อน +1

      Exactly! That's the challenge i've chosen. Importing fully assembled boards, for us, is asking for troubles and a very risky business.
      But i've chosen to fight for my package instead of frying the poor smd ICs which i hate doing.
      Your approach is very cautious and is going to work ISA, i've done that as well and it's much easier to import bare boards and components in separate packages.
      Please be advised, even free shipping can still be subject to clearance fees (at least 20-25$ for a 60$ worth of goods).
      Good Luck!

    • @mohamedsafy305
      @mohamedsafy305 7 หลายเดือนก่อน

      Thanks that was really helpful!
      Thanks also for wishing me good luck I really need it 😅.
      Ramadan kareem 🙏

  • @sanjikaneki6226
    @sanjikaneki6226 7 หลายเดือนก่อน +1

    how is V2 going? also is the code finished?

  • @zakhoover9946
    @zakhoover9946 4 หลายเดือนก่อน

    Did you post your microcontroller code/walkthrough it anywhere?

    • @khaledmagdy
      @khaledmagdy  4 หลายเดือนก่อน

      not yet, unfortunately :(

    • @zakhoover9946
      @zakhoover9946 4 หลายเดือนก่อน

      @@khaledmagdy no worries! I am a student and was impressed by your circuit design and learned a lot!

  • @kolyankorolev963
    @kolyankorolev963 8 หลายเดือนก่อน

    Hello. I'm trying to understand the necessity of the ZCD circuit. We generate Back Electromotive Force (BEMF) from each phase using resistor dividers, and then feed it to comparators for comparison with a virtual ground. Is it necessary to implement the ZCD node with comparators, or would it be better to use the MCU's ADC, where we can programmatically compare the readings of virtual_n and phv?

    • @khaledmagdy
      @khaledmagdy  8 หลายเดือนก่อน

      The microcontroller's ADC can do it but it will load the CPU too much to process this at the required rate of conversions. If there are internal analog comparators in the MCU it would be perfect to use, otherwise we'd go for an external analog comparator circuit like the shown in this video.
      Instead of doing continuous ADC conversions and voltage comparison in software, I just get an interrupt on EXTI pins on every ZCD event.

    • @kolyankorolev963
      @kolyankorolev963 8 หลายเดือนก่อน

      thanks for the answer, I understand why it's better to use a comparator. I have a few questions.
      1) I'm using an internal buck regulator to convert 6s-12s, i.e., 48 volts to 5 volts. For compactness, I choose a higher frequency because it affects the size of the inductor. So, at a frequency of 750 kHz, the inductance is about 15 µH. However, it's not entirely clear how to choose the decoupling for the COMP pin. Texas Instruments suggests calculating it in WEBENCH, but due to sanctions, I can't register. In the video, you mentioned that you're already working on a new version. Have you encountered choosing RT-CLK and COMP?
      2) Regarding the question about ZCD and BEMF. Why then connect the PHV_U (V and W) and Virtual_N pins to the microcontroller if they are only needed for the comparator to determine the position of the motor's phase angle? Then why do we need to connect BEMF to the MCU? And how did you calculate the dividers in BEMF?
      3)In the DRV8302 documentation, there is a connection to the MCU's ADC - PVDDSENSE. Do I understand correctly that this is battery discharge control? I just didn't see anything similar in your project. Overall, it's not clear why they use SENSE formation without comparators.@@khaledmagdy

    • @khaledmagdy
      @khaledmagdy  8 หลายเดือนก่อน

      @@kolyankorolev963
      1) I've used WEBENCH a few times in the past for Ti-based converters, I guess you can use another datasheet for a similar device where you may find a an example for the same values you're designing for or at least find an equation to calculate it.
      2) The phase voltages PHV_x & Virtual_N are connected to the microcontroller's ADC as well as the external comparators. The external comparators are for ZCD as we agreed on. But the connection to the ADC is for something else which is operating in sensorless FOC mode instead of six-step commutation. The intention behind designing this board is to be a dev board that should support so many control schemes. One of which is the "Windmilling Mode For Sensorless FOC" this is a non-Motoring mode where the BLDC will be spinning due to inertia or external wind without any given power from our ECU, therefore we need to monitor the phase voltages while the inverter bridge is fully opened. Designing a good observer can help us detect the motor speed & angle and consequently starting the motor successfully while it's spining (windmilling) without the need to completely stop the motor and move it to a "known vector" before attempting to start.
      TLDR: you don't have to do it unless you're building something similar to mine so you can try different control techniques on the same board.
      3) This is just for monitoring the VDD line in software and making sure it's operating within range. I do have a logic supply & battery voltage supply dividers that send those voltages to the MCU's ADC maybe the naming is different but essentially they're the same.
      Hope this helps!

  • @sassi7190
    @sassi7190 10 หลายเดือนก่อน

    عظمة

  • @TrilokSawant-pz9sn
    @TrilokSawant-pz9sn 5 หลายเดือนก่อน

    how to download schematic ? it is asking password for drive

  • @damianwiecaw492
    @damianwiecaw492 9 หลายเดือนก่อน +1

    Why didnt you use DRV built in buck converter?

    • @khaledmagdy
      @khaledmagdy  9 หลายเดือนก่อน +1

      I should have done. At that time I hadn't tested it before and decided to go for a Ti buck that I was more comfortable working with.
      It should work just as fine but needs a bit more double-checking for the information in the datasheet to make sure everything is implemented correctly. As i said near the end of the video, more optimizations should be done and this is one point of many others that i need to consider for the next revision. I hope i'll have some time to get back to it.

    • @damianwiecaw492
      @damianwiecaw492 8 หลายเดือนก่อน

      @@khaledmagdythank tou for the reply, i really appreciate your blog!

  • @Mohamed_Ali-24M
    @Mohamed_Ali-24M ปีที่แล้ว

    ياريت تستمر في الشرح

  • @hossamhussien7203
    @hossamhussien7203 5 หลายเดือนก่อน

    ارفع ايدك فوق انت مصري

  • @dbtechs2593
    @dbtechs2593 ปีที่แล้ว

    dont really get it how your reverse polarity works , POWER_GND_REVERSE isnt connected to any GROUND related to the power input .. meaning POWER_GND_REVERSE isnt 0 nor high , you dont know what is the voltage there since its floating..

    • @khaledmagdy
      @khaledmagdy  ปีที่แล้ว

      You can find it connected in the last part of the power section which is the "Bridge Cap. Array".
      The article here has some screenshots that should help.
      deepbluembedded.com/stm32-esc-pcb-design-foc-esc-bldc-schematic/

    • @dbtechs2593
      @dbtechs2593 ปีที่แล้ว

      yes but its still connected to GND that has no relation to the input.. how is there a voltage potential created without the gnd being connected to the source@@khaledmagdy

    • @khaledmagdy
      @khaledmagdy  ปีที่แล้ว

      This is a really good question. Take another look at the schematic and let's divide the operation as follows:
      1. Initial Condition:
      When you first plug the +12v power rails input, the MOSFET's source (Vs) will be floating and the MOSFET won't turn ON as you've mentioned but the current will flow back to the supply through the MOSFET's body diode. This will set the Vs to Vdiode
      Vs (Source) = Vdiode (Diode Drop)
      Now, we've got a Vgs = 12 - Vdiode, Which is more than enough to turn ON the MOSFET
      2. Steady State:
      At steady state, the MOSFET will be kept in the ON state and the current will keep flowing through it instead of the body diode.
      I hope this helps

    • @dbtechs2593
      @dbtechs2593 ปีที่แล้ว

      how will the current flow back to the source if it has no gnd on source pin? the anode is floating..@@khaledmagdy

    • @khaledmagdy
      @khaledmagdy  ปีที่แล้ว +1

      I was going to draw some illustrative diagrams to help you in this until I found this article in the link below which already has enough information about this topic. Give it a look and tell me if you need any further help!
      electronicsbeliever.com/how-to-use-mosfet-as-reverse-battery-protection/