Skip to content

GitLab

  • Menu
Projects Groups Snippets
    • Loading...
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in
  • D Documentation
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 0
    • Issues 0
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 0
    • Merge requests 0
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Monitor
    • Monitor
    • Incidents
  • Packages & Registries
    • Packages & Registries
    • Package Registry
    • Container Registry
    • Infrastructure Registry
  • Analytics
    • Analytics
    • CI/CD
    • Repository
    • Value Stream
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • anywave
  • Documentation
  • Wiki
  • MATLAB_debug

MATLAB_debug · Changes

Page history
transferring wiki from anywave to documentation authored Jun 06, 2024 by Bruno Colombet's avatar Bruno Colombet
Hide whitespace changes
Inline Side-by-side
Showing with 44 additions and 0 deletions
+44 -0
  • MATLAB_debug.md MATLAB_debug.md +44 -0
  • No files found.
MATLAB_debug.md 0 → 100644
View page @ 2d1e05f5
[[_TOC_]]
# Introduction
This command was designed for debugging purposes.
That means you will have to launch an instance of the AnyWave application in plugin debug mode specifying a TCP port to listen to.
# Launch AnyWave in debug mode
Depending on your OS platform, open a Terminal window or a console application and launch AnyWave using the following command:
````bash
anywave --plugin_debug --server_port 59000
````
If you installed the macOS version using the provided installation package, the anywave command is available from a terminal.
If you installed the Ubuntu 20.04 package, the command is available from a terminal.
If you installed the Windows release, you must add the PATH to the installation dir of AnyWave to the current system path or you must specify the full path to the anywave.exe file.
# Update your MATLAB path
in order to use anywave() function you must first add the path to the anywave mex fuctions to MATLAB.
````matlab
% Windows
addpath('c:\anywave\plugins\matlab\anywave');
% macos
addpath('/Applications/AnyWave.app/Contents/plugins/MATLAB/AnyWave');
% linux
addpath('/usr/local/AnyWave/Plugins/MATLAB/AnyWave');
````
# Connect to AnyWave as a fake plugin
````matlab
% use the same port number you specified when launching AnyWave.
props = anywave('debug_connect', 59000); % note that this is not a code you put in the main function.
% You can debug using the MATLAB workspace
% get the settings defined by AnyWave
% props is a struct containing all informations a plugin received when initialized.
````
This function will define a variable called *args* in the workspace namespace.
This variable is a struct containing all the settings defined by AnyWave when running a plugin.
# Test your code
While successfully connected to AnyWave, you can run any code using anywave() function.
You may have some issues as your code is not really running in the regular plugin context:
- The args struct returned will contain some empty paths, like the working directory path associated with the plugin or the plugin dir path.
You may have to take that into account while debugging.
\ No newline at end of file
Clone repository
  • Build_AnyWave
  • CLI
  • CLI_List
  • Changes
  • ExportData
  • MATLAB_API
  • MATLAB_BIDS
  • MATLAB_debug
  • MATLAB_functions
  • MATLAB_get_data
  • MATLAB_get_data_ex
  • MATLAB_get_markers
  • MATLAB_get_props
  • MATLAB_init
  • MATLAB_run
View All Pages