Design of vehicle navigation system based on embedded LINUX

Publisher:TechWhizKidLatest update time:2013-03-18 Source: dzscKeywords:LINUX Reading articles on mobile phones Scan QR code
Read articles on your mobile phone anytime, anywhere

1 Introduction

The continuous improvement of the technical level of vehicle-mounted electronic equipment has become one of the important signs of the development of modern automobiles, and vehicle-mounted navigation equipment is an important part of it. It should display the data communication system, audio and video entertainment system, positioning system, and electronic control system in real time, so that users can get sufficient driving information. The vehicle-mounted navigation system, which takes ARM and embedded operating system as the technical core and provides the vehicle driver with the necessary road conditions and geographic information for safe driving, is currently being used more and more widely around the world, greatly improving the user's driving experience and the safety of vehicle operation.

However, most of the in-vehicle navigation systems on the market currently use WinCE as the operating system. Not only is the software expensive to use, but it also has high hardware requirements and runs slowly. This paper proposes and designs an in-vehicle navigation system based on GPS and GPRS, using an embedded 32-bit processor and embedded Linux. The system uses S3C2440A: 32-bit ARM920T core processor, external expansion GPS receiver module and GPRS communication module, and the display part uses SAMSUNG 4.3-inch 480×272 resolution widescreen TFT true color LCD. The bottom layer uses an embedded Linux operating system, which has the advantages of open source, easy transplantation, modularization, and rich resources. The graphical user interface (GUI) is developed using Qt/Embedded software. This paper focuses on the reception and transmission of GPS and GPRS data, the overall architecture of embedded Linux, and the application of multi-threading technology in Qt.

2 System Overall Structure and Software Development Platform

The overall structure of the system is shown in Figure 1. This system uses SAMSUNG's S3C2440A embedded processor with a nominal operating frequency of 400MHz; the CPU has a built-in STN/CSTN/TFT LCD controller that supports various LCDs with a resolution of 1024ⅹ768 or less; Ethernet controller; 1-channel 5-wire serial port, 2-channel 3-wire serial port, CAN interface, SPI interface, RTC real-time clock, etc.; an external GPS receiver and GPRS module are connected via RS232; the system has an external 64NB SDRAM for operating system memory space, storing dynamic data and running programs; the system has an external 64MB Flash space for storing the Linux kernel, file system, application programs and user data.

  Figure 1 System structure

The system software is based on the embedded Linux operating system, and Qt/Embedded is selected as the graphical user interface (GUI) development environment. Qt is a cross-platform application framework launched by Trolltech. Qt/Embedded is the version of Qt for embedded applications. Write once and compile anywhere. Qt's unique signal/slot mechanism enhances the flexibility of communication between objects; the size of the library file can be adjusted by cutting out irrelevant modules, which is suitable for embedded systems; QT supports OpenGL interface and vector graphics format SVG. It can fully meet the drawing needs of the navigation system. The system obtains the vehicle position (including latitude and longitude and time, etc.) and operation information (including speed and direction, etc.) from the GPS in real time, and displays the relevant navigation information on the electronic map. Users can operate through the touch screen to provide map roaming, map query and road information management functions. [page]

3. GPS/GPRS system composition principle and structure

(1) Basic principles of GPS positioning

The positioning principle of GPS is essentially the spatial ranging positioning of surveying. It uses 24 satellites evenly distributed in 6 orbits at an average altitude of 20,200 km to transmit ranging signal codes and carriers. Users receive these signals through receivers to measure the distance from the satellite to the receiver. Through a series of equations, the ground positioning coordinates can be obtained. The distance from the satellite measured by the user is called "pseudo-range", which is not the real distance from the user to the satellite. It also includes the deviation of the satellite clock, the deviation signal of the user clock, the ranging error caused by propagation delay, etc. Therefore, after receiving at least three satellites, the plane coordinate (latitude and longitude) value can be calculated, and the equation value can be calculated after receiving four satellites. This is the basic positioning principle of GPS.


Figure 2 GPS positioning principle diagram

The meaning of each parameter in the program is as follows:

x, y, z are the spatial rectangular coordinates of the coordinates of the point to be measured. xi, yi, zi (i=1, 2, 3, 4) are the spatial rectangular coordinates of the four satellites at time t, which can be obtained from the satellite navigation message. Vti (i=1, 2, 3, 4) are the clock errors of the satellite clocks of the four satellites, provided by the satellite ephemeris. Vt0 is the clock error of the receiver. The above equations can be used to solve the coordinates x, y, z of the point to be measured and the clock error Vt0 of the receiver.

(2) GPRS network structure and transmission principle

GPRS adds two nodes to the original GSM network: SGSN (Serving GPRS Support Node) and GGSN (Gateway GPRS Support Node). The main function of SGSN is to record the current location information of the vehicle and complete the sending and receiving of mobile packet data between the vehicle and GGSN. GGSN mainly acts as a gateway, which can be connected to many different data networks. GGSN provides an interface between the GPRS network and the Internet, while SGSN is responsible for contacting the mobile terminal and GGSN. Therefore, a complete GPRS communication process is that the data sent by the vehicle terminal is first transmitted to the BSS (Base Station System), then transmitted to the GGSN via the GPRS network, accessed to the Internet through the GGSN, and transmitted to the host computer on the Internet by relying on the TCP protocol. The process of terminal receiving data is the opposite. GPRS data transmission and reception uses the TCP/IP protocol at the network layer.

4. Design and Implementation of System Software

(1) System software structure

It is mainly composed of the following modules: user interface display module, GPRS communication module, GPS positioning module, map matching module, path planning module, electronic map module, underlying communication module, etc.

  Figure 3 Overall block diagram of system software structure

User interface display module: a platform for users to interact with the vehicle navigation system, which plays a role in information exchange by calling other modules; GPRS communication module: transmits user driving information and vehicle condition information to the remote monitoring terminal in real time, which not only plays a role in recording vehicle conditions, but also can prevent theft; GPS positioning module: receives satellite positioning data in real time, including latitude and longitude, time, altitude, instant speed, etc.; map matching module: matches the data obtained from GPS positioning with the map information stored in the system to obtain geographic information around the vehicle and provide a reference for users; route planning module: the user enters the starting coordinates and the end coordinates, and the system automatically calculates the nearest road, thereby playing a role in vehicle navigation; bottom-level communication module: obtains various vehicle information through the CAN bus and 232 bus, and then displays it on the user display interface. [page]

(2) Linux porting on S3C2440

Embedded Linux manages the hardware devices of the entire navigation system and schedules all programs. It is the core of the software system. Since Linux is an operating system for PCs, it needs to be transplanted when used in the embedded field. It generally includes the transplantation of the boot loader code (Bootloader), kernel transplantation, driver writing, file system construction, etc. Compile the U-boot source code in the ADS environment, burn the successfully compiled binary code to the Flash of the development board, and then start it when powered on. The bootloader first completes the initialization of the hardware device, then sets the startup parameters of the Linux kernel, and finally calls the Liuux kernel to jump directly to the first instruction of the Linux kernel. From the Linux perspective, devices can be divided into three basic device types: character devices, block devices, or network devices. The device driver for the in-vehicle navigation system consists of the following three parts:

(1) Automatic configuration and initialization subroutine. The initialization subroutine runs first and is responsible for detecting whether the hardware device exists and whether it can run normally;

(2) Interrupt service subroutine. The embedded Liuux system receives the hardware interrupt and then calls the interrupt service subroutine through the system;

(3) A subroutine that serves I/O requests. It accesses I/O devices. It compiles the written device driver into the kernel and starts it together with the kernel when the system starts.

The file system forms the basis of all data on the Linux system. After comparison, the system design decided to use the Cramfs file system. When accessing files, the Cramfs file system automatically decompresses the files to be accessed into RAM, and will reserve RAM space for the actual executed application as much as possible, and can spare extra CPU cycles for runtime decompression. Use the mkcramfs command to generate a cramfs image file, and then download it to the system. When Linux starts, it automatically loads the root file system to complete the system startup.

(3) Application of multithreading technology in Qt

In a Qt application with a graphical user interface, the main thread is the GUI thread, which also has one or more non-GUI threads as worker threads to handle other time-consuming operations, such as constantly updated vehicle direction, speed, map matching, etc. In this way, the application can ensure the responsiveness of the graphical user interface even under heavy load. Relying on the multi-threading technology provided by Qt, multi-data interaction in the navigation system is possible. After calling the exec() function, the GUI thread either waits for an event or processes an event. Each thread can have its own event loop, as shown in Figure 4. The starting thread starts the event loop through QcoreApplication::exec(), and other non-GUI threads start their own event loops through Qthread::exec().

  Figure 4 Qt thread event model

5 Conclusion

The author's innovations:

(1) Using the embedded Liux operating system for the in-vehicle navigation system is a major improvement over the traditional vehicle navigation system, which greatly reduces the cost. At the same time, the multi-threading technology of the Linux system can solve the problem of parallel processing of multiple tasks in the system, ensure the stability and reliability of the system, and improve the system's operating speed.

(2) The display system uses Qt/Embeded software for user display interface design. It can be written once and compiled anywhere, making it easy to port to various platforms. It only needs to be recompiled. Using the open source version saves a lot of software licensing fees. These are unmatched by traditional WinCE programs.

(3) Currently, this system has been installed in the vehicle for trial operation. Practice has proved that this system can display the current operating status of the vehicle in real time, respond quickly to user operations, and provide the driver with good navigation information.

Keywords:LINUX Reference address:Design of vehicle navigation system based on embedded LINUX

Previous article:Design of vehicle-mounted supercapacitor test system based on single chip microcomputer
Next article:Application of MSP430 and GPS99808 module in automobile anti-theft system

Recommended ReadingLatest update time:2024-11-16 19:43

Research on Touch Screen Driver Based on TQ2440 and Linux
Abstract: Embedded technology is becoming more and more popular in industry and daily life. As an interactive terminal, touch screens have gradually replaced keyboards as input devices for embedded systems. Using the TQ2440 development board, through the study of touch screen drivers in the embedded Linux kernel, th
[Mobile phone portable]
Research on Touch Screen Driver Based on TQ2440 and Linux
Real experience of embedded Linux transplantation based on ARM (2) - BootLoader
BootLoader refers to a small program that runs after the system starts and before the operating system kernel runs. Through BootLoader, we can initialize hardware devices and establish a mapping of memory space, so as to bring the system's hardware and software environment to a suitable state, so as to prepare the corr
[Microcontroller]
How to implement flush_cache_all in Linux Kernel on ARM platform
In the design of the driver, we may use flush_cache_all to flush the contents of the ARM cache to the RAM, because the cache in ARM Linux is generally set to write back. Usually, DMA cannot access the cache, so if we need to start DMA to write the contents in RAM to Flash or LCD framebuffer, then we need to call flu
[Microcontroller]
Design and application of embedded Linux character device driver
  1 Introduction   With the development of embedded systems, embedded Linux has been widely used in the development of embedded systems due to its stability and open source advantages. More and more hardware and software manufacturers use embedded Linux to develop their own products, and the demand for drivers and a
[Microcontroller]
Design and application of embedded Linux character device driver
Porting standard Linux operating system to S3C2410
    1 Introduction     At present, embedded processors based on ARM core have become the mainstream in the embedded system market. With the widespread application of ARM technology, the establishment of embedded operating systems for ARM architecture has become a hot topic in current research. S3C2410 is a 16/32-bit e
[Microcontroller]
S3C6410 WATCHDOG TIMER (watchdog timer) driver under Linux (2)
In the previous article, we looked at the overall architecture of the watchdog driver implementation in Linux, which exists as a hybrid device and a platform device. Now let's look at the probe function corresponding to the platform device. static struct platform_driver s3c2410wdt_driver = { .probe = s3c2410wdt_prob
[Microcontroller]
S3C6410 WATCHDOG TIMER (watchdog timer) driver under Linux (2)
CRAMFS file system construction and configuration (Micro2440 + linux 2.6.39)
1. CRAMFS file system configuration         Cramfs is a read-only compressed file system developed by Linus Torvalds, the founder of Linux. It is also based on the MTD driver.         In the cramfs file system, each page (4KB) is compressed separately and can be accessed randomly. Its compression ratio is as high as
[Microcontroller]
OK6410A Development Board (VI) 3 OK6410A Linux-5.11 Compilation Analysis
Subscribe to our column Linux compilation requirements for host environment Documentation/process/changes.rst Compilation process 1. Miscellaneous   SYSHDR  arch/arm/include/generated/uapi/asm/unistd-common.h   sh './arch/arm/tools/syscallhdr.sh' 'arch/arm/tools/syscall.tbl' 'arch/arm/include/generated/uapi/asm/uni
[Microcontroller]
Latest Microcontroller Articles
  • Download from the Internet--ARM Getting Started Notes
    A brief introduction: From today on, the ARM notebook of the rookie is open, and it can be regarded as a place to store these notes. Why publish it? Maybe you are interested in it. In fact, the reason for these notes is ...
  • Learn ARM development(22)
    Turning off and on interrupts Interrupts are an efficient dialogue mechanism, but sometimes you don't want to interrupt the program while it is running. For example, when you are printing something, the program suddenly interrupts and another ...
  • Learn ARM development(21)
    First, declare the task pointer, because it will be used later. Task pointer volatile TASK_TCB* volatile g_pCurrentTask = NULL;volatile TASK_TCB* vol ...
  • Learn ARM development(20)
    With the previous Tick interrupt, the basic task switching conditions are ready. However, this "easterly" is also difficult to understand. Only through continuous practice can we understand it. ...
  • Learn ARM development(19)
    After many days of hard work, I finally got the interrupt working. But in order to allow RTOS to use timer interrupts, what kind of interrupts can be implemented in S3C44B0? There are two methods in S3C44B0. ...
  • Learn ARM development(14)
  • Learn ARM development(15)
  • Learn ARM development(16)
  • Learn ARM development(17)
Change More Related Popular Components

EEWorld
subscription
account

EEWorld
service
account

Automotive
development
circle

About Us Customer Service Contact Information Datasheet Sitemap LatestNews


Room 1530, 15th Floor, Building B, No.18 Zhongguancun Street, Haidian District, Beijing, Postal Code: 100190 China Telephone: 008610 8235 0740

Copyright © 2005-2024 EEWORLD.com.cn, Inc. All rights reserved 京ICP证060456号 京ICP备10001474号-1 电信业务审批[2006]字第258号函 京公网安备 11010802033920号