Difference between revisions of "MATLAB code"

From Training Technology Lab Wiki
Jump to navigation Jump to search
Line 14: Line 14:
  
 
=== MATLAB scripts: ===
 
=== MATLAB scripts: ===
'''Rosbag loader'''
+
'''rosbag_loader.m'''
 
Converts .bag files into .mat files. Must be done before using the other 2 scripts
 
Converts .bag files into .mat files. Must be done before using the other 2 scripts
  
'''Rosbag'''
+
'''rosbag_plotter.m'''
 
Automatically plots known data formats)
 
Automatically plots known data formats)
  
'''Rosbag video'''
+
'''rosbag_video.m'''
 
Automatically converts rosbags into .avi files with data plot overlays.
 
Automatically converts rosbags into .avi files with data plot overlays.
 
  
 
== EMG analyzer ==
 
== EMG analyzer ==

Revision as of 13:23, 9 August 2019

Introduction

Training Technology Lab uses MATLAB for most data processing and visualization purposes. Several scripts have been written to work with our various technology. Here is a list of the following scripts:

  • Rosbag extraction

Rosbag extraction

Official methods:
Viewing: For viewing video stored in a .bag file, rqt_bag is the standard tool.

Extraction: To extract video (which are just compressed/uncompressed images) several methods exist. We have often used bag2video.

MATLAB scripts:

rosbag_loader.m Converts .bag files into .mat files. Must be done before using the other 2 scripts

rosbag_plotter.m Automatically plots known data formats)

rosbag_video.m Automatically converts rosbags into .avi files with data plot overlays.

EMG analyzer

Purpose: For analyzing EMG data recorded with Myon electrodes and ADInstruments AD converter via ROS-setup in Training Technology Lab

FAQ/Debugging

This sections relates to all common problems with the software.