I am thinking to measure ERP from Emotiv EPOC (EEG), but in analysis, data should be divided based on timing of onset and offset of stimulus. So, during recording, timing of event, such as onset or offset, needs to be marked. Emotiv PRO offers function to record event marker via serial port. However, I have little knowledge about serial port, and I couldn't marked event. Could you tell me basic usage for Emotiv PRO about event marker via serial port ?
Below is what I tried.
First, I tried from MATLAB (2018a),
s=serial("/dev/cu.Bluetooth-Incoming-Port");
fopen(s);
then, from Emotiv PRO, I started "set up serial point markers" but response was
Resource Busy.
Second, I tried in different order and from Emotiv PRO, started "set up serial point markers", and then from MATLAB, ran same code, but response from MATLAB was
Cannot connect to the /dev/cu.Bluetooth-Incoming-Port port. Possible reasons are another application is connected to the port or the port does not exist.
Third, I tried new MATLAB (2020a),
s=serialport("/dev/cu.Bluetooth-Incoming-Port",9600)
and I started "set up serial point markers" from Emotiv PRO (error didn't appeared), and, again from MATLAB (2020a)
write(s,1,"uint8")
but, marker didn't appeared in Emotiv PRO.
I confirmed that Emotiv PRO appropriately record marker from key pressing, but I couldn't from serial port.