Subversion Repositories NaviCtrl

Rev

Rev 437 | Rev 451 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 437 Rev 447
Line 100... Line 100...
100
u8 UART1_Request_Data3D             = FALSE;
100
u8 UART1_Request_Data3D             = FALSE;
101
u8 UART1_Request_MotorData          = FALSE;
101
u8 UART1_Request_MotorData          = FALSE;
102
u8 UART1_Request_Echo               = FALSE;
102
u8 UART1_Request_Echo               = FALSE;
103
u8 UART1_Request_ParameterId    = 0;
103
u8 UART1_Request_ParameterId    = 0;
104
u8 UART1_Request_Parameter              = FALSE;
104
u8 UART1_Request_Parameter              = FALSE;
-
 
105
u8 UART1_Request_SystemTime             = FALSE;
105
u8 UART1_DisplayKeys                    = 0;
106
u8 UART1_DisplayKeys                    = 0;
106
u8 UART1_DisplayLine                    = 0;
107
u8 UART1_DisplayLine                    = 0;
107
u8 UART1_ConfirmFrame                   = 0;
108
u8 UART1_ConfirmFrame                   = 0;
108
u8 UART1_Request_FTP                    = FALSE;
109
u8 UART1_Request_FTP                    = FALSE;
109
u8 LastTransmittedFCStatusFlags2 = 0;
110
u8 LastTransmittedFCStatusFlags2 = 0;
Line 403... Line 404...
403
        switch(SerialMsg.Address) // check for Slave Address
404
        switch(SerialMsg.Address) // check for Slave Address
404
        {
405
        {
405
                case NC_ADDRESS:  // own Slave Address
406
                case NC_ADDRESS:  // own Slave Address
406
                switch(SerialMsg.CmdID)
407
                switch(SerialMsg.CmdID)
407
                {
408
                {
-
 
409
                        case 't': // request for the GPS time 
-
 
410
                                UART1_Request_SystemTime  = TRUE;
-
 
411
                                break;
408
                       
412
 
409
                        case 'f': // ftp command
413
                        case 'f': // ftp command
410
                               
-
 
411
                                UART1_Request_FTP = SerialMsg.pData[0];
414
                                UART1_Request_FTP = SerialMsg.pData[0];
412
                                //if (UART1_Request_FTP == FTP_CMD_SET_CWD || UART1_Request_FTP == FTP_CMD_GET_FILE) 
415
                                //if (UART1_Request_FTP == FTP_CMD_SET_CWD || UART1_Request_FTP == FTP_CMD_GET_FILE) 
413
                                memcpy(&FTP_data, &SerialMsg.pData[1], sizeof(FTP_data)); // copy ftp parameter
416
                                memcpy(&FTP_data, &SerialMsg.pData[1], sizeof(FTP_data)); // copy ftp parameter
414
                        break;
417
                        break;
Line 825... Line 828...
825
        else if(UART1_Request_VersionInfo && (UART1_tx_buffer.Locked == FALSE))
828
        else if(UART1_Request_VersionInfo && (UART1_tx_buffer.Locked == FALSE))
826
        {
829
        {
827
                MKProtocol_CreateSerialFrame(&UART1_tx_buffer, 'V', NC_ADDRESS,1, (u8 *)&UART_VersionInfo, sizeof(UART_VersionInfo));
830
                MKProtocol_CreateSerialFrame(&UART1_tx_buffer, 'V', NC_ADDRESS,1, (u8 *)&UART_VersionInfo, sizeof(UART_VersionInfo));
828
                UART1_Request_VersionInfo = FALSE;
831
                UART1_Request_VersionInfo = FALSE;
829
        }
832
        }
-
 
833
        else if(UART1_Request_SystemTime && (UART1_tx_buffer.Locked == FALSE))
-
 
834
        {
-
 
835
                MKProtocol_CreateSerialFrame(&UART1_tx_buffer, 'T', NC_ADDRESS,1, (u8 *)&SystemTime, sizeof(SystemTime));
-
 
836
                UART1_Request_SystemTime = FALSE;
-
 
837
        }
830
        else if(UART1_Request_ErrorMessage && (UART1_tx_buffer.Locked == FALSE))
838
        else if(UART1_Request_ErrorMessage && (UART1_tx_buffer.Locked == FALSE))
831
        {
839
        {
832
                MKProtocol_CreateSerialFrame(&UART1_tx_buffer, 'E', NC_ADDRESS, 1, (u8 *)&ErrorMSG, sizeof(ErrorMSG));
840
                MKProtocol_CreateSerialFrame(&UART1_tx_buffer, 'E', NC_ADDRESS, 1, (u8 *)&ErrorMSG, sizeof(ErrorMSG));
833
                UART1_Request_ErrorMessage = FALSE;
841
                UART1_Request_ErrorMessage = FALSE;
834
        }
842
        }