I hope everyone is doing well and is safe.
We are using BCI2000 to record EEG data, so no BCI's just yet

If we record EEG data with BCI2000, how do we send event markers (The event being the stimulation device has turned on) as accurately as possible without the use of a trigger box? The device is controlled using Matlab commands and all event times are stored in Matlab but are misaligned when the recording of BCI2000 starts and when we run Matlab separately.
I think there are three ways we can solve this problem in a real-time recording or offline:
1. In real-time: Connect Matlab and BCI2000, so when a command is sent from Matlab to the device, a command is sent to BCI2000 as well to mark the event (The event, again, is that the device has turned on) in a real-time recording.
2. In real-time: The moment the Arduino device is turned on, a signal is sent to BCI2000 as the data is being recorded and the event is marked in a real-time recording.
I read on the wiki there is this option (Please see attached Event MarkerQuestion.jpg). Is there more to this or is this the solution to our problem? If we do use the C++ or the Matlab implementation presented on the Wiki, how do we check the delay of our system?
3. Offline: After the experiment is done, match up the times in BCI2000 with the times that the commands were sent in Matlab after the recording is finished.
Previous discussions on this forum said to look at the App Connector, but the wiki
(https://www.bci2000.org/mediawiki/index ... _Connector)
says it's superseded by other BCI2000 code, so if there is another wiki link it would help:
Thank you so much, everyone!