Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Fork of Smoothie by
libs/Pwm.h
- Committer:
- Bigcheese
- Date:
- 2014-03-02
- Revision:
- 3:f151d08d335c
- Parent:
- 2:1df0b61d3b5a
File content as of revision 3:f151d08d335c:
#ifndef _PWM_H
#define _PWM_H
#include <stdint.h>
#include "Pin.h"
#include "Module.h"
class Pwm : public Module, public Pin {
public:
Pwm();
void on_module_load(void);
uint32_t on_tick(uint32_t);
Pwm* max_pwm(int);
int max_pwm(void);
void pwm(int);
void set(bool);
int _max;
int _pwm;
int _sd_accumulator;
bool _sd_direction;
};
#endif /* _PWM_H */
