23-PIN ECU CONNECTOR SIGNAL
ROUTING AND WIRING HARNESS
The 23-pin ECU connector, routing
communication and external I/O
signals including:
– 2x ADC input channels;
– 2x HS PWM output channels;
– 2x PWM input capture channels;
– 3x CAN bus;
– 2x LIN bus;
– 1x 100M-base TX1 automotive
ethernet;
– +12V VBAT power supply input;
– +5V power supply output for
external devices;
The 23-pin ECU connector enables the
board to work as GP-ECU easily:
The 23-pin ECU connector matched
wiring harness with signal labels as
below photo.
It is not included in S32K148 T-BOX
RDB, please contact NXP sales for
purchase:
PIN#SignalWire color
1VBATred1.2512V @ max 5A
2CAN1Hyellow0.5CAN bus 1 differential signal+
3CAN2Hyellow0.5CAN bus 2 differential signal+
4ECU_EXT_HS1green0.5ECU High Side driver output 1
5CAN0Hyellow0.5CAN bus 0 differential signal+
6ECU_EXT_ADC1blue0.5ECU external analog input 1
7ECU_EXT_ADC2blue0.5ECU external analog input 2
8GNDblack1.25Power/signal ground
9VBATred1.2512V @ max 5A
10ECU_EXT_LIN1white0.5LIN bus 1
11ECU_EXT_LIN2white0.5LIN bus 2
12SBC_HVIO5orange0.5SBC HVIO5
13ECU_EXT_PWM2purple0.5PWM input channel 2
14ECU_EXT_PWM1purple0.5PWM input channel 1
15ECU_EXT_5Vred0.75
16GNDblack1.25Power/signal ground
17CANL1pink0.5CAN bus 1 differential signal-
18CANL2pink0.5CAN bus 2 differential signal-
19ECU_EXT_HS2green0.5ECU High Side driver output 2
20CANL0pink0.5CAN bus 0 differential signal-
21GNDblack1.25Signal ground
22ENET_TRX_Pgreen0.5
23ENET_TRX_Norange0.5
Wire gauge
(conductor CSA/mm2)
description
5V power supply for ECU
external device@max100mA
100M-base TX1 automotive
ethernet differential signal+,
UTP
100M-base TX1 automotive
ethernet differential signal -,
UTP
7
Page 8
JUMPER SETTINGS (POWER SUPPLY)
JumperConfigurationDescription
J2
J8
J9
J29
J111-2 (Default)
The jumper connection schematic is as below, details can be found in the board schematic;
1-2 (Default)The 3.3V supply powered from VBAT(+12V);
2-3The 3.3V supply powered from P5V0(5V);
1-2 (Default)The P5V0 supply powered from SBC output ;
2-3Not use, no power source(NC on J8-3);
1-2 (Default)The VDD supply powered from P3V3_SW(3.3V);
2-3The VDD supply powered from P5V0(5V);
1-2 (Default)VCAN_SBC supply powered from P5V0_V1SBC;
2-3VCAN_SBC supply powered from PVEXT_SBC;
It’s connected between VDD and VDD_MCU, and is designed for
S32K148 MCU low-power static current measurement, for this case,
R77 needs to be unmounted.
JUMPER SETTINGS (LIN AND RTC CLOCK CONFIGURATION)
JumperConfigurationDescription
J32
J33
J34
External active 32.768 KHz oscillator for RTC schematic is as right, details can be found in the board
schematic and HW UG;
short (Default)Enable the LIN bus 1 pullup to work as a master node;
openThe LIN bus 1 is working as a slave node;
short (Default)Enable the LIN bus 2 pullup to work as a master node;
openThe LIN bus 2 is working as a slave node;
1-2 (Default)External active 32.768KHz oscillator for RTC is powered by VDD_MCU;
2-3
External active 32.768KHz oscillator for RTC is powered by VDD_MCU_
PERH;
8
Page 9
USING ETHERNET AND QSPI
IMPORTANT OBSERVATION
The S32K148 is the only member of the
family able to use ethernet and QuadSPI.
However, these interfaces are mutually
exclusive so only one of them can be
used at a time. In order to use either
Ethernet or QuadSPI, user must follow
an specific resistor configuration. The
default configuration of the board is to
be used for ethernet communication.
CHANGE 0Ω CONFIGURATION
RESISTORS TO REUSE BETWEEN
ENET AND QUADSPI
For S32K148 T-BOX RDB, some ENET
and QuadSPI data lines are shared
from the MCU, each interface is
separated by two 0 Ω resistors
external +12V power supply via the
23-pin ECU connector with the wiring
harness. If no 23-pin ECU connector
wiring harness available, the board be
powered by J31-8 (GND) and J31-1
(+12V)
Note: There is no embedded debugger
(e.g. OpenSDA) on the RDB, so debug
is done using PEMicro U-Multilink/FX
through J12 with a mini-20 pin cable on
debugger’s port F
After power on, the D10, D11 and D12
on the left up corner of the board will
light on
With Connecting the U-Multilink
debugger to PC, its USB and TGTPWR
LED will be lighted on
S32K148 T-BOX RDB SETUP CONNECTION
10
Page 11
Use the BSP test project
STEP 1: DOWNLOAD & INSTALL S32DS FOR ARM V2018.R1 AND S32K SDK RTM 2.0.0
Download S32DS for ARM v2018.R1 from the following link:
http://www.nxp.com/S32DS
– The download will require a NXP account login, user can register the account with any e-mail, and after download, you can
install S32DS IDE with a 32-bit active code received by the e-mail when download
Download and install the S32K SDK RTM 2.0.0
– S32 Design Studio for Arm® 2018.R1 Update 6 SDK S32K14x RTM v.2.0.0(REV UP6)
Any questions, please refer to the following NXP technical community for help:
https://community.nxp.com/docs/DOC-335302
STEP 2: IMPORT AND COMPILE THE BSP TEST PROJECT (1)
Open S32DS for ARM v2018.R1 IDE select File > Import.
Select General > Existing Projects into Workspace > Next
11
Page 12
STEP 2: IMPORT AND COMPILE THE BSP TEST PROJECT (2)
Select archive file > Browse, browse and choose S32K148_Based_T_BOX_BSP_TestPrj_SDK_RTM2_0.zip, select the project >
Finish:
After importing the project, clean it at first: select the project in Project Explorer, then right-click, choose Clean Project:
12
Page 13
STEP 2: IMPORT AND COMPILE THE BSP TEST PROJECT (3)
Select the project in Project Explorer, then right-click, choose Build Project:
The compile result is as below if no errors are found:
13
Page 14
STEP 3: DOWNLOAD AND DEBUG THE BSP TEST PROJECT
Select the project in Project Explorer, then right-click, choose Debug As > Debug Configuration:
In the Debug Configuration window, select the GDB PEMicro Interface Debugging > S32K148_Based_T_BOX_BSP_TestPrj_
SDK_RTM2_0_Debug>Debugger>under Interface select right debugger, and ensure Port has the right part number, then in
Additional Options, check Emergency Kinetis Device Recovery by Full Chip Erase and Use SWD protocol (if not check this
option, it will use JTAG debug protocol), at last, click Debug to launch the debug(it will download the compile result—elf file in
to the target MCU at first):
14
Page 15
STEP 4: CONNECT THE UART CONSOLE FOR TEST RESULT OUTPUT DISPLAY
The BSP test project use S32K148 LPUART2 to output the test result;
Use a USB-to-UART adapter to connect the board with PC via J25-6(TXD), J25-7(RXD) and J25-12(GND):
* For more details on the test results description and demo projects, please refer to the Software User Guide.
Open a UART console(e.g. Serial Port Utility) on PC, configure its serial communication format as the following:
– Data rate: 115200 baud/s;
– Data Bits: 8;
– Parity: None;
– Stop Bits: 1
– Flow Control: OFF
Then you can see the test result output as below:
15
Page 16
RDB Software package overview
OTHER DEMO PROJECTS
Besides of the BSP test project, which includes the SDK API based LLD of GPS module, BLE module, MMA8452Q,
PCA85063ATT, 3x FlexCAN, 3x LPUART communication, 2x HS(PWM), 2x user bottom, GPIO IRQ interrupt, RGB LED, 2x
input capture, 2x external analog input, 2x Touch Sense PAD and etc.
The SW package also provides the following demo projects:
– QSPI Flash test project
– LwIP based ENET and TJA1101 TCP/IP sever/client communication demo project
– LIN stack based Single board LIN master and slave communication demo project
– I2S audio codec—SGTL500 demo project
– T-BOX reference design project
* For more details, please refer to the S32K148 T-BOX_GP-ECU RDB SW user guide and download the SW package
16
Page 17
Create a New Project in
S32 Design Studio
CREATE NEW PROJECT: FIRST TIME – SELECT A WORKSPACE
Start program: Click on “S32 Design Studio for ARM v1.0” icon
Select workspace:
– Choose default (see below example) or specify new one
– Suggestion: Uncheck the box “Use this as the default and do not ask again”
– Click OK
CREATE NEW PROJECT: TOP MENU SELECTION
File – New –Project
17
Page 18
CREATE NEW PROJECT: S32DS PROJECT
Project Name:
– Example: FirstProject
Project Type:
– Select from inside executable or library folder
Next
Select Debugger Support and Library Support
Click Finish
18
Page 19
OPENSDA CONFIGURATION
To Debug your project with OpenSDA, it is necessary to select the OpenSDA in the Debug Configuration.
Select your project, and click on debug configuration
Select the Debug configuration under GDB PEMicro Interface Debugging
Click on Debugger tab
Select OpenSDA as the interface, if your board is plugged should appear in the Port field.
Click Apply and debug to finish.
19
Page 20
Debug Basics
DEBUG BASICS: STARTING THE DEBUGGER
Debug configuration is only required once. Subsequent starting of debugger does not require those steps.
Three options to start debugger:
– If the “Debug Configuration” has not been closed, click on “Debug” button on bottom right
– Select Run – Debug (or hit F11)
Note: This method currently selects the desktop target (project.elf) and gives an error. Do not use until this is changed.
Recommended Method: Click on pull down arrow for bug icon and select …_debug.elf target
DEBUG BASICS: STEP, RUN, SUSPEND, RESUME
Step Into (F5)
Step Over (F6)
Step Return (F7)
Run
Suspend
Resume (F8)
20
Page 21
DEBUG BASICS: VIEW & ALTER VARIABLES
View variables in “Variables” tab.
Click on a value to allow typing in a different value.
DEBUG BASICS: VIEW AND ALTER REGISTERS
View CPU registers in the “Registers” tab
Click on a value to allow typing in a different value
View peripheral registers in the EmbSys Registers tab