Search

Nxp Cup Project

About the project

The NXP Cup is a world wide competition where trio student teams build and program an autonomous model car to be raced on a track. The fastest one achieving one lap within its three attempts win the most points. There is also other tracks with various specificities, being part of optional extra disciplines.

Project info

Difficulty: Difficult

Platforms: DFRobotLinux

Estimated time: 5 months

License: GNU General Public License, version 3 or later (GPL3+)

Items used in this project

Hardware components

Pixy 2 CMUcam5 Image Sensor Pixy 2 CMUcam5 Image Sensor Line recognition camera, to demarcate the track x 1
PX4 Robotic Drone FMU (RDDRONE-FMUK66) PX4 Robotic Drone FMU (RDDRONE-FMUK66) Use to control our autonomous vehicles. This design runs PX4, the standard for industrial-grade drones, and gives freedom to develop our robotic vehicle. x 1
DFRobot ROB0165 DFRobot ROB0165 Car with brushless motors designed with spring suspension. Furthermore, the car features bumpers in the front and in the back to protect the car from damage. x 1
V-Charge Field 400 V-Charge Field 400 To charge the battery x 1
Gens ace Scale model battery pack (LiPo) 11.1 V 5000 mAh Gens ace Scale model battery pack (LiPo) 11.1 V 5000 mAh Used to supply power to the system x 1
3 A Switch- Mode UBEC 3 A Switch- Mode UBEC The following voltage amplifier is used to provide a 5.5 – 26 V variation because of the FMU which does not supply enough voltage to control the servomotor. x 1

Software apps and online services

QGroundControl QGroundControl
MCUXpresso MCUXpresso

Story

NXP Cup

ATHIAS Benoit, LINHARES Thomas, TANTI Luca

ft. MULLER Fabrice

1. Context

The NXP Cup is a world wide competition where trio student teams build and program an autonomous model car to be raced on a track. The fastest one achieving one lap within its three attempts win the most points. There is also other tracks with various specificities, being part of optional extra disciplines, rewarded with additional points : - The Figure 8 track, where students have sixty seconds to complete as many laps as possible within three attempts, without exiting the road. The team with the most laps completed wins.

  • The Figure 8 track, where students have sixty seconds to complete as many laps as possible within three attempts, without exiting the road. The team with the most laps completed wins.

  • Obstacle avoidance, which the car has to avoid an obstacle placed on the track. Nothing is allowed to touch the obstacle, and no wheel is allowed to get out of the track. Only one attempt is enabled and can last ninety seconds maximum.

  • Speed limit zone, according to a 4 stripes pattern on the track, the car's speed has to be reduced about half of its initial speed. After a 3 stripes pattern representing the end of the speed zone, its speed has to be resumed. No wheel is allowed to get out of the track, only one attempt is enabled and can last ninety seconds maximum.

  • Emergency braking, which the car must stop when an obstacle is place ahead. The car is not able neither to touch the obstacle nor to exit the track. Only one attempt is allowed.

The team with the most point according to the scoring system win the NXP Cup.

2. Schedule

        2.1. Gantt

                2.1.1. Initial

                2.1.2. Realized

        2.2. Work done in session

11th October : Understanding the project and rules to compete in the NXP CUP.We have thought about future orders to be made. We thought we would take the RDDRONE-FMUK66 card. Order of the car DFRobot ROB0165 Smart Robot Racing Car with Brushless Motors.

17th & 25th October : Handling and analysis of the existing project. We did tests on the car to see what to improve. We noticed that the car did not have an internal battery, so we ordered one and its charger. Moreover, it seems to have trouble to turn on the left. The wheels weren’t parallel, which makes the trajectory of the car imprecise when it picks up speed. On the other hand, to turn on the right the car negotiates the curves very well even at a high speed.

8th November : Reception of the card, configuration, and installation of the software for communicating with the card.

15th November : Download of the software to code on the board. Encountered problem : One command was missing in NXP datasheet: $ git clone https://github.com/PX4/Firmware.git We had to modify the line according to the following : $ cd ~/src/Firmware && make nxp_fmuk66-v3_default To $ cd ~/Firmware && make nxp_fmuk66-v3_default

22nd November : CMUcam5 received. Download of the software to code on the camera via the following website : https://nxp.gitbook.io/nxp-cup/developer-guide/development-tools/rddrone-fmuk66-development/setting-up-mcuxpresso We began installation and settings of MCUXpresso and the download of the SDK.

29nd November : 10.3.1 version that we installed is not the good one because the SDK generates an error. We had to take 10.3.0 version and SDK 2.5. We had an issue in the building project because the px4_sitl_default folder was not found. So we generated it that way : $ cd ~/Firmware && make px4_sitl_default

14th December : We received the cars and began to assemble them, cf 3.3 Assembly.

21st December : The first car had been assembled, the second one could not be assembled because of pieces which could not fit cf 3.4.Issues encountered.

18th January : We restarted to work on the project after a little break. We began to look for the datas acquired with the camera and control the trigger of the motors. 3 A Switch-Mode UBEC received and welded. It will powered the servomotor correctly, previously the FMU did it and did no supply enough voltage for controlling.

25th January : We can now control the trigger of the motors with the arming switch. We began to work on the control of their rotation speed.

7th February : We tried to control the motors according to the datas acquired with the camera, without success...

14th February : As previously, we got stuck on the advancement of the code. So we have done some tests with the Pixy 2 cam : if used without the FMU board and only with its specific software PixyMon we were able to have data from the camera and visualize images. Connecting it to our FMU Board made our program crashed again. We realized wires were wrongly connected once sold cf 3.4.Issues encountered. Therefore, we put camera’s wires in the right place to enable communication between the FMU and the camera.

21st February : We corrected the code so that now we can receive data from the camera and manage it to control the motors. We are able now to demarcate the straight lines of the track. Therefore on these parts of track the motors make the car drive at constant low speed.

6th Mars : We are able now to also demarcate the curved lines of the track. On these parts of track the motors make the car drive at constant low speed.

13th Mars : The speed adapts according to the track’s shape codded.

3. Components

        3.1. BOM

Here is what we ordered :

https://www.conrad.com/p/gens-ace-scale-model-battery-pack-lipo-111-v-5000-mah-no-of-cells-3-55-c-xt60-2145169

https://www.conrad.com/p/scale-model-multifunction-charger-12-v-24-v-16-a-voltcraft-v-charge-field-400-lead-acid-lifepo-lihv-li-ion-lipolyme-1873415

https://www.mouser.co.uk/ProductDetail/DFRobot/ROB0165?qs=%2Fha2pyFadujHzFjXu%252BABozkeOZ6pGqi7NBbWOAnFPno%3D

https://www.nxp.com/design/designs/px4-robotic-drone-fmu-rddrone-fmuk66:RDDRONE-FMUK66?&&tid=vanRDDRONE-FMUK66#buy

https://www.mouser.fr/ProductDetail/SparkFun/SEN-14678?qs=gTYE2QTfZfThcsWCHU6Kqw%3D%3D

https://www.banggood.com/Hobbywing-3A-UBEC-5V-6V-Switch-Mode-BEC-For-RC-Models-p-915037.html?cur_warehouse=CN

        3.2. Architecture

                3.2.1. General

The architecture is the following one :

Pixy 2 camera sends datas to the RDDRONE-FMUK66 card which is used to control the servomotors. These datas represent the shape of the track, either a curve one or a straight line.

                3.2.2. Pixy 2 CMUcam5

                3.2.3. PX4 Robotic Drone FMU RDDRONE-FMUK66

The RDDRONE-FMUK66 unit reference design is the following :

Simplified schema :

We have the following configuration :

        3.3. Assembly

Here are the main part of the car :

      

Actual shape, for the tests :

We will share some pictures of the assembly soon.

        3.4. Issues encountered 

                3.4.1. PIXY 2 CMUcam5

The cable between the camera and the FMU board was wrongly wired.

The green and the blue wire had to be exchange

                3.4.2. Power connection FMU – Servo

The FMU does not supply enough voltage to control the servomotor. Therefore, we had to use the following voltage amplifier, which provide a 5.5 – 26 V variation.

                3.4.3. Car assembly

During the step 13 the gear did not fit the motor axis.

As same as the following axles for step 16 which cannot fit in the hole of the car chassis and get stuck in it.

4. Results

Here is a video showing the advancement of the project :

 → watch here  ←

The project is in progress, we will share more advancement soon !

Schematics and circuit diagrams

Project report

Credits

Photo of Polytech_nice_sophia

Polytech_nice_sophia

Polytech nice sophia engineering school

   

Leave your feedback...