Important changes to forums and questions
All forums and questions are now archived. To start a new conversation or read the latest updates go to forums.mbed.com.
11 years, 11 months ago.
how to use LPC1768 to pause the waveform of a sinewave generator
Please i have been trying to use this mbed to pause the waveform of a sine-wave
generator but i don't know how to go about it. please i need advice on how to write the programme.
thanks
1 Answer
11 years, 11 months ago.
please help if you have any useful advice
i know this code is the most stupid code ever, i am just trying to see how i can pause the waveform with mbed. i am new to mbed
- include "mbed.h"
DigitalIn sinewaveinput(p7) DigitalOut osci_input(p23)
Int v; int main() { while(1) {
if (sinewaveinput.receive()) { v=sinewaveinput.read(); osci_input=v; if(v==1); sinewaveinput.pause(0); } else { sinewaveinput.pause(1); } } }
posted by 04 Jan 2013