NRF51822 as an "all-in-one"?
-
" The nRF51822 is built around a 32-bit ARM Cortex M0 CPU with 256kB/128kB flash + 32kB/16kB RAM. The embedded 2.4GHz transceiver supports both Bluetooth Smart and the Nordic Gazell 2.4 GHz protocol stack which is on air compatible with the nRF24L series products from Nordic Semiconductor."
https://www.nordicsemi.com/eng/Products/Bluetooth-R-low-energy/nRF51822Before you say it won't work with the arduino IDE, remember that the Arduino Zero does use an ARM Cortex M0...
Plus, there's already this, which appears to do just that: http://redbearlab.com/redbearlab-nrf51822 along with http://redbearlab.com/getting-started-nrf51822/, and you can buy it on Amazon today if you want: http://www.amazon.com/Red-Bear-Lab-RedBearLab-nRF51822/dp/B00QSB51ZO More to the point, there's this:
http://www.amazon.com/Red-Bear-Lab-RB-LAB-B05-RedBearLab/dp/B00WG75FI2/ref=sr_1_4?s=electronics&ie=UTF8&qid=1439421124&sr=1-4
available now, for <$18, with Amazon Prime.delivery.I'm not saying you should buy it. I'm just saying, "For instance..."
You can buy an inexpensive module from Alice on Ebay for $6.88:
http://www.ebay.com/itm/Low-Power-Consumption-BLE4-0-Bluetooth-2-4-GHz-Wireless-Module-NRF51822-/400970594571?hash=item5d5bb5b90bThe radio is backward compatible with the NRF24L01+ currently being used.
Whether it's the NRF51822 or something else, isn't it inevitable that a desirable option would be to have the MCU and the RF portion as a SOC? No running wires back and forth between them. No need to spend on a PCB for that purpose either, or hand solder the MCU and radio onto it.
Yes, it also comes with bluetooth, but you can just ignore that part if you want to.
Single unit pricing on Digikey for the chip is $4.15....
http://www.digikey.com/product-detail/en/NRF51822-CDAB-R/1490-1048-1-ND/5125205
-
Besides RedBearLab and eBay - Adafruit has a couple of interesting nRF51822 boards, Nordic itself has a development board and a dongle for reasonable prices, AliExpress has more of the cheap boards and chips. SEEEDstudio also has some boards.
And a few of these work with mBed.
There is work to support this chip with the Arduino IDE by RedBear at least.
The topic of this chip has arisen before on the forums. It looks like it could be very interesting, albeit a bit more expensive than the nRF24LE1 for which there is a Proof of Concept implementation for MySensors. I've been expecting a nRF51822 / MySensors implementation for a while, and was surprised to see the nRF24LE1 first.
And Nordic is starting to release the next generation, the nRF52 line starting with the nRF52832 if I recall correctly. Preview DK is out but no chips till the end of the year. Seems similar but with a Cortex M4, faster,more memory - and integrates ANT+ and NFC as well as Bluetooth LE and legacy protocols (like nRF24L01+ and ESB).
I've really been wanting to explore this family, just haven't had time yet. I will be watching carefully anything you come up with.
-
I don't know if the NRF24 part of it would be meaningfully better range than the regular NRF24L01+. At the moment, all I know is the the NRF51822 has a readable RSSI, so maybe there have been other improvements.
I did see the post by the guy here who did the NRF24lE1, and kudos to him. It didn't seem to fall within the arduino IDE, though, and that seems to be the driving theme underlying mysensors. When I earlier asked about mysensors using the LPC810 (as Jeelabs had done with one of its sensors) instead of an attiny85 (which may be too small to run mysensors well),, the pushback was that it wasn't arduino IDE. Most people, myself included, don't want to embrace a new IDE without proof that the payback will be worth the effort.
-
Agreed about the Arduino IDE being dear to the heart of MySensors.
So for the moment the nRF24LE1 is an interesting offshoot, rather than the main development direction. I can imagine some common node types being implemented that way as cheap/tiny special purpose options, but at the moment I think flexible roll-your-own-mixture nodes will continue to use the Arduino IDE.
If RedBear gets their Arduino IDE for the nRF51822 solid ("A work in progress" it says), that may become very tempting for some applications.
RSSI could be nice. I seem to recall their soft device has 8 pipes rather than 6, but we don't use them in a pipe-limited fashion. Not sure what other OTA advantages it would have in a MySensors application. Otherwise it's just cool to have the transceiver and uC in one module, with a more powerful uC (faster, 32bit, more memory).
I keep wondering that some Chinese vendor doesn't combine an APM and nRF24L01+ on one PCB. That could be a killer, at least in our circles. (Prepare for more interference!)
Meanwhile - onward nRF51822 !
-
@Zeph said:
If RedBear gets their Arduino IDE for the nRF51822 solid ("A work in progress" it says), that may become very tempting for some applications.
Yes, "If".... You've put your finger exactly on what's holding me back. I don't know "if" it has yet crossed over from "a work in progress" to "production ready." I started this thread mainly on the off chance someone with firsthand knowledge might know and post a response. I hate to say it, but very often Asian software is the absolute barest minimum of superficial veneers applied over their hardware in order to persuade buyers and make the sale. Later, when you dig into it, you find out it's full of gaping holes that are more or less permanent. I don't know whether RedBear Labs is one of those, or not. However, I've been burned by it often enough that I'm no longer willing to take the required leap of faith anymore that would be necessary in order to find out firsthand. Instead, I'll wait for secondhand corroboration that it checks out.
-
@NeverDie said:
NRF51822
Looks nice.
Also remember that you'd need libraries the (more advanced) sensors you'd attach. This is usually not a problem for AtMega328/Arduino (with its vivid community) but it might be trickier to find out-of-the-box for this.
-
I have not been involved in porting Arduino based sensor libraries to new architectures.
I would expect that some of them are built on top of the standard Arduino/Wiring libraries, so if the latter have been implemented, the sensor library would be OK. Eg: if the same i2c or spi calls can be made, some sensors should be fine.
The problem areas I would imagine are:
- Libraries which depend too closely on the uC hardware and onboard peripherals (eg: assume they can use Timer2 for something)
- Libraries which require assembly language or instruction counting for tight timing.
It would be interesting to assess which libraries often used by MySensors nodes would fit in each category. Is there anything like a list of the libraries used by MySensors code or examples?
-
Am noticing that Nordic Semiconductor now has the NRF52832 on display. It consumes only 5.5ma in receive mode at 3V.
For comparison, the NRF24L01+ consumes 13.5mA in receive mode, and the RFM69 consumes 16mA in receive mode.
Also noticing 7.7ma Tx current at 3V for +4dBm. The highest for the NRF24L01+ is 0dBm, and that takes 11.3mA. So, the range of the NRF52832 should be much better than the NRF24L01+, even though it's utilizing less current. Impressive!
No idea when it will be available, though. Maybe in a year?
-
This post is deleted!
-
I think that MySensors should absolutely support this chip, for all the reasons given - it's a compact, all-in-one chip with varied radio protocols; cheap and readily available; RSSI readings; nRF24-compatibility!
Apart from RedBear, Nordic, Ali and Seeed as mentioned above, it's available, as mentioned by Zeph, in two forms from Adafruit (UART+SPI).
Plus the RFduino uses it, and comes with a lot of Arduino support software.
Finally, for UK people, it's the chip at the heart of the BBC micro:bit, which is going to be distributed to a million school children early next year.
As NeverDie suspected, the RBL Arduino support isn't very good at all, but I've had plenty of success with porting Arduino SPI- and I2C-based libraries (for RGB strip, TFT touch, ENC28J60) to run on it, with help from the RFduino code.
And I've succeeded in getting the BLE and nRF24-compatible protocols (ESB) working at the same time, using Nordic's example code. I've also ported the UIP IPv6 library over, to run on the ENC28J60.
Cheers!
Duncan
-
This chip caught my eye to while searching for possibilities to incorporate the MOVE from Teptron with MySensors. It only supports BLE but it will have an open API. Did anyone else join their kickstarter?
-
I'm currently working on getting Cortex M0(+) working with mysensors (Atmel SAMD21G). It is progressing, but time is sparse at the moment.
However, some of this work could probably be lifted towards the nrf SOC, as its also using a Cortex M0. I haven't looked at the datasheet yet though, so don't know anything about the internals of the SOC
-
There's some Nordic example code that allows both Bluetooth LE and nRF24-ish protocols to run simultaneously on this chip.
Well, baby steps: I've made a start at porting it to Arduino and to the Nano mentioned above.
So you can exchange messages over nRF24-ish radio whilst also seeing those devices and messages on your phone using a BLE client. You can then send messages back. (And all that on USB serial, too.)
Take a look and see where you think we could take it next - there's a list of things at the end:
https://github.com/DuncanCragg/Onix
Cheers!
Duncan