Nigson Burgos / Mbed 2 deprecated DEBER_COMUNICACION_SERIAL

Dependencies:   mbed

Recepto_Datos/main.cpp

Committer:
nigsonb
Date:
2020-02-15
Revision:
1:7791182b8283

File content as of revision 1:7791182b8283:

#include "mbed.h"
#include "math.h" //libreria para las operaciones matematicas
char texto[20];
//Serial xbee (PA_2, PA_3);// comunicacion serial
Serial xbee (PC_10,PC_11);// comunicacion serial
Serial PC (SERIAL_TX, SERIAL_RX); //comunicacion con el hercules serial
float valor;
int main (){
    xbee.baud(9600); //velocidad de transmicion
    PC.baud(9600);
    while(true){   
      PC.scanf("%s[^\n]",texto);
      xbee.printf ("%s\n\r",texto);
      PC.printf ("ENVIA DATOS: %s\n\r",texto);
       wait(0.1);
           }
}