Politecnico di Torino (logo)

Optimization of SPI protocol in precision farming environment

Abdelazim Mansour Abdelazim Mansour

Optimization of SPI protocol in precision farming environment.

Rel. Massimo Violante. Politecnico di Torino, Corso di laurea magistrale in Ingegneria Elettronica (Electronic Engineering), 2020

PDF (Tesi_di_laurea) - Tesi
Licenza: Creative Commons Attribution Non-commercial No Derivatives.

Download (2MB) | Preview

Embedded System Programming for linux application The automotive industry is one of the most important industry, so the improvement of the automobile vehicle is very crucial to decrease the cost and increase the features and efficiency. This became so achievable by the technological evolution happened in the last in electronics field in the last decade by increasing the electronics component and decrasing the mechanical part everything became feasible. So, to achieve this improvement and this added feature in the car we should add a lot of ECU to control every feature added inside the car. To utilize this usage of the evolution we should have a good communication network between all the ECU and the module inside the vehicle. With a high-speed baud rate to cover all the data handling inside the network. The topic work done in the project only focus on achieving high performance on the communication buses and how the data packed and handled inside the microprocessors. Also study and analyze the path of the data in the low-level layer “Driver level” and how is it handled inside the communication layer system architecture starting from the CAN driver passing by the PDU Router to the SPI Driver using the DMA feature till it received by the microprocessor and handled by the PDU Router in the other part then delivered to the CAN Interface Net device reaching one of the APIs. Basically, the technique used to improve the communication over the bus by utilize the header added to packets over every stage of processing the data and handling it.The optimization done in two level or two stages of data processing. First stage done in the SPI driver level after data received from PDU Router and before delivered to the DMA. The Checksum has been changed by the CRC to improve the detection techniques. Also, the packet length has decreased from 384 bytes to 64 bytes so now the data delivered from the one microprocessor to the other has less size and sent in a less time also handled fast. Moreover the technique use in the SPI driver is the same technique used in ISOTP protocol “ISO 15765-2” so we have Synchronize frame in the beginning of the communication then depending on the data available to be sent over we will send them in the single frame packet or if it’s size is bigger than the single frame will be sent as First frame and consecutive frame in all situations the CRC bytes is sent with the packet so it is ready to processed in the after the CRC checked. Second stage is done in the PDU Router after data received from the CAN bus and the I2C Bus and before being delivered to the SPI driver. Every type of the information was handled by adding different types of the data, some important and some could be removed. So, the optimization has been done by utilizing the different types structure of the added header to the data. To sum everything up, the added header to the data has been decreased to contain only super important information and the maximum size has been decreased from 16 bytes to 12 bytes. Also, the SPI packet has been decreased from 384 bytes to be 64 bytes so it cloud be sent fast also to utilize the 12 bytes length of the data packet. The other four the packets are for the CRC and byte number.

Relators: Massimo Violante
Academic year: 2019/20
Publication type: Electronic
Number of Pages: 55
Corso di laurea: Corso di laurea magistrale in Ingegneria Elettronica (Electronic Engineering)
Classe di laurea: New organization > Master science > LM-29 - ELECTRONIC ENGINEERING
Aziende collaboratrici: Abinsula Srl
URI: http://webthesis.biblio.polito.it/id/eprint/14560
Modify record (reserved for operators) Modify record (reserved for operators)