Sin wave generation class using D/A converter(LPC1768)

Dependents:   agic_touch_panel_v3

Committer:
macht
Date:
Tue Jun 24 04:44:48 2014 +0000
Revision:
0:e934e95962bd
Sin wave generation class using D/A converter(LPC1768)

Who changed what in which revision?

UserRevisionLine numberNew contents of line
macht 0:e934e95962bd 1 #ifndef SINWAVE_H_
macht 0:e934e95962bd 2 #define SINWAVE_H_
macht 0:e934e95962bd 3 #include"mbed.h"
macht 0:e934e95962bd 4
macht 0:e934e95962bd 5 class Sinwave{
macht 0:e934e95962bd 6 public:
macht 0:e934e95962bd 7 Sinwave(PinName DAport,float amplitude,float frequency);
macht 0:e934e95962bd 8 void start();
macht 0:e934e95962bd 9 void stop();
macht 0:e934e95962bd 10 private:
macht 0:e934e95962bd 11 void update();
macht 0:e934e95962bd 12 float outputs_[10];
macht 0:e934e95962bd 13 float cycle_;
macht 0:e934e95962bd 14 Ticker output_int_;
macht 0:e934e95962bd 15 AnalogOut DAport_;
macht 0:e934e95962bd 16 };
macht 0:e934e95962bd 17 #endif