Design and implementation of embedded system development platform

Publisher:Yuexin888Latest update time:2012-05-21 Source: 微计算机信息 Keywords:EVB2107 Reading articles on mobile phones Scan QR code
Read articles on your mobile phone anytime, anywhere

1 Introduction

Embedded systems are application-centric, computer-based, software and hardware-customizable special-purpose computer systems that meet the strict requirements of application systems for functions, reliability, cost, volume, and power consumption. In recent years, with the development of computer, microelectronics, communication, and network technologies, embedded systems have penetrated into various fields. Since embedded systems are usually built with microcontroller chips, microcontroller manufacturers usually only provide compilers and connectors for chips, but not complete development platforms; application developers often build their own application products based on microcontrollers, and usually do not provide complete, especially general, embedded system development platforms; development platforms provided by foreign third-party companies are generally single-function, simple in structure, and expensive. Domestic development platforms are generally just simple evaluation boards and debugging platforms, and usually cannot support high-end microcontrollers. Therefore, in order to meet the needs of developing various application systems, this paper proposes the design and implementation method of embedded system development platform.

In terms of hardware, the embedded system development platform is a hardware design and debugging platform built with various microcontrollers as the core and the union of common components of embedded systems as the basic elements. As a general development platform, the platform supports 1~2 representative microcontrollers in the 8-bit, 16-bit, and 32-bit microcontroller families as the core, and includes common components such as network communication, USB high-speed serial communication, memory system expansion, large-screen LCD/touch screen controller, etc. In terms of software, the embedded system development platform is based on an embedded microkernel real-time operating system, provides various software and hardware resource management programs, rich function libraries and debugging tools, and standardized application design routines for various functional modules, and constructs a basic debugging and development platform. When developing specific embedded system applications, you only need to appropriately tailor and assemble the software and hardware based on this platform to complete an actual embedded system.

2 EVB2107 Evaluation Board Resources and Development Environment

The EVB2107 evaluation board is based on the 32-bit microcontroller MMC2107, and expands the memory, OnCE interface, serial interface, power circuit and other modules to form a basic board-level system. Its logical structure is shown in Figure 1.

The EVB2107 evaluation board provides 1MB of SRAM and 2MB of FLASH memory, which greatly expands the memory capacity of the board. The programmable logic device CPLD is used to implement various control logic circuits in the board, which can control the LED indicator display on the evaluation board; the sampling jumper switch setting value realizes the system configuration; generates memory address and control signal, and realizes the 16-bit or 32-bit access of MMC2107 to the external memory on the evaluation board. The 3 peripheral port lead-out sockets are used to lead out the signals of SPI, serial communication interface, timer interface, external interrupt request signal, and analog signal for analog-to-digital conversion using the on-chip QADC. Users can choose a 20-wire double-row flat cable or other connecting wire to connect it to the expansion board. The user expansion area (i.e., breadboard) is provided for users to add their own devices. 2 RS232 serial communication interfaces and OnCE interface are used for debugging; the 12V DC input power is converted into various working power supplies (such as 5V, 3.3V) in the board, which can power each module on the expansion board.

The EVB2107 evaluation board is connected to the host through EBDI (Embedded Background Debug Interface). The host uses the CodeWarrior IDE integrated development environment provided by Metrowerks and SysDS (M·CORE System Development Software) provided by Motorola to form a software debugging environment. EBDI is the hardware interface between the EVB2107 evaluation board and CodeWarrior IDE. The OnCE interface on the EVB2107 evaluation board is connected to EBDI, and EBDI is connected to the serial interface of the host through a serial line. When debugging, CodeWarrior uses the EBDI connection path to download the program to the EVB2107 evaluation board, and then the Debug function in CodeWarrior IDE can be used to debug the code.

3 USB interface module

The development is connected to external devices through the USB interface. The USB system consists of a host, a hub, and a device. They are connected through the USB bus to form a star topology. In a USB system, there must be one and only one host. The host uses the USB host controller to manipulate the data transmission between the host and the USB device. The host controller is hung under the system bus (PCI bus) like other I/O devices. The hub attached to the host controller is the root hub of the USB system. Each level of the hub provides several downstream ports for connecting other devices. USB devices are logically divided into several levels, namely devices, configurations, interfaces, and endpoints. The structure is shown in Figure 2.

Each USB device has one or more logical connection points, called endpoints. An endpoint is a buffer that stores multiple bytes and is used as a data buffer. The device exchanges data with the host through the endpoint. Each device endpoint consists of an endpoint number and a data direction. The number ranges from 00h to 0Fh. If the direction is input (IN), it means it flows to the host. If it is output (OUT), it means it flows out of the host. Endpoint 0 is used to transmit configuration and control information and can transmit data in both directions. Other endpoints are unidirectional data channels, that is, receiving endpoints or sending endpoints. USB provides four data transmission modes: control; isochronous; interrupt; bulk. In addition to endpoint 0, which is fixed to use control transmission, other endpoints can be configured as the other three transmission modes according to the characteristics of the actual data transmission.

The combination of a group of endpoints of the same nature is called an interface. If a device contains more than one interface, it is called a composite device. For most devices, one interface is enough, but some devices can have multiple interfaces in effect at the same time, and multiple interfaces can be enabled at the same time. Similarly, the combination of interfaces of the same type is called a configuration. Each configuration must support at least one interface. Most devices have only one configuration, but some devices can support multiple configurations, but only one configuration is enabled at the same time. Once the configuration is activated, the interfaces and endpoints in it can be used. A descriptor is a data structure that is formatted information for the host to understand the device. When the host detects the device, it requires the device to return a descriptor in order to understand the device and configure the device. The host first requires the device descriptor of the device, then the configuration descriptor and the interface descriptor of each configuration, and finally the endpoint descriptor, and there may be an optional string descriptor.

4 Human-computer interaction module

In order to provide users with a good human-computer interaction interface, a human-computer interaction module consisting of a liquid crystal display module and a touch screen control module is designed on this development platform, as shown in Figure 3. The liquid crystal display module consists of three parts: LCD (liquid crystal display) screen, LCD controller and display buffer memory. The LCD screen uses the MG320240 black and white LCD screen of Truly, which is covered with a four-wire resistive touch screen. The LCD controller uses the S1D13305 chip of EPSON, and the display buffer memory is composed of two 62L256 chips, totaling 64KB; the touch screen controller in the touch screen control module uses the ADS7846 of BB, and the ADS7846 and MMC2107 are connected through a standard SPI port. [page]

4.1 LCD Module

S1D13305 supports text (i.e. character) display, graphic display, and display mode combining text and graphics; LCD display resolution can reach 640×256 pixels; LCD drive duty cycle varies from 1/2 to 1/256; the internal mask has a character generator ROM with 160 characters and 5×7 pixel dot matrix; supports setting up a character generator ROM or RAM with 256 characters and a maximum of 8×16 pixel dot matrix outside the chip; the off-chip display RAM (also known as display buffer) can reach 64KB; the cursor position and shape can be programmable; the entire display screen or part of the display screen can scroll smoothly in the horizontal or vertical direction; can interface with 6800 series and 8080 series microcontrollers; wide operating voltage range (2.7~5.5V); low power consumption, the operating current is 3.5mA when VDD=3.5V, and the backup current is 0.05μA.

S1D13305 has three interfaces: microcontroller, display memory (including external character generator) and LCD module. It accepts and executes commands from the microcontroller to complete various display control functions, a total of 13 commands. It receives display data (character code or bit-mapped graphic data) from the microcontroller and generates a signal to write access to the memory, writes the display data to the display memory, then reads the display data and converts it into display pixels and generates various timing signals for the LCD, and sends the display pixel data to the LCD for display. The microcontroller only needs to send commands to the S1D13305 and send display data to the S1D13305 when updating the display content. The work of reading/writing the display memory and controlling the LCD scanning display is all completed by the S1D13305.

The design scheme of the hardware interface between MMC2107 and LCD is shown in Figure 3. S1D13305 can interface with two types of microprocessors, 8080 or 6800. Here, according to the interface requirements of MMC2107, the former is selected. During the design, the data line of S1D13305 is connected to the data line D[31:24] of MMC2107, the address A0 of S1D13305 is connected to the address line ADDR1 of MMC2107, and chip select 3 (CS3#) is used as the chip select signal of S1D13305. In the program, the command port address and data port address are defined as follows:

#define lcd_command (*(INT8U*)(0x81800002)) // Command port

#define lcd_data (*(INT8U*)(0x81800000)) // data port

4.2 Touch screen module

In addition to the basic X and Y coordinate measurement functions, the ADS7846 can also measure the system power supply battery voltage, chip temperature, touch pressure and external analog quantity. The core of the ADS7846 is a 12-bit successive approximation A/D converter. The internal 6-to-1 analog multiplexer sends one of X+, Y+, Y-, VBAT (battery voltage), TEMP (temperature) and AUXIN (external analog quantity) to the A/D converter according to the control word sent by the microcontroller. The ADS7846 can provide an internal reference voltage of 2.5V for A/D conversion, and also supports inputting an external reference voltage from the VREF pin.

ADS7846 is connected to the microcontroller via a standard SPI interface. It takes three SPI transmissions to complete one communication with the microcontroller. For example, for coordinate measurement, the microcontroller first transmits a coordinate reading command in the control word format. ADS7846 receives the command and measures and converts the corresponding coordinates. Then the microcontroller starts two SPI reads to obtain the coordinate values. The first read gets the first 7 bits of data, and the second reads the last 5 bits of data. ADS7846 is also equipped with a touch recognition circuit. When a touch is detected, the circuit outputs a low-level signal called PENIRQ# (pen interrupt). The microcontroller can use this signal as the interrupt request signal of ADS7846. When there is no touch, PENIRQ# is output high by the external pull-up resistor. After the pen interrupt becomes low, MMC2107 detects this signal and issues a start conversion command. During the conversion, MMC2107 must maintain the pen interrupt low.

5 Summary of innovations

The innovation of this paper is to organically combine various microcontrollers with embedded microkernel real-time operating systems to develop an embedded development platform, which can greatly shorten the development cycle of application systems, reduce system development cost investment, and reduce system development risks. At the same time, it can meet the requirements of application system functions, reliability, cost, volume, etc., and has very broad application prospects in the future mobile computer platforms, information appliances, wireless communication equipment, and industrial/commercial control.

References:

1  萧世文编著.  USB2.0硬件设计. 北京:清华大学出版社,2002

2 Wang Tianmiao, ed. Embedded System Design and Case Development. Beijing: Tsinghua University Press, 2002

3 邵贝贝,刘慧银编著.  微控制器原理与开发技术. 北京:清华大学出版社,1997

4 Mo Chuanmeng, Feng Xiaoyun, Dual CAN Communication Component Based on Embedded System μC/OS-II, Beijing, Microcomputer Computing Information, 2004.No.3

Keywords:EVB2107 Reference address:Design and implementation of embedded system development platform

Previous article:Research and Implementation of Hard Real-time Performance of Embedded Linux Based on RTAI
Next article:MapInfo format map display based on embedded Linux

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号