Shop OBEX P1 Docs P2 Docs Learn Events
Smart Pin Center Aligned PWM for 3 Phase Motor Driver — Parallax Forums

Smart Pin Center Aligned PWM for 3 Phase Motor Driver

I am working my way through the datasheet for the smart pins. I am converting one of my 3 phase motor drivers as an example to determine the feasibility of using the Propeller 2.

I need to generate 3 center aligned PWM signals. It would be extremely helpful if someone more familiar with smart pins could provide some direction?

Thank you for your time.

Comments

  • I found the information I needed with the Propeller 2 Smart Pin Supplementary Documentation by Jon Titus. Definitely a requirement and hopefully examples like this can be included in the datasheet.

  • remember you can start/stop multiple smartpins at the same time by using addpins to create a pingroup and use the pingroup for dirh/dirl.

    Enjoy!

    Mike

  • @msrobots Thanks Mike, just what I was looking for!

  • The PWM triangle mode of the smart pins only supports loading of the Y register once per full up/down counting cycle. I got around this restriction by using sawtooth mode instad and inverted the pin output polarity and negated the Y value at the beginning of each odd/even cycle with an interrupt. This way you can get double the update rate or half the switching frequency which helps reducing switching losses for high power IGBTs or MOSFETs.

  • @ManAtWork Thank you, great tip!

  • I had to look up centered aligned PWM to see what it is...
    I think the smart pin triangle mode is center aligned, and the saw tooth mode is left aligned...

    https://marcelmg.github.io/pwm_left_vs_centered/

    Mike

  • @mwroberts Thank you Mike for the reference. Yes, I have confirmed the triangle pwm is center aligned.

Sign In or Register to comment.