The following is an excerpt from A Comprehensible Guide To J1939 by Wilfried Voss.
For internal purposes, the parameter group number is extended to 24 bits = 3 bytes, where the most significant 6 bits are always set to zero. Each ECU must accomplish this process individually; this procedure is not part of the CAN standard.
To compile the exact Parameter Group Number (PGN), it is yet again necessary to consider the two alternatives, PDU1 (Peer-to-Peer communication) and PDU2 (Broadcast communication) format.
PDU1 – Peer-to-Peer Communication
The following picture demonstrates how a Parameter Group Number is assembled in PDU1 format. The PDU Format is less than 240, and thus the least significant 8 bits are set to zero. PDU Specific (PS) is handled as the destination address.
Note: While the destination address is defined to address a specific node (ECU) in the network, it can also be used to address all ECUs at the same time. For example, a destination address (DA) of 255 is called a Global Destination Address, and it requires all nodes to listen and, if required, to respond. The SAE J1939/21 standard defines the Global Destination Address in one short sentence that can be easily overlooked.
PDU2 – Broadcast Communication
The following picture demonstrates how a Parameter Group Number is assembled in PDU2 format. The PDU Format is equal to or greater than 240, and thus PDU Specific (PS) is handled as a group extension (GE).
Proprietary Parameter Group Numbers
As the name Proprietary Parameter Group Numbers implies, the SAE J1939 standard supports Parameter Groups in PDU1 and PDU2 Format that manufacturers can assign for their specific needs, including the use of the data field in the message. The only constraint is that, per the SAE request, it should avoid “excessive” utilization of the network (e.g., 2 percent or more). This requirement is, however, not based on any technical restrictions by the CAN/J1939 network.
The following table shows the Parameter Group Number Range where the Proprietary Parameter Group Numbers are highlighted.
SAE J1939 ECU Simulator Board With USB Port
The jCOM.J1939.USB gateway board is a high-performance, low-latency vehicle network adapter for SAE J1939 applications. It allows any host device with a USB COM port to monitor SAE J1939 data traffic and communicate with the SAE J1939 vehicle network.
The board supports the full SAE J1939 protocol according to J1939/81 Network Management (Address Claiming) and J1939/21 Transport Protocol (TP). It is also supported by an extensive programming interface for Windows and Linux/Ubuntu applications, including full C/C++/C# source code for short time-to-market developments.
The strength of the board lies in the fact that the entire SAE J1939 protocol, including all timing requirements, is stored on-chip, thus taking the burden off the main system. The board uses a USB COM port to communicate with the main system, i.e. all data transfer is handled through a standard COM port access.
The communication protocol between the board and the main system is well documented and thus allows a porting to any computer system with a USB connection. Working source code libraries exist for Windows (C# under Visual Studio 2012/2013), Linux and its derivatives (C++ using Code::Blocks), and Raspberry Pi (C using the standard gcc compiler).