Skip to content

Commit

Permalink
add math.h include
Browse files Browse the repository at this point in the history
  • Loading branch information
openshwprojects committed Sep 9, 2024
1 parent 209c9cd commit 6594d44
Showing 1 changed file with 9 additions and 4 deletions.
13 changes: 9 additions & 4 deletions src/driver/drv_pwmToggler.c
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
#include "drv_uart.h"
#include "../httpserver/new_http.h"
#include "../quicktick.h"
#include <math.h>

/*
PWM toggler provides you an abstraction layer over PWM channels
Expand Down Expand Up @@ -67,13 +68,17 @@ toggler_enable0 1
Test code for smooth transitions:
// NOTE: Enable "show raw pwm controllers" in flags
startDriver PWMToggler
toggler_channel0 4 20
toggler_name0 Laser
toggler_channel1 5 20
toggler_name1 Motor
// assumes we have PWM on channel 1
toggler_channel0 1 20
toggler_name0 First
// assumes we have PWM on channel 2
toggler_channel1 2 20
toggler_name1 Second
Expand Down

0 comments on commit 6594d44

Please sign in to comment.