General structure introduction
The development board basically has all the modules of six-channel ABS electronic control unit, including single chip microcomputer, solenoid valve drive, motor drive, power supply module, wheel speed processing and so on. In addition, there are wheel speed generation module and display module. The circuit board (referred to as circuit board 1 for short) below the LCD screen is used to generate a square wave signal and send it to the high-speed input capture port (CAPCOM) of the main control chip XC 164CS. Acceleration, deceleration and braking buttons are used to control the frequency of square wave signals, which can simulate the acceleration, deceleration and braking process of vehicles. After calculation, the main control chip sends the calculation results of wheel speed, wheel acceleration and deceleration, slip rate and so on to the circuit board 1 through the serial port, and then drives the LCD screen to display the data. At the same time, the main control chip drives the alarm lamp, motor, relay and valve according to different calculation results, thus simulating the working process of ABS.
Most of the chips of the development board are special chips produced by Infineon, which are widely used by ABS manufacturers at home and abroad. The main functional modules and chips used are shown in table 1:
Remarks on using chips in functional modules. The main chip MCU 1XC 164CS mainly completes the tasks of signal processing, calculation and control. The monitoring chip MCU2C505CA is mainly responsible for monitoring the work of the main chip. The main chip provides external CAN interface TLE6250, and the monitoring chip provides control diagnosis module K-LINE TL6259 to control the alarm lamp. Relay drive TL62 1 0-Internal CAN communication-Connect two MCU valves to drive TL6228 * * with 12 driving power supply and reset TLE7469 to provide dual voltmeter1function module and use chip.
The main control chip XC 164CS and the monitoring chip C505CA are introduced in detail below.
Main control chip XC 164CS
XC 164CS is a 16-bit high-end single chip microcomputer introduced by Infineon in recent years. Microcontrollers have the following advantages:
Fast operation speed: it can reach the CPU frequency of 40MHz.
Large storage capacity:
-2kB dual-port RAM is used for variables, register pool and system stack;
-Additional 2kB high-speed data SRAM for variables and user stacks
-2kB high-speed SRAM for code and data
-128k flash supports online programming.
There are many interrupt sources: 70 kinds of interrupts are received, which are divided into 16 interrupt priorities (ILVL), and each interrupt priority is divided into 4 group priorities (GLVL). The higher the number, the higher the priority.
With the on-chip debugging interface OCDS, the OCDS interface standard test protocol (compatible with IEEE1149.1) is mainly used for in-chip testing. Now, most advanced devices support JTAG protocol, such as DSP and FPGA devices. The standard JTAG interface consists of four lines: TMS, TCK, TDI and TDO, which are mode selection, clock, data input and data output lines respectively. OCDS interface extends JTAG interface, and its functions are shown in Table 2. TMS mode selection
OCDS interface greatly facilitates software debugging, which will be described in detail in the next section.
In addition, the chip also has the advantages of more peripheral IO ports, more clocks and more AD conversion ports, and has two CAN interfaces.
TDO test data output CPUCLKCPU clock TDI test data input TRST test reset input TCK test clock input BRKIN hardware interrupt input TRAP trap condition VCC positive voltage (5V)GND digital reset chip reset BRKOUT hardware interrupt output ocds enable Table 2 OCDS interface function description.
Development method of XC 164CS
XC 164CS can be connected with the host computer in three ways for on-chip simulation: serial port mode (bootloader mode), parallel port mode (LPT) and USB port mode (OCDS). Among them, the parallel port mode requires the main frequency of the upper computer to be less than 800MHz, which brings inconvenience to the application. Serial port mode, low speed. It needs to occupy a serial port, and it is often disconnected during debugging, so it is not used. OCDS interface is a debugging interface specially provided by XC 164CS, and it is also one of the main characteristics different from other Infineon 164 series single-chip computers. Therefore, the development board adopts OCDS debugging method.
The compiler used in the software is Keil Vision2 (PK 166, editor's note), which has powerful debugging function. Not only can pure software simulation be carried out, but the upper computer can also be connected with the user board through the parallel port or USB port to realize on-chip debugging. The connection relationship is shown in Figure 3.
Among them, ULINK is an adapter from USB interface to OCDS interface, which has the following characteristics:
The quick connection between the upper computer and the user board is realized through USB port;
The on-chip debugging function is realized through the on-chip debugging interface OCDS;
Realize the burning function of on-chip flash through OCDS.
Monitoring chip C505CA
The monitoring chip communicates with the main control chip in real time to ensure the correct operation of the main control, and the monitoring chip also performs the function of fault diagnosis.
C505CA is an 8-bit microcontroller of Infineon, based on 805 1 kernel. Its advantages are as follows:
The operation speed is fast, and the working frequency can reach 20MHz.
With on-chip CAN interface, it is convenient to communicate with the main control chip;
Support on-chip simulation;
Use patch packaging.
Workflow of development board
After the development board is powered on, the LCD screen displays some explanatory information, and at the same time, it starts to simulate the ABS power-on self-test: the alarm light flashes for a few seconds, then the LEDs of the analog motor and the 12 solenoid valve light up in turn, and finally all the LEDs flash once.
After the self-inspection, the LCD screen starts to display the wheel speed calculation value sent by XC 164CS, and the wheel speed pulse is generated by the circuit board 1; If the current wheel speed is low, the LED of the analog motor and 12 solenoid valve will light up circularly, indicating that the ABS system will not carry out low-speed anti-lock braking, but only conduct routine on-line inspection; If the current wheel speed is high, all LEDs except the warning light will flash at the same time, indicating that the ABS system will work at this speed.
For the change of wheel speed, you need to use three buttons on the development board. If you hold down the up key, the wheel speed will increase; If you hold down the down key, the wheel speed will decrease; If you press the stop key, the current wheel speed will quickly drop to 0.
Application of development board in ABS development process
Because Intel's 196 series single chip microcomputer was used as the main control chip, it is a very complicated job to transplant the code of 196 to XC 164CS. In view of the danger of real vehicle testing, the code must be strictly verified before real vehicle testing, and the development board has played this role well.
First of all, the development board can observe the wheel speed, wheel acceleration and deceleration and other control variables. By changing the frequency of pulse generation and observing the display of LCD, we can know whether the calculation result is right or wrong, which is very intuitive.
Secondly, it can verify the operation of the main control chip and monitoring chip on external devices such as alarm lights, relays, motors and solenoid valves.
Thirdly, the switch beside the valve can simulate the on-off of the valve and realize the function of fault diagnosis.
Fourthly, through the CAN communication between the main control chip and the monitoring chip, the correctness of the codes of the main control chip and the monitoring chip is verified.
In addition, the access conditions of ABS can also be verified by the development board.
The difference between development board and actual AB system
Development board is only used to verify the functions of ABS system and single chip microcomputer, so it can't be comprehensive, and some functions can't be demonstrated, such as:
XC 164CS and C505CA provide powerful CAN interface, and in the design process, the K-line /LIN bus interface is extended on the board, but it is impossible to demonstrate its real-time data transmission in the automobile network.
It is impossible to complete the perfect diagnosis function, because the LED used to demonstrate the motor and solenoid valve needs very little driving current compared with the actual motor and solenoid valve, and the Infineon TLE6228 driving chip used in ABS will think this situation is a fault.