Electric shaver system design based on MSP430x09x MCU

Publisher:恬淡如云Latest update time:2013-08-06 Source: dzscKeywords:MSP430x09x  MCU Reading articles on mobile phones Scan QR code
Read articles on your mobile phone anytime, anywhere

  1 Introduction to MSP430x09x

  MSP430x09x is the first 0.9V operating voltage MCU in the MSP430 series. This series is powerful and can be easily applied to micro motor control, infrared transmission, power supply detection and other occasions. In addition, its 0.9V operating characteristics can be widely used in single-battery powered consumer electronics. MSP430x09x contains a variety of functional modules (see Figure 1). This series of solutions not only highly integrates 16-bit timers, watchdog timers, 11 I/Os with interrupt functions and zero-power low-voltage reset function (BOR), but also integrates new analog function pool peripherals that can be configured as ADC, DAC, comparator, system voltage monitor (SVS) and temperature sensor, all with an operating voltage of only 0.9V. The 16-bit RISC architecture CPU and its instruction set are compatible with existing MSP430 MCU devices, with an operating frequency of up to 4MHz and a power consumption of only 45μA/MHz in working mode. The MSP430x09x series supports three 0.9V MCU versions with up to 2kB RAM and 2kB ROM - MSP430L092 (RAM), MSP430C091 (ROM) and MSP430C092 (ROM), providing a variety of options according to needs. This is done because the 0.9V working characteristics cannot erase the FLASH, so its application mode is to use EEPROM and L092 to complete the system design in the research and development stage, and use C09x with ROM after productization, which can operate normally without EEPROM.

MSP430x09x includes rich functional modules

  2. A-Pool

  The analog function pool developed and designed by MSP430x09x is to realize various analog function modules under 0.9V. The specific implementation of a certain function is based on the user's software design. The reference voltage of the entire analog function pool module can be provided by an internal 256mV reference voltage or an external reference voltage. Multiple clock sources can be selected as its clock source. In general, the analog function pool can realize the following functions:

  Comparator

  ●8-bit digital-to-analog converter (DAC)

  ●System voltage monitor

  Internal temperature sensor

  ●Ultra-low reference voltage source

  The analog function pool looks complicated, but its core is actually a comparator and two multiplexers. The multiplexer is used to select the input signal of the positive and negative input terminals of the comparator to achieve different functions. In addition, the operation of the ADC and DAC modules can achieve more flexible and intelligent analog acquisition conversion functions through a variety of triggering methods. The programmable A-Pool enables various analog peripheral configurations to run in an orderly manner without user intervention, thereby improving system flexibility. A-Pool also provides two AD sampling modes-RAMP and SAR mode. When using RAMP mode, it can work in no compensation mode, overload compensation mode, offset compensation mode, full compensation mode and window mode, etc. Of course, the higher the accuracy, the longer the required sampling cycle. Therefore, it is necessary to arrange the working mode reasonably according to the sampling accuracy and sampling time. In addition, when the analog sampling voltage is greater than the reference voltage, the appropriate voltage sampling range can be set by software to complete the AD sampling of higher voltage, thereby eliminating the external voltage divider resistor and greatly facilitating the user. As a powerful analog function module, the analog function pool can realize rich analog functions. In order to make it work better and avoid misoperation, please refer to the instructions in its user manual.

  3 System structure diagram and overall design scheme

  The block diagram of the electric shaver system in this article is shown below. In this solution, the electric shaver uses MSP430L092 as the MCU. Its ultra-low power consumption feature allows the shaver to be used longer. The operating voltage of all functions on the MSP430x09x chip is 0.9V, so when the system is powered by a single battery, no boost chip is required to make the system work normally. In this way, the same function is achieved, not only saving a battery, but also saving the cost of the boost circuit, and making the entire system structure very simple. The entire system is powered by a single battery to power the MCU and the 0.9V DC motor. The self-locking circuit is used to realize the power-on, speed selection, and shutdown functions with a single button. The DC motor drive is realized by using a 0.9V MOSFET (because the rated current of a single 0.9V MOSFET is small, two MOSFETs are connected in parallel, and the voltage drop on the MOSFET is reduced at the same time), and the PWM wave is used to control the on and off of the MOSFET to achieve motor speed regulation. Since the MSP430x09x series MCU has a powerful analog function pool, it can easily monitor the system power supply voltage. When the voltage is lower than a certain level, the system is prevented from continuing to work, so as to prevent permanent damage to the rechargeable battery due to excessive use. In addition, when charging, the battery voltage can be sampled through AD. When the battery is fully charged, the charging circuit can be controlled by PWM to enter the trickle charging mode to achieve charging management. Users can use the comparator, AD, DA, internal temperature sensor and other functions of the analog function pool in MSP430x09x to develop more advanced and functional products. In view of the use of MSP430L092 in the product development stage, which only has RAM, an external EEPROM is required for user programs. Since the working voltage of EEPROM is 2.5~5.5V, a simple boost circuit is required with independent components to load the running program from EEPROM during the initialization phase of L092. In the final product, C092 or C091 is used, and the external EEPROM part can be omitted.

Electric shaver system block diagram

Figure 2: Electric shaver system block diagram

  4 System Hardware Design

  4.1 MCU Pin Assignment

MCU Pin Assignment

Figure 3: MCU pinout

  The pinout of this system is shown in the figure above. It can be seen that the pins of the MSP430x09x series are multiplexed, allowing users to reasonably allocate corresponding functions, making the design simple and flexible. This system uses general I/O, SPI, TA0, TA1, A-Pool, BOOST and other functions. [page]

    4.2 External storage part

External EEPROM storage module

Figure 4: External EEPROM storage module

  The above figure shows the EEPROM module and the BOOST boost circuit composed of discrete components. The working principle will not be described here. During the boot phase, the MSP430L092 needs to communicate with the EEPROM through SPI to load the program into the RAM. During this period, the boost circuit is controlled by the P1.2 pin to output a 3V voltage for the EEPROM to work. This part of the code does not need to be written by the user and has been solidified in the IDE.

  4.3 Charging Circuit Control Module

Charging control circuit

Figure 5: Charging control circuit

  The above figure shows the system charging control module. When the system is powered on externally, the system enters the charging mode, the MCU is powered and running, CHARGE_IN is at a low level, and the MCU enters the charging mode. The battery voltage is sampled by AD, and after judging whether it is fully charged, the charging circuit is switched to the trickle charging mode to prevent the battery from overcharging. At the same time, the battery voltage is detected, and when the battery is lower than 1.45V, it is switched to the charging mode again. The ADC module of the analog function pool unique to the MSP430x09x series supports two AD sampling modes, RAMP and SAR. In RAMP mode, the AD module can also be set in different error compensation modes to improve sampling accuracy.

  4.4 Button self-locking part

System self-locking circuit

Figure 6: System self-locking circuit

  The figure above shows the system button self-locking circuit. When the button is pressed, the MCU is powered on and runs, and it judges to enter the working mode. It is self-locking when it is turned on. The system can still operate normally when the button is released; press the button again to switch the working mode; press the button again, the system is unlocked and shuts down. In addition, the MCU regularly detects the battery voltage through A-Pool. When the battery voltage is lower than 1V, the working circuit is cut off to prevent permanent damage to the battery during undervoltage operation and affect the battery life. The MCU also detects the system temperature by configuring A-Pool. If it exceeds the normal working range, the circuit is cut off.

  4.5 Circuit driving part

DC motor drive circuit

Figure 7: DC motor drive circuit

  The DC motor module of the system is shown in Figure 7. As a single-battery system, in order to ensure that the system can work normally under low battery voltage, the system selects a DC motor and MOSFET with an operating voltage of 0.9V, making the entire system more energy-efficient and running longer. Since some low-voltage MOSFETs have a small rated current, a single one cannot meet the performance requirements of the DC motor, so sometimes two MOSFETs need to be connected in parallel to increase the working current while reducing the voltage drop on the MOSFET. In this design, MOSFETs are selected from ROHM's RYU002N05 (2 in parallel) and VISHAY's Si2342DS (single), both of which can make the system work normally.

  5 System Software Design

  The software part of this system mainly needs to realize the main program main loop, initialization, external storage communication, battery charging control, button processing, LED indication, DC motor drive control, voltage sampling, temperature sampling, sleep wake-up function, etc. The system is powered on and started in two ways: system charging and button startup. After power is on, L092 loads the program from EEPROM, starts normal operation, and determines the working mode. When the system is charging, the system works to regularly detect the battery charging voltage. According to the battery characteristics, after the battery is fully charged, it enters the trickle charging mode to prevent the battery from overcharging and causing damage to the battery. When the battery voltage is lower than 1.45V, it enters the charging mode again. In normal use, the button startup enters the normal working mode, the system is self-locked to ensure normal operation when the button is released, the system outputs PWM to control the motor operation, and changes the working mode by pressing the button. Continue to press the button to release the self-locking and shut down the system. In addition, when the system is working normally, the battery voltage is regularly detected by the ADC module. When it is lower than a certain voltage, the system is prohibited from continuing to work to prevent permanent damage to the rechargeable battery during undervoltage. At the same time, the MCU needs to record the battery voltage values ​​before and after. Because the battery voltage will jump greatly when the motor is blocked, the battery voltage value is recorded and this feature is used to determine whether the motor is blocked. If it is blocked, the system will be shut down immediately. After the ADC samples the battery voltage, the A-Pool is configured to sample the system temperature to determine whether the operating temperature is within the normal range. If it is not normal, the system will be shut down immediately. The entire system sets the system working status value through the input port and each interrupt handler, and opens the corresponding functional module according to different status values ​​in the program loop.

Keywords:MSP430x09x  MCU Reference address:Electric shaver system design based on MSP430x09x MCU

Previous article:A Design Scheme for Wireless Voice Transmission System
Next article:WIFI intelligent thermostat design

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

Constructing a real-time operating system for 51 single-chip microcomputer
Abstract : Starting from the memory space management method of Keil C51, this paper focuses on the reentry problem of the real-time operating system during task scheduling, and analyzes some basic ways and methods to solve reentry: analyzing the preemptiveness of task scheduling in the real-time operating syst
[Microcontroller]
Constructing a real-time operating system for 51 single-chip microcomputer
Application of ColdFire MCU on Clinux
Introduction to ColdFire Series Processors Freescale's 32-bit processors are divided into PowerPC series, ColdFire series and DragonBall series. ColdFire series is one of the important components, which can be applied to industrial control, instrumentation, civil products, network products and other fields. ColdFire
[Microcontroller]
51 MCU: Light up an LED and make it flash (simulation + code)
Lighting up an LED is the simplest introductory experiment for microcontrollers. It can give you a preliminary understanding of the functions of microcontrollers. (Because it is simple, I will only show it to you on the simulation software) Let me show you the circuit of the simulation software (the software is Prot
[Microcontroller]
51 MCU: Light up an LED and make it flash (simulation + code)
High-precision position control of linear switched reluctance motor based on AVR microcontroller
1. Project Overview 1.1 Introduction The motor is an indispensable power equipment for industrial production. There are many types of motors and their functions are quite extensive. The linear switched reluctance motor is a new type of traction motor. It has the following main advantages: simple structure and low
[Power Management]
High-precision position control of linear switched reluctance motor based on AVR microcontroller
How to design a multimedia terminal remote control using a PIC microcontroller?
1 Design Concept and Principle 1.1 Design Concept With the rapid development of technology in the field of digital home, there will be more and more value-added services on multimedia terminals. Browsing web pages, searching, and sending text messages all require input via remote control. However, as an important peri
[Microcontroller]
How to design a multimedia terminal remote control using a PIC microcontroller?
A design of energy-saving power-off protection circuit based on single-chip microcomputer
Electricity brings economic benefits to human beings and is convenient and environmentally friendly, but we should save electricity, pay attention to safety, and prevent fires. Energy saving is a major issue to reduce costs and improve economic benefits. Paying attention to safety when using electricity and preventing
[Microcontroller]
A design of energy-saving power-off protection circuit based on single-chip microcomputer
Bus stop voice announcement system based on SLH89F5162 single chip microcomputer
1. Project design background and overview With the progress of urbanization and the rapid development of the economy, the situation of "difficulty in taking buses" and "difficulty in driving" in cities is getting worse. Many cities recommend people to take the bus when going out. However, in bad weather or poor visibi
[Power Management]
Bus stop voice announcement system based on SLH89F5162 single chip microcomputer
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号