Home
last modified time | relevance | path

Searched refs:app_idx (Results 1 – 25 of 29) sorted by relevance

12

/Zephyr-Core-2.7.6/subsys/bluetooth/mesh/
Dapp_keys.c49 uint16_t app_idx; member
61 .app_idx = BT_MESH_KEY_UNUSED,
66 static struct app_key *app_get(uint16_t app_idx) in app_get() argument
69 if (apps[i].app_idx == app_idx) { in app_get()
77 static void clear_app_key(uint16_t app_idx) in clear_app_key() argument
82 snprintk(path, sizeof(path), "bt/mesh/AppKey/%x", app_idx); in clear_app_key()
85 BT_ERR("Failed to clear AppKeyIndex 0x%03x", app_idx); in clear_app_key()
87 BT_DBG("Cleared AppKeyIndex 0x%03x", app_idx); in clear_app_key()
91 static void store_app_key(uint16_t app_idx) in store_app_key() argument
98 snprintk(path, sizeof(path), "bt/mesh/AppKey/%x", app_idx); in store_app_key()
[all …]
Dhealth_cli.c47 ctx->net_idx, ctx->app_idx, ctx->addr, buf->len, in health_fault_status()
93 ctx->net_idx, ctx->app_idx, ctx->addr, buf->len, in health_current_status()
123 ctx->net_idx, ctx->app_idx, ctx->addr, buf->len, in health_period_status()
149 ctx->net_idx, ctx->app_idx, ctx->addr, buf->len, in health_attention_status()
184 int bt_mesh_health_attention_get(uint16_t addr, uint16_t app_idx, uint8_t *attention) in bt_mesh_health_attention_get() argument
188 .app_idx = app_idx, in bt_mesh_health_attention_get()
214 int bt_mesh_health_attention_set(uint16_t addr, uint16_t app_idx, uint8_t attention, in bt_mesh_health_attention_set() argument
219 .app_idx = app_idx, in bt_mesh_health_attention_set()
256 int bt_mesh_health_period_get(uint16_t addr, uint16_t app_idx, uint8_t *divisor) in bt_mesh_health_period_get() argument
260 .app_idx = app_idx, in bt_mesh_health_period_get()
[all …]
Dcdb.c316 uint16_t app_idx; in cdb_app_key_set() local
324 app_idx = strtol(name, NULL, 16); in cdb_app_key_set()
328 BT_DBG("Deleting AppKeyIndex 0x%03x", app_idx); in cdb_app_key_set()
330 app = bt_mesh_cdb_app_key_get(app_idx); in cdb_app_key_set()
344 app = bt_mesh_cdb_app_key_get(app_idx); in cdb_app_key_set()
346 app = bt_mesh_cdb_app_key_alloc(key.net_idx, app_idx); in cdb_app_key_set()
357 BT_DBG("AppKeyIndex 0x%03x recovered from storage", app_idx); in cdb_app_key_set()
497 snprintk(path, sizeof(path), "bt/mesh/cdb/AppKey/%x", app->app_idx); in store_cdb_app_key()
507 static void clear_cdb_app_key(uint16_t app_idx) in clear_cdb_app_key() argument
512 snprintk(path, sizeof(path), "bt/mesh/cdb/AppKey/%x", app_idx); in clear_cdb_app_key()
[all …]
Dcfg_cli.c49 ctx->net_idx, ctx->app_idx, ctx->addr, buf->len, in comp_data_status()
77 ctx->net_idx, ctx->app_idx, ctx->addr, buf->len, in state_status_u8()
140 ctx->net_idx, ctx->app_idx, ctx->addr, buf->len, in krp_status()
180 ctx->net_idx, ctx->app_idx, ctx->addr, buf->len, in relay_status()
217 ctx->net_idx, ctx->app_idx, ctx->addr, buf->len, in net_key_status()
255 ctx->net_idx, ctx->app_idx, ctx->addr, buf->len, in net_key_list()
289 ctx->app_idx, ctx->addr); in node_reset_status()
307 uint16_t app_idx; member
315 uint16_t net_idx, app_idx; in app_key_status() local
319 ctx->net_idx, ctx->app_idx, ctx->addr, buf->len, in app_key_status()
[all …]
Dcfg_srv.c123 ctx->net_idx, ctx->app_idx, ctx->addr, buf->len, in dev_comp_data_get()
177 uint16_t app_idx, uint8_t cred_flag, uint8_t ttl, uint8_t period, in _mod_pub_set() argument
219 if (!bt_mesh_app_key_exists(app_idx) || !bt_mesh_model_has_key(model, app_idx)) { in _mod_pub_set()
234 model->pub->key = app_idx; in _mod_pub_set()
329 uint16_t app_idx, uint16_t net_idx) in send_app_key_status() argument
335 key_idx_pack(&msg, net_idx, app_idx); in send_app_key_status()
381 uint16_t *app_idx = user_data; in mod_app_key_del() local
383 mod_unbind(mod, *app_idx, true); in mod_app_key_del()
386 static void app_key_evt(uint16_t app_idx, uint16_t net_idx, in app_key_evt() argument
390 bt_mesh_model_foreach(&mod_app_key_del, &app_idx); in app_key_evt()
[all …]
Dmesh.h19 void (*evt_handler)(uint16_t app_idx, uint16_t net_idx,
Dshell.c41 uint16_t app_idx; member
682 shell_print(shell, "AppIdx: 0x%04x", net.app_idx); in cmd_appidx()
686 net.app_idx = strtoul(argv[1], NULL, 0); in cmd_appidx()
687 shell_print(shell, "AppIdx set to 0x%04x", net.app_idx); in cmd_appidx()
698 .app_idx = net.app_idx, in cmd_net_send()
1625 addr, mod_id, pub.addr, pub.app_idx, pub.cred_flag, pub.ttl, in mod_pub_get()
1642 pub.app_idx = strtoul(argv[1], NULL, 0); in mod_pub_set()
2021 err = bt_mesh_health_fault_get(net.dst, net.app_idx, cid, &test_id, in cmd_fault_get()
2049 err = bt_mesh_health_fault_clear(net.dst, net.app_idx, cid, in cmd_fault_clear()
2073 err = bt_mesh_health_fault_clear(net.dst, net.app_idx, cid, in cmd_fault_clear_unack()
[all …]
Dapp_keys.h25 int bt_mesh_app_key_set(uint16_t app_idx, uint16_t net_idx,
Dfriend.c56 uint16_t app_idx; member
63 adv_pool[id].app_idx = BT_MESH_KEY_UNUSED; in adv_alloc()
362 uint16_t app_idx = FRIEND_ADV(buf)->app_idx; in unseg_app_sdu_unpack() local
365 .app_idx = app_idx, in unseg_app_sdu_unpack()
381 meta->crypto.dev_key = BT_MESH_IS_DEV_KEY(app_idx); in unseg_app_sdu_unpack()
439 if (FRIEND_ADV(buf)->app_idx == BT_MESH_KEY_UNUSED) { in unseg_app_sdu_prepare()
494 if (FRIEND_ADV(buf)->app_idx != BT_MESH_KEY_UNUSED) { in encrypt_friend_pdu()
505 FRIEND_ADV(buf)->app_idx = BT_MESH_KEY_UNUSED; in encrypt_friend_pdu()
798 .app_idx = BT_MESH_KEY_UNUSED, in send_friend_clear()
1486 info.ctl = (tx->ctx->app_idx == BT_MESH_KEY_UNUSED); in friend_lpn_enqueue_tx()
[all …]
Dtransport.c157 } else if (BT_MESH_IS_DEV_KEY(tx->ctx->app_idx)) { in send_unseg()
374 .app_idx = (tx->ctl ? BT_MESH_KEY_UNUSED : 0), in seg_tx_send_unacked()
467 net_tx->src, net_tx->ctx->addr, net_tx->ctx->app_idx, in send_seg()
486 } else if (BT_MESH_IS_DEV_KEY(net_tx->ctx->app_idx)) { in send_seg()
608 .dev_key = BT_MESH_IS_DEV_KEY(tx->ctx->app_idx), in trans_encrypt()
658 BT_MESH_IS_DEV_KEY(tx->ctx->app_idx))) { in bt_mesh_trans_send()
669 tx->ctx->app_idx, tx->ctx->addr); in bt_mesh_trans_send()
765 rx->ctx.app_idx = bt_mesh_app_key_find(ctx.crypto.dev_key, AID(&hdr), in sdu_recv()
767 if (rx->ctx.app_idx == BT_MESH_KEY_UNUSED) { in sdu_recv()
772 BT_DBG("Decrypted (AppIdx: 0x%03x)", rx->ctx.app_idx); in sdu_recv()
[all …]
Daccess.c188 .app_idx = pub->key, in publish_transmit()
540 tx.ctx->app_idx, tx.ctx->addr); in bt_mesh_msg_send()
677 BT_DBG("app_idx 0x%04x src 0x%04x dst 0x%04x", rx->ctx.app_idx, in bt_mesh_model_recv()
697 if (!bt_mesh_model_has_key(model, rx->ctx.app_idx)) { in bt_mesh_model_recv()
732 if (!bt_mesh_model_has_key(model, ctx->app_idx)) { in bt_mesh_model_send()
733 BT_ERR("Model not bound to AppKey 0x%04x", ctx->app_idx); in bt_mesh_model_send()
Dlpn.c196 .app_idx = BT_MESH_KEY_UNUSED, in send_friend_clear()
307 .app_idx = BT_MESH_KEY_UNUSED, in send_friend_req()
391 .app_idx = BT_MESH_KEY_UNUSED, in send_friend_poll()
705 .app_idx = BT_MESH_KEY_UNUSED, in sub_update()
Dnet.c363 .app_idx = BT_MESH_KEY_UNUSED, in bt_mesh_net_local()
404 const bool ctl = (tx->ctx->app_idx == BT_MESH_KEY_UNUSED); in net_header_encode()
757 rx->ctx.app_idx = BT_MESH_KEY_UNUSED; in bt_mesh_net_decode()
/Zephyr-Core-2.7.6/include/bluetooth/mesh/
Dhealth_cli.h84 int bt_mesh_health_fault_get(uint16_t addr, uint16_t app_idx, uint16_t cid,
101 int bt_mesh_health_fault_clear(uint16_t addr, uint16_t app_idx, uint16_t cid,
116 int bt_mesh_health_fault_test(uint16_t addr, uint16_t app_idx, uint16_t cid,
136 int bt_mesh_health_period_get(uint16_t addr, uint16_t app_idx, uint8_t *divisor);
155 int bt_mesh_health_period_set(uint16_t addr, uint16_t app_idx, uint8_t divisor,
166 int bt_mesh_health_attention_get(uint16_t addr, uint16_t app_idx, uint8_t *attention);
178 int bt_mesh_health_attention_set(uint16_t addr, uint16_t app_idx, uint8_t attention,
Dcfg.h400 uint8_t bt_mesh_app_key_add(uint16_t app_idx, uint16_t net_idx,
427 uint8_t bt_mesh_app_key_update(uint16_t app_idx, uint16_t net_idx,
442 uint8_t bt_mesh_app_key_del(uint16_t app_idx, uint16_t net_idx);
450 bool bt_mesh_app_key_exists(uint16_t app_idx);
Dcdb.h54 uint16_t app_idx; member
240 uint16_t app_idx);
260 struct bt_mesh_cdb_app_key *bt_mesh_cdb_app_key_get(uint16_t app_idx);
Dmsg.h83 uint16_t app_idx; member
/Zephyr-Core-2.7.6/samples/bluetooth/mesh_provisioner/src/
Dmain.c15 static const uint16_t app_idx; variable
72 key = bt_mesh_cdb_app_key_alloc(net_idx, app_idx); in setup_cdb()
74 printk("Failed to allocate app-key 0x%04x\n", app_idx); in setup_cdb()
93 key = bt_mesh_cdb_app_key_get(app_idx); in configure_self()
95 printk("No app-key 0x%04x\n", app_idx); in configure_self()
101 app_idx, key->keys[0].app_key, &status); in configure_self()
109 app_idx, BT_MESH_MODEL_ID_HEALTH_CLI, in configure_self()
137 key = bt_mesh_cdb_app_key_get(app_idx); in configure_node()
139 printk("No app-key 0x%04x\n", app_idx); in configure_node()
144 err = bt_mesh_cfg_app_key_add(net_idx, node->addr, net_idx, app_idx, in configure_node()
[all …]
/Zephyr-Core-2.7.6/samples/bluetooth/mesh_demo/src/
Dmain.c38 static const uint16_t app_idx; variable
123 bt_mesh_cfg_app_key_add(net_idx, addr, net_idx, app_idx, app_key, NULL); in configure()
126 bt_mesh_cfg_mod_app_bind_vnd(net_idx, addr, addr, app_idx, in configure()
130 bt_mesh_cfg_mod_app_bind(net_idx, addr, addr, app_idx, in configure()
226 .app_idx = app_idx, in board_button_1_pressed()
/Zephyr-Core-2.7.6/tests/bluetooth/tester/src/
Dbttester.h1066 uint16_t app_idx; member
1247 uint16_t app_idx; member
1268 uint16_t app_idx; member
1275 uint16_t app_idx; member
1283 uint16_t app_idx; member
1292 uint16_t app_idx; member
1298 uint16_t app_idx; member
1306 uint16_t app_idx; member
1312 uint16_t app_idx; member
Dmesh.c702 .app_idx = vnd_app_key_idx, in net_send()
773 .app_idx = BT_MESH_KEY_DEV, in model_send()
785 ctx.app_idx = model_bound[i].appkey_idx; in model_send()
1230 pub.app_idx = cmd->app_idx; in config_mod_pub_set()
1264 pub.app_idx = cmd->app_idx; in config_mod_pub_va_set()
2150 err = bt_mesh_health_fault_get(cmd->address, cmd->app_idx, cmd->cid, in health_fault_get()
2174 err = bt_mesh_health_fault_clear(cmd->address, cmd->app_idx, in health_fault_clear()
2178 err = bt_mesh_health_fault_clear(cmd->address, cmd->app_idx, in health_fault_clear()
2216 err = bt_mesh_health_fault_test(cmd->address, cmd->app_idx, in health_fault_test()
2220 err = bt_mesh_health_fault_test(cmd->address, cmd->app_idx, in health_fault_test()
[all …]
/Zephyr-Core-2.7.6/tests/bluetooth/bsim_bt/bsim_test_mesh/src/
Dtest_persistence.c66 .app_idx = TEST_APPKEY_0_IDX, \
76 .app_idx = TEST_APPKEY_1_IDX, \
86 .app_idx = 0, \
287 ASSERT_EQUAL(expected->app_idx, got->app_idx); in check_mod_pub_params()
441 tx.ctx->app_idx = BT_MESH_KEY_DEV_REMOTE; /* to resolve devkey */ in test_provisioning_data_load()
Dtest_provision.c253 healthpub.app_idx = 0; in test_provisioner_pb_adv_reprovision()
/Zephyr-Core-2.7.6/samples/boards/reel_board/mesh_badge/src/
Dmesh.c448 .app_idx = APP_IDX, in send_hello()
475 .app_idx = APP_IDX, in send_baduser()
509 .app_idx = APP_IDX, in provision_and_configure()
/Zephyr-Core-2.7.6/samples/bluetooth/mesh/src/
Dmain.c306 .app_idx = models[3].keys[0], /* Use the bound key */ in gen_onoff_send()
312 if (ctx.app_idx == BT_MESH_KEY_UNUSED) { in gen_onoff_send()

12