Proyecto de Tesis en Mecatrónica. Universidad Técnica del Norte. Ernesto Palacios <mecatronica.mid@gmail.com>
Dependencies: EthernetNetIf HTTPServer QEI_hw RPCInterface mbed
main.cpp@4:552beeda4722, 2012-03-28 (annotated)
- Committer:
- Yo_Robot
- Date:
- Wed Mar 28 18:42:32 2012 +0000
- Revision:
- 4:552beeda4722
- Parent:
- 3:8d5a9e3cd680
- Child:
- 5:c5aea1eb10bb
Generador de frecuencias OK!
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
Yo_Robot | 4:552beeda4722 | 1 | // GENERADOR DE FRECUENCIAS |
Yo_Robot | 3:8d5a9e3cd680 | 2 | |
Yo_Robot | 3:8d5a9e3cd680 | 3 | #include "mbed.h" |
Yo_Robot | 3:8d5a9e3cd680 | 4 | #include "setup.h" |
Yo_Robot | 3:8d5a9e3cd680 | 5 | |
Yo_Robot | 3:8d5a9e3cd680 | 6 | Serial pc( USBTX, USBRX ); |
Yo_Robot | 3:8d5a9e3cd680 | 7 | |
Yo_Robot | 3:8d5a9e3cd680 | 8 | int main() { |
Yo_Robot | 3:8d5a9e3cd680 | 9 | |
Yo_Robot | 4:552beeda4722 | 10 | // IMPRIMIR modo de operacion |
Yo_Robot | 4:552beeda4722 | 11 | pc.printf( "\n GENERADOR DE FRECUENCIAS\n" ); |
Yo_Robot | 4:552beeda4722 | 12 | pc.printf( "\n Formato: F___H\\r " ); |
Yo_Robot | 4:552beeda4722 | 13 | pc.printf( "\n Genera un tren de pulsos en Hz ej: F500H" ); |
Yo_Robot | 4:552beeda4722 | 14 | pc.printf( "\n Generara un tren de impulsos de 500Hz, al final del comando se debe" ); |
Yo_Robot | 4:552beeda4722 | 15 | pc.printf( "\n ingresar enter (CarriageReturn, \\r )\n" ); |
Yo_Robot | 4:552beeda4722 | 16 | |
Yo_Robot | 4:552beeda4722 | 17 | pc.printf( "\n Formato: F___K\\r " ); |
Yo_Robot | 4:552beeda4722 | 18 | pc.printf( "\n Genera un tren de pulsos en kHz ej: F250K" ); |
Yo_Robot | 4:552beeda4722 | 19 | pc.printf( "\n Generara un tren de impulsos de 250kHz, al final del comando se debe" ); |
Yo_Robot | 4:552beeda4722 | 20 | pc.printf( "\n ingresar enter (CarriageReturn, \\r )\n" ); |
Yo_Robot | 3:8d5a9e3cd680 | 21 | |
Yo_Robot | 4:552beeda4722 | 22 | pc.printf( "\n Formato: I___I\\r " ); |
Yo_Robot | 4:552beeda4722 | 23 | pc.printf( "\n INICIO del tren de pulsos ej: I22I" ); |
Yo_Robot | 4:552beeda4722 | 24 | pc.printf( "\n El numero entre las I no interesa, al final del comando se debe" ); |
Yo_Robot | 4:552beeda4722 | 25 | pc.printf( "\n ingresar un enter (CarriageReturn, \\r )\n" ); |
Yo_Robot | 4:552beeda4722 | 26 | |
Yo_Robot | 4:552beeda4722 | 27 | pc.printf( "\n Formato: P___P\\r " ); |
Yo_Robot | 4:552beeda4722 | 28 | pc.printf( "\n PARO del tren de pulsos ej: P22P" ); |
Yo_Robot | 4:552beeda4722 | 29 | pc.printf( "\n El numero entre las I no interesa, al final del comando se debe" ); |
Yo_Robot | 4:552beeda4722 | 30 | pc.printf( "\n ingresar un enter (CarriageReturn, \\r )\n" ); |
Yo_Robot | 4:552beeda4722 | 31 | |
Yo_Robot | 4:552beeda4722 | 32 | pc.printf( "\n Los numeros ingresados deben ser solamente enteros \n\n" ); |
Yo_Robot | 4:552beeda4722 | 33 | |
Yo_Robot | 4:552beeda4722 | 34 | setTimer2(); |
Yo_Robot | 3:8d5a9e3cd680 | 35 | pc.attach( &ISR_Serial ); |
Yo_Robot | 3:8d5a9e3cd680 | 36 | |
Yo_Robot | 4:552beeda4722 | 37 | |
Yo_Robot | 3:8d5a9e3cd680 | 38 | while(1) { |
Yo_Robot | 3:8d5a9e3cd680 | 39 | |
Yo_Robot | 3:8d5a9e3cd680 | 40 | |
Yo_Robot | 3:8d5a9e3cd680 | 41 | } |
Yo_Robot | 2:a1b556d78a7f | 42 | } |