Design of Action Control MP3 Based on SEP4O2O Microprocessor

Abstract: This paper briefly analyzes the trends of today's social electronic products. It mainly describes the use of existing hardware and software resources such as SEP4020, MMA7620, MC9S08QG8a to design a control, pause, play, stop function through motion control. MP3. The problems encountered in the design process are presented and corresponding solutions are given, and suggestions on how to improve the performance of the MP3 are proposed in the future.
Keywords: SEP4020; action control: MP3

This article refers to the address: http://

0 Introduction Motion recognition is a hot topic. After launching the sensational multi-touch technology, Apple is preparing to apply for its own motion recognition patent. The recognition of motion is simply to use an acceleration sensor to detect changes in velocity in space and to extract motion through algorithms. Motion recognition has applications in many areas, such as Wii, mobile phone induction games, quad-propellers, etc., but it is rarely used or even used in MP3 control. A major trend in today's electronic products is the use of motion control. Imagine an MP3 without any touch or mechanical buttons. As long as you can perform all the most basic control operations, you can be both smart and stylish. This should be a brand new operation experience. This article will explore how to design such an MP3 that is controlled by actions.

1 hardware platform
1.1 SEP4020 Embedded Processor The driver described in this article is based on the SEP4020 embedded microprocessor. SEP4020 is a processor designed by Southeast University National ASIC System Engineering Technology Research Center. It adopts 0.18 μm standard CMOS process design and embedded ASIX CORE (32-bit RISC core, compatible with ARM720T, with 8kB instruction data cache). And full-featured MMU). The SEP4020 chip integrates various functions, including:
8/16-bit SRAM/NOR FALSH interface, 16-bit SDRAM interface Hardware NAND FLASH controller, support NAND FLASH self-start, support software/hardware ECC check 10M/100M adaptive Ethernet MAC, support RMII interface 64k Byte high speed on-chip SRAM
USBl. 1 Device, full speed 12Mb/s
Support I2S audio interface supports MMC/SD card LCD controller, support 640×480×16-bit TFT color screen and STN black and white, grayscale screen RTC, support calendar function/WatchDog, support backup power supply 10-channel TIMER, support capture, external clock drive And MATCHOUT
4-channel PWM with high speed GPIO support
4-channel UART, both support infrared 2-channel SSI, support SPI and Microwire protocol 2-channel SmartCard interface, compatible with IS07816 protocol supports up to 97 GPIOs, 14 external interrupts support linked list DMA transfer and external DMA transfer on-chip DPLL, support multiple power consumption Mode: IDLE, SLOW, NORMAL SLEEP
1.2 MC9S08QG8
The motion capture judgment part in this paper is controlled by the MC9S08QG8. The MC9S08QG8 is a single-chip microcomputer from Freescale. Its performance is as follows:
8-channel, 10-bit analog-to-digital converter 3 communication interfaces: SCI, SPI, IIC
4k or 8k reprogrammable FLASH memory Built-in in-circuit emulator (ICE)
1.3 MMA7620
The motion control action in MP3 is done by the MMA7620. The MMA7620 is a three-way accelerometer from Freescale. Its performance is as follows:
3-axis acceleration sensing and output, which can measure the values ​​of three axes (x, y, z) simultaneously and output by three channels. 4 kinds of sensitivity are available. Sleep mode

2 motion control MP3 design
2.1 Motion Capture There is always acceleration in the motion from the beginning to the end. Therefore, the motion can be determined by detecting the magnitude and direction of the acceleration caused by the motion. To measure the magnitude of the acceleration, an acceleration sensor is needed, and the obtained acceleration is expressed in the form of an analog quantity, and then the analog quantity obtained by the sensor is converted into a digital signal by an AD conversion module to facilitate subsequent calculation. However, the search found that if a single unilateral conversion of the voltage signal obtained from the acceleration sensor into a digital signal and requires the desired accuracy is achieved, the cost will be greatly improved. However, many existing single-chip microcomputers have been integrated. The AD conversion module, and the price of the entire microcontroller is lower than the single-chip single-channel AD conversion chip. What is more remarkable is that the digital signal obtained by AD conversion can also be processed by the processing function of the single chip microcomputer, and the action is predicted. Moreover, a large number of communication protocols are integrated in the single chip microcomputer, which is simple and robust. Based on the above considerations, if a single-chip microcomputer is used instead of the AD conversion module, the burden on the core board and the development difficulty of the entire project can be alleviated.
Accelerometers are available with Freescale's MMA7620 triaxial accelerometer. The MCU can choose to use Freescale's MC9S08QG8 MCU. Its integrated eight-channel 9bit AD conversion module matches the MMA7620's three-channel output and is small in size for portable devices.
Figure 1 is a schematic diagram of the handheld part, including the MCU and sensor PTA0, PTAl, PTA2: Input: respectively connected to the x, y, z port output of the three-way acceleration sensor, reading the analog data of the x, y, z axis of the acceleration sensor .


PTA3: Output; the Sleep pin of the three-way accelerometer is used to put the sensor in a sleep state to reduce power consumption and lock, and avoid interference during motion.
PTTB0: Input; as a serial port receive pin for receiving commands from the core board.
PTFBl: output; as the serial port send pin is used to send the action information obtained by the acceleration sensor to the core board after being processed by the single chip microcomputer.
PTB6, PTB7: Output; connect the gselect pin of the acceleration sensor to control the sensitivity of the acceleration sensor.
2.2 Action Judging Freescale's FreeMASTER software makes it easy to debug programs online and view all global variables. For specific software and usage, please check the Frees-cfle website. The data obtained below is obtained by plotting time and AD conversion values ​​using FreeMASTER.
Each time 20 data is sampled in each direction, since the reliability of the first data is relatively large, the first data of each set of data is used as a basis for comparison. After many tests, when the value in the x direction is less than 80, it is a right turn motion. When the value of the x direction is greater than 170, it is a left turn motion. When the value in the y direction is less than 70, it is an upward motion, and the value in the y direction is greater than 160. The time is the action of pressing down. Although the above data can represent the action, the difference between the human action time and the single-chip processing analysis speed is still too large. In order to solve this problem, the MCU and the action are synchronized, the first two actions can be recorded, and the current action is filtered according to the previous two actions: if several consecutive actions are consecutive, it is judged as one action, not the same. Switch. The switching of the action must have a change of the front and rear movements, and the action before the memory can determine whether there is an action switching. Such a motion recognition method is relatively simple and easy to implement, and if a more accurate recognition is to be achieved, the algorithm needs to be further optimized. Figure 2 shows the results obtained by the AD converter on the right shake. Figure 3 shows the data before and after the swing.


After the discriminating action, the action ID of the double-scheduled agreement is sent through the serial communication protocol, as shown in Table l


Through the serial port protocol, the core board can also perform certain control on the sensor and the single chip microcomputer, including the sensor sensitivity adjustment and the lock sleep function, which makes the later test development more convenient.
2.3 MP3 Control Linux operating system as a platform, its good system can be customized, portability makes it occupy an important position in the embedded field. Linux has many good process communication mechanisms, such as memory sharing, pipeline, multi-threading, signals, etc. Here, the signal is selected as a bridge for controlling communication. The complete serial port driver in Linux can easily transmit signals to the specified program through the soft interrupt receiving program of the serial port, that is, the player program, and then the player program receives and judges the signal type, and assigns the corresponding control global variable. With the corresponding control values, intervention control becomes possible. The control uses the mechanism that comes with the player, making it more stable and reliable. Using Madplay as the MP3 player software, the default control is implemented through the terminal keyboard. In order to achieve the control of the semaphore generated by the action to control the playback, while not modifying the program source code of Madplay, you can cut off the connection between the player and the keyboard, and connect to the serial port, so that you can basically do not modify the upper layer mechanism. Ability to control the movement of the entire player.
Specific system porting and required source code packages are available at www. Armfans. Net
2.4 MP3 Playback The MC9S08QG8 communicates with the SEP4020 through the serial port.
The basic serial port operation principle is to save the original parameters of the serial port first, and then set the parameters required by the program, and restore the scene after the program ends. The general operation of the serial port is as follows:
Header files required for serial port operation
Serial port soft interrupt setting, fill SIGIO structure, assign corresponding interrupt function:

Add an autoplay script to the operating system to enable the system to search for MP3 files, create playlists, and start Madplay players when booting. The script code is as follows:

When the action occurs, the MC9S08QG8 sends an action signal to the SEP4020, and then the Linux kernel in the SEP4020 sends a SIGIO (serial signal) to each user process. Madplay captures the signal and reads the message on the serial port to determine the form of the action. Two modules need to be added in the Madplay program. The first module is used to read the message on the serial port. The specific implementation method is to open and read the serial device file /dev/ttySl to get the message, and then read the four serial port signals from the device according to the settings, corresponding to 4 The ASCII characters "L, R, U, D" correspond to four different actions; the second module is the processing function of the response signal. Once the Linux kernel receives the SIGIO serial signal, the Madplay process enters the soft interrupt to read /dev/ Serial message on ttySl. When you determine the action, Madplay uses the kill function to send a corresponding signal to the process to control playback.

3 Summary This paper introduces the design flow of the action control MP3 for the SEP4020 processor and other hardware under the Linux operating system, and provides an example for the MP3 design of this control mode. The following are some suggestions for improvement: As a handheld device, the motion control MP3 has higher energy requirements, so it is necessary to consider using more low-power devices instead of high-power devices. The MP3 of motion control is limited in motion, and the judgment of MP3 is subject to relatively large interference. Therefore, if the motion sampling method and the motion judgment algorithm are difficult to be greatly improved, in order to facilitate continued use, it is necessary to consider adding other control methods to the MP3, temporarily replacing the motion control.

Insulated Piercing Connector Clamps are designed for use in 1 kV to 10 kV insulation cable systems. The Piercing Clamps material are made of weather and UV resistant glass fibre reinforcec polymer. The clip mechanical and electrical properties by the Piercing Connector Clamp are a result of high quality materials used to create it. Contact with the blade selects tin bronze alloy or a strong aluminum alloy, Insulation Piercing Clamp ensures the optimal transition of contact area. The waterproof material is made of high quality rubber ring and silica gel  of quality properties. 

Features

1. The connectors with specially designed contact teeth are suitable for the connetion of aluminum.
2. The teeth grooves of the clamp make the conductors connect the insulation cover functions as waterproof and sealing perfectly
3. At the breaking force of the conductor the connector will not be distorted and broken
4. At the rate current and short circuit rising temperature of the connector should be less than the connecting conductor  
piercing connector clamp
We warmly welcome friends both domestic and abroad to visit our company, if you have any questions, please contact with us directly. 

Piercing Connector Clamp

Piercing Clamps,Insulation Piercing Clamp,Insulated Piercing Connector Clamps,Piercing Connector Clamp

FUZHOU SINGREE IMP.& EXP.CO.,LTD. , http://www.cninsulators.com