Memory Commands

These commands are used for memory storage and retrieval.

:MEMory:DATA and :MEMory:APPend commands are provided for backward compatibility with previous instruments.

 

:MMEMory:DATA "<file_name>",#ABC or
:MEMory:DATA "<file_name>",#ABC

This command writes <data> into "<file_name>", where <data> is in 488.2 block format.  

The PXB expects to see waveform data as block data (binary files). The IEEE standard 488.2-1992 section 7.7.6 defines block data. The following example shows how to structure a SCPI command for downloading waveform data where #ABC represents the block data.

"<file_name>"

The file name can be the short name, full file path, or NVWFM format.

  • Use the short name ("my_file"); the file will be stored in the default directory D:\User_My_Documents.

  • Use the file path: "D:\User_My_Documents\my_file" (recommended)

  • Use the non-volatile file name: (NVWFM[1,2,3,...9]); the file will be stored in D:\Waveforms\Channel[1,2,3,...,9] respectively.

#

This character indicates the beginning of the data block.

A

Number of decimal digits present in B

B

Decimal number specifying the number of data bytes to follow in C

C

Actual binary waveform data

 

:MMEMory:DATA:APPend "<file_name>",<blockdata> or
:MEMory:DATA:APPend "<file_name>",<blockdata>

This command appends byte data to an existing file stored in memory in the specified "<file name>".

"<file_name>"

This variable names the destination file.

<blockdata>

This parameter represents the file length and data to be appended.

 

Example: "NVWFM1:IQ_Data",#14Y9oL

"NVWFM1:IQ_Data"

File path and file name. (D:\Waveforms\Channel1 is implied by reference.)

#149oL 

Data block

#

This character indicates the beginning of the data block.

1

Number of digits in the byte count.

4

Byte count

Y9oL

Four byes of data to be appended (used for example purpose only)

 

The following commands are not supported for non-volatile waveform memory (NVWFM).

 

:MMEMory:CATalog? "<file_system>"

This query outputs a list of the files from the specified file system. The return data will be in the following form: <mem_used>,<mem_free>{,"<file_listing>"}.

 

:MMEMory:CDIRectory "[<directory_name>]", "[<directory_name>]"

:MMEMory:CDIRectory?

This command changes the directory name for a file system. If no parameter is specified, the directory is set to the *RST value. At *RST, this value is set to the default user data directory. The query returns the full path of the default directory.

 

:MMEMory:COPY "<file_name>","<file_name>"

This command makes a duplicate of the requested file.

 

:MMEMory:DELete "<file_name>",<directory_name>

This command removes a file from the specified directory.

 

:MMEMory:MDIRectory <directory_name>

This command creates a new directory where the <directory name> parameter specifies the name of the new directory.
 

:MMEMory:MOVE "<src_file>","<src_file_1>"

This command renames the src_file to src_file_1.
 

:MMEMory:RDIRectory <directory_name>

This command removes a directory where the <directory_name> parameter specifies the name of the directory to be removed. All files and directories under the specified directory are also removed.