This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

How to select provisionee by UUID in mesh serial example?

Dear friends:

I flashed a mesh serial example.  I scand mesh beacon  by the function "scan_start()". As you can see in below code, I got two uuid device, I want to select one to provison, could you provide me the cmd? thank you in advance.

E:\bluemesh\nrf5_SDK_for_Mesh_v5.0.0_src\scripts\interactive_pyaci> python interactive_pyaci.py -d COM4 --no-logfile

    To control your device, use d[x], where x is the device index.
    Devices are indexed based on the order of the COM ports specified by the -d option.
    The first device, d[0], can also be accessed using device.

    Type d[x]. and hit tab to see the available methods.

Python 3.8.6 (tags/v3.8.6:db45529, Sep 23 2020, 15:52:53) [MSC v.1927 64 bit (AMD64)]
Type 'copyright', 'credits' or 'license' for more information
IPython 7.23.1 -- An enhanced Interactive Python. Type '?' for help.

In [1]: db = MeshDB("database/example_database.json")

In [2]: db.provisioners
Out[2]: [{'name': 'BT Mesh Provisioner', 'UUID': _UUID(b'\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00'), 'allocated_unicast_range': [{'low_address': 0010, 'high_address': 7fff}], 'allocated_group_range': [{'low_address': c000, 'high_address': feff}]}]

In [3]: p = Provisioner(device, db)

In [4]: 2021-05-11 14:29:45,057 - INFO - COM4: Success
2021-05-11 14:29:45,061 - INFO - COM4: Success
2021-05-11 14:29:45,065 - INFO - COM4: SubnetAdd: {'subnet_handle': 0}
2021-05-11 14:29:45,069 - INFO - COM4: AppkeyAdd: {'appkey_handle': 0}
2021-05-11 14:29:45,073 - INFO - COM4: AppkeyAdd: {'appkey_handle': 1}
In [4]:

In [4]: p.scan_start()

In [5]: 2021-05-11 14:29:54,370 - INFO - COM4: Success
2021-05-11 14:29:54,600 - INFO - COM4: Received UUID ca6a0a8e3c2ef63d9dbe646a88de8e3c with RSSI: -58 dB
2021-05-11 14:29:55,258 - INFO - COM4: Received UUID 005955aa00000000c10130f48247099f with RSSI: -20 dB
In [5]: p.scan_stop()

In [6]: 2021-05-11 14:30:07,001 - INFO - COM4: Success
In [6]:

In [6]:

My operation according the guide from nodic infocenter Software Development Kit > nRF5 SDK for Mesh v5.0.0 > Bluetooth mesh stack user guide > Modules > Serial interface > Interactive PyACI script 

Parents Reply Children
Related