Logo Search packages:      
Sourcecode: icomlib version File versions  Download package

const char * PCP::PCPGetModeStr (  ) 

Gets current session's mode setting (const char* version).

Checks PCPRadio struct for member PCPMode for the current mode setting. Decodes the mode setting to plain english equivalent.

Returns:
the plain english of current mode setting
See also:
PCPGetMode PCPSetMode

Definition at line 1041 of file pcp.cpp.

References PRadInf::PCPMode, PCPRadio, and PCPTemp.

{
    memset(PCPTemp, '\0', sizeof(PCPTemp));

    if (strcmp(PCRMODWFM, PCPRadio->PCPMode)==0) {
      strcpy(PCPTemp, "WFM");
      return PCPTemp;
    } else if (strcmp(PCRMODNFM, PCPRadio->PCPMode)==0) {
      strcpy(PCPTemp, "NFM");
      return PCPTemp;
    } else if (strcmp(PCRMODCW, PCPRadio->PCPMode)==0) {
      strcpy(PCPTemp, "CW");
      return PCPTemp;
    } else if (strcmp(PCRMODAM, PCPRadio->PCPMode)==0) {
      strcpy(PCPTemp, "AM");
      return PCPTemp;
    } else if (strcmp(PCRMODUSB, PCPRadio->PCPMode)==0) {
      strcpy(PCPTemp, "USB");
      return PCPTemp;
    } else if (strcmp(PCRMODLSB, PCPRadio->PCPMode)==0) {
      strcpy(PCPTemp, "LSB");
      return PCPTemp;
    } 
    
    strcpy(PCPTemp, "UNKNOWN");
    return PCPTemp;

}


Generated by  Doxygen 1.6.0   Back to index