setPwm abstract method

Future<void> setPwm(
  1. String pin,
  2. double dutyCyclePct, {
  3. Map<String, dynamic>? extra,
})

Set the duty cycle of the given pin of a board.

// Set the PWM duty cycle of pin 13
await myBoard.setPwm('13', 0.6);

For more information, see Board component.

Implementation

Future<void> setPwm(String pin, double dutyCyclePct, {Map<String, dynamic>? extra});