Hi,
With the release of R2016b, support package version 16.2.2, we are now supporting external mode on all the GPIO pins that can be configured for SCI_A via the SCI_A pane (Hardware Implementation->Target Hardware Resources-> SCI_A). However, which GPIO pin for the given board needs to be selected is dependent on the board schematic. If the user has a custom designed board, then user must configure those GPIO pins for SCI_A which are routed to serial port/FTDI chip. Bottom line is, any GPIO pin which support SCI_A functionality can be configured for external mode, but which GPIO pin is used on the given board for SCI_A is for users to investigate. Some popular board from TI and their default GPIO pin assignment for SCI_A are as below:
For F28377S Launchpad, FTDI connected to GPIO pins GPIO84(Tx) and GPIO85(Rx)
For F28379D Launchpad, FTDI connected to GPIO pins GPIO42(Tx) and GPIO43(Rx)
For F28377D Controlcards,FTDI connected to GPIO pins GIO29(Tx) and GPIO28(Rx)
Selecting internal oscillator works for F28379D Launchpad for following reason: the external oscillator on this launchpad runs at 10MHz, but our default value for Oscillator clock (OSCCLK) frequency in MHz is 20MHz. This default value is true for a F28379D control card but not for launchpad. When user generates the code keeping this default value and tries to run it on Launchpad, we get incorrect value for the PLL multiplier as we are generating it for a 20MHz oscillator but launchpad has a 10MHz oscillator as noted above. This in-turn affects the calculation of other parameters like SCI baud rate which affects the external mode. However, selecting internal oscillator for the launchpad seem to do the trick, upon selection, we no more default to 20MHz but use actual value of the internal oscillator i.e 10MHz, to derive the PLL multiplier. This keeps other calculations consistent and thus external mode works. It would be better if the user is able to change the external oscillator frequency “Oscillator clock (OSCCLK) frequency in MHz” from default value of 20MHz to 10MHz if he plans to work with F28379D Launchpad against the current solution of selecting the internal oscillator.
Regards,
Venkatesh Chilapur
Best Answer
- Parameter tuning and signal logging for 8-bit data types is not supported over serial external mode for Texas Instruments C2000 processors.
- An error stating "Attempting to establish connection with hostname 127.0.0.1 through port ..." indicates that either the COM port or the TCP/IP port 17725 on the local loopback are held by some other application. Ensure that the ports are available before launching external mode. External mode uses a process in the background to buffer data and improve data logging. This process needs port 17725.
- When using a serial connection like DB9 connector on Spectrum eZDSP boards, use the COM1 port of Host PC for external mode connection.
7. Tips on Improving Performance Issues- If you observe breaks in the scope traces, you can try the following to improve logging performance:\n
- Increase serial baud rate
- Decrease the number of signals selected for logging
- Decrease the model base rate
- When running external mode, be careful not to increase the acquisition frequency beyond the functional range of 10kHz. Please refer to the MATLAB Answer post below which gives details on modeling workarounds using Rate Transition block and DSP buffer blocks that can help step the acquisition frequency up to 50KHz on a F28379D board. The same underlying concept can be used on any board. The link below also contains information on the 2model approach which is seen as an alternative to external mode simulation for fast data logging up to 200kHz.
https://www.mathworks.com/matlabcentral/answers/353179-how-to-increase-acquisition-frequency-in-real-time-ti-board-f28379d- If you cannot run your model in CCP external mode, please compare the model configuration settings from our example model with your model. For example: As CAN external mode is dependent on custom storage class canlib.signal, we should not select ‘Ignore custom storage class’ in the Interface pane under Code Generation. For details on custom storage class canlib.signal please refer the documentation page:
https://www.mathworks.com/help/supportpkg/texasinstrumentsc2000/ug/external-mode.html- Signals that are coming out of function call (triggered) subsystems or signals inside function call subsystems are currently not supported for logging due to asynchronous behavior. One workaround for this issue is to log outside the triggered subsystem after adding a rate transition block before logging.
- For external mode over CAN, note that our examples are tested to work with hardware from Vector only. Please refer to the following MATLAB Answers post for more information:
https://www.mathworks.com/matlabcentral/answers/431853-ecan-loading-problems-to-ti-c2000-c28x3x-card-are-example-only-for-vector-hardware