------------------------------------------------------------------------------- Generate a pulsewidth modulated sequence given x. If no outputs are specified it will plot the sequence. ------------------------------------------------------------------------------- Form: [tPWM, tSign, xPWM] = PWMSeq( m, dT, x, dTSeq, wDither ) ------------------------------------------------------------------------------- ------ Inputs ------ m (1,1) Magnitude dT (1,1) Sampling rate x (n) Input sequence dTSeq (1,1) Sampling time for the input sequence wDither (1,1) If add triangle wave dither to the output ------- Outputs ------- tPWM (n) Times for each pulse at each dTSeq tSign (n) Sign of the command xPWM (n) Value at each dTSeq -------------------------------------------------------------------------------