\HRule
\vspace{0.4cm}
{\huge \bfseries Simulink code generation target for Texas~Instruments
- RM48 platform\par}
+ \tgname platform\par}
\vspace{0.4cm}
\HRule \\[1.5cm]
\label{chap-introduction}
This text documents software part of Rapid Prototyping Platform (RPP)
-project for Texas Instruments RM48 safety microcontroller. The
+project for Texas Instruments \tgname safety microcontroller. The
software consists of code generation target for Simulink Embedded
Coder, a low-level run-time C library and a tool for interactive
testing of hardware and software functionality.
Originally, the RPP project was created for TMS570 microcontroller and
-the port to RM48 was derived from it under a contract with Eaton
+the port to \tgname was derived from it under a contract with Eaton
Corporation.
The document contains step-by-step instructions for installation of
\section{Background}
\label{sec-background}
-The Rapid Prototyping Platform is an control unit based on TMDSRM48HDK
+The Rapid Prototyping Platform is an control unit based on \develkitname
development kit from Texas Instruments. Cental to the kit is the
-RM48L952 MCU -- an ARM Cortex R4 based microcontroller developed by
+\mcuname MCU -- an ARM Cortex R4 based microcontroller developed by
Texas Instruments. This MCU contains several protective mechanisms
(two cores in lockstep, error correction mechanisms for SRAM and Flash
memory, voltage monitoring, etc.) to fulfill the requirements for
safety critical applications.
-See~\cite{rm48xtechnicalreferencemanual2013} for details.
+See~\cite{\tgrefman} for details.
In order to develop non-trivial applications for the RPP, an operating
system is necessary. The RPP is based on FreeRTOS -- a simple
\label{sec-hardware-description}
This section provides a brief description of the Texas Instrument
-TMDSRM48HDK development kit. For a more detailed information refer to
-\cite{rm48hdkusersguide2013}. The kit is depicted in
+\develkitname development kit. For a more detailed information refer to
+\cite{\tghdkman}. The kit is depicted in
Figure~\ref{fig-board_photo}.
\begin{figure}\begin{center}
\noindent
\includegraphics[width=300px]{images/board.png}
- \caption{The TMDSRM48HDK kit \cite[p. 8]{rm48hdkusersguide2013}}
+ \caption{The \develkitname kit \cite[p. 8]{\tghdkman}}
\label{fig-board_photo}
\end{center}\end{figure}
Figure~\ref{fig-blocks} ilustrates the supported peripherals and their
connection to the MCU, expansion connectors and other components on
the development kit. For pinout description of the implemented
-peripherals refer the RM48HDK User's Guide
-\cite{rm48hdkusersguide2013}. The main features of supported
+peripherals refer the \tgname HDK User's Guide
+\cite{\tghdkman}. The main features of supported
peripherals are provided in the following subsections.
\begin{figure}\begin{center}
\item Pull up, Pull down or tri-stated for Input configuration.
\end{compactitem}
\item Some of the pins are connected to LEDs or to a button. See
- Figure~\ref{fig-blocks} or refer to~\cite{rm48hdkusersguide2013}.
+ Figure~\ref{fig-blocks} or refer to~\cite{\tghdkman}.
\end{compactitem}
\subsection{Analog Input (ADC)}
version of the library.
\item[7.4.0] Newest version distributed by the Texas Instruments.
\item[7.4.2] Newer version available from FreeRTOS pages. Slightly
-modified to run on RM48 MCU.
+modified to run on \tgname MCU.
\end{description}
\noindent
unified API.
Note that this functionality is not needed in the current version of
-for TMDSRM48HDK, because all IOs are controlled directly by GPIO pins.
+for \develkitname, because all IOs are controlled directly by GPIO pins.
As a result, the higher layers do not have to know anything about the
wiring of the peripherals, they can just call read, write or configure
\newpage
\subsection{Creating new project}
\label{sec:creating-new-project}
-Follow these steps to create an application for RM48 MCU compiled with
+Follow these steps to create an application for \tgname MCU compiled with
CGT.
\begin{compactenum}
-\item Create a new empty CCS project. Select RM48L952 device, XDS100v2
+\item Create a new empty CCS project. Select \mcuname device, XDS100v2
connection and set Linker command file to
- \texttt{rpp-lib/rpp/RM48L952FlashLnk.cmd}.
+ \texttt{rpp-lib/rpp/\ldscriptname}.
\noindent\includegraphics[scale=0.45]{images/base_1.png}
\item Configure the compiler \#include search path to contain
project's \texttt{include} directory, \penalty-100
- \texttt{\$\{RPP\_LIB\_ROOT\}/os/7.0.2\_rm48/include} and
+ \texttt{\$\{RPP\_LIB\_ROOT\}/os/7.0.2/include} and
\texttt{\$\{RPP\_LIB\_ROOT\}/rpp/include}, in that order.
\includegraphics[scale=.43]{images/base_5.png}
\textsc{Resume}.
\item If your application fails to run with a \texttt{\_dabort} interrupt, check
that the linker script selected in step 1 is not excluded from the build.
-You can do this by right clicking on the file \texttt{RM48L952FlashLnk.cmd}
+You can do this by right clicking on the file \texttt{\ldscriptname}
in the \textsc{Project Explorer} and unchecking the \textsc{Exclude from build}
item. The Code Composer Studio sometimes automaticaly excludes this file from
the build process when creating the new project.
% configuration. Select \textsc{Windows $\rightarrow$ Show View
% $\rightarrow$ Target Configurations}. In the shown window, click
% on \textsc{New Target Configuration} icon and configure XDS100v2
-% connection and RM48L952 device as shown below. Click \textsc{Save},
+% connection and \mcuname device as shown below. Click \textsc{Save},
% connect your board and click \textsc{Test Connection}.
% \medskip
\textsc{File$\rightarrow$New$\rightarrow$CCS Project}.
\item In the dialog window, type in a project name, for example
myBinaryLoad, Select \textsc{Device
-variant} (ARM, Cortex R, RM48L952, Texas Instruments XDS100v2 USB Emulator)
+variant} (ARM, Cortex R, \mcuname, Texas Instruments XDS100v2 USB Emulator)
and select project template to \textsc{Empty Project}. The filled dialog should
look like in Figure~\ref{fig-new-empty-project}
\item Click on the \textsc{Finish} button and a new empty project will
\item Click \textsc{New launch configuration} button
\item Rename the New\_configuration to, for example, myConfiguration.
\item Select configuration target file by clicking the \textsc{File
-System} button, finding and selecting the \texttt{RM48L952.ccxml} file. The result
+System} button, finding and selecting the \texttt{\tgconfigfilename} file. The result
should look like in Figure~\ref{fig-debug-conf-main-diag}.
\item In the \textsc{program} pane select the binary file you want to
download to the board. Click on the \textsc{File System} button,
\end{itemize}
Use GtkTerm in Linux or Bray Terminal for accessing the serial
-interface. On TMDSRM48HDK, the serial line is tunneled over the USB
+interface. On \develkitname, the serial line is tunneled over the USB
cable. % See Section \ref{sec-hardware-description} for reference about
% the position of the serial interface connector on the RPP board.
\begin{description}
\item[rpp-lib.lib and librpp.a] static RPP libraries.
- The first one is the library for Simulink models and other ARM/RM48
+ The first one is the library for Simulink models and other ARM/\tgname
applications, the other can be used for POSIX simulation. This files
are placed here by the Makefile, when the library is built.
nothing common with the test suite described later in
Chapter~\ref{chap-rpp-test-software} and those two suits are going
to be merged in the future. Also other Hello World applications are
- included as a reference about how to create an RM48 application.
+ included as a reference about how to create an \tgname application.
\item[os/] OS layers directory. See
Section~\ref{sec-operating-system-layer} for more information about
currently available operating system versions and
\item[rpp/] Main directory for the RPP library.
\item[rpp/doc/] RPP Library API
documentation.
-\item[rpp/RM48L952FlashLnk.cmd] CGT Linker command file.
+\item[rpp/\ldscriptname] CGT Linker command file.
This file is used by all applications linked for the RPP board,
including the Simulink models and test suite. It includes
\begin{compactitem}
\item Configure include search path to contain the directory of
used FreeRTOS version, e.g.
- \texttt{\repo/os/7.0.2\_rm48/include}. See Section
+ \texttt{\repo/os/7.0.2/include}. See Section
\ref{sec-software-architecture}.
\item Include \texttt{rpp/rpp.h} header file or just the needed
peripheral specific header files such as \texttt{rpp/can.h}.
The RPP library must be placed before Texas Instruments
support library \texttt{rtsv7R4\_T\_le\_v3D16\_eabi.lib}.
\item Use the provided linker command file
- \texttt{RM48L952FlashLnk.cmd}.
+ \texttt{\ldscriptname}.
\end{compactitem}
\subsection{POSIX target}
the operating system header files.
Current implementation for FreeRTOS includes a header file
-\texttt{\repo/rpp/lib/os/\-7.0.2\_rm48/\-include/os.h}, which
+\texttt{\repo/rpp/lib/os/\-7.0.2\-include/os.h}, which
contains all necessary declarations and definitions for the FreeRTOS.
We suggest to provide a similar header file for your operating system as
well.
implemented for the simulink target.
\item \textbf{Use OpenOCD to download the compiled binary}: This feature is not yet
-implemented for the RM48L952 simulink target.
+implemented for the \mcuname simulink target.
\item \textbf{Print model metadata to SCI at start}: if set this option will
print a message to the Serial Communication Interface when the model start
and prompt should look like:
\begin{verbatim}
-Ti HDK RM48L952, FreeRTOS 7.0.2
+Ti HDK \mcuname, FreeRTOS 7.0.2
Test Software version eaton-0.1-beta-8-g91419f5
CTU in Prague 10/2014
-->