Editorial credit: DFree / Shutterstock.com
One of my favorite musical groups is the French DJ duo Daft Punk. One of the quirks of Daft Punk is that they pretend to be robots and perform all their shows in awesome robot costumes. In 2013 they released their album Random Access Memories, or RAM, to play on the robotic theme. However, they failed to specify exactly which kind of RAM. You and I know that in the world of embedded systems the type of memory you use is quite important. SRAM specifically has some advantages over Flash memory and especially DRAM, particularly when it comes to energy usage. There are now several different varieties of SRAM in embedded system that you can use. Deep sleep-enabled SRAM can give you both speed and energy savings when used correctly.
It can be hard to choose a favorite band or artist. There are hundreds of thousands to choose from in so many different genres. When it comes to choosing memory for your embedded system things are a bit more simple. Let’s quickly compare SRAM, Flash memory, and DRAM so we can see exactly where SRAM can best be used in your system.
There are many different types of memory that are designed for embedded systems, including new entrants like CBRAM and Spin Wave devices. Some of the more traditional types are Flash, SRAM, and DRAM and each has its own place in the system. Interestingly, the physical locations of these memory types and the way you access them affect their power consumption. The way each memory architecture works also has an effect. DRAM has to be refreshed in order to retain data, making it use more energy than the other two types. Flash is often used to store code, whereas SRAM is used as a cache, and DRAM is used for general memory.
The microcontroller that runs your system processes data very quickly and needs memory that can keep up with the pace. That’s why SRAM is normally used as a cache. Flash and DRAM both have long write times that can limit the MCU (microcontroller unit). SRAM is also primarily limited to caches because of its small size. DRAM is used for operations that need bigger chunks of temporary storage.
SRAM and DRAM both have their place in embedded systems.
Daft Punk is my favorite band overall, but I also have top artists in each genre. Likewise, it’s important not only to know that you will use SRAM but exactly which type. Generally, SRAM with a deep sleep mode, can give you both the speed you need and save some energy.
Before the explosion of portable electronic devices, SRAM mostly focused on speed. Since we started carrying around super-computers with high-power consumption processors, though, low-power SRAM has found a niche. The faster variety has access times of around 10 ns compared to low power’s 45 ns. Low power mode obviously uses less energy with a 36 mA operating current vs 110 mA and astoundingly low 16 µA standby current as opposed to the speedier variety’s 30 mA. Obviously, both kinds are specialized and can provide great functionality for their designed use cases. However, neither kind can provide what we really want; speed with power savings.
Deep sleep SRAM is a hybrid type that nearly gives us the best of both worlds. With a 10 ns access time, it’s as quick as can be, and its “deep sleep mode” state nearly matches the low power standby current at 22 µA. When not in deep sleep mode its standby current is still 30 mA, and during normal operation, it will still draw around 110 mA. When used properly deep sleep SRAM can give you the performance you need, while saving you nearly as much energy as a low-power mode type.
Deep sleep SRAM will help you save energy.
It’s important to play the right kind of music at the right time. You don’t want to break out Beethoven’s Moonlight Sonata at a birthday party. The same goes for deep sleep SRAM, there are times when it will help, and times when it just doesn’t make sense.
There is one case, in particular, where using deep sleep SRAM doesn’t make much sense. That’s when the use times of the SRAM are too close together for it to enter deep sleep mode. Let’s say your SRAM takes 300 µs to enter sleep mode and your system accesses it every 250 µs. Your SRAM will never be able to enter sleep mode and will essentially behave like a typical SRAM. Then you’ll have spent the extra money on something that does what any normal SRAM can do. Before implementing deep sleep SRAM in your system make sure that you can get the most out of its deep sleep mode capabilities.
Some of you might be concerned that deep sleep SRAM in embedded system is hard to integrate into your system. Will you have to redesign your connections or battery backup if you have one? Luckily the answer is no, not really. Sleep mode-enabled SRAM has only one extra pin when compared with normal fast SRAM. If you can’t squeeze one extra pin in there then I don’t know what to say.
You may not think much of my musical choices, but I hope you can see the value of deep sleep SRAM. You’re probably using SRAM as a cache for your MCU, which beats the access times of Flash and DRAM. I’m sure you’re happy that SRAM uses less energy than DRAM, but by using fast SRAM with deep sleep mode capabilities you can get both speed and power savings. Users can implement this technology and many other PCB design techniques with the world-class PCB design and layout features in Altium Designer®. Users can take advantage of a single integrated design platform with circuit design and PCB layout features for creating manufacturable circuit boards. When you’ve finished your design, and you want to release files to your manufacturer, the Altium 365™ platform makes it easy to collaborate and share your projects.
We have only scratched the surface of what’s possible with Altium Designer on Altium 365. Start your free trial of Altium Designer + Altium 365 today.