| | |
| | | * @return |
| | | */ |
| | | scpi_result_t SCPI_CoreIdnQ(scpi_t * context) { |
| | | SCPI_ResultMnemonic(context, context->idn[0]); |
| | | SCPI_ResultMnemonic(context, context->idn[1]); |
| | | SCPI_ResultMnemonic(context, context->idn[2]); |
| | | SCPI_ResultMnemonic(context, context->idn[3]); |
| | | int i; |
| | | for (i = 0; i<4; i++) { |
| | | if (context->idn[i]) { |
| | | SCPI_ResultMnemonic(context, context->idn[i]); |
| | | } else { |
| | | SCPI_ResultMnemonic(context, "0"); |
| | | } |
| | | } |
| | | return SCPI_RES_OK; |
| | | } |
| | | |
| | |
| | | * @return |
| | | */ |
| | | scpi_result_t SCPI_CoreTstQ(scpi_t * context) { |
| | | int result = 0; |
| | | if (context && context->interface && context->interface->test) { |
| | | result = context->interface->test(context); |
| | | } |
| | | SCPI_ResultInt(context, result); |
| | | (void) context; |
| | | SCPI_ResultInt(context, 0); |
| | | return SCPI_RES_OK; |
| | | } |
| | | |