Navigation

    • Register
    • Login
    • OpenHardware.io
    • Categories
    • Recent
    • Tags
    • Popular
    1. Home
    2. duncancragg
    3. Posts
    • Profile
    • Following
    • Followers
    • Topics
    • Posts
    • Best
    • Groups

    Posts made by duncancragg

    • RE: NRF51822 as an "all-in-one"?

      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

      posted in Hardware
      duncancragg
      duncancragg
    • Objects as collections of variables with a new global, aggregate UID

      Variables are a very low-level abstraction: it would be nice to have collections of them in 'objects'.

      For example, say a weather station has these variables:

       Node number: 3
      
       Sensors/variables: 
      
       S_BARO: V_PRESSURE, V_FORECAST
       S_WIND: V_WIND, V_GUST
       S_RAIN: V_RAIN, V_RAINRATE
      

      How about a combined object like this:

       { UID: node-3
         is: pressure wind rain sensor
         pressure: 1020
         forecast: thunderstorm
         wind: 8
         gust: 13
         rain: 3
         rainrate: 9
       }
      

      It has a UID made here from the Node ID number, although it can be any string uniquely identifying the object. This is an opportunity to use a more globally-unique UID, perhaps including IPv6 address strings.

      This would require payload fragmentation to transfer the whole string in something like the above format (JSON-like, but without all the punctuation noise). Or alternatively, some way of constructing and deconstructing objects from the current protocol messages.

      A parallel, alternative protocol could be designed - if fragmentation and re-send of missed frags is built in efficiently and reliably, and if the objects are usually pretty small, like the above example, you could take a little hit on efficiency to get the benefit of raising the level of abstraction throughout the system, in terms of both coherent object formats and types and the use of more global UIDs or addresses.

      Of course, it's less efficient to transfer the whole object: if only 'wind' changes, you only really need to transfer that variable, not the whole object. Plus string text is bigger than numbers. Plus backwards-compatibility is pretty important.

      So, using the present protocol, this object approach would just be 'syntactic sugar' - via a helper API. You'd only see the above format with a special print_object() function, and the API would handle aggregation and the new UID. The downside would be having to deal with two levels of abstraction everywhere.

      Cheers!
      Duncan

      posted in Feature Requests
      duncancragg
      duncancragg
    • RE: NRF51822 as an "all-in-one"?

      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

      posted in Hardware
      duncancragg
      duncancragg