bluetooth-lowenergyraspbiannode-redraspbian-buster

How to set up node-red on rasbian to get information from a ble-energy-harvesting button?


at first: I'm not a BLE expert so I try to describe my problem as good as I can and I apologize in advance if I don't use the right terms or definitions.

when node-red is started I can see the elements of generic-ble-package and so I tried to configure the "Generic Ble In"-Item.

When I scan for devices, I have to push and release the button several times till it is shown in the list - that's no wonder because without these actions the button has no energy. But then it gets complicated. When I click on "Apply", the item tries to get the GATT(ributes) from the button.The problem is - as far as I understood - the button doesn't have any.

From the CLI I've used bluetoothctl to scan for devices and I've seen that the button is always recognized by the system (on-button-pressed and on-button-released).

I've also tried with different other node-red packaged but they had even more problems ( e.g. noble (4) could not be installed properly and it looks like abandoned )

I assume the problem is sitting in front of the screen but this is the second Saturday I'm trying to "install a button" and I really don't know how to proceed.

I've read (somewhere) that one of the strength of BLE is the possible usage of energy-harvesting -sensors. But does the "general-ble"-package do the job?

-If yes, how? -If no, which package should I use?

I'd really like to use a node-red-package because I want to expand an already existing flow.

I appreciate any help and/or link.

Thank you in advance.

Regards,

Mr P

Additional info:

Ref.


Solution

  • I found the way to do the job:

    I installed the ble-beacon-scanner (1) and that works fine for my purpose.

    As I understood: Beacons use ble-notifications, which don't share attributes and don't need a continuous connectivity.

    The generic library unfortunately doesn't offer this part of the ble-protocol.

    Thank you all.

    Regards,

    Mr P

    (1) https://flows.nodered.org/node/node-red-contrib-blebeacon-scanner