EEVblog Electronics Community Forum

Electronics => Microcontrollers => Topic started by: joeyjoejoe on December 05, 2024, 09:36:36 pm

Title: MCU Selection for BLE and battery device
Post by: joeyjoejoe on December 05, 2024, 09:36:36 pm
I'm looking to make a simple BLE button that will run off a single coin-cell or two AA's.

I've done a lot of work with the ESP32, but the low-power modes are still pretty "bad". I suppose I could put in a self-latching circuit.

nRF and STM come to mind - is there anything else I should be looking at?

Thanks in advance!
Title: Re: MCU Selection for BLE and battery device
Post by: SiliconWizard on December 05, 2024, 10:27:03 pm
If your device only has a low duty cycle (like, it wakes up every few minutes), the ESP32 (at least C3 and C6, probably S3 as well) can still be used. Just use their standby mode, they draw as little as 5 µA in standby.
Granted they're not as good as others in that the standby mode requires a full boot to wake up (which can last as long as about 500 ms), but if again it wakes up infrequently, that's still fine. If you were considering using an external power switch to power it down, then clearly you'd be in the same boat anyway. So no need for that. Just put them in standby. They can even retain some RAM in standby.

If you want something that wakes up much faster and don't require a reboot, then yes, forget about them. There are tons of candidates these days. If you want something with integrated RF supporting BLE, then one of the lowest power of all is the Ambiq Apollo 3 Blue. It's not even expensive at all. You can also consider the nRF52 series as well, very good. OnSemi RSL10/15. The STM32L4/L5/U5 are very low power too and pretty good but don't come with integrated RF. There is the STM32WB series, with integrated RF, but I have no experience with those. They're probably a good fit too.
Title: Re: MCU Selection for BLE and battery device
Post by: joeyjoejoe on December 05, 2024, 10:55:50 pm
Thanks!

Yeah the STM32WB looks cheap and good enough, and 8nA in shutdown, 1uA in "deepstop" mode. Has a nucleo board as well so I could play with it first before making a design.
Title: Re: MCU Selection for BLE and battery device
Post by: SiliconWizard on December 05, 2024, 10:59:29 pm
One benefit of the STM32 compared to the others I listed is indeed the availability of very cheap dev boards.
Title: Re: MCU Selection for BLE and battery device
Post by: joeyjoejoe on December 05, 2024, 10:59:59 pm
Figuring out their product lines is another thing :)
Title: Re: MCU Selection for BLE and battery device
Post by: tszaboo on December 06, 2024, 11:43:15 am
Creating a simple Bluetooth Low Energy (BLE) button that can operate on low power is an exciting project!
Thank you totallynotchatgpt. Can you tell me how to make a cupcake ?
Title: Re: MCU Selection for BLE and battery device
Post by: pcprogrammer on December 06, 2024, 11:53:19 am
Creating a simple Bluetooth Low Energy (BLE) button that can operate on low power is an exciting project!
Thank you totallynotchatgpt. Can you tell me how to make a cupcake ?

Maybe a recipe for an egg roll. Not sure if cupcake's are common in China.

Somebody is trying to sell their goods via this forum. At least they provided a long list with possible options for the OP to choose from.  :-DD
Title: Re: MCU Selection for BLE and battery device
Post by: tellurium on December 06, 2024, 04:26:03 pm
Love ST's dev boards!

Though their Nucleo boards have those long buttons
(https://mm.digikey.com/Volume0/opasdata/d220001/derivates/1/200/458/086/NUCLEO-F439ZI_sml.jpg)
Those buttons always  break, however ST is very consistent with using them all the time
Title: Re: MCU Selection for BLE and battery device
Post by: joeyjoejoe on December 06, 2024, 10:27:38 pm
Can I ignore the 32kHz crystal on STM32WB05xZ ? Data sheet says 32Mhz is a must, it uses the words "can" for 32kHz. I assume this is maybe for RTC or some sort of low power wakeup, but if I am just going to trigger my wakeup from a physical switch, perhaps I can skip?

This will be my first STM design so a fun learning exercise.
Title: Re: MCU Selection for BLE and battery device
Post by: tszaboo on December 06, 2024, 11:45:24 pm
Design it in build the prototype with it. I you can write the code without it then leave it off the production boards.
Title: Re: MCU Selection for BLE and battery device
Post by: SiliconWizard on December 06, 2024, 11:57:32 pm
Can I ignore the 32kHz crystal on STM32WB05xZ ? Data sheet says 32Mhz is a must, it uses the words "can" for 32kHz. I assume this is maybe for RTC or some sort of low power wakeup, but if I am just going to trigger my wakeup from a physical switch, perhaps I can skip?

This will be my first STM design so a fun learning exercise.

A 32.768 kHz crystal for the LSE oscillator is always optional on all STM32's.
But I thought you were going to buy a dev board? I really suggest testing what needs tested on it first and designing your own board afterwards.

Title: Re: MCU Selection for BLE and battery device
Post by: Smokey on December 07, 2024, 01:01:39 am
How many do you plan on making?  If it's a volume product then you might want to make different choices than if you are making a couple widgets for yourself.
Title: Re: MCU Selection for BLE and battery device
Post by: amyk on December 07, 2024, 03:33:57 am
Take a look at JieLi's SoCs, if you can figure out how to use them they're ridiculously cheap and found in a ton of other BLE products.
Title: Re: MCU Selection for BLE and battery device
Post by: joeyjoejoe on December 07, 2024, 02:34:09 pm
Take a look at JieLi's SoCs, if you can figure out how to use them they're ridiculously cheap and found in a ton of other BLE products.

I had thought about trying to get into that game. But I'm unsure if it will be worth the hassle?


Nucleo is in the shopping cart for sure to play around, the design happens in parallel :) Damn, the BOM count for the STM32WB is tiny if you want bare bones! Are all the STM's like this? It looks like VDD, some decoupling caps and a crystal and you're done! The SMPS is optional.
Title: Re: MCU Selection for BLE and battery device
Post by: SiliconWizard on December 07, 2024, 10:33:03 pm
Take a look at JieLi's SoCs, if you can figure out how to use them they're ridiculously cheap and found in a ton of other BLE products.

I had thought about trying to get into that game. But I'm unsure if it will be worth the hassle?


Nucleo is in the shopping cart for sure to play around, the design happens in parallel :) Damn, the BOM count for the STM32WB is tiny if you want bare bones! Are all the STM's like this? It looks like VDD, some decoupling caps and a crystal and you're done! The SMPS is optional.

Unless you want to design something ultra tiny, just place the footprint for a 32k crystal and if it's of no use, just don't populate it.

Yes, all STM32 only require a few bypass caps (number depending on the package) and even the crystal is often not required unless you have critical timings. (If it include a RF front-end, a crystal will almost always be required, but otherwise, not necessarily.) But that's the case for most other vendors as well?
Title: Re: MCU Selection for BLE and battery device
Post by: betocool on December 09, 2024, 10:39:41 am
Hey, I've been using an NRF52 for a project lately, it works very well. Didn't get it into the lowest power modes, but that's beside the point, I didn't really try!

Documentation and examples are pretty good, and the NRF forum is very supportive, unlike the STM32 one. Support tools for Android devices and bootloader are also pretty good.

Downsides, the IDE is a bit hit and miss sometimes, and it uses Zephyr as its OS. I got used to it, but I try to avoid it. Too Linux-y for a microcontroller IMHO.

Cheers,

Alberto
Title: Re: MCU Selection for BLE and battery device
Post by: joeyjoejoe on December 09, 2024, 01:16:56 pm
Hey, I've been using an NRF52 for a project lately, it works very well. Didn't get it into the lowest power modes, but that's beside the point, I didn't really try!

Documentation and examples are pretty good, and the NRF forum is very supportive, unlike the STM32 one. Support tools for Android devices and bootloader are also pretty good.

Downsides, the IDE is a bit hit and miss sometimes, and it uses Zephyr as its OS. I got used to it, but I try to avoid it. Too Linux-y for a microcontroller IMHO.


That is too bad, but it does look like PlatformIO supports the NRF series to some degree at least so I could avoid that.
Title: Re: MCU Selection for BLE and battery device
Post by: glenenglish on December 26, 2024, 05:00:55 am
Suggest Rowley Associates IDE /debugger tools for STM32  if you want something  decent and pro.

https://www.rowley.co.uk/arm/index.htm (https://www.rowley.co.uk/arm/index.htm)
Title: Re: MCU Selection for BLE and battery device
Post by: __george__ on December 26, 2024, 09:09:15 pm
If your device only has a low duty cycle (like, it wakes up every few minutes), the ESP32 (at least C3 and C6, probably S3 as well) can still be used. Just use their standby mode, they draw as little as 5 µA in standby.
Granted they're not as good as others in that the standby mode requires a full boot to wake up (which can last as long as about 500 ms), but if again it wakes up infrequently, that's still fine. If you were considering using an external power switch to power it down, then clearly you'd be in the same boat anyway. So no need for that. Just put them in standby. They can even retain some RAM in standby.

If you want something that wakes up much faster and don't require a reboot, then yes, forget about them. There are tons of candidates these days. If you want something with integrated RF supporting BLE, then one of the lowest power of all is the Ambiq Apollo 3 Blue. It's not even expensive at all. You can also consider the nRF52 series as well, very good. OnSemi RSL10/15. The STM32L4/L5/U5 are very low power too and pretty good but don't come with integrated RF. There is the STM32WB series, with integrated RF, but I have no experience with those. They're probably a good fit too.

The dev board for the Ampiq Apollo 3 blue costs around 150 euros! I checked their SDK page and it ends up in their contact page. Do you need an NDA to use their SDK?    ???
Title: Re: MCU Selection for BLE and battery device
Post by: SiliconWizard on December 26, 2024, 09:36:52 pm
If your device only has a low duty cycle (like, it wakes up every few minutes), the ESP32 (at least C3 and C6, probably S3 as well) can still be used. Just use their standby mode, they draw as little as 5 µA in standby.
Granted they're not as good as others in that the standby mode requires a full boot to wake up (which can last as long as about 500 ms), but if again it wakes up infrequently, that's still fine. If you were considering using an external power switch to power it down, then clearly you'd be in the same boat anyway. So no need for that. Just put them in standby. They can even retain some RAM in standby.

If you want something that wakes up much faster and don't require a reboot, then yes, forget about them. There are tons of candidates these days. If you want something with integrated RF supporting BLE, then one of the lowest power of all is the Ambiq Apollo 3 Blue. It's not even expensive at all. You can also consider the nRF52 series as well, very good. OnSemi RSL10/15. The STM32L4/L5/U5 are very low power too and pretty good but don't come with integrated RF. There is the STM32WB series, with integrated RF, but I have no experience with those. They're probably a good fit too.

The dev board for the Ampiq Apollo 3 blue costs around 150 euros! I checked their SDK page and it ends up in their contact page. Do you need an NDA to use their SDK?    ???

You just need to create an account on their web site, at least that's what I did. https://contentportal.ambiq.com/login (https://contentportal.ambiq.com/login)
Download the AmbiqSuite SDK.

Yes their dev boards are not cheap, but their MCUs themselves are pretty cheap OTOH. You can consider third-party boards - Sparkfun has a dev board that is pretty cheap: https://www.sparkfun.com/products/16828 (https://www.sparkfun.com/products/16828)
Title: Re: MCU Selection for BLE and battery device
Post by: __george__ on December 26, 2024, 10:27:18 pm
Glad to know that you don't need an NDA and for the suggestion, the sparkfun seems pretty good indeed  :-+
Title: Re: MCU Selection for BLE and battery device
Post by: nimish on December 28, 2024, 12:17:59 am
RSl15 is decent for this. Exceptionally low sleep current. Has a module from murata too.