Home
last modified time | relevance | path

Searched +full:code +full:- +full:0 (Results 1 – 25 of 1040) sorted by relevance

12345678910>>...42

/Zephyr-latest/doc/connectivity/bluetooth/shell/host/
Dgap.rst15 :kconfig:option:`CONFIG_BT_ID_MAX`. To create a new identity, use :code:`bt id-create` command. You
16 can then use it by selecting it with its ID :code:`bt id-select <id>`. Finally, you can list all the
17 available identities with :code:`id-show`.
22 Start scanning by using the :code:`bt scan on` command. Depending on the environment you're in, you
23 may see a lot of lines printed on the shell. To stop the scan, run :code:`bt scan off`, the
28 .. code-block:: console
32 …6E:AE (random), AD evt type 0, RSSI -78 C:1 S:1 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Inter…
33 …B (random), AD evt type 3, RSSI -62 C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval:…
34 …8 (random), AD evt type 3, RSSI -74 C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval:…
35 …4 (random), AD evt type 3, RSSI -67 C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval:…
[all …]
/Zephyr-latest/doc/connectivity/bluetooth/shell/audio/
Dbap.rst9 - Capabilities and Endpoint discovery
10 - Audio Stream Endpoint procedures
15 .. code-block:: console
17 bap --help
25 create_broadcast_sink : 0x<broadcast_id>
27 sync_broadcast : 0x<bis_index> [[[0x<bis_index>] 0x<bis_index>] ...]
28 [bcode <broadcast code> || bcode_str <broadcast code
58 [lang <ISO 639-3 lang>]
74 .. csv-table:: State Machine Transitions
80 "config","discover","idle/codec-configured/qos-configured","codec-configured"
[all …]
Dcap.rst9 The Acceptor will typically be a resource-constrained device, such as a headset, earbud or hearing
16 When the Bluetooth stack has been initialized (:code:`bt init`), the Acceptor can be registered by
17 calling :code:`cap_acceptor init`, which will register the CAS and CSIS services, as well as
20 .. code-block:: console
23 cap_acceptor --help
24 cap_acceptor - Bluetooth CAP acceptor shell commands
27 [rank <int>] [not-lockable] [sirk <data>]
39 ------------------
42 :code:`bt adv-data` or :code:`bt advertise` must be called again to set the new advertising data.
43 If :code:`CONFIG_BT_CSIP_SET_MEMBER_NOTIFIABLE` is enabled, this will also notify connected
[all …]
Dbap_broadcast_assistant.rst21 When the Bluetooth stack has been initialized (:code:`bt init`),
23 the connected device calling :code:`bap_broadcast_assistant discover`, which
27 .. code-block:: console
29 uart:~$ bap_broadcast_assistant --help
30 bap_broadcast_assistant - Bluetooth BAP broadcast assistant client shell
45 broadcast_code : Send a string-based broadcast code of up to 16 bytes
46 <src_id> <broadcast code>
56 .. code-block:: console
66 --------------------------------------------------------
73 .. code-block:: console
[all …]
/Zephyr-latest/tests/drivers/eeprom/api/src/
Dmain.c4 * SPDX-License-Identifier: Apache-2.0
20 zassert_not_equal(0, size, "Unexpected size of zero bytes"); in ZTEST_USER()
26 const uint8_t data[4] = { 0x01, 0x02, 0x03, 0x03 }; in ZTEST_USER()
32 rc = eeprom_write(eeprom, size - 1, data, sizeof(data)); in ZTEST_USER()
33 zassert_equal(-EINVAL, rc, "Unexpected error code (%d)", rc); in ZTEST_USER()
39 const uint8_t wr_buf1[4] = { 0xFF, 0xEE, 0xDD, 0xCC }; in ZTEST_USER()
40 const uint8_t wr_buf2[sizeof(wr_buf1)] = { 0xAA, 0xBB, 0xCC, 0xDD }; in ZTEST_USER()
48 address = 0; in ZTEST_USER()
51 zassert_equal(0, rc, "Unexpected error code (%d)", rc); in ZTEST_USER()
54 zassert_equal(0, rc, "Unexpected error code (%d)", rc); in ZTEST_USER()
[all …]
/Zephyr-latest/tests/subsys/input/longpress/src/
Dmain.c4 * SPDX-License-Identifier: Apache-2.0
19 DEVICE_DT_DEFINE(DT_INST(0, vnd_input_device), NULL, NULL, NULL, NULL,
27 TC_PRINT("%s: %d %x %d\n", __func__, event_count, evt->code, evt->value); in test_cb()
30 memcpy(&last_events[1], &last_events[0], sizeof(struct input_event)); in test_cb()
31 memcpy(&last_events[0], evt, sizeof(struct input_event)); in test_cb()
39 TC_PRINT("%s: %d %x %d\n", __func__, event_count_no_short, evt->code, evt->value); in test_cb_no_short()
42 memcpy(&last_events_no_short[1], &last_events_no_short[0], sizeof(struct input_event)); in test_cb_no_short()
43 memcpy(&last_events_no_short[0], evt, sizeof(struct input_event)); in test_cb_no_short()
49 zassert_equal(event_count, 0); in ZTEST()
53 input_report_key(fake_dev, INPUT_KEY_3, 0, true, K_FOREVER); in ZTEST()
[all …]
/Zephyr-latest/tests/bluetooth/host/id/bt_id_set_adv_own_addr/src/
Dtest_suite_invalid_inputs.c4 * SPDX-License-Identifier: Apache-2.0
24 * - Advertise parameters reference is passed as NULL
27 * - An assertion is raised and execution stops
34 bt_id_set_adv_own_addr(NULL, 0x00, false, &own_addr_type); in ZTEST()
41 * - Address type reference is passed as NULL
44 * - An assertion is raised and execution stops
51 bt_id_set_adv_own_addr(&adv, 0x00, false, NULL); in ZTEST()
59 * - Directed advertising flag is set
60 * - 'BT_LE_FEAT_BIT_PRIVACY' bit isn't set
61 * - Options 'BT_LE_ADV_OPT_CONN' bit is set
[all …]
/Zephyr-latest/samples/boards/intel/adsp/code_relocation/
DREADME.rst1 .. zephyr:code-sample:: intel_adsp_code_relocation
2 :name: Code relocation
4 Relocate code using custom linker script.
9 A simple sample that shows code relocation working for Intel ADSP CAVS
21 .. zephyr-app-commands::
22 :zephyr-app: samples/boards/intel/adsp/code_relocation
31 .. code-block:: console
33 main location: 0xbe0105e4
34 Calling relocated code
35 Relocated code! reloc location 0xbe008010
[all …]
/Zephyr-latest/samples/shields/npm6001_ek/doc/
Dindex.rst1 .. zephyr:code-sample:: npm6001_ek
13 - Regulators (BUCK0/1/2/3 and LDO0/1)
14 - GPIO
15 - Watchdog
24 :alt: nRF52840DK + nPM6001-EK wiring example
27 nRF52840DK + nPM6001-EK wiring example
35 .. zephyr-app-commands::
36 :zephyr-app: samples/shields/npm6001_ek
52 .. code-block:: bash
63 .. code-block:: bash
[all …]
/Zephyr-latest/samples/sensor/tdk_apex/
DREADME.rst1 .. zephyr:code-sample:: tdk_apex
3 :relevant-api: sensor_interface
25- https://invensense.tdk.com/download-pdf/an-000271-icm-42607x-and-icm-42670x-apex-motion-function…
44 to be aliased as ``tdk-apex-sensorN`` where ``N`` goes from ``0`` to ``9``. For example:
46 .. code-block:: devicetree
50 tdk-apex-sensor0 = &icm42670p;
56 .. code-block:: devicetree
58 icm42670p: icm42670p@0 {
64 .. zephyr-app-commands::
65 :zephyr-app: samples/sensor/tdk_apex
[all …]
/Zephyr-latest/include/zephyr/input/
Dinput_hid.h4 * SPDX-License-Identifier: Apache-2.0
16 * @brief Convert an input code to HID code.
18 * Takes an input code as input and returns the corresponding HID code as
19 * output. The return value is -1 if the code is not found, if found it can
22 * @param input_code Event code (see @ref INPUT_KEY_CODES).
23 * @retval the HID code corresponding to the input code.
24 * @retval -1 if there's no HID code for the specified input code.
29 * @brief Convert an input code to HID modifier.
31 * Takes an input code as input and returns the corresponding HID modifier as
32 * output or 0.
[all …]
/Zephyr-latest/samples/net/sockets/coap_server/src/
Dlarge.c5 * SPDX-License-Identifier: Apache-2.0
28 uint8_t code; in large_get() local
33 if (ctx.total_size == 0) { in large_get()
38 if (r < 0) { in large_get()
39 return -EINVAL; in large_get()
42 code = coap_header_get_code(request); in large_get()
48 LOG_INF("type: %u code %u id %u", type, code, id); in large_get()
54 if (r < 0) { in large_get()
55 return -EINVAL; in large_get()
60 if (r < 0) { in large_get()
[all …]
/Zephyr-latest/samples/application_development/code_relocation_nocopy/
DREADME.rst1 .. zephyr:code-sample:: code_relocation_nocopy
2 :name: Code relocation nocopy
4 Relocate code, data, or bss sections using a custom linker script.
8 A simple example that demonstrates how relocation of code, data or bss sections
11 Differently from the code relocation sample, this sample is relocating the
12 content of the ext_code.c file to a different FLASH section and the code is XIP
13 directly from there without the need to copy / relocate the code. All other code
20 mapped to 0x10000000.
24 .. zephyr-app-commands::
25 :zephyr-app: samples/application_development/code_relocation_nocopy
[all …]
/Zephyr-latest/tests/bluetooth/host/id/bt_id_set_adv_private_addr/src/
Dtest_suite_invalid_cases.c4 * SPDX-License-Identifier: Apache-2.0
27 * - A NULL value is passed to the function as a reference
30 * - An assertion is raised and execution stops
42 * - A valid advertise parameters reference is used
43 * - bt_rand() fails and returns a negative error code (failure)
46 * - bt_id_set_adv_private_addr() returns a negative error code (failure)
55 bt_rand_fake.return_val = -1; in ZTEST()
59 zassert_true(err < 0, "Unexpected error code '%d' was returned", err); in ZTEST()
65 __ASSERT_NO_MSG(len == sizeof(BT_ADDR->val)); in bt_rand_custom_fake()
67 return 0; in bt_rand_custom_fake()
[all …]
/Zephyr-latest/tests/drivers/retained_mem/api/src/
Dmain.c4 * SPDX-License-Identifier: Apache-2.0
14 /* For size-limited tests, use data size of 1 byte */
16 0x5b,
19 0x00,
25 0x23, 0x82, 0xa8, 0x7b, 0xde, 0x18, 0x00, 0xff, 0x8e, 0xd6,
28 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
37 rc = retained_mem_write(retained_mem_test_device, 0, data, sizeof(data)); in ZTEST()
38 zassert_equal(rc, 0, "Return code should be success"); in ZTEST()
40 memset(buffer, 0, sizeof(buffer)); in ZTEST()
42 rc = retained_mem_read(retained_mem_test_device, 0, buffer, sizeof(buffer)); in ZTEST()
[all …]
/Zephyr-latest/tests/bluetooth/host/id/bt_id_set_private_addr/src/
Dtest_suite_invalid_cases.c4 * SPDX-License-Identifier: Apache-2.0
26 * - Non-valid 'id' should be used (>= CONFIG_BT_ID_MAX)
29 * - An assertion is raised and execution stops
34 bt_id_set_private_addr(0xff); in ZTEST()
41 * - Any ID value can be used
42 * - bt_rand() fails and returns a negative error code (failure)
43 * - 'CONFIG_BT_PRIVACY' isn't enabled
46 * - bt_id_set_private_addr() returns a negative error code (failure)
54 bt_rand_fake.return_val = -1; in ZTEST()
58 zassert_true(err < 0, "Unexpected error code '%d' was returned", err); in ZTEST()
[all …]
/Zephyr-latest/subsys/net/l2/ppp/
Doptions.c4 * SPDX-License-Identifier: Apache-2.0
23 int (*parse)(struct net_pkt *pkt, uint8_t code, in ppp_parse_options() argument
36 return -EMSGSIZE; in ppp_parse_options()
39 while (remaining > 0) { in ppp_parse_options()
41 if (ret < 0) { in ppp_parse_options()
44 return -EBADMSG; in ppp_parse_options()
48 if (ret < 0) { in ppp_parse_options()
51 return -EBADMSG; in ppp_parse_options()
54 opt_val_len = opt_len - sizeof(opt_type) - sizeof(opt_len); in ppp_parse_options()
58 NET_DBG("[%s/%p] option %s (%d) len %d", fsm->name, fsm, in ppp_parse_options()
[all …]
/Zephyr-latest/include/zephyr/fs/
Dfs_sys.h4 * SPDX-License-Identifier: Apache-2.0
33 * @return 0 on success, negative errno code on fail.
43 * @return Number of bytes read on success, negative errno code on fail.
52 * @return Number of bytes written on success, negative errno code on fail.
62 * @return New position in the file or negative errno code on fail.
69 * @return Current position in the file or negative errno code on fail.
77 * @return 0 on success, negative errno code on fail.
84 * @return 0 on success, negative errno code on fail.
91 * @return 0 on success, negative errno code on fail.
105 * @return 0 on success, negative errno code on fail.
[all …]
/Zephyr-latest/samples/subsys/modbus/tcp_gateway/
DREADME.rst1 .. zephyr:code-sample:: modbus-gateway
2 :name: Modbus TCP-to-serial gateway
3 :relevant-api: modbus bsd_sockets
5 Implement a gateway between an Ethernet TCP-IP network and a Modbus serial line.
11 an Ethernet TCP-IP network and a Modbus serial line.
16 This sample has been tested with FRDM-K64F board,
21 :zephyr:code-sample:`modbus-rtu-server` sample. Client is running on a PC or laptop.
26 In addition to the evaluation boards RS-485 shields may be used.
27 The A+, B- lines of the RS-485 shields should be connected together.
38 .. zephyr-app-commands::
[all …]
/Zephyr-latest/samples/subsys/edac/
DREADME.rst1 .. zephyr:code-sample:: edac
3 :relevant-api: edac
19 .. zephyr-app-commands::
20 :zephyr-app: samples/subsys/edac
21 :host-os: unix
39 .. code-block:: console
41 uart:~$ edac -h
42 edac - EDAC information
51 .. code-block:: console
53 uart:~$ edac info -h
[all …]
/Zephyr-latest/doc/services/debugging/
Dgdbstub.rst51 * If there are spare UART devices on the board, set ``zephyr,gdbstub-uart``
75 .. code-block:: bash
81 .. code-block:: bash
97 .. code-block:: console
99 ./scripts/twister -p qemu_x86 -T tests/subsys/debug/gdbstub
101 The test should run successfully, and now let's do something similar step-by-step
112 .. zephyr-app-commands::
113 :zephyr-app: tests/subsys/debug/gdbstub
114 :host-os: unix
116 :gen-args: '-DCONFIG_QEMU_EXTRA_FLAGS="-serial tcp:localhost:5678,server"'
[all …]
/Zephyr-latest/samples/subsys/modbus/tcp_server/
DREADME.rst1 .. zephyr:code-sample:: modbus-tcp-server
3 :relevant-api: modbus bsd_sockets
16 This sample has been tested with FRDM-K64F board,
34 .. zephyr-app-commands::
35 :zephyr-app: samples/subsys/modbus/tcp_server
43 .. code-block:: console
45 # pymodbus.console tcp --host 192.0.2.1 --port 502
50 .. code-block:: console
53 > client.write_coil address=0 value=1 slave=1
57 .. code-block:: console
[all …]
/Zephyr-latest/boards/snps/em_starterkit/
Dboard.dtsi1 /* SPDX-License-Identifier: Apache-2.0 */
4 #include <zephyr/dt-bindings/input/input-event-codes.h>
23 compatible = "gpio-leds";
25 gpios = <&gpio1 0 0>;
26 label = "LED 0";
29 gpios = <&gpio1 1 0>;
33 gpios = <&gpio1 2 0>;
37 gpios = <&gpio1 3 0>;
41 gpios = <&gpio1 4 0>;
45 gpios = <&gpio1 5 0>;
[all …]
/Zephyr-latest/samples/subsys/usb/hid-mouse/
DREADME.rst1 .. zephyr:code-sample:: usb-hid-mouse
3 :relevant-api: _usb_device_core_api usb_hid_device_api input_interface
13 the number of buttons on the board) a right mouse button, X-axis movement,
14 and Y-axis movement.
17 This sample can be found under :zephyr_file:`samples/subsys/usb/hid-mouse` in the
24 There must be a :dtcompatible:`gpio-keys` group of buttons or keys defined at
30 - ``INPUT_KEY_0``: left button
31 - ``INPUT_KEY_1``: right button
32 - ``INPUT_KEY_2``: move the mouse along the x-axis
33 - ``INPUT_KEY_3``: move the mouse along the y-axis
[all …]
/Zephyr-latest/samples/subsys/display/lvgl/boards/
Dnative_posix.overlay4 * SPDX-License-Identifier: Apache-2.0
7 #include <zephyr/dt-bindings/input/input-event-codes.h>
8 #include <zephyr/dt-bindings/lvgl/lvgl.h>
16 compatible = "gpio-qdec";
18 steps-per-period = <4>;
20 sample-time-us = <2000>;
21 idle-timeout-ms = <200>;
25 compatible = "gpio-keys";
27 /* gpio0 pin 0 is already aliased to led0 */
29 zephyr,code = <INPUT_KEY_R>;
[all …]

12345678910>>...42