nRF5 action!
-
@d00616 said in nRF5 Bluetooth action!:
@rmtucker said in nRF5 Bluetooth action!:
@d00616 said in nRF5 Bluetooth action!:
I have used I2C with an display and u8g2 without any problem.
Yes But it seems to have trouble reading sensors.
It has been mentioned on sandeepmistry github.I have found this issue: https://github.com/sandeepmistry/arduino-nRF5/issues/180
Is this yours?
Does it rest entirely on Sandeep's shoulders as to if/when it gets fixed? I'm trying to understand how big/small the workforce is.
-
@rmtucker said in nRF5 Bluetooth action!:
@d00616
No not mine but that is the issue i was talking about.
When connecting DS3231 RTC i get the same as that guy mentions.
When connecting HTU21D the readings are all over the place.@scalz Have you encountered any I2C problems in your work on Aeos? I seem to recall you have a TH sensor in it.
-
@NeverDie
Actually i wonder if development has stopped?
no new commits in three months?
-
@NeverDie
Trouble is the aeos is using nrf52 not nrf51.
-
@rmtucker said in nRF5 Bluetooth action!:
@NeverDie
Trouble is the aeos is using nrf52 not nrf51.At least it would be something, rather than nothing. Wouldn't you rather be on nRF52 anyway? It has advantages. (I say that even though I do have some nRF51's on order, but only just because they're small and cheap).
-
@NeverDie
yes but it would take 4-6weeks and i was impatient so thought i would start with what i could get.
But it seems it does not work on either looking at some of the other issues on sandeeps github.
-
@rmtucker
Hmmmm... Maybe this explains why I didn't notice any MySensor's example demo code that used I2C.On the other hand, I wouldn't think the gap can be all that big if d00616 is able to use I2C for display purposes.
Still, that by itself doesn't get you there.
-
Bummer. I guess you still have anticimex's suggestion though of the bit-bang workaround, if you're so inclined. If you're able to get that to work, please do post to let us know.
-
@NeverDie i have no problem with my aeos (nrf52) and i2c so far. only tested the onboard sensors.
agree, in case, you can use a software i2c lib.
-
On the 10F supercap, the infor-link module was losing about 0.025v per hour, and that included it reporting its voltage every 5 minutes. So, I've hooked it up to a mini solar panel now so that the supercap will charge during daytime, and with that it should run in perpetuity.
-
@NeverDie nice results! What kind of overcharge protection are you using?
-
@mfalkvidd said in nRF5 Bluetooth action!:
@NeverDie nice results! What kind of overcharge protection are you using?
A 2.7v LDO. Very low quiescent current of just 1ua.
-
@NeverDie thanks. My first supercap is on the way so I'm looking forward to build something with it.
-
@rmtucker
I notice someone on AliExpress is selling a similar concept for the nRF52832 to what you're using for the nRF51:
https://www.aliexpress.com/item/NRF52832-Development-Board-NRF52832-Test-Board-Bluetooth-BLE4-2/32824948546.html?spm=2114.search0104.3.1.YoEIHi&ws_ab_test=searchweb0_0,searchweb201602_4_10152_10065_10151_10068_10130_5430020_5410020_10307_10137_10060_10155_10154_5370011_10056_10055_10054_10059_100031_10099_5400020_10103_10102_10052_10053_10142_10107_10050_10051_5380020_5390020_10084_10083_10119_10080_10082_10081_10178_10110_10111_10112_10113_10114_10312_10313_10314_10315_10078_10079_10073_10120_5420011,searchweb201603_19,ppcSwitch_4&btsid=abd93cae-a709-47f9-989d-0c52b4cde846&algo_expid=450d3875-3c65-41c4-99a8-0a2b5eb4479e-0&algo_pvid=450d3875-3c65-41c4-99a8-0a2b5eb4479e&transAbTest=ae803_3
-
I did another sleep current measurement, this time on a Ebyte module that I had mounted to one of my breakout boards. The sleep current measured between 8ua and 9ua. However, it would jump considerably higher depending on whether I was moving or otherwise close to it. I got the lower measurements by positioning myself about 6 feet away (further than that and it gets hard to read the multimeter that's connected to the uCurrent Gold). I've never seen this kind of behavior before in anything other than the nrf52832 boards. Very curious. They're acting almost like proximity detectors. I have no idea what to make of it, but I thought I'd report it in case anyone else here is doing measurements too.
Also, I'm going to avoid exposing the IO pins to voltages that approach Vcc in magnitude. Despite what the datasheet says, they don't seem to handle it well.
-
@Mike_Lemo said in nRF5 Bluetooth action!:
Does anybody know why the function tone() doesn't work for the nrf52?
tone() and other things like NFC are implemented with the new Arduino Primo board. There is no MySensors support at the moment because the Primo comes with the SoftDevice which doesn't allow accessing the complete hardware without using the SoftDevice API, which is not implemented.
-
What you using for pcb design?
I would like to design something for the waveshare core board to plug into similar to what you just designed for the nrf52832 modules to adapt to 2.54mm pitch headers.
Similar to what you did here but with two sockets on top for the waveshare board.
https://www.openhardware.io/view/436/nRF52832-Breakout-Board
-
@rmtucker said in nRF5 Bluetooth action!:
What you using for pcb design?
Diptrace.
Very easy to learn. Watch this tutorial series, and in a little more than an hour you'll know enough to use it for doing real work: https://www.youtube.com/playlist?list=PLWy-YwxbAu8EkNv6iMsfLeH6Yahcwejwx
-
@rmtucker said in nRF5 Bluetooth action!:
What you using for pcb design?
However, if you have the time to invest, you might want to learn KiCAD instead (http://kicad-pcb.org/). It's open source and free.
My only real concern about Diptrace is that sharing source files is very, very difficult. Eagle is much better for that, it seems. I'm guessing KiCAD is also good with that, but I can't say that I know for sure.
-
If I was starting, it would be with Kicad.
-
@Nca78
Is it easy to share source files in KiCAD?
-
@NeverDie in KiCAD format, I suppose But even if it's not easy at least anyone can download Kicad and open them to at have a look without beeing block if you have more than two layers, or too big board.
I'm still using Eagle at the moment, it's the most common software but the changes made in what you can do with the free licence + limitation of PCB size are annoying. At some point I'll have to be strong and make the move to KiCAD...
-
before you design your own board:
-
@Toyman
Yes i am already running that board at the moment.
But that board consumes around 140uA when sleeping.
It must be the extra electronics like the regulator and uart.
even when feeding the core board with 3.3v directly.
When the core board is on its own it only measures 5uA when sleeping.
-
This nRF52832 module looks to be pretty small, and it has both oscillators on it.
-
Help needed!! I am trying to program nrf51822 with Black Magic Probe , but BMP is not recognized by Arduino IDE.
I can do everything in gdb, e.g. do mass erase, upload soft device etc, but BMP is simply not listed in programmers' list in Arduino IDE so I can't upload sketches.
-
Could anyone tell me why the waveshare board is pulling 140uA when sleeping with everything unpugged including the usb and all the header jumpers so only 3.3v and ground fed to the header pins so not using the regulator etc.
I have attached a link to the schematic hoping some circuit wiz might be able to explain.
link textIf i unplug the core board and just power that with 3.3v and gnd it only uses 5uA when sleeping.
-
Even if you're not using the regulator and the CP2102 usb-serial converter there are some leakage currents which are caused by the output stages of those IC's. For example the output stage of the voltage regulator can draw some even if it's not powered. The CP2102 can draw also through the TXD1/RXD1/SUSPEND1 LEDs and the associated GPIO pins P0.11, P0.09, etc.
So to prove and test that the above it's true you need to:
- Desolder the RT9193-33 or at least its output pin(Vout pin 5)
- Desolder R6, R7, R10
This is what I can conclude by looking at that schematic. Any other opinions?
-
@mtiutiu said in nRF5 Bluetooth action!:
Any other opinions?
Yes. If it really matters that much, RMTucker should buy or make a uCurrent Gold. Otherwise, he'll find hmself chasing phantoms. I have a Fluke 87V, and I don't trust it to do these types of measurements (I've tried, and the results are just wrong when compared to a uCurrent Gold). I would trust a crappy multimeter even less. Been there and tried that already.
Just my two cents.
-
BTW, uCurrent Gold is open source. I have an original, but you can buy clones. For instance, LowPowerLab sells a clone. You might get it faster than ordering from Australia.... unless you live in Australia. Dave Jones did a video for me once, and so I thought he deserved the profit instead of somebody else.
-
@NeverDie said in nRF5 Bluetooth action!:
@mtiutiu said in nRF5 Bluetooth action!:
Any other opinions?
Yes. If it really matters that much, RMTucker should buy or make a uCurrent Gold. Otherwise, he'll find hmself chasing phantoms. I have a Fluke 87V, and I don't trust it to do these types of measurements (I've tried, and the results are just wrong when compared to a uCurrent Gold). I would trust a crappy multimeter even less. Been there and tried that already.
Just my two cents.
It just depends on the burden voltage, no ? It's proportional to current in the circuit so in sleep mode when measuring around 10 uA it should be negligible.
Anyway I measure when powered with 3.3V so I'm sure what I measure is higher than what I will get in reality when circuit is powered with a 3V battery.
-
For measuring small currents I'm using Texas Instruments EnergyTrace piece of technology and it works pretty well. You just need one of their development boards with energytrace special microcontroller embedded which is very cheap. More infos here: http://43oh.com/2015/09/how-to-measure-an-energia-applications-power-usage-with-energytrace/
It can be used to measure other boards power usage also - you just need to take of some jumpers and plug in your external board.
It gives you real time energy measurements and with plotting too(and battery life estimation is displayed real time too). No need to worry about burden voltage and other external factors which affect the measurements.
-
@mtiutiu
I think maybe the nRF52 DK also has some energy measurement capability, but I haven't looked into it.
-
-
Looks like I was wrong earlier about the voltage reference being Vcc when doing an analog read on a pin. Instead, it seems to be a fixed reference. In any case, I'm getting better results with an expression like this, which is independent of Vcc:
millivolts = (analogRead(PIN)*3000/4095)
What are others here doing in this case?
-
@NeverDie
As mentioned earlier by someone the nrf52 is preset to 0.6v internal ref and a 1/5 divider so 0 - 3v is the max input so your calculation is correct.
The nrf51 is different because the ref can be set to a few different settings but the default is vdd.
-
Is RSSI reporting implemented in the NRF5 setup yet?
If so how is it done?
-
I don't think sendSignalStrength function is implemented yet, but you should be able to get this info with:
int16_t transportGetSendingRSSI(void) int16_t transportGetReceivingRSSI(void)
-
How can I redefine UART pins in nrf51822? For example, if I want to have p13 as uart tx?
-
@Toyman
it has been explained above in the topic
you have to follow
-
@scalz
Rssi works really well.
Thank you.
-
So range test.
Using esp8266 with standard nrf24 not amplified gateway at one end of the house.
Nrf51822 node in garage which is not fastened to house so at a guess 15m through 3 brick walls is reporting -86db.
I think that is quite respectable.;-)
-
@scalz thx.
-
Regarding the PCB/KiCad comments.
I was trying out KiCad and copied the NRF52832 DC/DC schematic from the datasheet.It might be of help for someone.
https://github.com/Omemanti/KiCAD/tree/master/NRF52832PS. been at KiCad for a couple of hours, been used to Eagle, so please double check.
-
@rmtucker said in nRF5 Bluetooth action!:
@NeverDie
As mentioned earlier by someone the nrf52 is preset to 0.6v internal ref and a 1/5 divider so 0 - 3v is the max input so your calculation is correct.
The nrf51 is different because the ref can be set to a few different settings but the default is vdd.I've lately found that I seem to get a more accurate measurement if I multiply by 3131 instead of 3000. Just an empirical result with no real theory behind it.
-
I don't know if it is actually related, but I'll post the link to this programmer
adafruit.com/product/3571
-
What's going to be the best way to reduce the sleep current and Tx current on the nRF52? Since I'm feeding off a supercap for power, it's noticeably worse (by an order of magnitude) on the same task than the atmega328p+rfm69 combo. I've already increased the datarate to 2mbps, and it's inherently lower Tx current should give it a natural advantage.
I guess I'll try reducing Tx power and see if that makes much of a dent....
I suppose reducing 3 separate packets to one single packet, and maybe turning off ACK requests might also help. Then, maybe all of the LONG_WAIT's can be eliminated. Is the radio still awake even if the CPU is sleeping during a "wait" period? If so, that might be a large chunk of the wasted power.
I wonder if the mysensors mesh networking (which I don't intend to use) might be getting in the way, and possibly keeping it awake longer than it otherwise would be? Can I disable the mysensors meshnetworking just to be sure?
Sorry for the shotgun blast of questions, but I'm trying to get a sense of what will yield the highest payoff.
-
Since I'll be reducing Tx power in an attempt to reduce current consumption, I'll be using a scanner program to try to find empty channels. The only one I know of is: https://github.com/nRF24/RF24/tree/master/examples/scanner
for the nRF24L01, but it seems to work well enough if you let it run awhile. Anyone else using one that they like?
-
@NeverDie said in nRF5 Bluetooth action!:
Since I'll be reducing Tx power in an attempt to reduce current consumption, I'll be using a scanner program to try to find empty channels. The only one I know of is: https://github.com/nRF24/RF24/tree/master/examples/scanner
for the nRF24L01, but it seems to work well enough if you let it run awhile. Anyone else using one that they like?Nevermind. I see now that there's an entire entry on it:
https://forum.mysensors.org/topic/2454/node-cant-see-gateway-less-than-10m-away/11
-
@gohan said in nRF5 Bluetooth action!:
I don't know if it is actually related, but I'll post the link to this programmer
adafruit.com/product/3571Not sure it's even legal to use this if you ever plan to sell PCBs on openhardware.io ...
You may use the J-Link EDU for non profit educational purposes only! Non-profit educational purposes means that you >may not use the J-Link EDU and its J-Link software.
- direct or indirect in or for a profit organization or business purposes or other undertaking intended for profit
- direct or indirect in any other commercial environment (e.g. office)
- to develop, debug, program or manufacturer a commercial product (or parts thereof)
- to use it to either earn money or reasonably anticipate the receipt of monetary gain from it.
-
@Nca78 Educational versions of many things can not be used for commercial purposes, maybe they got an agreement as it will be sold primarily to hobbyists.
-
In my testing, NRF5_PA_LOW did offer some modest reduction in overall current consumption, but it's no silver bullet.
The range with NRF5_PA_MIN is just a few feet, so I don't consider it practical for the vast majority of use cases.
So, further reductions in current consumption will have to come from somewhere (?) else.
I suppose the next step is to turn-off auto ACK's and any listening for ACK's by the mote. Hopefully (?) there's a switch in myconfig which does that.
-
I have checked the current with my nRF52 board with integrated shunt. I have measured 6.5µA while sleeping until timeout or sleeping until interrupt. It doesn't matter if RX/TX are connected but after flashing the firmware a reset by removing the voltage is required.
There was an bug, with any type of sleep(0) which is fixed by this PR https://github.com/mysensors/MySensors/pull/909
-
Unless I'm doing it unwittingly, I'm not doing any sleep(0)'s at present.
-
I'm finding that having a very simple adapter board, such as that in the photo here, is quite convenient both for programming and for powering the nRF52832, and for wiring-up prototypes. I made my breakout board for breadboards, but those connections are always just too flakey. Maybe I need to use better breadboards? Anyhow, this meets the requirement for reliable, solid connections.
-
I removed this useless block of code from the main loop, which, with its long waits, may have been what was draining the power:
Serial.println(""); Serial.println(""); Serial.println(""); Serial.println("#########################"); randNumber=random(0,101); Serial.print("RandomNumber:"); Serial.println(randNumber); // Send fake battery level Serial.println("Send Battery Level"); sendBatteryLevel(randNumber); wait(LONG_WAIT); // Request time Serial.println("Request Time"); requestTime(); wait(LONG_WAIT);
-
@NeverDie
When you are comparing the atmega 328 and the nrf52 what sketch are you using to come to your conclusions?.
-
@rmtucker said in nRF5 Bluetooth action!:
@NeverDie
When you are comparing the atmega 328 and the nrf52 what sketch are you using to come to your conclusions?.A solar mote which reports the voltage on the supercap and the unloaded voltage on the solar panel.
The goal is to get the mote to be a solar powered remote, where it will wake up and listen for a packet once every 100ms and then go back to sleep if it doesn't receive one inside a very narrow window of time. That window can be a lot narrower on the nRF52302, because it supports 2Mbps, whereas the RFM69 can support at most 300kbps. I got the atmega328p+rfm69 to do that (although it required a larger than 10F supercap to get through the night), and it worked. At the present moment, though, I don't think the nrf52 can do it, unless I were to use an even bigger supercap and more than one mini solar panel. The potential to do it is there though. I just need to drive it better.
I think a high priority is to get the DCDC working on the nRF52.
That should cut the higher currents (such as during Tx and Rx) by about half, as discussed earlier in this thread.BTW, removing the above block of code did help appreciably.
-
@NeverDie said in nRF5 Bluetooth action!:
I think a high priority is to get the DCDC working on the nRF52.
You can try to do this:
#include <nrf.h>...in before()
NRF_POWER->DCDCEN = 1;
-
I haven't yet touched DCDC, but having stripped the example code down a bit, my 10F capacitor is now losing only about 18mv per hour, which is much better than when I began. Some of that is even self-discharge. Whew! Another bullet dodged. Of course, it needs to go lower still, but at least this is meaningful progress for minimal effort.
-
Removing ACK's is the next easy step, and I found the entry in myconfig.h that will do it:
/** * @def MY_PASSIVE_NODE * @brief If enabled, the node operates fully autonomously, i.e. messages are sent without ACKing. * * @note All transport-related checks and safety-mechanisms are disabled. * @note Requires that @ref MY_NODE_ID is set, @ref MY_PARENT_NODE_ID and * @ref MY_PARENT_NODE_IS_STATIC are optional. * @note Singing, registration, and OTA FW update are disabled. */ //#define MY_PASSIVE_NODE
-
@NeverDie
in case.. it's better to make the config changes inside your sketch instead of the MyConfig file, especially if you want to use MySensors for others nodes (else each time you'll have to struggle with MyConfig)
-
@NeverDie said in nRF5 Bluetooth action!:
#define MY_PASSIVE_NODE
Not sure, but I may have run into a bug. I've defined MY_PASSIVE_NODE, and in the main loop I send two different packets once every 5 minutes. The first one never arrives. The second one always arrives. Prior to defining MY_PASSIVE_NODE, both would always arrive. This is on an nRF52832.
-
@NeverDie said in nRF5 Bluetooth action!:
@NeverDie said in nRF5 Bluetooth action!:
#define MY_PASSIVE_NODE
Not sure, but I may have run into a bug. I've defined MY_PASSIVE_NODE, and in the main loop I send two different packets once every 5 minutes. The first one never arrives. The second one always arrives. Prior to defining MY_PASSIVE_NODE, both would always arrive. This is on an nRF52832.
Of course, within a minute of posting the above, the first one suddenly decided to arrive. Maybe it's not a bug after all.
-
On the other hand, it really does seem to receive the second packet (solar panel voltage) far more often than the first (supercap voltage):
2017-08-14 12:17:45.613 (nRF52 DK Gateway) General/Barometer (Solar Panel Voltage)
2017-08-14 12:22:45.866 (nRF52 DK Gateway) General/Barometer (Solar Panel Voltage)
2017-08-14 12:22:45.887 (nRF52 DK Gateway) General/Barometer (Solar Panel Voltage)
2017-08-14 12:27:46.121 (nRF52 DK Gateway) General/Barometer (Solar Panel Voltage)
2017-08-14 12:27:46.152 (nRF52 DK Gateway) General/Barometer (Solar Panel Voltage)
2017-08-14 12:32:46.399 (nRF52 DK Gateway) General/Barometer (Solar Panel Voltage)
2017-08-14 12:32:46.431 (nRF52 DK Gateway) General/Barometer (Solar Panel Voltage)
2017-08-14 12:37:46.661 (nRF52 DK Gateway) General/Barometer (SuperCap Voltage)
2017-08-14 12:37:46.708 (nRF52 DK Gateway) General/Barometer (Solar Panel Voltage)
2017-08-14 12:42:46.928 (nRF52 DK Gateway) General/Barometer (Solar Panel Voltage)
2017-08-14 12:42:46.975 (nRF52 DK Gateway) General/Barometer (Solar Panel Voltage)
2017-08-14 12:47:47.207 (nRF52 DK Gateway) General/Barometer (Solar Panel Voltage)
2017-08-14 12:47:47.254 (nRF52 DK Gateway) General/Barometer (Solar Panel Voltage)
2017-08-14 12:52:47.474 (nRF52 DK Gateway) General/Barometer (Solar Panel Voltage)
2017-08-14 12:52:47.493 (nRF52 DK Gateway) General/Barometer (Solar Panel Voltage)
2017-08-14 12:57:47.736 (nRF52 DK Gateway) General/Barometer (SuperCap Voltage)
2017-08-14 12:57:47.767 (nRF52 DK Gateway) General/Barometer (Solar Panel Voltage)
2017-08-14 13:02:48.006 (nRF52 DK Gateway) General/Barometer (Solar Panel Voltage)
2017-08-14 13:02:48.051 (nRF52 DK Gateway) General/Barometer (Solar Panel Voltage)
2017-08-14 13:07:48.279 (nRF52 DK Gateway) General/Barometer (Solar Panel Voltage)
2017-08-14 13:07:48.310 (nRF52 DK Gateway) General/Barometer (Solar Panel Voltage)
2017-08-14 13:12:48.556 (nRF52 DK Gateway) General/Barometer (Solar Panel Voltage)
2017-08-14 13:12:48.587 (nRF52 DK Gateway) General/Barometer (Solar Panel Voltage)
2017-08-14 13:17:48.843 (nRF52 DK Gateway) General/Barometer (SuperCap Voltage)
2017-08-14 13:17:48.882 (nRF52 DK Gateway) General/Barometer (Solar Panel Voltage)
2017-08-14 13:22:49.085 (nRF52 DK Gateway) General/Barometer (Solar Panel Voltage)
2017-08-14 13:22:49.116 (nRF52 DK Gateway) General/Barometer (Solar Panel Voltage)
2017-08-14 13:27:49.371 (nRF52 DK Gateway) General/Barometer (Solar Panel Voltage)
2017-08-14 13:27:49.402 (nRF52 DK Gateway) General/Barometer (Solar Panel Voltage)
2017-08-14 13:32:49.624 (nRF52 DK Gateway) General/Barometer (Solar Panel Voltage)
2017-08-14 13:32:49.655 (nRF52 DK Gateway) General/Barometer (Solar Panel Voltage)
2017-08-14 13:37:49.896 (nRF52 DK Gateway) General/Barometer (SuperCap Voltage)
2017-08-14 13:37:49.942 (nRF52 DK Gateway) General/Barometer (Solar Panel Voltage)
2017-08-14 13:42:50.169 (nRF52 DK Gateway) General/Barometer (Solar Panel Voltage)
2017-08-14 13:42:50.215 (nRF52 DK Gateway) General/Barometer (Solar Panel Voltage)
2017-08-14 13:47:50.450 (nRF52 DK Gateway) General/Barometer (Solar Panel Voltage)
2017-08-14 13:47:50.481 (nRF52 DK Gateway) General/Barometer (Solar Panel Voltage)Also, I hadn't realized until now that it was sending them multiple times. I had wanted each packet to be sent only once.
-
It looks as though it's a bug in Domoticz. If I open up the serial monitor to the gateway, I can see that it is receiving both packets. However, Domoticz isn't displaying them or even logging them. However, if I don't turn on MY_PASSIVE_NODE, then it does correctly display them. So, Bye-bye Domoticz. I hopee the other controllers don't have the same problem.
-
Maybe nobody uses MY_PASSIVE_NODE? I just did a search of the forum, and nobody but me ever mentions it.
-
@NeverDie I don't think many people know about it, I didn't know this define existed. But sounds like a good mode for things like temperature sensors with tiny batteries, so thank you for pointing it out.
-
At the moment i am range testing.
I have the nrf51822 sending v_status true then false every second.
The esp8266 gateway recieves it and sends it back to the nrf8122 which turns an led on and off accordingly.
I have the nrf8122 running from a usb powerbank so i can walk around my house.
There are a few deadspots around the house with the unamplified nrf24l01 on the gateway.
I tried my nrf24l01 pa lna sma but it seemed to be only working every now and again so waiting on a new one being delivered.
-
@rmtucker said in nRF5 Bluetooth action!:
I tried my nrf24l01 pa lna sma but it seemed to be only working every now and again so waiting on a new one being delivered.
According to hackaday, there's a certain very common model which doesn't perform well unless you wrap it first in saran wrap (as an electrical insulator) and then in aluminum foil (except for the antenna, obviously).
-
@Nca78 said in nRF5 Bluetooth action!:
sounds like a good mode for things like temperature sensors with tiny batteries
Exactly. If you're updating every 5 minutes (which is typical) or less, then it doesn't matter too much if you occasionally lose a packet, because there will be another one coming along in just a few minutes. So, if you can greatly increase your battery life as recompense, most people would
I'm shocked it's not more prevalent here on the mysensors forum.
-
@NeverDie I guess people are happy with 10 years of battery life. I am, so I haven't seen a need for increasing it further.
-
@mfalkvidd said in nRF5 Bluetooth action!:
@NeverDie I guess people are happy with 10 years of battery life. I am, so I haven't seen a need for increasing it further.
Fair enough. How about smaller then? The battery may be the single biggest component. You could trade-off longer battery life for a smaller size.mote i.e. If it's a more energy efficient mote, it can use a smaller battery (or a smaller solar panel and a smaller supercap).
-
@d00616 said in nRF5 Bluetooth action!:
I have checked the current with my nRF52 board with integrated shunt. I have measured 6.5µA while sleeping until timeout or sleeping until interrupt. It doesn't matter if RX/TX are connected but after flashing the firmware a reset by removing the voltage is required.
Does the onboard regulator on this board not draw any current when not being used?
ie when feeding the board with 3.3v and bypassing the regulator?
-
I should be receiving my nRF51 modules a few days from now. Since they lack a 32K oscillator on the module, which "board" should I program it as?
-
@NeverDie said in nRF5 Bluetooth action!:
I should be receiving my nRF51 modules a few days from now. Since they lack a 32K oscillator on the module, which "board" should I program it as?
With the Generic nRF51822 or the MySensors nRF5 boards, you can switch the oscillator via the tools menu. You have to choose the RC oscillator.
-
@d00616 said in nRF5 Bluetooth action!:
@NeverDie said in nRF5 Bluetooth action!:
I should be receiving my nRF51 modules a few days from now. Since they lack a 32K oscillator on the module, which "board" should I program it as?
With the Generic nRF51822 or the MySensors nRF5 boards, you can switch the oscillator via the tools menu. You have to choose the RC oscillator.
If I were to choose RC oscillator in a case where the module (such as the Ebyte nRF52832 module) actually does have an external oscillator, will it no longer spend any power on the external oscillator?
-
@NeverDie said in nRF5 Bluetooth action!:
MY_PASSIVE_NODE,
I found a shlocky workaround for the current problems with MY_PASSIVE_NODE. It turns out that if you have the gateway up and running before the passive node power up, then the passive node often gets stuck in a loop trying to register itself. However, for whatever reason, if you first power up the passive node, let it run for a bit trying to register and failing, and then power on the gateway, the loop is avoided. Then the passive node will broadcast one packet per cycle and the gateway will receive it and send it to the serial port.
Unfortunately, Domoticz can't really deal with it.
Soooooo... For now, I'm using Termite on the serial port to capture the packets and time stamp them. That at least allows me to continue with measurements as to whether MY_PASSIVE_NODE saves significant energy or not. It also has 1 second resolution, not the 5 minute time resoluton of Domoticz.
-
The specification for the nRF52832 advertises: "Fast wake-up using 64 MHz internal oscillator."
However, there's not a menu item in the tool menu to set that. So, how is it done?
-
@NeverDie said in nRF5 Bluetooth action!:
@NeverDie said in nRF5 Bluetooth action!:
MY_PASSIVE_NODE,
I found a shlocky workaround for the current problems with MY_PASSIVE_NODE. It turns out that if you have the gateway up and running before the passive node power up, then the passive node often gets stuck in a loop trying to register itself. However, for whatever reason, if you first power up the passive node, let it run for a bit trying to register and failing, and then power on the gateway, the loop is avoided. Then the passive node will broadcast one packet per cycle and the gateway will receive it and send it to the serial port.
Unfortunately, Domoticz can't really deal with it.
Soooooo... For now, I'm using Termite on the serial port to capture the packets and time stamp them. That at least allows me to continue with measurements as to whether MY_PASSIVE_NODE saves significant energy or not. It also has 1 second resolution, not the 5 minute time resoluton of Domoticz.
Good news! Using the above method, I've established that the EByte nRF52832 module consumes an order of magnitude less current if "MY_PASSIVE_NODE" is defined.
-
@NeverDie said in nRF5 Bluetooth action!:
Good news! Using the above method, I've established that the EByte nRF52832 module consumes an order of magnitude less current if "MY_PASSIVE_NODE" is defined.
Does that mean you are reaching consumption levels as low as atmega+nrf24 ?
-
@Nca78 said in nRF5 Bluetooth action!:
@NeverDie said in nRF5 Bluetooth action!:
Good news! Using the above method, I've established that the EByte nRF52832 module consumes an order of magnitude less current if "MY_PASSIVE_NODE" is defined.
Does that mean you are reaching consumption levels as low as atmega+nrf24 ?
Not for all cases, but maybe for this case, provided I can run it off of both of its internal resonators (the 32Khz and the 64Mhz). The datasheet promises a "fast wakeup" if run off the internal 64mHz resonator, and its access to the radio should be a lot faster through DMA, which is automatic.
Presently, running it all night long (12 hours), it lost less than 50mv off the supercap, and some of that is probably just self-discharge by the supercap.
Also, getting the DCDC to work would no doubt help...
-
Maybe using the internal oscillator doesn't matter. Thge datasheet says, "The HFXO must be running to use the RADIO..."
i.e. without the external 64Mhz oscillator, the radio can't be used. So, if that's true, then I guess from my point of view the 64Mhz external oscillator isn't optional after all. Perhaps that explains why there is one on literaly every module I've seen so far.
-
I'm ordering today some AVX supercaps with smaller Farad values so that I can get more resolution on the amount of energy (at least relatively) being consumed in different configurations.
-
I received the nRF51822 modules I had ordered (center of photograph):
Small enough to fit almost anywhere!
-
@Nca78
Did you ever figure out how to reset the MCU on the Ebyte module?
-
@NeverDie
I connected a new amplified nrf24 to the gateway with the tin foil as mentioned and it is reading -60dB compared to -89dB with the non amplified version.
Now lets see how far it goes past the original test.
-
@rmtucker
Well outside of the garden now no problem.
On to supercaps now i think.
-
@rmtucker said in nRF5 Bluetooth action!:
@NeverDie
I connected a new amplified nrf24 to the gateway with the tin foil as mentioned and it is reading -60dB compared to -89dB with the non amplified version.Did the tin foil make a difference? Hackaday seemed to think it made a big difference. I haven't tried it yet.
-
@NeverDie said in nRF5 Bluetooth action!:
@rmtucker said in nRF5 Bluetooth action!:
@NeverDie
I connected a new amplified nrf24 to the gateway with the tin foil as mentioned and it is reading -60dB compared to -89dB with the non amplified version.Did the tin foil make a difference? Hackaday seemed to think it made a big difference. I haven't tried it yet.
I think it did but what do you have to lose
-
Here's the Hackaday article: http://hackaday.com/2016/05/31/fixing-the-terrible-range-of-your-cheap-nrf24l01-palna-module/
-
@NeverDie said in nRF5 Bluetooth action!:
@Nca78
Did you ever figure out how to reset the MCU on the Ebyte module?Sorry didn't touch my NRF5 in the last weeks. A bit busy on other things...
-
What's the best way to make a "receive only" gateway? i.e. one that cannot transmit? Then I wouldn't need to worry about whether the gateway is turned on before powering up a MY_PASSIVE_NODE sensor mote. Is there a way to do it simply in hardware, or do I have to sabotage the gateway library code?
-
It's getting too baroque. What I'd really like to have is a short nRF5 library of just the bare essentials (like the MIRF library is for the RF24).
-
Hmmm... it looks like radiohead may be such a library: http://www.airspayce.com/mikem/arduino/RadioHead/classRH__NRF52.html
-
@NeverDie said in nRF5 Bluetooth action!:
It's getting too baroque. What I'd really like to have is a short nRF5 library of just the bare essentials (like the MIRF library is for the RF24).
You can take a look into the actual Nordic NRF SDK. There are the ESB library for nRF24 compatible communication.
-
@d00616 said in nRF5 Bluetooth action!:
@NeverDie said in nRF5 Bluetooth action!:
It's getting too baroque. What I'd really like to have is a short nRF5 library of just the bare essentials (like the MIRF library is for the RF24).
You can take a look into the actual Nordic NRF SDK. There are the ESB library for nRF24 compatible communication.
The RadioHead library seems very easy to pickup and start using. Maybe it's me, but I can't say the same for the Nordic SDK.
Interestingly, it looks as though @Yveaux may (?) have written the nRF51 part of the RadioHead library.
-
I was able to program the tiny nRF51822 (earlier photograph above) by programming it as an xxaa Generic nRF51 with an RC oscillator.
Nice!
-
Here's a close-up photo:
-
FWIW, range on the tiny nRF51822 does seem compromised when compared against larger sized nRF52832 modules. Not really surprising, but I had hoped it might be a little better than it is.