Main Content

deleteCursor

Delete Logic Analyzer cursor

Description

deleteCursor(scope,tag) deletes the Logic Analyzer cursor specified by the input tag.

example

Examples

collapse all

This example shows how to use functions to create, manipulate, and delete cursors in a dsp.LogicAnalyzer object.

Create Logic Analyzer and Signals

scope = dsp.LogicAnalyzer('NumInputPorts',3);
for ii = 1:20
    scope(ii,10*ii,20*ii);
end

Add Cursor

Add a cursor at 15 seconds and show the cursor information.

cursor = addCursor(scope,'Location',15,'Color','Cyan');
getCursorInfo(scope,cursor)
ans = struct with fields:
    Location: 15
       Color: [0 1 1]
      Locked: 0
         Tag: 'C2'

Modify Cursor

Change the cursor color to magenta.

hide(scope)
modifyCursor(scope,cursor,'Color','Magenta')
show(scope)

Remove Cursor

Delete the yellow cursor at 0 seconds.

hide(scope)
tags = getCursorTags(scope);
deleteCursor(scope,tags{1});
show(scope)

Input Arguments

collapse all

The Logic Analyzer object from which you want to delete a cursor, specified as a handle to the dsp.LogicAnalyzer object.

The tag identifying which cursor to delete, specified as a randomly assigned character vector.

Example: deleteCursor(scope,tag) deletes a cursor from Logic Analyzer.

Data Types: char | string

Version History

Introduced in R2013a