Problem with real-time execution with External mode of simulation in Simulink

Homepage Forums Emotiv Main Forum Applications & Games Problem with real-time execution with External mode of simulation in Simulink

This topic contains 4 replies, has 3 voices, and was last updated by  gmac 2 years, 8 months ago.

  • Author
  • #105853

    Reza Abiri

    real-time, simulink

  • #220672

    Reza Abiri

    Recently, we bought ‘EPOC Simulink EEG Importer’ software for our Lab. We can run the Simulink model with its default setting with Normal mode of simulation in Simulink. Right now, I have another Simulink file for another hardware that can connect with Simulink with External Mode of simulation and it can be run as a standalone without any error. By copying the EpocEEG block from the previous file to this Simulink, I am trying to run both models in one Simulink window for my further application and work. But, at the start of running this Simulink, there is an error:
    S-function ‘cmex_EmotivEpocEEG’ in ‘newTest2/cmex_EmotivEpocEEG’ specifies option SS_OPTION_SFUNCTION_INLINED_FOR_RTW however a
    ‘cmex_EmotivEpocEEG.tlc’ file could not be located in the current working directory, the S-function directory ‘C:\Users\mabe\Desktop\Epoc
    Simulink EEG Importer\Matlab’, or the directory ‘C:\Users\mabe\Desktop\Epoc Simulink EEG Importer\Matlab\tlc_c
    It seems to me that the problem is because of the External mode of simulation and EpocEEG block can not be run just by *.mexw64 file in the route.

    I am not sure what is the best solution for this problem. Any help will be appreciated.
    Thanks a lot,

  • #220677


    Simulink EEG Importer is a third party app provided by Xcessity. You can contact them for advice at

  • #229512

    Dear Reza

    Have you tried to buffer the signal in case of applying any kind of sliding window-based signal processing in the Simulink?

  • #229519


    I guess this means you can copy the data into a circular buffer large enough to contain your sliding window then extract the sample you are interested in and pass it to the analysis package. So for example if you want to pass 2 seconds of data into your processing engine, updated every 0.25 seconds (for example) you can make a circular buffer 512 samples long and trigger your analysis when 32 samples have been added to the buffer

The forum ‘Applications & Games’ is closed to new topics and replies.