-
Notifications
You must be signed in to change notification settings - Fork 9
/
Copy pathaddSymphonyFramework.m
29 lines (25 loc) · 1.29 KB
/
addSymphonyFramework.m
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
% Copyright (c) 2012 Howard Hughes Medical Institute.
% All rights reserved.
% Use is subject to Janelia Farm Research Campus Software Copyright 1.1 license terms.
% http://license.janelia.org/license/jfrc_copyright_1_1.html
function addSymphonyFramework()
if isempty(which('NET.convertArray'))
% Use the .NET stub classes instead of the real thing on non-PC platforms.
symphonyPath = mfilename('fullpath');
parentDir = fileparts(symphonyPath);
addpath(fullfile(parentDir, filesep, 'Stubs'));
else
isWin64bit = strcmpi(getenv('PROCESSOR_ARCHITEW6432'), 'amd64') || strcmpi(getenv('PROCESSOR_ARCHITECTURE'), 'amd64');
if isWin64bit
symphonyPath = 'C:\Program Files (x86)\Physion\Symphony\bin';
else
symphonyPath = 'C:\Program Files\Physion\Symphony\bin';
end
% Add Symphony.Core assemblies
NET.addAssembly(fullfile(symphonyPath, 'Symphony.Core.dll'));
NET.addAssembly(fullfile(symphonyPath, 'Symphony.ExternalDevices.dll'));
NET.addAssembly(fullfile(symphonyPath, 'HekaDAQInterface.dll'));
NET.addAssembly(fullfile(symphonyPath, 'Symphony.SimulationDAQController.dll'));
NET.addAssembly('System.Windows.Forms');
end
end