Changes to standard SCPI commands: IDN/OPC

This commit is contained in:
Jan Käberich 2023-07-16 12:35:10 +02:00
parent 7370ed7f17
commit 0ba1493d19
3 changed files with 7 additions and 2 deletions

View File

@ -212,7 +212,9 @@ Some commands are both events and queries, depending on whether the question mar
\section{Commands}
\subsection{General Commands}
\subsubsection{*IDN}
\query{Returns the identifications string}{*IDN?}{None}{LibreVNA-GUI}
\query{Returns the identifications string}{*IDN?}{None}{LibreVNA,LibreVNA-GUI,dummy\_serial,<software version>}
\subsubsection{*OPC}
\query{Returns a 1 after every previous command has been handled}{*OPC?}{None}{1}
\subsubsection{*LST}
\query{Lists all available commands}{*LST?}{None}{List of commands, separated by newline}
\subsection{Device Commands}

View File

@ -477,7 +477,10 @@ void AppWindow::CreateToolbars()
void AppWindow::SetupSCPI()
{
scpi.add(new SCPICommand("*IDN", nullptr, [=](QStringList){
return "LibreVNA-GUI";
return "LibreVNA,LibreVNA-GUI,dummy_serial,"+appVersion;
}));
scpi.add(new SCPICommand("*OPC", nullptr, [=](QStringList){
return "1";
}));
auto scpi_dev = new SCPINode("DEVice");
scpi.add(scpi_dev);