Matlab connection

Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Matlab connection
#1
We're having trouble starting up the Matlab software. When running PulsePal from the Matlab command line, we get the error:

Error using PulsePalSerialInterface (line 163)
Error: could not find your Pulse Pal device. Please make sure it is connected and drivers are
installed.

The firmware has been updated and Windows is recognizing the PP as an Arduino Due on COM7. How can we get Matlab to recognize that this thing is connected?
Reply
#2
(12-08-2016, 07:15 PM)mjacobs Wrote: We're having trouble starting up the Matlab software. When running PulsePal from the Matlab command line, we get the error:

Error using PulsePalSerialInterface (line 163)
Error: could not find your Pulse Pal device. Please make sure it is connected and drivers are
installed.

The firmware has been updated and Windows is recognizing the PP as an Arduino Due on COM7. How can we get Matlab to recognize that this thing is connected?

Hi MJacobs

The COM port auto-detect algorithm may not be finding your port correctly. 
Does it work if you run PulsePal('COM7') at the MATLAB command line?

If you share your OS and MATLAB version, I can help more.

Thanks,
Josh
Reply
#3
That worked! It was trying ports COM7C and COM7O, are those specific interfaces or is something going wrong in the auto-detect algorithm?

I'm using Matlab R2016a on Windows 10 for reference.
Reply
#4
(12-09-2016, 03:10 PM)mjacobs Wrote: That worked! It was trying ports COM7C and COM7O, are those specific interfaces or is something going wrong in the auto-detect algorithm?

I'm using Matlab R2016a on Windows 10 for reference.

Nope - I think the culprit is line 34 in /PulsePal/MATLAB/Interface/FindPulsePalPorts.m:

Code:
Clip = RawString(PortLocations(x):PortLocations(x)+6)

If you change it from +6 to +5, does it work?
If so, I'll have to figure out whether Windows10 sometimes returns funny strings.
If you make a breakpoint in the file and paste the contents of the RawString variable to the forums, we can probably solve it =)

Thanks,
Josh
Reply
#5
(12-09-2016, 06:35 PM)Josh Wrote:
(12-09-2016, 03:10 PM)mjacobs Wrote: That worked! It was trying ports COM7C and COM7O, are those specific interfaces or is something going wrong in the auto-detect algorithm?

I'm using Matlab R2016a on Windows 10 for reference.

Nope - I think the culprit is line 34 in /PulsePal/MATLAB/Interface/FindPulsePalPorts.m:

Code:
Clip = RawString(PortLocations(x):PortLocations(x)+6)

If you change it from +6 to +5, does it work?
If so, I'll have to figure out whether Windows10 sometimes returns funny strings.
If you make a breakpoint in the file and paste the contents of the RawString variable to the forums, we can probably solve it =)

Thanks,
Josh

Ahah, found it-- it's not on line 34 but on line 46, corresponding to our PulsePal 2.0

Changing PortLocations(x)+19 to +18 does the trick, it was just tacking on an extra character from RawString.
Reply
#6
(12-09-2016, 07:01 PM)mjacobs Wrote:
(12-09-2016, 06:35 PM)Josh Wrote:
(12-09-2016, 03:10 PM)mjacobs Wrote: That worked! It was trying ports COM7C and COM7O, are those specific interfaces or is something going wrong in the auto-detect algorithm?

I'm using Matlab R2016a on Windows 10 for reference.

Nope - I think the culprit is line 34 in /PulsePal/MATLAB/Interface/FindPulsePalPorts.m:

Code:
Clip = RawString(PortLocations(x):PortLocations(x)+6)

If you change it from +6 to +5, does it work?
If so, I'll have to figure out whether Windows10 sometimes returns funny strings.
If you make a breakpoint in the file and paste the contents of the RawString variable to the forums, we can probably solve it =)

Thanks,
Josh

Ahah, found it-- it's not on line 34 but on line 46, corresponding to our PulsePal 2.0

Changing PortLocations(x)+19 to +18 does the trick, it was just tacking on an extra character from RawString.

Very cool - Thanks for troubleshooting!
If you have a moment, can you please share the contents of RawString?
That will help me understand why it needs to be 18 on your system, and make a fix that will work more broadly.
Thanks again!!
Reply
#7
The contents of RawString in FindPulsePalPorts:

Code:
__GENUS                     : 2
__CLASS                     : Win32_SerialPort
__SUPERCLASS                : CIM_SerialController
__DYNASTY                   : CIM_ManagedSystemElement
__RELPATH                   : Win32_SerialPort.DeviceID="COM3"
__PROPERTY_COUNT            : 47
__DERIVATION                : {CIM_SerialController, CIM_Controller, CIM_LogicalDevice, CIM_LogicalElement...}
__SERVER                    : PSY074-W52736
__NAMESPACE                 : root\cimv2
__PATH                      : \\PSY074-W52736\root\cimv2:Win32_SerialPort.DeviceID="COM3"
Availability                : 2
Binary                      : True
Capabilities                :
CapabilityDescriptions      :
Caption                     : Intel(R) Active Management Technology - SOL (COM3)
ConfigManagerErrorCode      : 0
ConfigManagerUserConfig     : False
CreationClassName           : Win32_SerialPort
Description                 : Intel(R) Active Management Technology - SOL
DeviceID                    : COM3
ErrorCleared                :
ErrorDescription            :
InstallDate                 :
LastErrorCode               :
MaxBaudRate                 : 115200
MaximumInputBufferSize      : 0
MaximumOutputBufferSize     : 0
MaxNumberControlled         :
Name                        : Intel(R) Active Management Technology - SOL (COM3)
OSAutoDiscovered            : True
PNPDeviceID                 : PCI\VEN_8086&DEV_3B67&SUBSYS_02DA1028&REV_06\3&172E68DD&0&B3
PowerManagementCapabilities : {1}
PowerManagementSupported    : False
ProtocolSupported           :
ProviderType                : RS232 Serial Port
SettableBaudRate            : True
SettableDataBits            : True
SettableFlowControl         : True
SettableParity              : True
SettableParityCheck         : True
SettableRLSD                : True
SettableStopBits            : True
Status                      : OK
StatusInfo                  : 3
Supports16BitMode           : False
SupportsDTRDSR              : True
SupportsElapsedTimeouts     : True
SupportsIntTimeouts         : True
SupportsParityCheck         : True
SupportsRLSD                : True
SupportsRTSCTS              : True
SupportsSpecialCharacters   : False
SupportsXOnXOff             : True
SupportsXOnXOffSet          : True
SystemCreationClassName     : Win32_ComputerSystem
SystemName                  : PSY074-W52736
TimeOfLastReset             :
PSComputerName              : PSY074-W52736

__GENUS                     : 2
__CLASS                     : Win32_SerialPort
__SUPERCLASS                : CIM_SerialController
__DYNASTY                   : CIM_ManagedSystemElement
__RELPATH                   : Win32_SerialPort.DeviceID="COM1"
__PROPERTY_COUNT            : 47
__DERIVATION                : {CIM_SerialController, CIM_Controller, CIM_LogicalDevice, CIM_LogicalElement...}
__SERVER                    : PSY074-W52736
__NAMESPACE                 : root\cimv2
__PATH                      : \\PSY074-W52736\root\cimv2:Win32_SerialPort.DeviceID="COM1"
Availability                : 2
Binary                      : True
Capabilities                :
CapabilityDescriptions      :
Caption                     : Communications Port (COM1)
ConfigManagerErrorCode      : 0
ConfigManagerUserConfig     : False
CreationClassName           : Win32_SerialPort
Description                 : Communications Port
DeviceID                    : COM1
ErrorCleared                :
ErrorDescription            :
InstallDate                 :
LastErrorCode               :
MaxBaudRate                 : 115200
MaximumInputBufferSize      : 0
MaximumOutputBufferSize     : 0
MaxNumberControlled         :
Name                        : Communications Port (COM1)
OSAutoDiscovered            : True
PNPDeviceID                 : ACPI\PNP0501\1
PowerManagementCapabilities : {1}
PowerManagementSupported    : False
ProtocolSupported           :
ProviderType                : RS232 Serial Port
SettableBaudRate            : True
SettableDataBits            : True
SettableFlowControl         : True
SettableParity              : True
SettableParityCheck         : True
SettableRLSD                : True
SettableStopBits            : True
Status                      : OK
StatusInfo                  : 3
Supports16BitMode           : False
SupportsDTRDSR              : True
SupportsElapsedTimeouts     : True
SupportsIntTimeouts         : True
SupportsParityCheck         : True
SupportsRLSD                : True
SupportsRTSCTS              : True
SupportsSpecialCharacters   : False
SupportsXOnXOff             : True
SupportsXOnXOffSet          : True
SystemCreationClassName     : Win32_ComputerSystem
SystemName                  : PSY074-W52736
TimeOfLastReset             :
PSComputerName              : PSY074-W52736

__GENUS                     : 2
__CLASS                     : Win32_SerialPort
__SUPERCLASS                : CIM_SerialController
__DYNASTY                   : CIM_ManagedSystemElement
__RELPATH                   : Win32_SerialPort.DeviceID="COM7"
__PROPERTY_COUNT            : 47
__DERIVATION                : {CIM_SerialController, CIM_Controller, CIM_LogicalDevice, CIM_LogicalElement...}
__SERVER                    : PSY074-W52736
__NAMESPACE                 : root\cimv2
__PATH                      : \\PSY074-W52736\root\cimv2:Win32_SerialPort.DeviceID="COM7"
Availability                : 2
Binary                      : True
Capabilities                :
CapabilityDescriptions      :
Caption                     : Arduino Due (COM7)
ConfigManagerErrorCode      : 0
ConfigManagerUserConfig     : False
CreationClassName           : Win32_SerialPort
Description                 : Arduino Due
DeviceID                    : COM7
ErrorCleared                :
ErrorDescription            :
InstallDate                 :
LastErrorCode               :
MaxBaudRate                 : 115200
MaximumInputBufferSize      : 0
MaximumOutputBufferSize     : 0
MaxNumberControlled         :
Name                        : Arduino Due (COM7)
OSAutoDiscovered            : True
PNPDeviceID                 : USB\VID_2341&PID_003E&MI_00\7&2D7C6253&0&0000
PowerManagementCapabilities : {1}
PowerManagementSupported    : False
ProtocolSupported           :
ProviderType                : Modem Device
SettableBaudRate            : True
SettableDataBits            : True
SettableFlowControl         : True
SettableParity              : True
SettableParityCheck         : True
SettableRLSD                : True
SettableStopBits            : True
Status                      : OK
StatusInfo                  : 3
Supports16BitMode           : False
SupportsDTRDSR              : True
SupportsElapsedTimeouts     : True
SupportsIntTimeouts         : True
SupportsParityCheck         : True
SupportsRLSD                : True
SupportsRTSCTS              : False
SupportsSpecialCharacters   : False
SupportsXOnXOff             : False
SupportsXOnXOffSet          : False
SystemCreationClassName     : Win32_ComputerSystem
SystemName                  : PSY074-W52736
TimeOfLastReset             :
PSComputerName              : PSY074-W52736
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)