World's lowest power Bluetooth single chip DA14580 hardware architecture and low power consumption

Source: Internet
Author: User

Known as the world's lowest power Bluetooth single chip DA14580 in the wearable market, health care, ibeacon positioning and other markets have been widely used, but because of its more closed technology/data support led to a high level of technical barriers developers, the network also rarely see the development of DA14580 technology sharing, Therefore, the general enterprise and the general technical team are not daring to adopt the platform, but once proficient in the development of the chip platform, can be used in the development of Bluetooth solutions to obtain greater technical advantages.

The author has a deep accumulation in the field of integrated circuits, and has rich development experience in the DA14580 platform, and then analyzes the hardware architecture and software system of DA14580 with a series of articles. If you need technical advice, please email [email protected] contact.

This paper analyzes the hardware architecture and sleep and wake Technology of DA14580. Sleep and wake are the core technologies for low power consumption. The principle of sleep and wake is analyzed from a hardware perspective. The software framework and practice of sleep and wake-up are further expanded.

First, DA14580 hardware architecture

DA14580 hardware architecture such as:

Visible, the DA14580 consists of three parts:

1) use Arm Company's Cortex M0 as the Cpuprocessor processor.

2) Use Rivierawaves Company's IP core as the Blecore and baseband, RF part.

3) Integrated clock management CMU, power management PMU, memory control storage and other peripheral module controllers such as Gpio, UART, I²c, SPI and timer, etc.

Generally, when used in Bluetooth BLE applications, the DA14580 uses two external crystals, where the 16M oscillator is used for CPU-related modules (such as M0 and memory) and is also divided into partial peripheral. The 32K oscillator is used for the BLE precision reference clock and low-power part of the circuit during sleep.

Second, DA14580 low power (sleep and wake up)

The low power consumption of Bluetooth single chip mainly refers to the whole hardware system sleep and wake. The low power consumption is mainly for power and clock management. This is determined by the characteristics of the integrated circuit.

1. Sleep

For sleep, from the above architecture, it includes the following sections:

1) CPU sleep, that is, cortex M0. Based on the architecture of the cortex M0, it includes two sleep modes: normal sleep and deep sleep, which map to M0 registers and different hardware circuits. It is important to note that the CPU does not differ greatly in the two modes, but each SOC vendor will have different control over the peripheral part when integrating cortex M0. For example, DA14580 will subdivide two modes on the deepsleep of M0, namely extended sleep and deepsleep. The former RAM data can be kept, while the latter is not maintained.

2) BLE core stack, baseband and RF RF part sleep. For the low power consumption of M0, there are many guidance documents, but the rivierawaves of the BLE part of the information is very small, the program may not have, only the development of DA14580 Dialog company, developers only from the DA14580 SDK to understand the source code, The experience of low power control is obtained through continuous debugging and verification. This is why many companies choose Ti instead of da as a Bluetooth application. But DA14580 's power consumption is indeed the strongest in the industry, if it can be mastered in the internet of things industry will have a very technical advantage.

3) Peripheral part of sleep, this section includes other integration modules such as memory and UART, GPIO, TIMER, SPI, interrupt control, and so on. Dialog company in DA14580 Spec specification book also does not have the public system design frame diagram, only partial registers the description, therefore wants to be proficient in the DA14580 peripheral low power control method and the debugging, also takes a lot of time. Also, the debugging of sleep and wake is relatively difficult and requires mastering methods.

4) For each of the above parts, we are to consider clock and power, for advanced CPU may have dynamic FM voltage regulation, but for Bluetooth single chip, basically is disable power supply and clock.

For Cortex M0, the circuit that corresponds to the WFI instruction uses a technique called State Retention power gating to control the power supply, and the Cotext M0 controller module that combines wakeup interrupt can wake the CPU. For clocks, it is the Disable 16M high frequency crystal oscillator.

For BLE, you need to actively disable its clock [16M or 8M] and power. The BLE clock source is 32KHz, where the turn-off refers to the clock portion of the BLE, rather than completely disable the 32K external crystal oscillator. Because it also needs to provide a clock for the wake-up part.

For the peripheral part, it turns off the power supply and clock, because it mainly uses 16M Crystal Frequency division, so when the 16M crystal stops working, it naturally also no clock.

2. Wake up

For DA14580 wake-up, there are two main wake-up sources. One is the synchronous wake-up source, the internal timer from the BLE (default 10 seconds) and the Ble event, and the other is the asynchronous wake-up source, the wake-up interrupt, which can be configured to wake on any pin, which uses the WIC technology specified by Cortex M0.

WIC (Wakeup Interruptcontroller) is independent of the CPU and interrupt control work, but the WIC detects a level change (can also count to a specified value) will remind the PMU to power the CPU, and start the internal RC oscillator circuit to provide the clock, and maintain the interrupt signal to the CPU interrupt section so that the CPU can wake from sleep.

So, what do you need to pay attention to when it comes to DA14580 's awakening?

1) BLE wake-up timer setting

2) External wake-up settings for DA14580

The DA14580 supports Wakuptimer to wake up to monitor the level change count of any pin, which can be either rising edge or falling edge. It accesses the CPU via WIC.

Three, low-power code framework

The above knowledge just shows how to do a good job of sleep and wake up, when the CPU executes WFI instruction, that is, go to sleep state. So, when should the sleep and wake settings be executed? What to do with the message/event, BLE Timer event that is generated after wake-up interrupt? What do I do first when I return to the user state after a CPU wake-up interrupt? These should be factors to consider for low-power code frameworks.

The DA14580 software system determines that the message/event is based on the BLE timer reference clock, such as the core timer Ke-timer is part of the Ble-core, not the peripheral timer. The schedule function will handle all pending message events. Here, assuming that the CPU is awakened by the BLE timer, the BLE core is functioning normally after the wakeup, so the schedule can be performed normally. The above is the synchronous wake-up process.

Asynchronous wakeup is the wake-up of the wakeup timer interrupt, and the BLE timer may or disable state after waking.

We're not going to differentiate the DA14580 SDK for events generated by asynchronous wake interrupts and ble timer synchronous wakeup. and a low-power sleep code framework is given based on synchronous wakeup:

Voidmain_loop (void)

{

while (1)

{

Schedule ();//All message events are returned after processing

Disable ble;//off Blecore

Disable radio;//off RF

Disable Peripheral Power domain;//off the perimeter control Section

Set CPU deep sleep.//cpu sleep settings

WFI (); Wait for interrupt

The CPU sets the active state after the set CPU active.//wakes up, and the BLE timer wake-up interrupt service should be enabled in the Bluetooth CORE, RADIO, peripheral and other parts.

}

}

The low-power code framework becomes complex if you want to support both asynchronous interrupts and the asynchronous messages/events they produce, while handling the effects of extended sleep and deep sleep two modes. In the future, the author will analyze in detail how DA14580 supports low-power features from the perspective of software practice.

The original team of embedded Penguin Circle consists of senior engineers such as Ali, Meizu, nvidia, godson, Ju Li, and so on. Hundreds of original, two articles a week, sharing embedded, Linux, Internet of Things, GPU, Android, autonomous driving and other technologies. Welcome to sweep code attention to the public number: embedded Penguin ring, real-time push the original article!

World's lowest power Bluetooth single chip DA14580 hardware architecture and low power consumption

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.