This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

configure CCS v6 or CCS v5 to work with Simulink

Other Parts Discussed in Thread: TMS320F28069M

I am trying to configure CCS v6 to work with Simulink (MATLAB R2016a​) so that I flash the generated code to my board directly from Simulink. Is this possible? And how?

I am using TMS320F28069M board, windows 7 64 bit.

  • To do this, in your Simulink model, go to Simulation -> Model Configuration Parameters -> Hardware Implementation

    Here there is a check-box to boot-from-flash, check the box and rebuild your model.

    Doc link (Login may be required): http://www.mathworks.com/help/supportpkg/texasinstrumentsc2000/ug/coder-target-pane-texas-instruments-c2000-processors.html#bu1q1kf

  • I got the following error:

    -------------------------------------------------------------
    Build process completed successfully
    Failed to open serial port '\\.\COM2'. The reported error code is: 2 or 0x00000002. Possible causes are:
    a) The target is not powered on.
    b) The specified port number is not correct.
    c) The specified bit rate is not supported by the host machine.
    d) The previous connection was not closed correctly. If this is the case, you may need to re-start MATLAB.
    Error occurred while executing External Mode MEX-file 'ext_serial_win32_comm':
    Failed to connect to the target. Possible reasons for the failure:
    a) The target is not switched on.
    b) The target is not connected to your host machine.
    c) The application for the model is not running on the target. You might have clicked the Stop button. If the Run button is not dimmed, click it. Otherwise, click the Build button, which downloads and runs your application on the target.

    Caused by:
    ExtOpenSerialConnection() returned an error. More details may be reported in the MATLAB command window.
    Component: Simulink | Category: Model error
    Unable to connect to the 'TI Piccolo F2806x' target for 'untitled'.
    Component: Simulink | Category: Model error
    -------------------------------------------------------------

    It is as if Simulink is not detecting the board.

    I followed this video tutorial:
    www.youtube.com/watch
  • If you previously connected to the board via CCS, the USB port might be locked and cant be accessed by MathWorks tools for download.

    1) Test that CCS can connect and download. This verifies the connectivity.
    2) Close CCS. I'm hoping this will free the USB port.
    3) Rebuild and see if the download works.

    -Brian
  • I still get the same error.
  • I'm not sure what is amiss, but I still think the USB port is locked.  What happens if you reboot your machine and try and build and run from MATLAB, before opening CCS?

    You may need to contact MathWorks Technical Support for additional assistance.

    -Brian

  • Hi

    I trying to run my simulink model in external mode with TI's 28335 exp kit , CCSv6 ,Matlab 2016a, window 8.1-64 bit.

    error is-

    Failed to open serial port '\\.\COM2'. The reported error code is: 2 or 0x00000002. Possible causes are:
    a) The target is not powered on.
    b) The specified port number is not correct.
    c) The specified bit rate is not supported by the host machine.
    d) The previous connection was not closed correctly. If this is the case, you may need to re-start MATLAB.

    deploying the model works , but external mode is problem.

    restarting matlab does not works.

    I want to know that contacting Matworks support team is only the remaining choice?

    Thanks.