This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

End Device Bindig ZDP_MatchDescReq()

Other Parts Discussed in Thread: Z-STACK, CC2538

Hi,


I am trying to bind to end device using ZDP_MatchDescReq(). Can anybody suggest me where shall i call this function in enddevice.

And is there any need to fill the simple descriptor of coordinator to bind two end device with matching clusters using ZDP_MatchDescReq()

what shall i fill my destination and network address if i want only clustur binding.

please help me

regards,

sibin

  • 1. You can make device to send ZDP_MatchDescReq with broadcast when ZDO_STATE_CHANGE.
    2. If you want ZC to response to ZDP_MatchDescReq from ZED, you should put related cluster ID in InClusterList of ZC Simple Descriptor.
  • thanks for reply,

    but I need to bind two end devices which communicates through coordinator or router so is it enough to give same cluster IDs to input cluster list of a endevice and output cluster list of another end device then is there any need to fill the coordinator Simple Descriptor as in my project coordinator is used only for nework formation and routing.

    please suggest

  • Except put the same cluster to input cluster list of end device, I think polling rate of end device has to fast enough to not missing match request broadcasting.
  • Hi YK Chen,

    I am trying this in sample doorlock controller project.

    I made:-
    => input and output clusters in SimpleDescriptor(SD) of ZC NULL
    => i/p cluster in SD of one Zed(sample doorlock) to ZCL_CLUSTER_ID_CLOSURES_DOOR_LOCK
    => o/p cluster in SD of another Zed (sample doorlock controller) to ZCL_CLUSTER_ID_CLOSURES_DOOR_LOCK

    in ZDP_MatchDescReq():
    => dstAddr->addrMode = AddrBroadcast
    => dstAddr->addr.shortAddr=0xffff
    =>nwkAddr=0xffff

    but in ZC it is displaying "Match Desc Req", "Non Matched"

    and I am not able to lock or unlock remote enddevice through the controller

    i tried to debug a lot but i can't understand the problem

    please suggest some solution

    regards,
    sibin
  • Do you put ZCL_CLUSTER_ID_CLOSURES_DOOR_LOCK in your output cluster list of match request?
  • yes I did then also coordinator showing non match

  • I suggest you can have a look at GenericApp example in Z-Stack mesh 1.0.0. You can invoke match request with SW4 in GenericApp example.
  • thanks for reply,

    please will you get me the link i tried to search but i cant get a GenericApp example for cc2538 controller

    sibin
  • You should download and installZ-Stack Mesh 1.0.0. GenericApp example is in it.
  • Hello Yikai Sir,

    Greeting for the day,

    I am a Writing an Application where My Light can be connected to any HA Supported HUB, using the Stack version Z-Stack Home 1.2.2.42930
    but as I am Running the sample Application and trying to Connect it with Smart things HUB , It is (SampleLight App) not sending the MatchDescReq after DeviceAnnce... ??

    So my Question is How can I made the Sample Light to Connect with Smart Things HUB.
    how to make the Application Send MatchDescReq after DeviceAnnce ???

    I am wondering about it for last 3 days but unable to get any answer could you please help??

    Thanks and regards
    Manish
  • You can send MatchDescReq in ZDO_STATE_CHANGE.

  • Hello Yikai Sir,

    Thanks for the reply,

    I have done the same but still i am unable to add the Sample Light node to smart things hub could you please tell how to do it ??
    thanks and regards
    Manish
  • I suggest you to use sniffer to check it.
  • Hello Yikai Sir,


    I have seen the Sniffer but not finding any thing but , I thought that Sample Application should Connect Automatically to any Third Party HUB ??

    Because Sample Application should be written in a reference way..

    Could you please elaborate what to do now ??

    should I send you the Sniffer Log ??

    Thanks and regards
    manish
  • Please attach the sniffer log.
  • Hello Yikai Sir,

    I am sending you two log files

    a) own device is not having Match_Desc_req

    b) After_Match_des is having Match_Desc_req Command

    Please find the AttachmentlogFile.zip

  • I see device sends match request but there is no response and I think there's no on/off cluster implemented on coordinator endpoint.
  • Hello Yikai Sir,

    Thanks for reply,

    I don't know whether it has on/off cluster implemented or not one thing I know is Smartthings HUB can Control GE Light link Device.
    And i have controller the GE LightLink Device which support On/Off and dimming Cluster.

    Sir, What should I try Now ???

    Thanks and Regards
    Manish
  • The hub should send binding but I don't see it. When you use GE bulb, do you see binding?
  • Hello Yikai Sir,

    Greetings for the day!!!

    Sir, I am trying to join my Node with Third party hub for last few days but  I am unable to do so in My latest try I tried 

    1) GE link node connect to Smart things HUB and control the same and got the Log for it, The GE link Node is connected and I am able to Control it

    2) I have tried the same with SampleLight App of TI which is provided in stack , But the Logs are different and node is not connected to Smart things HUB.I am sending you both the Logs please find the Attachment and do let me know what to try else.

    2337.logFile.zip

  • I have no idea why SmartThings hub doesn't send binding when SampleLight joins. You can try to change manufacturer name and model ID as those of GE bulbs and test again.
  • Hello Sir,

    I have one more thing to ask in Case of GE link After DeviceAnnce GE send the Match_Desc_req after which Smart Things Acknowledges the same

    but is case of Standard SampleLight App it is not sending any Match_desc_req after Adding ..

    Another thing  I have noticed is I have added the OTA cluster and sent the Match_Desc_Req at ZDO_STATE_CHANGE at that time Smart Things HUB sent the Command Match_desc_res

    But still it has not sent the Bind req and response ??

    What should I try Now Because Standard App should send the  Match_Desc_Req after DeviceAnnc Command but it is not sending may be due to this Smart Things HUB can not  Authenticate the Device ??

    Attaching here with the file please try and let me know please

    logFile (1).zip

    Thanks and regards

    Manish

  • I think SmartThings hub checks manufacture name and model ID. So, I suggest you to change those two in SampleLight and test again.
  • Hello Sir,

    Thanks for the reply .

    1) where should i find the manufacturer name and model ID in sniffer Log ?

    2) How to send the Match_Desc_Req after the DeviceAnnc if my node is sending Device Announcement how do i send Match_Desc_req ???

    Thanks and regards

    Manish

  • 1. You can check "Basic: Read Attributes..." packets in GE log.
    2. I usually send match request in ZDO_STATE_CHANGE.
  • Hello Yikai Sir,

    But while Sending the Match_Desc_req at ZDO_STATE_CHANGE
    Match_Desc_Req goes Earlier than DeviceAnnouncement Command
    But in Actual GE_LOG Match_Desc_Req is sent After The Device Annce
    What to do If I want to send the Match_desc_req after the Device annce command ??

    thanks and regards
    Manish
  • You can start a timer event to send match request a few seconds later in ZDO_STATE_CHANGE.
  • Hello Yikai Sir,

    I have done the Same as you told me I have sent the  Match_Desc_req. After the desired time , And have Copied the Manufacture and ModelId in the code,

    The sequence trace on sniffer for Ge and My log are almost same but smart things HUB is not sending the Bind Request  I am sending you the Log please compare the Both and please do let me know the next step to go for ??

    0741.logFile.zip

    thanks and regards

    Manish

  • If you check manufacture name and model ID between GE bulb and yours, the length of both fileds are different and string is not exact the same in manufacturer name. Please make them exact the same and test again.
  • Hello Yikai Sir,

    I have tried the same it is working and my node is Added to smart things HUB, I am sending you the log But When I am writing the application for Multi endpoint application With same Name of Manufacturer and Model ID my node is not added to Smart thing HUB

    I am sending you

    1) own_device_working log (for Single End Point)

    2) MultiEndpoint Log (For Multi End point)

    5504.logFile.zip

    please do let me know what to do for adding and testing my Product (A multi End point Power strip module) that works with Zigbee Interface but i want to test it with Smart thing HUB

    Thanks and regards

    Manish 

  • If it can work after you use GE manufacture name and model ID, it means SmartThings hub has constrains on joined Zigbee device. I am not SmartThings employee so I don't know how they constrain multiple endpoint. I suggest you to contact SmartThings for help.
  • Hello Yikai Sir,

    Greetings for the day!!!

    Sir I have an issue with Cluster and Command,

    I have tried with Communicating GE bulb with My Controller , I have found that it is Having 6 Clusters, and e.g Basic, Identity, ON-OFF, DIMMER, etc

    But I have not Found the Command Supported on Clusters. e.g if we have DIMMER Cluster (0x0008) is supports 6 commands (according to document and reference code ) but how can i found the command which this device actually supports..
    Currently It is Supporting 06 command with transition Time of 0x0014 but this data i have found after watching in sniffer for smartthings..
    Now i wish to know is there a way that i can find out , which command the 3rd party devices are supporting for desired Cluster IDs
    Thanks and regards
    manish
  • I suppose this GE bulb uses standard HA profile so you can refer to Zigbee cluster library spec and HA spec for all of command details.
  • Hello Yikai Sir,

    I know it is supporting HA profile and have Clusters 0x0006 and 0x0008

    and For Dimming it is supporting


    #define COMMAND_LEVEL_MOVE_TO_LEVEL 0x00
    #define COMMAND_LEVEL_MOVE 0x01
    #define COMMAND_LEVEL_STEP 0x02
    #define COMMAND_LEVEL_STOP 0x03
    #define COMMAND_LEVEL_MOVE_TO_LEVEL_WITH_ON_OFF 0x04
    #define COMMAND_LEVEL_MOVE_WITH_ON_OFF 0x05
    #define COMMAND_LEVEL_STEP_WITH_ON_OFF 0x06
    #define COMMAND_LEVEL_STOP_WITH_ON_OFF 0x07

    but when i send any command other than 0x06

    the device is not responding??

    that is why i would like to know is there any way out by which Command the device actually supporting as we have seen about this device in sniffer but if device is new we can not give support so My question is for any new device is there any API by which we came to know what command the device is Supporting ??

    thanks and regards
    manish
  • You can only do try and error test to know what commands it supports.
  • Hello Yikai Sir,

    Greetings for the day!!!

    Sir, I have one issue , In my code I have made the static PAN ID 0x2424 in Config File now my controller adds GE Light, but when i restart My Coordinator ( Controller again) it starts to Incremented PAN ID 0x2425 .

    I want my coordinator to boot on same PAN ID i.e 0x2424 is there any file in stack which scans for neighbor network by modifying that we can make the coordinator to boot on same Network ID i.e PAN ID 0x02424???

    Please do let me know is there any way by which we can make coordinator and end node 3rd party to rejoin on restart ???

    thanks and regards

    Manish

  • You cannot have two coordinator using the same PANID in the same channel.
  • Hello Yikai Sir,

    I have Scenerio 

    1) My Controller (Coordinator) and GE 3rd Party device

    a) I have add GE bulb to my Controller at 0x2424 GE bulb added to my controller. Now i restart the Controller it Boots at 0x2425. Now my question is Can i boot the Controller(My Coordinator) at 0x2424 ?

    I don't want another Coordinator to boot in same network, Just an existing Controller and GE bulb because what happening is every time controller restarts I need to re add the GE bulb but I want that if any of the Controller or GE bulb starts it add to PAN ID 0x2424 and controller Start controlling the GE bulb but it is not happening as every time controller restarts it scans the network exist and it boots itself on incremented value.

    I want to reboot it on same PAN ID is it possible and I dont have any other Coordinator in My Network.

    2) Smart things HUB on the other hand if GE bulb is added to it and if Smarthings HUB restart it can control the GE bulb irrespective of adding it again and again and it boots to same PAN ID how ??

    thats the question I have could you please let me know how it is Achievable?? I thought in stack where controller before being boot up scans for neighbor PAN IDs can do the trick if we block that part may be that it will boot on Static PAN???

    Thanks and regards

    Manish

  • Do you enable NV_RESTORE on your coordinator?
  • Hello Yikai Sir,

    Greetings for the day!!

    Sir, I have Router SampleLight App i have added it to Coordinator , and i can send on -off and levelcontrol command to it, But when it goes power down Router (reset) , The Router is not sending Device Annce to coordinator and may be it change the network address,

    I dont know why it is happening in a mean time my coordinator is untouched.

    what should i try now ??

    thanks and regards

    manish

  • Do you enable NV_RESTORE when you test this?
  • Hello Yikai sir,

    I have not enable the Flag that you mentioned
    thanks and regards
    Manish
  • If you enable NV_RESTORE, the short address won't change when device does power recycle. Why don't you enable it?
  • Hello Yikai Sir,

    Ok , I will check it and one more thing how to send the device Annce on each power recycle?? What to do so that if each time my node restarts it sends the DeviceAnnc to the Controller ??

    thanks and regards
    Manish
  • You can send end node announcement when device receives ZDO_STATE_CHANGE.
  • Hello Sir,

    So will it be a Automatically taken care from Stack or I should send the DeviceAnnce API call if device State Change ???

    thanks and regards
    Manish
  • You should send DeviceAnnce API call if device State Change.