Skip to Main Content Skip to Search
Product Documentation

Place Component Function on MATLAB Search Path

Use MATLAB which Function to Find Component Function

The MATLAB function that you are associating with an HDL component must be on the MATLAB search path or reside in the current working folder (see the MATLAB cd function). To verify whether the function is accessible, use the MATLAB which function. The following call to which checks whether the function MyVhdlFunction is on the MATLAB search path, for example:

which MyVhdlFunction
/work/incisive/MySym/MyVhdlFunction.m

If the specified function is on the search path, which displays the complete path to the function. If the function is not on the search path, which informs you that the file was not found.

Add Component Function to MATLAB Search Path

To add a MATLAB function to the MATLAB search path, open the Set Path window by clicking File > Set Path, or use the addpath command. Alternatively, for temporary access, you can change the MATLAB working folder to a desired location with the cd command.

  


Recommended Products

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