This script is executed by nru230_startup_script.sh. It also leverages jetson_clocks to ensure a stable heartbeat protocol between the Jetson and the automotive MCU.
sudojetson_clockssudo./UARTSend&#jetson_clocks : Set the jetson clocks to 2.2GHz.
System Monitoring Sample Code
On NRU-230V-AWP, it's located at the following path. The System Monitoring sample code could be found at github.
CANDataFormat.ini
This CANDataFormat.ini offers 3 different System Monitoring modes.
Jetson Status
The CPU and GPU information is based on tegrastats, so it is important to ensure that tegrastats is working properly on your machine.
/home/nvidia/System_Monitoring/UART/
CANDataFormat.ini ; Modify MCU send data format via CAN BUS
GetPCStatus.sh ; Get Jetson OS status data & analyze
GetPCStatus_Simple.sh ; Get Jetson CPU & GPU temperature & analyze
runStatus.sh ; nru230_startup_script.sh execute this script
UARTSend ; Main application, runStatus.sh would execute this APP
Is_Simple=0
; Mode 0: Send Heartbeat only. (default)
; Mode 1: Send Heartbeat + CPU/GPU temperature.
; Mode 2: Send Heartbeat + CPU/GPU temperature + CPU/GPU
Heartbeat_Period=15
; The unit is milliseconds (ms).
; If the MCU does not receive a sufficient heartbeat from the Jetson
; via the internal UART within the specified "Heartbeat_Period,"
; the MCU will assume that the Jetson is not functioning properly.
; The minimum value for Heartbeat_Period is 10 ms.
; The maximum value for Heartbeat_Period is 1000 ms.
Host_Period=5
; The unit is milliseconds (ms).
; On the Jetson side, the Jetson will send a heartbeat every "Host_Period" ms.
; To ensure that the MCU can receive a heartbeat within the "Heartbeat_Period",
; it is recommended to set the "Host_Period" to less than 50% of the "Heartbeat_Period."od".
; For example:
; Heartbeat_Period = 15ms
; Host_Period < 7ms; DO HIGH
; 7ms <= Host_Period < 15ms; DO HIGH or LOW
; Host_Period >= 15ms; DO LOW for 7ms (ROUNDDOWN(Heartbeat_Period/2,0))