
1. Background Introduction
The rules for the 20th National College Student Intelligent Car Competition have been released, and the race will be held in the summer of 2025. The competition is divided into 9 subject groups, among which the “Speedy Optoelectronics” group is distinguished into two tracks based on different car models and programming methods, namely the Loongson track and the NXP-MicroPython track. The competition tasks, environment, and sensor requirements for both tracks are roughly the same, except that the NXP-MicroPython track requires the use of balanced D and E car models as the platform, utilizing an NXP controller-based MicroPython development board as the main control unit, and programming the car model using Python. This article will explain the NXP-MicroPython track of the Speedy Optoelectronics group. The official documentation will be published on the National College Student Intelligent Car Competition website.
Regarding MicroPython, many of you may already be familiar with it. In the previous 19th competition, a dedicated MicroPython track was set up in the camera group, and a MicroPython challenge was held in the finals of the 18th competition. After two years of exploration and practice, the simplicity and ease of use of MicroPython have been validated, and the 20th competition will continue to offer a dedicated MicroPython track in the relatively basic Speedy Optoelectronics subject group. MicroPython is a lightweight open-source Python interpreter that runs on microcontrollers. Using MicroPython, you can write clean and simple Python code to control hardware without needing to use complex low-level languages such as C or C++ for programming.
The simplicity of the Python programming language makes MicroPython an ideal choice for programming and hardware beginners. MicroPython is highly functional and supports most Python syntax, so even experienced Python veterans will find using MicroPython familiar and enjoyable.
Introducing a more concise and convenient Python as a programming means can lighten the programming burden for students, allowing them to focus more on innovation. Additionally, it is hoped to attract more students (including those from non-electronic majors, lower-grade students, and students from vocational schools) to participate in this foundational subject, enhancing the interdisciplinary application abilities of contemporary college students.
2. NXP-MicroPython Track Overview
As noted, the MicroPython track of the Speedy Optoelectronics group will not allow traditional C language programming for microcontrollers. To ensure fairness in the competition, this year’s event requires the use of specially priced core boards that have been pre-programmed with MicroPython firmware, and only Python language can be used to program the microcontroller for automatic tracking, completing the car’s construction. The basic task description is as follows:
(1) It is required to use balanced D and E car models to create a racing car. The car starts from within 1 meter in front of the starting line, automatically maintains upright balance while running around the track, and stops automatically within 1 meter behind the starting line after passing the starting line again. Only two tires are allowed to touch the ground during the process, and the car is not allowed to fall over and slide;
(2) It is allowed to add directional markers beside the track to prompt the car to slow down in advance or identify elements. The identification of markers can be completed using the OpenART and MCXVision vision modules based on NXP microcontrollers;
(3) There are no restrictions on the height of the camera;
(4) The track includes elements such as straight roads, curves, intersections, rings, slopes, and obstacles;
2.1. Hardware Platform
According to the rules mentioned above, the MicroPython track requires the use of a designated NXP controller-based MicroPython development board as the main control unit. This main control core board is based on the NXP RT1021 series microcontroller, which is defined as a cross-border MCU. In terms of computing performance, it has made a qualitative leap compared to traditional MCUs. The RT1021 has a maximum frequency of 500M, richer peripheral configurations, and has significantly increased memory capacity. Additionally, the core board is equipped with QFlash, which can fully meet the requirements for running MicroPython. The provided MicroPython firmware compatible with i.MX RT1021 supports the main functions required for making the car, such as GPIO, EXTI, ADC, PWM, Encoder, Ticker, UART, SPI, etc., meeting the basic needs for making a tracking car with MicroPython. In the future, a specially priced core board based on the RT1021DAG5X (with LQFP144 packaging and 144 pins) will be added to support the competition, which will have more peripheral resources (such as WIFI module support, more CCD interfaces, serial interfaces, etc.) to enrich the implementation methods for participating students.

▲ Figure 2.1 RT1021 MicroPython Core Board
2.2. MicroPython Firmware Overview
The designated RT1021 core board comes with pre-programmed firmware, and only the officially provided firmware is allowed; other firmware cannot be programmed. Technical checks will be conducted to ensure that C language programming is not used. During offline competitions, the hidden commands in the firmware will be read on-site through the REPL console, and if the correct response is not obtained, it will be deemed a violation. Alternatively, competitors may use the core boards provided on-site for the competition, where they will write Python code into the core boards provided on-site and then replace them in their cars for competition to prevent fairness issues caused by C language programming.
The firmware has encapsulated the calling interfaces for the main modules, including:
1. The machine class modules: Pin, ADC, UART, PWM;
2. The ADC_Group, encoder, ticker modules under the smartcar class provided by NXP, as well as the independent LCD module under the display class;
3. The seekfree class provided by Zhufei Technology, including the IMU660/963RA, MOTOR_CONTROLLER, BLDC_CONTROLLER, KEY_HANDLER, TSL1401, and WIRELESS_UART modules;
This year, the newly added MicroPython core board based on RT1021DAG5X (with LQFP144 packaging and 144 pins) will also provide more peripheral support:
1. The seekfree class will add support for the WIFI_SPI module for WIFI modules;
2. The TSL1401 module will increase the interface to support up to four interfaces, allowing for the connection of up to four CCD devices;
3. The motor driver and encoder interfaces will be doubled;
4. Additional servo/ESC interfaces will be added (a total of six interfaces, which can be used for servos or ESCs);
5. New UART and IIC interface pin support (new non-conflicting pin support).
Participating teams need to use Thonny software for debugging and development via virtual serial communication through a Type-C connection. The use of C language to write applications is not allowed, and the use of online debuggers such as DAP and J-Link for downloading and debugging is prohibited. Tracking, control, and other algorithms must be written by students using Python. Program writing and debugging can only be done using a Type-C data cable. Violating teams will have their results disqualified.
2.3. Compilation Environment and Related Learning Materials
The compilation environment uses Thonny software. Please refer to the provided material package for usage instructions. The material package includes the schematic of the RT1021 core board, instructions for using related sensors, and related documents, Thonny installation package, test routines, and MicroPython firmware interface documentation.
※ #: Link: https://pan.baidu.com/s/1l0fn_c0V8xbtoS6rHBpd2g
※ #: Extraction code: 33ei
3. Application for NXP-MicroPython Special Price Core Board
In order to better support students in participating, NXP has collaborated with Zhufei Technology to design and produce a special price MicroPython core board, entrusted to Zhufei for distribution. The special price core board must be applied for in advance, and the application requirements are as follows:
(1) The special price core board is produced and provided by NXP partner Zhufei, and is only for use in this competition in the NXP-MicroPython track using NXP microcontrollers. It cannot be used for commercial purposes or resold;
(2) The special purchase microcontroller models are:
-
RT1021DAF5X (LQFP100 package with 100 pins) MicroPython core board, -
RT1021DAG5X (LQFP144 package with 144 pins) MicroPython core board;
(3) Each school can apply to purchase a maximum of 10 special price core boards (you can decide the combination of models to apply for, e.g., 5 RT1021DAF5X and 5 RT1021DAG5X, that is, 5 of each 100-pin and 144-pin version);
(4) The application must be unified by the supervising teacher or team leader, and an application form stamped by the school must be submitted (please refer to the template at the end of the article);
(5) Special price: 125 yuan (including tax and shipping, applicable to both large and small core boards);
(6) The quantity of special price core boards is limited, and they are available on a first-come, first-served basis. The application deadline is June 30, 2025;
-
Application channel: http://seekfree.mikecrm.com/O2IKbpw

We encourage students to actively participate in the 20th National College Student Intelligent Car Competition Speedy Optoelectronics Group NXP-MicroPython track, and wish you all speed, style, and growth in the competition.