Forum Rule: Always post complete source code & details to reproduce any issue!
Results 1 to 3 of 3

Thread: Phase Shift PWM?

  1. #1
    Junior Member
    Join Date
    Sep 2020
    Posts
    7

    Phase Shift PWM?

    Hello!

    I using 4 PWM channels for 4 Motors. I want to lower the current that goes through the somewhat long cable to the whole PCB.. and my idea is that the 4 PWM channels are slightly phase shifted that they are not ON all at the same time.

    Is that possible and how should I manage to do that? I am using the analogWrite(); function in Arduino.


    Thanks for any advice!

    schlank

  2. #2
    Senior Member
    Join Date
    Jul 2020
    Posts
    406
    You'd need to configure 4 separate timers for that (usually each timer controls multiple PWM pins). Depends on
    the precise microcontroller how to do this.

    But perhaps you just need decent decoupling on the board to smooth the supply current? What kind of current
    are we talking, and what PWM frequency?

  3. #3
    Junior Member
    Join Date
    Sep 2020
    Posts
    7
    Hi!

    I changed the PCB so only 2 PWM channels are needed as 2 Motors anyway have the same speed. I have 4 Motors with a peak of 1A at 24V and the whole robot has a 15m cable. I put a 1500uF 35V capacitor on the PCB to lower the ripple. I don't know if this is enough.

    Thanks in advance

    schlank

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •