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

Adding Zigbee production settings

Hi, I'm just started developing on 52840DK platform and I am trying to create my own zigbee end device (remote controller) with higher WAF than IKEAs controllers. I've tried different examples from SDK 1, but none of them are compatible with SDK2. In SDK 2, I've successfully joined a network with the example code zigbee_light_switch_groups and the device appears in my gateway logs as undefined: zigbee2mqtt:warn 2019-2-19 22:44:46 Device with modelID 'undefined' is not supported.

According to their documentation I'm supposed to add a new device in their configuration, but undefined is not a valid name. Where do I set new name? I see that zigbee production settings is missing, so I tried the enclosed application to create one. But the executable throws errors:


Skipping unknown key-value pair: manufacturer_name = TEST
Skipping unknown key-value pair: model_id = test1
Skipping unknown key-value pair: manufacturer_code = 0x1234

What do I do wrong? Or is there any other ways to set model_id?

Btw, there are a couple of open source projects that tries to implement zigbee gateway, but everyone is using Texas Instruments C2530 or SiLabs. I'm curiously waiting for a more mature CLI that uses nrf dongle. Is there anything down the road? If Nordic implements support for zigpy or another open source gateway component, you guys can easily take a market position.

  • Found the answer, now zigbee2mqtt reports my defined name:

    Device with modelID 'test1' is not supported.

    Now I can move on and define my model in zigbee2mqtt

    Added this to the example:

    #define BASIC_MANUF_NAME        "TEST"
    #define BASIC_MODEL_ID          "test1"
    #define BASIC_DATE_CODE         "20190221"
    #define BASIC_LOCATION_DESC     "wall"  
    
    static zb_uint8_t app_version = 01; 
    static zb_uint8_t stack_version = 10; 
    static zb_uint8_t hw_version = 11; 
    static zb_char_t mf_name[32]; 
    static zb_char_t model_id[32]; 
    static zb_char_t date_code[16]; 
    static zb_char_t location_id[17]; 
    static zb_uint8_t ph_env = ZB_ZCL_BASIC_ENV_UNSPECIFIED;
    
    ZB_ZCL_DECLARE_BASIC_ATTRIB_LIST_HA_ADDS_FULL(basic_attr_list,
                                                  &m_attr_zcl_version,
                                                  &app_version,
                                                  &stack_version,
                                                  &hw_version,
                                                  mf_name,
                                                  model_id,
                                                  date_code,
                                                  &m_attr_power_source,
                                                  location_id,
                                                  &ph_env);
    
    

    And in main():

        ZB_ZCL_SET_STRING_VAL(mf_name,
                              BASIC_MANUF_NAME,
                              ZB_ZCL_STRING_CONST_SIZE(BASIC_MANUF_NAME));
    
        ZB_ZCL_SET_STRING_VAL(model_id,
                              BASIC_MODEL_ID,
                              ZB_ZCL_STRING_CONST_SIZE(BASIC_MODEL_ID));
    
        ZB_ZCL_SET_STRING_VAL(date_code,
                              BASIC_DATE_CODE,
                              ZB_ZCL_STRING_CONST_SIZE(BASIC_DATE_CODE));
    
        ZB_ZCL_SET_STRING_VAL(location_id,
                              BASIC_LOCATION_DESC,
                              ZB_ZCL_STRING_CONST_SIZE(BASIC_LOCATION_DESC));
    

  • Hello,

    I think I am trying to do the same what you did already, can you please help me. I try to create the end Zigbee device and integrate it into the HA. But I am stuck on the connecting. I can pare the device but can't transfer the data.
    And also after I insert your code I can't build it until comment the //ZB_ZCL_DECLARE_BASIC_ATTRIB_LIST_HA_ADDS_FULL

  • Hi, Roman. I thin my code is obsolete as Nordic updated the examples in newer version of the SDK. I'll check if I can compile with newer SDK. 

    change ZB_ZCL_DECLARE_BASIC_ATTRIB_LIST_HA_ADDS_FULL with ZB_ZCL_DECLARE_BASIC_ATTRIB_LIST_EXT?

    I'll check this later tonight.

Related