MATLAB: Serial port is not working


I am working with the USB-RLY82 from
I have connected this device to the computer and it is available on COM3. But when i make a serial and open the port, it is not responding. I have a C++ program to control the device and this program works, so the device is not broken. But i want to control the device via matlab. How can i fix the serial?
this script is used to open the serial:

Best Answer

  • Oh i solved my own problem, i should use int8 commands:
    fwrite(s, [hex2dec('64')], 'int8');