429 NRF52 Bluetooth (BLE) Tutorial. Does it consume less than the ESP32? (Feather, XIAO, ItsyBitsy)

  Рет қаралды 83,331

Andreas Spiess

Andreas Spiess

Күн бұрын

The NRF52 chips from Nordic should be much better for Bluetooth Low Energy projects than the ESP32. Is this true? Can we use them with the Arduino IDE? And which boards are available? Let’s have a closer look.
My second channel: / @hb9bla
Links:
Example code: github.com/SensorsIot/NRF52-v...
Adafruit BLE introduction: learn.adafruit.com/introducin...
XIAO BLE: s.click.aliexpress.com/e/_AsR6JV
Makerdiary: s.click.aliexpress.com/e/_9JvUA7 or amzn.to/3Mtbybd
ItsyBitsy: amzn.to/3sJaFDl
Feather: amzn.to/3Lx46dW
The links above usually are affiliate links that support the channel (no additional cost for you).
Supporting Material and Blog Page: www.sensorsiot.org
Github: www.github.com/sensorsiot
My Patreon Page: / andreasspiess
Discord: / discord
If you want to support the channel, please use the links below to start your shopping. No additional charges for you, but I get a commission on your purchases to buy new stuff for the channel
My Amazon.com shop: www.amazon.com/shop/andreassp...
For Banggood bit.ly/2jAQEf4
For AliExpress: bit.ly/2B0yTLL
For Amazon.de: amzn.to/2r0ZCYI
For Amazon UK: amzn.to/2mxBaJf
For ebay.com: ebay.to/2DuYXBp
profile.php?...
/ spiessa
www.instructables.com/member/...
Please do not try to email me. This communication channel is reserved for my primary job
As an Amazon Associate, I earn from qualifying purchases
#no#midroll#ads

Пікірлер: 316
@Dronebotworkshop
@Dronebotworkshop Жыл бұрын
Great video as always, Andreas! However, I don't concur regarding creating KZbin videos not being arduous - especially when you spend half an hour recording some demonstrations only to realize that you forgot to plug a microphone cable into the video recorder (which happened to me just yesterday). Would have loved to have measured my heart rate at that point, I'm sure it was well over the 63 BPM of calmness you manage to maintain!
@mookfaru835
@mookfaru835 Жыл бұрын
Make a device that tells you when something goes wrong with your work
@qcnck2776
@qcnck2776 Жыл бұрын
You are so right! And commiserations on your loss (of audio) :(
@MandoRick1978
@MandoRick1978 Жыл бұрын
This reminds me of working on machines. When I bash my knuckles, I do not get mad at the machine, because I am the idiot, not the machine. I also don't get mad because the lessons that are hard won are never forgotten. Your hand/wrench only has to slip once for you to remember to work smarter. You only have to lose audio once to remember to check your audio from now on ;)
@jovaraszigmantas
@jovaraszigmantas Жыл бұрын
You are in luck with only 2AAA batteries you are able to measure your BPM for for over 2 months. 😁
@gregorymccoy6797
@gregorymccoy6797 Жыл бұрын
Consider it a substitute for your weekly cardio😄
@insanitywolf05
@insanitywolf05 Жыл бұрын
Thanks Andreas. Long awaited video! The Adafruit core (also my favourite by far) is based on freeertos and has some interesting functionality. I think you should try out not suspending the loop but instead putting delay(xxx); in there which is the equivalent to a sleep mode. A little counter intuitive. The XIAO BLE sense powers all of its sensors from gpio pins so pulling them low switches them off completely. This is the most interesting nrf52840 board out there because it actually takes care of those things and also uses a very low Iq LDO. BTW the seeed core is weird: if you install 1.0.0 you get a ported version of the bluefruit library out of the box with all the examples, whereas the 2.x version does not include them.
@AndreasSpiess
@AndreasSpiess Жыл бұрын
I saw the differences between v1 and v2 too but did not understand. I hope somebody will create a boards Definition file for the Adafruit core. It should not be too complicated for somebody with knowledge…
@JanCiger
@JanCiger Жыл бұрын
Nordic doesn't really support Arduino, their focus is both on their own libraries and the Zephyr RTOS. The Arduino BLE support is built by third parties (like Adafruit) on top of the closed source Nordic "softdevice" (essentially RTOS core), AFAIK. I have personally found this setup extremely buggy and borderline unusable. Worse, it does not expose a lot of important functionality. If you want to really get control of what the SoC is doing and minimize power consumption, you need to use either Nordic's SDK directly (and then you can use other protocols too - e.g. Zigbee, Ant/Ant+, NRF24L01+ compatible Shockburst ...) or Zephyr. Don't expect Arduino to be able to do that, it is set up for making the common use case simple, not for allowing to squeeze every bit of performance out of the hardware. Nordic's documentation is excellent, BTW - but do expect a really steep learning curve because there is no "handholding" with something like BLE for you there - you get the control of literally everything, including the crypto required for establishing the connection. So it can be quite overwhelming at the start.
@ysmsverige4179
@ysmsverige4179 Жыл бұрын
Exactly... I agree with all points... Same experience I have.
@Gabriel965519437
@Gabriel965519437 Жыл бұрын
best comment ever. People think Arduino Core is the key to everything, but no. Also, nRF52 has Bluetooth Stack implemented in hardware while ESP32 implements Bluetooth Stack in software as I understand. So for Wifi ESP32 it may be better but for BLE nRF52 it is much better. In the future, Nordic will also release a SoC with Wifi stack implemented in hardware, as it has just purchased a wifi IP core start-up and is working on creating new SoCs for low-power applications with wifi and ble.
@savejeff15
@savejeff15 Жыл бұрын
Thx for the information. Sadly this sound like Nordics Products do not really suit the Arduino approach. I personally favor a clean and uniform approach over a very hardware specific. I want to Abstract from the actual hardware quick and cleanly. Arduino works very well with that approach. You get to you goal quite fast or close enough to customize the last 10% The Nordic approve sounds like very hard work before anything works and than it gets easier. But that's very expensive.
@AndreasSpiess
@AndreasSpiess Жыл бұрын
I agree that it should be possible to create an Arduino simplification. We do not want every feature, just the standard cases. If I would have to learn a new environment for each chip I have no time to build something… This would also help the professional market where time is money an learning curves are investments.
@ericbwertz
@ericbwertz Жыл бұрын
@@Gabriel965519437 None of it is implemented in hardware -- it's all in the blob of firmware that they call their SoftDevice, which you're not strictly forced to use if you can do better.
@aacasd
@aacasd Жыл бұрын
This is one of the best introduction video on how to plan and decide which uc and board to select when building a low power solutions.
@AndreasSpiess
@AndreasSpiess Жыл бұрын
Thank you!
@garytrehair
@garytrehair Жыл бұрын
Thanks for the video Andreas and great timing for me as I have recently started experimenting with the NRF52840 development kit. As others have stated, the learning curve is very steep, but I finally managed to build a thermometer beacon. It transmits every 5 seconds using the highest power setting (+8dB) and is drawing an average of 34µA with only the most basic power saving features enabled. I'm sure it can go a lot lower with further tweaking.
@elangovanhariprashanth4087
@elangovanhariprashanth4087 Жыл бұрын
Code written on nRF studio or arduino?
@garytrehair
@garytrehair Жыл бұрын
@@elangovanhariprashanth4087 I used nRF Studio with the Zephyr RTOS.
@AndreasSpiess
@AndreasSpiess Жыл бұрын
I am sure this is possible. I would love if somebody would transfer this knowledge to a Arduino library…
@austinhiggs7257
@austinhiggs7257 Жыл бұрын
Thank you for all your videos, especially the ones on antenna tuning!
@AndreasSpiess
@AndreasSpiess Жыл бұрын
You are welcome!
@AndreasSpiess
@AndreasSpiess Жыл бұрын
I just saw your super Thanks on my PC (it is not displayed on the IPad). Thank you for your support!
@Average_Geo
@Average_Geo Жыл бұрын
As always, thanks for your thorough research into the nRF solution. It is a good tutorial to reference in the future!
@AndreasSpiess
@AndreasSpiess Жыл бұрын
I had it on my list for a long time. Now the status seemed to be "usable". We will see where this goes and if ESPRESSIF will get better in power consumption with their Zigbee chips.
@avejst
@avejst Жыл бұрын
Impressive work! Thanks for sharing your experiences with all of us 🙂
@AndreasSpiess
@AndreasSpiess Жыл бұрын
You are welcome!
@jpconstantineau
@jpconstantineau Жыл бұрын
Great Video Andreas. I have been a maintainer of a BLE keyboard firmware ever since the days of the nRF52832. When I first got into it, I did try to program with the Nordic SDK and after hours of work, I still couldn't even get a LED to flash. I then turned to the Adafruit nRF52 board support package and I was able to get it working within minutes. Since then, I have been creating keyboards and even extended my firmware to the nRF52840. It's really a shame that Nordic doesn''t support the maker community and that Adafruit will only accept boards that they make or sell to be as part of their BSP. (This is quite understandable from a support point of view). However, this only helps fragmenting Arduino Support for the nRF52840 boards into several forks and really doesn't help for maker adoption. The nRF52 chips are amongst the best (if not THE best) for power consumption. To get power consumption down with the Arduino IDE, you need to do some coding black magic (minimum would be to make sure to use a delay in the main loop; if you use a loop) and measure, measure, measure. Apparent small changes in code, sometimes makes big differences in power consumption. One has to remember that the CPU when running non-stop would use about 6mA (from the datasheet) and the radio about 20mA (From the datasheet). Anything to minimize CPU time and radio time will help bring power consumption down. There are also some "magic settings" from the softdevice that will also influence power consumption. These aren't documented in the Adafruit nRF52 library but are buried in Nordic's documentation. Adafruit's implementation uses FreeRTOS to manage the main loop and any other tasks one wants. Delay for the Adafruit nRF52 library isn't a true "delay" but more of a yield of the currently running task to other tasks. If the RTOS doesn't have any other tasks to process, it will go into low power mode until the next "tick" and see if it need to go back at running the delayed task again. If I remember well, the "Idle" task does have the necessary code to put the CPU into idle state (low power) but the default might not be what everyone wants. The defaults that Adafruit has implemented are reasonable for most applications but are not necessarily for everyone. A lot of the tweaks one would need to do to get it running exactly as they want aren't exposed by the library but many settings have been exposed since I first started working with it. To make fragmentation even worse, support for the nRF52833 (a chip with USB - like the 840 but with the flash and ram of the 832) isn't there yet, even if the chip has been out for a while. The complicating factor to get support for it is Nordic's different softdevice versions. From what I remember, the update from 6.x to 7.x changed a few things and none of the Arduino libraries I have seen supports the 7.x version - which is the version needed for the 833 and the newer, more advanced BLE features some people have been asking about.
@insanitywolf05
@insanitywolf05 Жыл бұрын
Oh actually, the seeed xiao ble core uses the 7.xx softdevice and version 1.0.0 of the core includes the bluefruit library and examples
@AndreasSpiess
@AndreasSpiess Жыл бұрын
Good information. Thank you! Maybe we will get more attention after this video…
@Chris-ut6eq
@Chris-ut6eq 10 ай бұрын
Love the details in your videos, great work!
@AndreasSpiess
@AndreasSpiess 10 ай бұрын
Thank you very much!
@Ed.R
@Ed.R Жыл бұрын
Always interesting to see other people using these chips. I started getting into Segger embedded studio to program them and have got rather out of my depth. Partly because I'm determined to use ANT+. One day maybe it will make sence and the benefit is the Arduino IDE now looks simple.
@jpconstantineau
@jpconstantineau Жыл бұрын
I think licensing for the ANT+ stack will always be a problem for makers wanting to use ANT+. I don't foresee any support for Arduino for this because of that.
@AndreasSpiess
@AndreasSpiess Жыл бұрын
I never used ANT+ :-(
@Uncle-Duncan-Shack
@Uncle-Duncan-Shack Жыл бұрын
That's why my Nordic boards are still unused and waiting for a rainy day when I am very bored and have lots of time. The resources are rather thin. It is such a lot of work to get the stuff working, hence me not having bothered with it yet. Your video on the subject is good, it illustrates a path one could follow when there's a need to do one of these types of projects.
@AndreasSpiess
@AndreasSpiess Жыл бұрын
That was my intention…
@dotcool2262
@dotcool2262 Жыл бұрын
Very interesting AND useful indeed. Thank you dear Andreas.
@AndreasSpiess
@AndreasSpiess Жыл бұрын
You are welcome!
@AerialWaviator
@AerialWaviator Жыл бұрын
Great video, with some good questions to inspire makers to discuss and collaborate. :)
@AndreasSpiess
@AndreasSpiess Жыл бұрын
Let’s hope we will get some improvements…
@AlwinArrasyid
@AlwinArrasyid Жыл бұрын
Great video as always. Got my Seeed XIAO BLE sense earlier this year. I think the core is based on Arduino mbed OS. I wrote a way to work with it on PlatformIO IDE.
@Podemosllegaralossubs-ty7bq
@Podemosllegaralossubs-ty7bq Жыл бұрын
You probably need to bypass the regulator: "Input voltage (VIN): 5V", "Circuit operating voltage: 3.3V" and/or disable (or more likely remove) the other unused (lipo charger, IMU, mic, etc) components.
@AndreasSpiess
@AndreasSpiess Жыл бұрын
I agree that the other components consume some energy. Maybe I will compare a standard board.
@Holiday_Ringo
@Holiday_Ringo Жыл бұрын
My first microcontroller was a 32u4 ble from adafruit. Very fun and simple to control neopixels via bluetooth.
@AndreasSpiess
@AndreasSpiess Жыл бұрын
I was not aware that this chip has Bluetooth.
@bluefishactcl1464
@bluefishactcl1464 Жыл бұрын
Good work ! Valuable !! Thank you
@AndreasSpiess
@AndreasSpiess Жыл бұрын
You are welcome!
@CorvanEssen
@CorvanEssen Жыл бұрын
I've been using the Arduino BLE Sense. It has a number of fun sensors. At the moment I convinced it that it is a Bluetooth mouse that moves the pointer based on acceleration values
@AndreasSpiess
@AndreasSpiess Жыл бұрын
Cool project!
@usefulelectronics
@usefulelectronics Жыл бұрын
Awesome tutorial this will be a good reference to start programming this processor. Nordic has the leadership in BLE field. Generally, it has higher price compared to ESP32 though.
@AndreasSpiess
@AndreasSpiess Жыл бұрын
Yes, the ESP32 is very cheap!
@Johnny.Fedora
@Johnny.Fedora Жыл бұрын
Have you tried to program and use the peripherals on the ESP32 (e.g., the ESP32S2)? It's hideous. They're all screwed up. The ADC is not useful for anything beyond a potentiometer input, and even for that, it needs a translation table to linearize the values. That chip is a joke. Contrast that with the Atmel SAMD51 or the nrf52840. They presumably use peripherals from the ARM library. They work beautifully -- even the ADC is useful for many purposes, and in fact, it's offset/linearity/etc. can be tweaked through registers. It's a thing of beauty. The ESP32 chips are fine for calculators, but nothing with non-trivial I/O.
@usefulelectronics
@usefulelectronics Жыл бұрын
Well it is a bit unfair to judge ESP32 like that. There are many parameters to discuss. Assume that ESP32 is just like what you have said, it would be impossible to go that popular in the market, where there are real products run on ESP32. You can give ESP32 a try using its native SDK. It has improved a lot
@Johnny.Fedora
@Johnny.Fedora Жыл бұрын
@@usefulelectronics, you may not be replying to my comment, but I'll reply to yours. The core and peripherals on the Nordic chip work the same they do on other Cortex M4 chips, for which there is very good documentation. Perhaps Nordic could provide better documentation on the Bluetooth section of the nrf52840. (By the way, Raspberry provides even better documentation for the RP2040, with it's dual-core M0+; they are also very up-front about with its errata.) I don't have personal experience with the RP2040, but I have a fair amount of experience with the ATSAMD51, the nrf52840, and the ESP32S2. Except for Bluetooth, the first two of those chips operate identically, plus or minus clock speed. The ESP32, on the other hand, has a fine core (with less flexibility than the ARM chips, and with very poor documentation, as I said), and with very poor peripherals that are full of show-stopping defects. If the ESP32S2's core were sold as a microprocessor, that would be fine. The products that use the chip are likely using the "SoC" in a simple way, driven by cost considerations. Once you finally get it to do what you want, it's not hard to crank out a lot of that product. I would not, however, use that chip in any critical application. There must be better choices among RISC-V-core chips. So far, though I don't have insight into the internal machinery and registers of the nrf52840's Bluetooth section, it's worked well and reliably for me. Nordic is a serious company, unlike Espressive and the IP chain that underlies that RISC-V parts. For toys, it's not a big issue.
@drmocm
@drmocm Жыл бұрын
BTW, one more board one could try is an ESP32C3. They are now even available in the ESP01 form factor. Before I used the Xioami thermometer I built a WiFi solution with UM's TinyPico and after that ran out of power after 90 days I tried a TinyS2 which is still running after a 100 days, just to see how long it will run. Both had long intervals (6min) between readings and only switched on Wifi in case of a temperature change (sensor was a BME680 and now and SHT30 powered via GPIO, battery was 1000mA Lipo). My next try would have been an ESP32C3, which may give better results with BLE instead of WiFi).
@AndreasSpiess
@AndreasSpiess Жыл бұрын
Good point. So far I never used the C3 in a project.
@shortage9347
@shortage9347 Жыл бұрын
There is also official LOLIN Store on Aliexpress with another tiny esp32c3 board variant "C3 PICO V1.0.0" 25.4x25.4mm (which is larger than TTGO T-01C3, but seems more usable for different cases). And Seeed XIAO module on esp32c3 chip is also available.
@innomkr
@innomkr Жыл бұрын
Good job! Thanks for the another great video!
@AndreasSpiess
@AndreasSpiess Жыл бұрын
You are welcome!
@PhG1961
@PhG1961 Жыл бұрын
Really interesting video ! This calls for some tinkering fur sure !
@AndreasSpiess
@AndreasSpiess Жыл бұрын
Maybe we get some additional help to reduce power…
@BlueyMcPhluey
@BlueyMcPhluey Жыл бұрын
As always, exactly what I am looking for, even though I am always 9+ months late :)
@AndreasSpiess
@AndreasSpiess Жыл бұрын
Late for the video, but for sure not late for you! That is the advantage of KZbin!
@drmocm
@drmocm Жыл бұрын
I was just thinking about building a BLE thermometer with an NRF58240, but then I saw the Xiaomi LYWSD03MMC thermometers which you can flash with the ATC firmware and which then have very low power consumption. I got 4 for $27 and use them with OpenMQTTGateway, even the seeed board would be much more expensive than that.
@AndreasSpiess
@AndreasSpiess Жыл бұрын
Good point if you want to stick with BLE. For temperature and humidity Another possibility Is Zigbee sensors. They do not need reflashing…
@drmocm
@drmocm Жыл бұрын
@@AndreasSpiess I tried the Xiaomi Zigbee thermometers at the location I need it, but the connection was unreliable. Additionally, the BLE variant has a screen where you can read the temperature directly.
@mahudson3547
@mahudson3547 Жыл бұрын
Very interesting video. Looking at the NRF design brief there's a huge amount of stuff on that chip. I bet if you learned how to turn bits of it off, reduce rf output etc. you could get a huge improvement. Needs someone younger than me!
@AndreasSpiess
@AndreasSpiess Жыл бұрын
And definitively more skilled and with more time than me ;-)
@AdityaMehendale
@AdityaMehendale Жыл бұрын
At a certain footprint, it would become possible to put a harvester to counteract the power-consumption of the beacon. A solar panel (~10 cm^2) would, in this case, be able to permanently power the NRF52, off of the ambient light in a room.
@AndreasSpiess
@AndreasSpiess Жыл бұрын
I agree that we come closer to „no battery“ boards like the Enocean.
@MakunaRGBIC
@MakunaRGBIC Жыл бұрын
The hardware support on these chips to send async pulses is easy and flexible; one of the best on the market I have seen for Arduino. Great for IR, NeoPixel, etc sort of features; without using bitbang so it timing is accurate and doesn't processor time (power?) to support them.
@AndreasSpiess
@AndreasSpiess Жыл бұрын
Interesting! Thank you.
@thanks600
@thanks600 Жыл бұрын
First thought for reducing power is to reduce tx power in code and further stretch advertising interval. Use board with rtc xtal installed AND properly configure it from code. Use lowest permissible power mode whilst ble beacon still works. For those who don’t want to use softdevice, alternative exists: Riot RTOS support nrf thru Apache Nimble, Zephyr RTOS has direct NordicSemi contributions for ble drivers.
@AndreasSpiess
@AndreasSpiess Жыл бұрын
Maybe I will have a look at Zephyr once…
@-r-495
@-r-495 Жыл бұрын
Dear fellow Guy with a Swiss accent I‘m not sure why and since when, but I consider the Arduino IDE to be bloatware (OsX). As I currently have no low latency projects I have deinstalled it completely and switched to μPython. Yes, this has limited me in some ways, but I‘ve also noticed that as an engineer I can basically transfer the specifications to Python and it‘s still legible for beginners. Less hassle for me and my few clients, albeit limitations apply. Hopefully Arduino will change their approach (maybe they already have?) and maybe even open the IDE to μPython.. Thank you very much for your effort, your content has nonetheless helped me broaden my perspective (and workshop 😅) and I‘ll be replicating your Pöschtler alarm soon. Bye!
@AndreasSpiess
@AndreasSpiess Жыл бұрын
Three years ago I made a video about Microphython and the comments were not very favorable. Maybe it’s time will come later…
@EdFrench_uk
@EdFrench_uk Жыл бұрын
Very useful. I have sometimes read that the esp32 can do much better bluetooth sleeping if it has a second xtal- but I think we would have seen someone sort that out by now if it was!
@AndreasSpiess
@AndreasSpiess Жыл бұрын
I never heard of this second XTAL :-(
@EdFrench_uk
@EdFrench_uk Жыл бұрын
@@AndreasSpiess I think it's the 32Khz RTC xtal. I guess that allows the RTC to keep the radio active at the right intervals somehow?
@thanks600
@thanks600 Жыл бұрын
Nrf also use optional 2nd xtal for rtc.
@john_hind
@john_hind Жыл бұрын
(Useful AND Interesting) as always! How about a look at Python development options? As far as I can see CircuitPython supports the Peripheral case but not (yet) Central. A long term project of mine is a modern version of the HP-41C calculator with HP-IL/HP-IB reimagined over BLE, and Python programmability. I'd like to define a generic instrumentation GATT profile with value, units expressed as SI dimensions, and error bars.
@AndreasSpiess
@AndreasSpiess Жыл бұрын
Sounds like an interesting project! Concerning micro-Python. I tried two times to present higher languages for microcontrollers and the feedback was not favorable. So I will wait for a few years till my next try ;-)
@yekutielbenheshel354
@yekutielbenheshel354 Жыл бұрын
Excellent... as usual! As i have frequently commented, I think your videos are generally excellent Really, I think they are. Nonetheless, to increase viewership, I think it would help if you were to create interesting projects such as, "Here's a simple electric heater that can be built for 20 euros that you could use to maintain the temperature of your bath water while you are taking a bath." Or, "For 15 euros a 'let the dog out' reminder can be built. This will send you a message on your phone to remind you to let your dog out within X minutes after his dog bowl has been emptied of food (after he has eaten his dinner)." Currently, it seems that your channel is unnecessarily too narrowly focused on projects that appeal to, too few people. In addition, your channel could be more interesting for your current viewers. I'm not bashing you at all. This channel is a real gem (treasure). But it's essentially buried treasure because most of its prospective viewers will never watch it. Why not? A title like, "NRF52 Bluetooth (BLE) Tutorial. Does it consume less than the ESP32? (Feather, XIAO, ItsyBitsy)" probably isn't going to get them to watch, because it's probably unintelligible to them. By contrast, "Keep your wife in hot water with a €20 DIY bath tub heater" is the kind of tantalizing title that probably would appeal to guys who like to build stuff but aren't yet building stuff with microelectronics.
@ericbwertz
@ericbwertz Жыл бұрын
Most people are doing little projects like you seem to be asking for, so there are plenty of other channels out there for that already. This channel is intended for non-beginners and this is why it's attractive to that audience. If you want a beginner's channel, then I'd suggest Adafruit's channel for you, or just go to Instructables where people do the projects you seem to be looking for. Regards.
@yekutielbenheshel354
@yekutielbenheshel354 Жыл бұрын
​@@ericbwertz Huh? What? I'm not sure what your background is, but from my perspective, this channel seems to be targeted at beginners who have little or no experience whatsoever with micro-controllers. Don't get me wrong: Andreas does a great job. But there's nothing on this channel that I've ever seen which I would consider to even be intermediate level, let alone advanced. Adafruit's channel is unwatchable to me. To me, their channel is essentially, "Electronics for Children Aged 8 to 12." I'm trying to prod Andreas to focus on simple projects because, then, perhaps, he might eventually create some intermediate and advanced projects. "Oh look, I received a notification that the postman delivered the mail!" To me that's a simple beginner project. It seems suitable for high school students taking a class entitled, "Introduction to Micro-Controllers."
@ericbwertz
@ericbwertz Жыл бұрын
@@yekutielbenheshel354 I don't really agree about who you think that the audience is here, but do about Adafruit's content generally. The only exceptions there are Scott's Friday live coding show and some of the guest projects on Show and Tell. Otherwise they mostly do seem assume (or pretend, or want) that most of their audience are early/mid-teenagers. I haven't seen any inclination that Andreas wants to do projects here. He seems to enjoy doing product evaluations and comparison, and focused technology demonstrations and explorations. By the way, you may want to check out Great Scott's channel. I haven't been there for years, but Hackaday used to have a lot of pointers to interesting projects that people were working on, so you may want to look there also. Regards.
@yekutielbenheshel354
@yekutielbenheshel354 Жыл бұрын
@@ericbwertz I suppose some people think Andreas’ videos on this channel are aimed at advanced beginners or perhaps even low intermediate students. That’s fine. Everyone has their own perspective. From my perspective, Andreas’ videos on this channel are aimed at novices. That is not a veiled criticism; that’s merely my opinion. Generally I dislike Great Scott's channel. Although I think Great Scott really is great, his channel content rarely interests me. Once in a while I come across an article which I find valuable on Hackaday, but mostly I find it to be a waste of my time. The whole premise of Hackaday leaves me cold because I almost invariably refuse to waste my time on obsolete, “retro tech.” From my vantage point, trying to revive some obsolete piece of technology that guys used to play with when they were kids is foolish. Put obsolete tech in a museum, or a recycling center, or a landfill. But keep it far away from me. I agree with your sentiment that Andreas doesn't seem to want to work on complex projects on this channel. In and of themselves, his toy projects themselves are mostly worthless to me. Don't get me wrong: Andreas does a great job. I assume some high schools and universities actually use his videos in their introduction to microelectronics classes. Of course, for toy projects C/C++ is fine because C/C++ is often easy to use for toy projects. But for more complex projects (such as many commercial projects) developing with C/C++ code is often (but of course not always) unnecessarily time-consuming and tedious. It’s well-known that languages like MicroPython and TinyGo have the potential to dramatically lower the cost of producing many IoT products. When, for example, the performance benefits of C/C++ aren’t needed, MicroPython or TinyGo are often better choices for building many IoT products. Sure, they are immature, incomplete languages. I know that. Furthermore, languages such as MicroPython and TinyGo also tend to enable “regular” software engineers (not only “embedded engineers”) to more easily develop software for embedded devices without having to delve too deeply into the world of embedded engineering generally, nor C/C++ in particular. Andreas' product evaluations and comparisons are valuable to me. His methodical and redundant "Swiss approach" lends itself very nicely to evaluating and reviewing products. On this channel, Andreas is great at what he does. But I wish he’d do, something like, for example, a 30 part series on an automated solution for retrieving his mail, which his “Postman who doesn’t ring twice” (Jack Nicholson’s real-life persona disgusts me) has delivered, and which then slices a slit in each envelope, and finally places each slitted yet unopened envelope on a table. IoT has a bad reputation for a good reason: too many people spend too much time promoting their toy projects including, by the way, manufacturers. (I’m looking at you Samsung! Stop putting ridiculous IoT features into, say, dishwashers and refrigerators in order to jack up the prices and reap greater profits). Toy projects are relatively easy. Sure, toy projects are often excellent learning tools. But most real projects sold to real customers require engineers to resolve many vexing problems, which usually don’t show up in toy projects. When he bothers to actually do a toy project, to me, it’s as if Andreas metaphorically demonstrates how to build a dog house. That’s nice, but not enough for me. See, “I want more!” (Where have I heard that before? Has some guy with a Swiss accent harped on that point for years?/s sarcasm). Metaphorically, instead of building dog houses, eventually I want to see Andreas build, say, a kitchen or a bathroom. In other words, I want him to build more complex projects which utilize microelectronics. Will he do that? I doubt it. But, I hope he does. Andreas is an excellent teacher. Of course toy engineering is a great way to get started. But I despise the popular approach in most university engineering curricula that focuses far too much on theory and far too little on practice. Real world engineering projects are often remarkably complex and vexing. The best way to learn how to build them, is, of course, to build them. Frankly, I am contemptuous of university engineering departments that award diplomas to students who haven’t actually built real (and useful) projects for real people to use in the real world. Theory is crucial. But it’s merely a foundation for actual practice. Trying to deal with so-called engineers, who cannot solve relatively simple problems, has been a vexing problem I’ve encountered so often, that I have become habituated implicitly assume that any engineer whom I have begun to work for the first time with is “incompetent until proven otherwise.” The world is full of university students who are studying engineering. But because their education is based primarily on theory and simple toy projects, most of them don’t learn how to be good engineers. I find this sad state of affairs extremely disheartening. If you want someone to learn how to build houses, at some point, you should have them actually build houses… as part of their formal education. Teaching with toy projects is a great start. But it’s not enough. “I want more!”
@sharpbends
@sharpbends Жыл бұрын
Excellent video, thank you :-)
@AndreasSpiess
@AndreasSpiess Жыл бұрын
You are welcome!
@ericsibert1757
@ericsibert1757 Жыл бұрын
2 years ago, I investigated nrf52840 boards to make a low power data logger (for rain gauge first) and use BT to unload data (with a goal of 3 years autonomy, at list with a 1/2AA LiSOCl2 battery). Best arduino support seems provided by adafruit but should also apply to sparkfun products (I should check the whole list in your video). Only Adafruit nrf52840 boards provide additional memory available for user, up to 2 MB. I made a first device with the Feather board. Indeed, power consumption at idle (without BT) is between 600 µA and 1 mA, due to the RGB LED that is drawing 600 µA off. I will try to unsolder that LED, which may be more accessible on ItsyBitsy than on Feather. If I can go bellow 100 µA, it should be enough to go for 3 years operation. Otherwise, I may apply other tricks like bypassing the LDO and battery voltage divider (and go for coin cell???).
@AndreasSpiess
@AndreasSpiess Жыл бұрын
Nice project! Pay attention with coin cells. They cannot provide a lot of current. So maybe you need capacitors to buffer the power peaks of the BLE transmitter. They are short, but high (compared with the microamperes in normal operation)
@ericsibert1757
@ericsibert1757 Жыл бұрын
Thanks for your answer. If I go down to the coin cell level, I will take a look at your tip.
@rickharold7884
@rickharold7884 Жыл бұрын
Awesomeness. Thx!
@AndreasSpiess
@AndreasSpiess Жыл бұрын
You are welcome!
@zyghom
@zyghom Жыл бұрын
the only problem is: chip only (NRF52840) costs around 9$ while ESP32 chip cost 10x less. So for particular well thought project it is ok, but for day to day thinkering... quite expensive.
@jeffking3693
@jeffking3693 Жыл бұрын
and for high volume products as well.
@AndreasSpiess
@AndreasSpiess Жыл бұрын
I agree.
@MaxGoddur
@MaxGoddur Жыл бұрын
Sorry to jump in but was sitting in the front row and missed if you have ever done a video or the T-PicoC3 from LiilyGo? Thank you for your great videos. Go solar!
@AndreasSpiess
@AndreasSpiess Жыл бұрын
No, I did not do such a video.
@madararam2853
@madararam2853 Жыл бұрын
Genius one!
@AndreasSpiess
@AndreasSpiess Жыл бұрын
:-)
@rrhprosser
@rrhprosser Жыл бұрын
Note that the mbed web IDE also supports at least the older nrf51 chips. The new Keil cloud (free version) replaces this and also supports the nrf52 series. Not many examples available so far however.
@Podemosllegaralossubs-ty7bq
@Podemosllegaralossubs-ty7bq Жыл бұрын
Always interesting to see other people using these chips. I started getting into Segger embedded studio to program them and have got rather out of my depth. Partly because I'm determined to use ANT+. One day maybe it will make sence and the benefit is the Arduino IDE now looks simple.
@AndreasSpiess
@AndreasSpiess Жыл бұрын
The ecosystem is the most important advantage of the Arduino IDE…
@topphemelig
@topphemelig Жыл бұрын
I work with the nRF52840 at work, and when I use their SDK I get about ~30µA during an active BLE connection. The UART controller on the board seems to use alot of power when enabled (~600µA), which seems close to the idle consumption at around 12:20 (or maybe it is the sensor itself) :)
@AndreasSpiess
@AndreasSpiess Жыл бұрын
Good info. Thanks!
@DUDA-__-
@DUDA-__- Жыл бұрын
I have some nice!nano v2 here those have the nrf52 too. They have native battery pins and have a great size to pin ratio.
@AndreasSpiess
@AndreasSpiess Жыл бұрын
:-)
@funkymonk2254
@funkymonk2254 Жыл бұрын
Thanks Andreas.
@AndreasSpiess
@AndreasSpiess Жыл бұрын
You are welcome!
@virginiaperez8971
@virginiaperez8971 Жыл бұрын
vous etes un genie merci
@AndreasSpiess
@AndreasSpiess Жыл бұрын
De rien!
@uwezimmermann5427
@uwezimmermann5427 Жыл бұрын
Platformio appears to be supporting quite a few NRF52-boards, both with the Arduino framework and Zephyr RTOS. Not that I have any experience with these boards or any RTOS - but perhaps it's worth while looking into it again (and to abandon Arduino IDE for good).
@AndreasSpiess
@AndreasSpiess Жыл бұрын
Zephyr is on my list. We will see…
@toastrecon
@toastrecon Жыл бұрын
I was just looking to see if you could program it to transmit less power, or at a lower data rate, or both. I remember that the WSPR network from Ham radio does this thing where they transmit at three different power levels on a cycle. Depending on your application, maybe you could program it to send out a low, medium, and high chirp, with a second between them. Some people would get it right away, some might need to get pretty close. Maybe also the beacons have antennae built into the cases that are much larger or better tuned than the ones on the PCB.
@AndreasSpiess
@AndreasSpiess Жыл бұрын
You can reduce the power with a command. And for sure, this also would reduce power consumption. I did not try it.
@toastrecon
@toastrecon Жыл бұрын
@@AndreasSpiess can it “tell” when it gets interrogated? Maybe have it go into a less frequent broadcast mode when it doesn’t have anyone using it. Then, if it does start getting used, you could have it “wake up” and broadcast more. Like if it was a beacon at an art show, it’d be more active when tours were coming through.
@romarylucas6780
@romarylucas6780 Жыл бұрын
Great stuff as always ! What tools do you use to get that power consumption graph at 12:00 ??
@AndreasSpiess
@AndreasSpiess Жыл бұрын
I use the power profiler kit 2
@rakol96
@rakol96 28 күн бұрын
Great video :) what about range? I'm looking for transition over 30 meters. Should I look for BLE or BT classic?
@AndreasSpiess
@AndreasSpiess 26 күн бұрын
I do not know if there is a range difference between BLE and Bluetooth. 30m seems to be a lot with the onboard antennas.
@MSP_TechLab
@MSP_TechLab Жыл бұрын
Basically Nordic provides documentation and libraries for their chips. However unlike arduino the learning curve is very steep. It is easy to run demo, but once you need to run your own code it is pretty hard to debug. Because ble rf core is separate peace of code.
@AndreasSpiess
@AndreasSpiess Жыл бұрын
This is probably why I still stick to the Arduino IDE…
@tonysfun
@tonysfun Жыл бұрын
You are the best!!!
@AndreasSpiess
@AndreasSpiess Жыл бұрын
:-)
@maximilianmosimann8032
@maximilianmosimann8032 Жыл бұрын
Can you make any recommendations for low latency applications? I have a time critical application where I’d like to use one or multiple wireless push buttons to trigger an event on an Arduino (e.g. light up different LEDs). The latency should be in submillisecond range (preferably
@AndreasSpiess
@AndreasSpiess Жыл бұрын
Low latency on the receiver always means high power consumption because the receiver has to be always on. I suggest the simplest protocol you can find for your application like 433 MHz. But keep in mind that it will not work if two buttons are pressed the same time.
@alanclarke7868
@alanclarke7868 Ай бұрын
Excellent video. I'm new to Arduino, and nRF. Why do you need to put Adafruit's bootloader onto the Seeed device? Arduino code seems to upload no problem to it as it comes from the factory.
@AndreasSpiess
@AndreasSpiess Ай бұрын
This is an old video. So maybe things changed by now.
@felipefranciosi398
@felipefranciosi398 2 ай бұрын
Great video! Many thanks. Did you ever evaluate and find a good solution for low power _scanning_? I find that full duty cycle RX consumes a lot of power, especially on the ESP32.
@AndreasSpiess
@AndreasSpiess 2 ай бұрын
I did no more use the ESP32 for BLE other than a gateway connected to mains.
@MandoRick1978
@MandoRick1978 Жыл бұрын
Excellent video, thank you. My understanding from the datasheet of the U-blox Nina W102 is that it also uses an esp32 chip. Is that correct Jedi Spiess? I have been playing with the nano rp2040 connect recently and I very much like it apart from the flimsy wifi antenna. My first one broke off by accident from a 1 meter drop. I noticed the second one I got from arduino now has a blob of hot glue or epoxy resin holding the antenna in place as additional strength. They are not cheap but I have had great success using it in my weather station. I was going to use an ESP32 but my simple brain could not get all the hardware to play nice. Lucky for me, old Philhower III saved my butt. Thx again Earle. His board manager made my project possible.
@Podemosllegaralossubs-ty7bq
@Podemosllegaralossubs-ty7bq Жыл бұрын
Excellent video, thank you. My understanding from the datasheet of the U-blox Nina W102 is that it also uses an esp32 chip. Is that correct Jedi Spiess? I have been playing with the nano rp2040 connect recently and I very much like it apart from the flimsy wifi antenna. My first one broke off by accident from a 1 meter drop. I noticed the second one I got from arduino now has a blob of hot glue or epoxy resin holding the antenna in place as additional strength. They are not cheap but I have had great success using it in my weather station. I was going to use an ESP32 but my simple brain could not get all the hardware to play nice. Lucky for me, old Philhower III saved my butt. Thx again Earle. His board manager made my project possible.
@AndreasSpiess
@AndreasSpiess Жыл бұрын
Yes, the Nina W102 uses an ESP32.
@IgorJeri
@IgorJeri Жыл бұрын
Thanks
@AndreasSpiess
@AndreasSpiess Жыл бұрын
You are welcome!
@AndreasSpiess
@AndreasSpiess Жыл бұрын
I just saw your Super Thanks on my PC (it is not displayed on the IPad). Thank you for your support!
@McTroyd
@McTroyd Жыл бұрын
Aside from the ongoing chip shortages plaguing everyone, I've found Lady Ada's operation has been making things incrementally cheaper over the last few years. I was shocked to learn her company was offering an ESP32 (bare module, but still) for US$4 a year or so ago. With a warehouse and staff in the middle of Manhattan, New York City, I don't know how she manages to balance this. Maybe her manufacturing scale has just become that large? It's an engineering marvel in itself. 👍️
@akhurash
@akhurash Жыл бұрын
I wonder the same. I think they use the model of selling cheaper but at a bigger volume to make up for the price. Adafruit has also grown quite a lot since their competition days with Sparkfun. It’s one of the largest small scale electronics manufacturer in the USA.
@ericbwertz
@ericbwertz Жыл бұрын
That ESP32 module is almost certainly the one straight from Espressif that they've marked-up because some people don't want to get them straight from DigiKey for less. I wouldn't say that they've been making things cheaper, but they have consistently made stuff at a decent price (especially as a US company). Some prices DO go up though. Their STM32 Feather went from $25 to $40 6-12 months ago. All in all they do a good job of running the company though in most respects.
@AndreasSpiess
@AndreasSpiess Жыл бұрын
A major problem of Adafruit is the global distribution cost. For the US they are a good solution. For Europe shipping adds a lot of cost…
@McTroyd
@McTroyd Жыл бұрын
@@AndreasSpiess I believe it. Does Digikey distribute in Switzerland? I know Adafruit sells on there as well.
@AndreasSpiess
@AndreasSpiess Жыл бұрын
@@McTroyd I can order from Digikey. But there is a minimum of 60 dollars if I remember right.
@Ownedyou
@Ownedyou Жыл бұрын
Wasn't the first Arduino with nRF 52840 the Arduino Primo? Would love to see a vid going in depth on the BLE 5 ultra logn range mode.
@AndreasSpiess
@AndreasSpiess Жыл бұрын
I never heard of the Arduino Primo :-(
@Ownedyou
@Ownedyou Жыл бұрын
@@AndreasSpiess Primo was a board that was made in about 2017 and discontinued sometime on 2018. It was interesting becasue it came as a package of 2 boards: main one with Uno form factor and a tiny one (like Adafruit lillypad) that you flashed by connecting to tghe main board. Great board, but Nordic chips work best in their own environment.
@ghlscitel6714
@ghlscitel6714 Жыл бұрын
Grüezi! Does the NRF52 support the Fraunhofer IIS Bluetooth LC3/LC3plus audio protocols? Did the LC3 codec ever come to your awareness anywhere else?
@AndreasSpiess
@AndreasSpiess Жыл бұрын
I do not know. Maybe the datasheet knows?
@srknyxl
@srknyxl 8 ай бұрын
What model of power analyzer are you using?
@AndreasSpiess
@AndreasSpiess 8 ай бұрын
Mostly, I use Nordic's Power Profiler II because it is small and convenient.
@Xkam555
@Xkam555 Жыл бұрын
Your video is making me want to switch MCU in my project again, as I’m looking to implement wireless communication, and ESP power consumption is to high. How does NRF52840 ADC performance compare to STM32? Is it somewhat comparable, or is it on ESP32 level and basically needs external ADC?
@AndreasSpiess
@AndreasSpiess Жыл бұрын
I never worked with the NRF ADC, so I do not know.
@waynekeenansvideos
@waynekeenansvideos Жыл бұрын
It's possible to switch of RAM banks. The Arduino libs wouldn't do this by default, unless it is in 'system off' low power mode, which resets on wake so RAM contents not matter anyway. dont know if any expose this as an option. It's best to get a board that has the external 32kHz oscillator, Low Frequency Clock (LFCLK) in the docs, as this further reduces power consumption, and ensure any Aruino library you are using enables it.
@Podemosllegaralossubs-ty7bq
@Podemosllegaralossubs-ty7bq Жыл бұрын
Your summary and "conclusions" lead me to consider using the "coin-cell beacon" as a stand-alone, local slave, which serves NRF52840 timed interrupts. .. So, the NRF board need only "wake itself up" and "ask" the coin-cell beacon for the most recent sensor value .. Maybe, the NRF update interval could be increased until the entire "system" could run for one year, on minimum battery resources. (Yes, "an expedient hack" but, for a tired,. old engineer, who values time over money, such an expedient kludge could be a *good thing!).
@AndreasSpiess
@AndreasSpiess Жыл бұрын
Maybe somebody will create a small low power library with examples…
@Natepwnsu
@Natepwnsu Жыл бұрын
HyperX has managed to get 300 hours of operation from a single 5.5v cell in their new cloud headset. Maybe buying one and pulling the board and Bluetooth controller out might answer your question. The new chips use like .7miliamps , which is very impressive.
@AndreasSpiess
@AndreasSpiess Жыл бұрын
Astonishing! Usually this is the result of good hardware and good software…
@fundorinlive
@fundorinlive Жыл бұрын
Hello. I just got myself TTGo 1.5 from Aliexpress. It has 16 MB of storage space and pinout was slightly altered, as opposed to 1.4 version. I see that pins 16 and 17 were changed to 25 and 27, accordingly, but can't figure out how to properly edit "pins_arduino.h" table in the "variants" folder of platformio home dir. Can you help me with this? I was able to change board_build.partitions = default_16MB.csv from default one to get more storage but still need to set up those pins.
@AndreasSpiess
@AndreasSpiess Жыл бұрын
You can change pinnumbers using a text editor. But I am not sure if this is needed.
@mecatronicsforeveryone9565
@mecatronicsforeveryone9565 Жыл бұрын
are you planning on doing a video on ESP32 S3. I mean comparison with others.
@AndreasSpiess
@AndreasSpiess Жыл бұрын
Maybe. Not decided yet…
@tszaboo4952
@tszaboo4952 Жыл бұрын
The NRF52 boards look interesting, they are just so expensive IMHO to just play around. They really should end at 10 USD for a fully featured board with USB type-C. The SOC alone is like 4 USD, so it has to be extra markup compared to ESP32 or Pi PICO.
@AndreasSpiess
@AndreasSpiess Жыл бұрын
These days most things are a bit pricey if compared with two years ago. One exception is Espressif. I do not know how they do it!
@twobob
@twobob Жыл бұрын
Does the Xiao have a power regulator? maybe you can fudge some of the feedback values to make it run a little lower. Perhaps the "power" can be put into a lower power mode via flags. total guesses
@AndreasSpiess
@AndreasSpiess Жыл бұрын
Both are valid proposals.
@ralphj4012
@ralphj4012 Жыл бұрын
it would be interesting to see the average current when using sleep mode, you mention that you were not using sleep. Sleep would be practical perhaps for the 1 second interval, but probably not for anything less.
@AndreasSpiess
@AndreasSpiess Жыл бұрын
I assume the code uses some sleep mode in the background. But I do not have more info :-(
@ralphj4012
@ralphj4012 Жыл бұрын
@@AndreasSpiess Ah, I was referring to your "no sleep function is used" ( 9:22 ) and wasn't sure whether it was accessible, usable, switched off or on etc. There is also an InPlay NanoBeacon (supposedly lowest power, no coding required), though I don't know how good these are.
@dariussaturno4568
@dariussaturno4568 Жыл бұрын
Greate video,sir you know how to setup internet with cable tv into a certain client on the other side for distribution,
@AndreasSpiess
@AndreasSpiess Жыл бұрын
No.
@DAVIDGREGORYKERR
@DAVIDGREGORYKERR 10 ай бұрын
What about the UDOO RYZEN V1000 Maker Board SBC which is ARDUINO compatible.
@AndreasSpiess
@AndreasSpiess 10 ай бұрын
This seems something completely different to what I showed in the video.
@thesimbon
@thesimbon Жыл бұрын
Also mysensors supports the nrf chips to transfer data
@AndreasSpiess
@AndreasSpiess Жыл бұрын
Good to know. Thanks.
@phrankus2009
@phrankus2009 Жыл бұрын
Your summary and "conclusions" lead me to consider using the "coin-cell beacon" as a stand-alone, local slave, which serves NRF52840 timed interrupts. .. So, the NRF board need only "wake itself up" and "ask" the coin-cell beacon for the most recent sensor value .. Maybe, the NRF update interval could be increased until the entire "system" could run for one year, on minimum battery resources. (Yes, "an expedient hack" but, for a tired,. old engineer, who values time over money, such an expedient kludge could be a *good thing!).
@AndreasSpiess
@AndreasSpiess Жыл бұрын
Maybe this will work. Somebody has to try it.
@andrewtitcombe8378
@andrewtitcombe8378 Жыл бұрын
I believe Nordic also support ANT+ and Bluetooth at the same. But had no success in running both at the same time on my Partical boards.
@AndreasSpiess
@AndreasSpiess Жыл бұрын
So far I had no usage for ANT+ …
@iggarpe1
@iggarpe1 Жыл бұрын
~25uA average consumption (also measured with PPK2) in my nRF52840 based custom system running what is basically a the UART example (1s announcement interval) + FreeRTOS. Something is really messed up either in the boards you used or in the Arduino core if your average is ~400uA.
@AndreasSpiess
@AndreasSpiess Жыл бұрын
Which board did you use?
@gpashok
@gpashok Жыл бұрын
Happy to know that, you could reach the 25uA average current. Can you please share details about the board and a code
@john-r-edge
@john-r-edge Жыл бұрын
Cat with microchips know a thing about power use - not quite true, but plenty of space for memes. Seriously tho there is a neat approach to power usage which is used on cat flaps which only open if the animal has an RFID chip whose ID matches a value stored in the door electronics. These doors are usually battery operated - with battery life often greater than a year. The neat idea is that they do not constantly generate the electrical field which is picked up by the RFID chip and powers it to transmit. Instead the cat door entrance tunnel (about 120mm long) contains an always-on (and very low power) motion sensor which detects the presence of an animal. That then switches on the RFID circuitry, generates the energizing field, and unlocks the door to the right cat. Having a very low power detector to activate a more power hungry (but smarter) detector is an approach which will be applicable in certain situations. Clever 🐈 😺 🐈 😺.
@AndreasSpiess
@AndreasSpiess Жыл бұрын
This is a good idea! RFID indeed consumes a lot of energy.
@fernandosantos3576
@fernandosantos3576 Жыл бұрын
Hi Andreas. The link to example code refers to a page that does not exist.
@AndreasSpiess
@AndreasSpiess Жыл бұрын
It should work now. Sorry!
@bickhofe
@bickhofe Жыл бұрын
Danke!
@AndreasSpiess
@AndreasSpiess Жыл бұрын
Gern geschehen!
@AndreasSpiess
@AndreasSpiess Жыл бұрын
Ich habe gerade dein Super Thanks auf dem PC gesehen. Auf dem iPad wurde er nicht angezeigt). Danke!
@MrJanulis
@MrJanulis Жыл бұрын
Finally!
@AndreasSpiess
@AndreasSpiess Жыл бұрын
:-)
@mathicalee
@mathicalee Жыл бұрын
I tried to learn zephyr. It has a hurdle at the start, but it seems good for me.
@AndreasSpiess
@AndreasSpiess Жыл бұрын
It is also on my list…
@Lion_McLionhead
@Lion_McLionhead Жыл бұрын
The lion kingdom programmed those with just the Nordic SDK & single wire debug. It was possible without any IDE. Only now does it become obvious how hard that was.
@Andrew-rc3vh
@Andrew-rc3vh Жыл бұрын
I think all boards get close to the theoretical maximum performance. You just have the trade-off between distance, power and data rate. All boards like the ESP32 which give 20db output on transmit will consume similar power on transmit. The NR52 chips seem to have good receive currents, but then I think this is because the ESP32 are beefier processors. Another thing you can try though is that some chips just give you the RF and leave it up to you to control it with your own processor, and if you want ultra low consumption then some people have tried using and ATtiny chip. After all the sensor only need to be a dumb machine.
@AndreasSpiess
@AndreasSpiess Жыл бұрын
The problem with the ESP32 is it’s long on-time. Much much longer than the signal length. The signal power is comparable, I agree
@Andrew-rc3vh
@Andrew-rc3vh Жыл бұрын
@@AndreasSpiess There are some tricks to get a transmit and power up spike which can be as short as 100ms. One which you probably know about is the static IP mode, but there are others as well. Take a look at this. Someone has rewritten the wifi libraries for speed. kzbin.info/www/bejne/f2TPe4qZh7ifi6M
@AndreasSpiess
@AndreasSpiess Жыл бұрын
I thought I talked about BLE in this video and not WiFi…
@stevenknudsen1446
@stevenknudsen1446 Жыл бұрын
If you want to get the true performance from nrf5x chips, the SDK is the way to go. I have never found it to be a problem in terms of development or debugging. I have found that RTOSes like mbed hide too much and force lowest common denominator functionality that cripples what you can do. For example, setting up for externally-triggered ISRs that have tight time constraints, the RTOS made it impossible. As ever, whatever works for you is best, but Nordics stuff is so good it’s worth investing some effort to learn the SDK and the ARM data sheet. Last, to get power usage that matches Nordic’s online calculator, I had to run bare metal. But it did match or exceed the online calc value.
@AndreasSpiess
@AndreasSpiess Жыл бұрын
You are right, you always get most out of a chip if you use the proprietary IDE. However, we want to be able to use the same IDE for different chips (Atmel, Espressif, STM). That is why I use the Arduino IDE on this channel.
@stevenknudsen1446
@stevenknudsen1446 Жыл бұрын
@@AndreasSpiess I believe you mean SDK as the IDE is usually independent of the processor. The Nordic SDK is really about managing the Bluetooth peripheral and represents the minimum allocation of resources to do that and still maintain efficiency and flexibility. Without it all you have is an ARM, with it, you have most of the bare metal functionality of the ARM plus Bluetooth, which is kind of the point. A similar nRF52-based board was recently released by XIAO and it has support in the Arduino system with and without mbed. Same IDE, same programming model, but with a ton hidden from the developer. This is fine if you are not making any serious demands on the board. YMMV.
@jaydeepbatra6909
@jaydeepbatra6909 6 ай бұрын
I need your help. I want to prepare a wireless subwoofer and a speaker connection with one Bluetooth, please confirm if it's possible..
@AndreasSpiess
@AndreasSpiess 6 ай бұрын
I am a KZbinr and no consultant. So it is not possible. But you get ready-made amplifier boards with bluetooth on AliExpress. That helps a lot, I think.
@TomLeg
@TomLeg Жыл бұрын
Excellent video! minor English lesson: Yes, adver-tis-ment, but advert-eyes-ing. Who designed this language, anyway?
@AndreasSpiess
@AndreasSpiess Жыл бұрын
Thanks!
@murraymadness4674
@murraymadness4674 Жыл бұрын
I built product using the nrf2401 and msp430 very low power, using straight gcc/gdb command line tools. And also got esp8266 working by downloading tons of glued together software before it had arduino support. Arduino ide so much simpler to use even if limited functionality. I was hoping the guy with the accent ;) would show how to update the bootloader in the nrf dongle so I can use it with the arduino ide like the feather. If you don't want to buy the $500 dongle, you can do it using openOCD..somehow, no simple tutorial on how.
@AndreasSpiess
@AndreasSpiess Жыл бұрын
OpenOCD is a very special topic and nothing for a mainstream channel like mine :-(
@soulprospector6931
@soulprospector6931 10 ай бұрын
Hello Andreas, I love your channel. I am experimenting with the Xaio NRF52 right now, and I was wondering if you knew of any desktop software that can be used to log sensor data from the chip over BLE.
@AndreasSpiess
@AndreasSpiess 10 ай бұрын
Unfortunately, I never used BLE on a desktop :-(
@SarahKchannel
@SarahKchannel Жыл бұрын
Xiao from the chinese, is pronounced with a swiss accent as "Schau", means little or small or something along those lines ;)
@AndreasSpiess
@AndreasSpiess Жыл бұрын
Thanks for the clarification!
@ysmsverige4179
@ysmsverige4179 Жыл бұрын
I have been playing with these chips quite a while. Major advantage is low power. If you programming using its own SDK.. you can get low level control and reduce power consumption further down. But note that recently I also read news that these chips have some security vulnerability... No idea if it has been resolved by nrf.
@kwakeham
@kwakeham Жыл бұрын
It's not been resolved, but also this vulnerability happened like 3 - 4 years ago. It's just that it only really got notable when people used that well documented vulnerability to get apple's firmware out of the nrf52832 they used. There are a lot of microcontrollers on the market with similar vulnerabilities and nobody does anything because it's a difficult (though now automated) physical attack and only if you're selling millions of units will you likely be targeted.
@AndreasSpiess
@AndreasSpiess Жыл бұрын
Thank you for the information!
@SinanAkkoyun
@SinanAkkoyun Жыл бұрын
❤❤️❤️❤️❤️
@AndreasSpiess
@AndreasSpiess Жыл бұрын
:-)
@user-uv6yv9pk6u
@user-uv6yv9pk6u 10 ай бұрын
I LOVE YOU
@AndreasSpiess
@AndreasSpiess 10 ай бұрын
:-)
@TrasteIAm
@TrasteIAm Жыл бұрын
The Nordic NRF52s need to go down in price and up in Open Source support before I would find them interesting for any practical use. Even bare NRF52840 chips are at a too high price point compared to existing ready-made BLE/ZigBee devices.
@AndreasSpiess
@AndreasSpiess Жыл бұрын
I agree that commercial BLE/Zigbee Devices are very cheap.
@mikejaras
@mikejaras Жыл бұрын
I cant't find the example code. Link ends with 404?
@AndreasSpiess
@AndreasSpiess Жыл бұрын
Now it should work. Sorry for the inconvenience.
@BinderTronics
@BinderTronics Жыл бұрын
These chips can do about 1.5uA with a average of 1mA (this is the lowest I got it to go). This involves some black magic with the internal PMC, how the IO and signal strength (antenna power) are managed . It is also required to use the deep sleep features and a damn good regulator in some cases. I believe the Arduino core only uses idle CPU state witch seems to be supported by the measurements you have shown. It was never required to use Segger Embedded Studio or Keil. Eclipse worked just fine. It just required some extra steps to install. A full guide is available on there site (last time I looked, way back when). Something with the dev boards available is that I have not found one that exposes the second IO port on the NRF52840. Fun fact the modules are made by a 3de party company called Raytac.
@AndreasSpiess
@AndreasSpiess Жыл бұрын
Good info. Maybe somebody will add a small low power library or change the examples to use these particular modes…
@pararera6394
@pararera6394 Жыл бұрын
Will you test HM-16 module?
@AndreasSpiess
@AndreasSpiess Жыл бұрын
So far I have no such plans.
@pararera6394
@pararera6394 Жыл бұрын
@@AndreasSpiess It would be nice to see it since its very popular for DIYs
@wm6h
@wm6h Жыл бұрын
As others have mentioned, the ESP32-C3 (RISC-V supported with Arduino IDE) might be worth checking out. And it doesn’t get any cuter and maybe cheaper than the M5Stamp C3U. Have a great summer and remember to ride the bike a little.
@AndreasSpiess
@AndreasSpiess Жыл бұрын
I once made a video about the C3 (mainly about RISC) . And I will ride both bikes extensively during summer…
@PriyankBolia
@PriyankBolia Жыл бұрын
Support by the maker, is not just a point, it is the most important point. Why do you think Arduino UNO is still sold in 2022?
@AndreasSpiess
@AndreasSpiess Жыл бұрын
Maybe they see it differently:-(
@algre977
@algre977 Жыл бұрын
Did you measure the current in receiver mode ?
@AndreasSpiess
@AndreasSpiess Жыл бұрын
Both mixed
@insanitywolf05
@insanitywolf05 Жыл бұрын
Scan mode is receive mode and it's very power hungry, drawing about 12mA
@algre977
@algre977 Жыл бұрын
@@insanitywolf05 is there a way to have a receiver constantly listening in ultra low power ?
@insanitywolf05
@insanitywolf05 Жыл бұрын
That's what BLE aims at by defining connection intervals (as far as I understand correctly) where data is exchanged so the rx does not have to be on all the time.
@savejeff15
@savejeff15 Жыл бұрын
FYI: The XIAOs Core ist just a fork of the standard nRF Arduino Core. They just added there board definition.
@insanitywolf05
@insanitywolf05 Жыл бұрын
True for v2.x (and it's crap), but v1.0.0 of the core is a fork of the adafruit nrf52 core but with a newer softdevice. I'm testing it at the moment and it seems to work quite well...
@savejeff15
@savejeff15 Жыл бұрын
@@insanitywolf05 i hate the fakt that they don't work together for a single Arduino core for every Architektur. The changes Seeed does to the official core are so small. They could have just asked for an inclusion in the official core. This means double the debuggingy support and features arriving late. Therefore the XIAO BLE went right into the unsed microcontroller Box. I habe enough old sparkfun and seed boards that are not supposed anymore and discontinued
@insanitywolf05
@insanitywolf05 Жыл бұрын
It should be a breeze to adapt the Adafruit nrf52 Bootloader to the xiao ble by just changing the led and button pins and recompiling. But I agree, nrf52 for Arduino is messy patchwork, but I like to hack around with it anyway. Let's face it: the 80mA the ESP32s pull have nothing to do with the Idea of BLE.
@savejeff15
@savejeff15 Жыл бұрын
@@insanitywolf05 hm. Maybe yes but you would have to maintain the fork for future updates and all. I'm only using Platform IO. They have there own version of the Arduino cores. There it might be simpler but still, why not combine all Boards of an architectur. About the BLE power consumption, that's something I didn't look into up to this point. I'm using BLE to connect to a smartphone while running continuously with multiple sensors. Here the energy usage is neglectable. Would be another story for ultra low power applications. Buts the ESP32 in general is not for ULP. It's more for constantly running IoT and sensor applications that have high performance requirements
@ericbwertz
@ericbwertz Жыл бұрын
@@savejeff15 The only company that does a decent job in this space is Adafruit, I have to say. You do get more and cheaper choices from Seeed, but they've always been a challenge to get anything resembling decent support from, except hardware replacement.
@kwakeham
@kwakeham Жыл бұрын
This current is literally 20 times higher than what we see with an nrf52832 and nrf52840 in our commercial designs. Yes, it's that bad to use this code. We have a 10 - 15hz keyboard emulator running at 20ua average. If you use the SDK and proper interrupts and such, it beats a lot of this maker stuff. Like there is no reason a ble keyboard couldn't run for months on a cr2032, but most diy stuff is measured in hours on 1000mah rechargeable.
@AndreasSpiess
@AndreasSpiess Жыл бұрын
That is what I thought. So we still have a lot of improvement…
@dmitrysysoletin9967
@dmitrysysoletin9967 Жыл бұрын
For sure, for applications that don't requires WiFi, Nordic is better. And Thread protocol for some sensor applications is better than BLE.
@Sdeadweather1023
@Sdeadweather1023 Жыл бұрын
I need some help you have telegram?
@AndreasSpiess
@AndreasSpiess Жыл бұрын
So far I did not see a lot of Thread projects. Do you have examples?
@dmitrysysoletin9967
@dmitrysysoletin9967 Жыл бұрын
@@AndreasSpiess Well, I have temperature/humidity sensors based on nRF52840 and Thread, just a hobby project. I can share firmware with you if you want. From the commercial side, if I remember correctly, Google Nest is Thread based.
@AndreasSpiess
@AndreasSpiess Жыл бұрын
@@dmitrysysoletin9967 Maybe you send me a message on Twitter or Facebook Messenger?
@ivuvu4065
@ivuvu4065 10 ай бұрын
wich is the smallest one?
@AndreasSpiess
@AndreasSpiess 10 ай бұрын
I do not understand your question :-(
@ivuvu4065
@ivuvu4065 10 ай бұрын
@@AndreasSpiess My question was.. Which of these micro devices is the smallest in size?
@AndreasSpiess
@AndreasSpiess 10 ай бұрын
@@ivuvu4065 Probably the XIAO
@Emre-Sunay-Gebes
@Emre-Sunay-Gebes Жыл бұрын
i still wonder how diy solar is going :)
@AndreasSpiess
@AndreasSpiess Жыл бұрын
It works fine!
Use the very attractive new ATTINY chips for your projects
14:34
Andreas Spiess
Рет қаралды 190 М.
Seeeduino XIAO - 32-bit Arduino-compatible Microcontroller
41:54
DroneBot Workshop
Рет қаралды 246 М.
Зомби Апокалипсис  часть 1 🤯#shorts
00:29
INNA SERG
Рет қаралды 1,9 МЛН
SMART GADGET FOR COOL PARENTS ☔️
00:30
123 GO! HOUSE
Рет қаралды 21 МЛН
I Trapped Myself in a Box with Colored Smoke!
00:50
A4
Рет қаралды 18 МЛН
Rutgers University Confirmed: Meshtastic and LoRa are dangerous
13:27
Andreas Spiess
Рет қаралды 718 М.
Master BLE Basics in Just 10 Minutes: The Ultimate Guide!
9:15
Novel Bits
Рет қаралды 86 М.
451 Which Processor can kill the ESP32?
11:24
Andreas Spiess
Рет қаралды 331 М.
ESP32 Guide 2024 | Choosing and Using an ESP32 Board
41:06
DroneBot Workshop
Рет қаралды 200 М.
We should use this amazing mechanism that's inside a grasshopper leg
19:19
What is Bluetooth Mesh?
9:47
Gary Explains
Рет қаралды 17 М.
How Neuralink Works 🧠
0:28
Zack D. Films
Рет қаралды 14 МЛН
Samsung mobile phone waterproof display. samsung mobile phone digital s23ultra  #shorts
0:15
Опасная флешка 🤯
0:22
FATA MORGANA
Рет қаралды 546 М.
КУПИЛ SAMSUNG GALAXY S24 ULTRA ЗА 88000 РУБЛЕЙ!
27:29