![background image](http://html1.mh-extra.com/html/neuronexus/smartbox/smartbox_instruction-manual_1676335042.webp)
NeuroNexus Technologies, Inc. ©2014
| 655 Fairfield Court, Suite 100, Ann Arbor, Michigan USA
Telephone: +1.734.913.8858 | Fax: +1.734.786.0069 |
APPENDIX B
If no supply voltage channels are enabled in the GUI, this file will not be written.
The following MATLAB code reads a supply voltage data file and creates a waveform matrix with units of volts:
num_channels = length(supply_voltage_channels);
% supply channel info from header file
fileinfo = dir(
‘supply.dat’
);
num_samples = fileinfo.bytes/(num_channels * 2);
% uint16 = 2 bytes
fid = fopen(
‘supply.dat’
,
‘r’
);
v = fread(fid, [num_channels, num_samples],
‘uint16’
);
fclose(fid);
v = v * 0.0000748;
% convert to volts
Board ADC input data file: auxin.dat
This file contains a matrix of ADC samples from the analog inputs on the SmartBox
™
, in
uint16
format. To convert to volts, multiply by 0.000050354. (If
the board mode is not equal to zero, other scaling values may apply.)
If no board ADC input channels are enabled in the GUI, this file will not be written.
The following MATLAB code reads an board ADC input data file and creates a waveform matrix with units of volts:
num_channels = length(board_adc_channels);
% ADC input info from header file
fileinfo = dir(
‘analogin.dat’
);
num_samples = fileinfo.bytes/(num_channels * 2);
% uint16 = 2 bytes
fid = fopen(
‘analogin.dat’
,
‘r’
);
v = fread(fid, [num_channels, num_samples],
‘uint16’
);
fclose(fid);
v = v * 0.000050354;
% convert to volts
p.42