Sending triggers via serial port
I'm currently working on an experiment with BioSemi EEG and I'm trying to send triggers via serial port, without success.
I've tried the following code to open connection:
import serial exp.serial_port = serial.Serial('COM3', baudrate=115200, bytesize=serial.EIGHTBITS)
And I've tried the following code to send the trigger:
However, when I run the experiment, a error appeears:
unicode strings are not supported, please encode to bytes: '\x01'
I'm not sure what to do in order to send the triggers successfully. Can you help me please?