/*
 * serial.c
 *
 *  Created on: Nov 30, 2022
 *      Author: thomm
 */

#include "system.h"
#include "uartstdio.h"
#include "user_io.h"
#include "uart3.h"
#include "serial.h"


/*
 * serial_stateMachine on uart0
 *
 * commands:
 *      gdata,
 *      ts,
 *      stop,
 *      dump,
 *      samp_byte,
 *      gh,
 *      gm,
 *      sl,
 *      ss,
 *      pumpon,
 *      pumpoff,
 *      go,
 *      resume,
 *      exit
 *
 *
 *
 *
 *
 *
 *
 *
 *
 */

int serial_stateMachine(int serialState)
{




}


#ifdef NOCODE
uint32_t exec_command(uint32_t timeout)
{
    //time_t start_time;
    int charCount, gdata, ts, stop, dump, samp_byte, gh, gm, sl, ss, pumpon, pumpoff, go, resume, exit;  //, to, tc;   // to, tc added for Dale Graves nsFOCE Jan 2020 Thom, nsFOCE team changed requirements so it was removed.
    int pumponFlg;
    char buff[81];
    FIL fileObject;
    FRESULT fresult;
    UINT br;
    bool line_end;
    time_t current_time;        // new

    pumponFlg = 0;

    if(sys_data.app_cfg[APPCFG_DEPLOY_UARTECHO] == 0)
    {
        UARTEchoSet(false);  // 18 Aug 2021 Disable UART echo in deployment - this is for m2m / labview to reduce the amount of echo char parsing along with 0x0d, 0x0a echo
    }



}
#endif
