| Contents | Index |
You can configure RecordMode to be overwrite, append, or index. If RecordMode is overwrite, then the record file is overwritten each time recording is initiated. If RecordMode is append, then data is appended to the record file each time recording is initiated. If RecordMode is index, a different record file is created each time recording is initiated, each with an indexed filename.
You can configure RecordMode only when the object is not recording. You terminate recording with the record function. A object that is not recording has a RecordStatus property value of off.
You specify the record filename with the RecordName property. The indexed filename follows a prescribed set of rules. Refer to Specifying a File Name for a description of these rules.
Usage | Any instrument object |
Read only | While recording |
Data type | String |
{overwrite} | The record file is overwritten. |
append | Data is appended to the record file. |
index | Multiple record files are written, each with an indexed filename. |
Suppose you create the serial port object s on a Windows machine associated with the serial port COM1.
s = serial('COM1');
fopen(s)Specify the record filename with the RecordName property, configure RecordMode to index, and initiate recording.
s.RecordName = 'myrecord.txt'; s.RecordMode = 'index'; record(s)
The record filename is automatically updated with an indexed filename after recording is turned off.
record(s,'off') s.RecordName ans = myrecord01.txt
Disconnect s from the instrument, and remove s from memory and from the MATLAB workspace.
fclose(s) delete(s) clear s
RecordDetail, RecordName, RecordStatus

Includes the most popular MATLAB recorded presentations with Q&A sessions led by MATLAB experts.
| © 1984-2012- The MathWorks, Inc. - Site Help - Patents - Trademarks - Privacy Policy - Preventing Piracy - RSS |