Home
last modified time | relevance | path

Searched refs:tx_buf (Results 1 – 25 of 199) sorted by relevance

12345678

/Zephyr-Core-3.6.0/subsys/lorawan/services/
Dclock_sync.c91 uint8_t tx_buf[3 * MAX_CLOCK_SYNC_ANS_LEN]; in clock_sync_package_callback() local
100 if (sizeof(tx_buf) - tx_pos < MAX_CLOCK_SYNC_ANS_LEN) { in clock_sync_package_callback()
107 tx_buf[tx_pos++] = CLOCK_SYNC_CMD_PKG_VERSION; in clock_sync_package_callback()
108 tx_buf[tx_pos++] = LORAWAN_PACKAGE_ID_CLOCK_SYNC; in clock_sync_package_callback()
109 tx_buf[tx_pos++] = CLOCK_SYNC_PACKAGE_VERSION; in clock_sync_package_callback()
142 tx_buf[tx_pos++] = CLOCK_SYNC_CMD_DEVICE_APP_TIME_PERIODICITY; in clock_sync_package_callback()
143 tx_buf[tx_pos++] = 0x00; /* Status: OK */ in clock_sync_package_callback()
145 tx_pos += clock_sync_serialize_device_time(tx_buf + tx_pos, in clock_sync_package_callback()
146 sizeof(tx_buf) - tx_pos); in clock_sync_package_callback()
168 lorawan_services_schedule_uplink(LORAWAN_PORT_CLOCK_SYNC, tx_buf, tx_pos, 0); in clock_sync_package_callback()
[all …]
Dmulticast.c113 uint8_t tx_buf[MAX_MULTICAST_CMDS_PER_PACKAGE * MAX_MULTICAST_ANS_LEN]; in multicast_package_callback() local
122 if (sizeof(tx_buf) - tx_pos < MAX_MULTICAST_ANS_LEN) { in multicast_package_callback()
129 tx_buf[tx_pos++] = MULTICAST_CMD_PKG_VERSION; in multicast_package_callback()
130 tx_buf[tx_pos++] = LORAWAN_PACKAGE_ID_REMOTE_MULTICAST_SETUP; in multicast_package_callback()
131 tx_buf[tx_pos++] = MULTICAST_PACKAGE_VERSION; in multicast_package_callback()
164 tx_buf[tx_pos++] = MULTICAST_CMD_MC_GROUP_SETUP; in multicast_package_callback()
166 tx_buf[tx_pos++] = id; in multicast_package_callback()
169 tx_buf[tx_pos++] = (1U << 2) | id; in multicast_package_callback()
183 tx_buf[tx_pos++] = MULTICAST_CMD_MC_GROUP_DELETE; in multicast_package_callback()
185 tx_buf[tx_pos++] = id; in multicast_package_callback()
[all …]
/Zephyr-Core-3.6.0/drivers/sensor/sht3xd/
Dsht3xd.c57 uint8_t tx_buf[2]; in sht3xd_write_command() local
59 sys_put_be16(cmd, tx_buf); in sht3xd_write_command()
60 return i2c_write_dt(&config->bus, tx_buf, sizeof(tx_buf)); in sht3xd_write_command()
66 uint8_t tx_buf[5]; in sht3xd_write_reg() local
68 sys_put_be16(cmd, &tx_buf[0]); in sht3xd_write_reg()
69 sys_put_be16(val, &tx_buf[2]); in sht3xd_write_reg()
70 tx_buf[4] = sht3xd_compute_crc(val); in sht3xd_write_reg()
72 return i2c_write_dt(&config->bus, tx_buf, sizeof(tx_buf)); in sht3xd_write_reg()
101 uint8_t tx_buf[2]; in sht3xd_sample_fetch() local
103 sys_put_be16(SHT3XD_CMD_FETCH, tx_buf); in sht3xd_sample_fetch()
[all …]
/Zephyr-Core-3.6.0/tests/drivers/uart/uart_async_api/src/
Dtest_uart_async.c146 static void tdata_check_recv_buffers(const uint8_t *tx_buf, uint32_t sent_bytes) in tdata_check_recv_buffers() argument
153 zassert_equal(memcmp(tx_buf, tdata.rx_first_buffer, tdata.recv_bytes_first_buffer), 0, in tdata_check_recv_buffers()
155 zassert_equal(memcmp(tx_buf + tdata.recv_bytes_first_buffer, tdata.rx_second_buffer, in tdata_check_recv_buffers()
174 static const uint8_t tx_buf[] = "0123456789"; in ZTEST_USER() local
177 zassert_not_equal(memcmp(tx_buf, tdata.rx_first_buffer, 5), 0, in ZTEST_USER()
184 uart_tx(uart_dev, tx_buf, 5, 100 * USEC_PER_MSEC); in ZTEST_USER()
192 tdata_check_recv_buffers(tx_buf, sent_bytes); in ZTEST_USER()
194 uart_tx(uart_dev, tx_buf + sent_bytes, 5, 100 * USEC_PER_MSEC); in ZTEST_USER()
209 tdata_check_recv_buffers(tx_buf, sent_bytes); in ZTEST_USER()
232 static const uint8_t tx_buf[] = "test"; in ZTEST_USER() local
[all …]
Dtest_uart_wide.c92 static const uint16_t tx_buf[5] = {0x74, 0x65, 0x73, 0x74, 0x0D}; in ZTEST_USER() local
94 zassert_not_equal(memcmp(tx_buf, rx_buf, 5), 0, in ZTEST_USER()
101 uart_tx_u16(uart_dev, tx_buf, sizeof(tx_buf)/sizeof(uint16_t), 100 * USEC_PER_MSEC); in ZTEST_USER()
107 zassert_equal(memcmp(tx_buf, rx_buf, 5), 0, "Buffers not equal"); in ZTEST_USER()
108 zassert_not_equal(memcmp(tx_buf, rx_buf+5, 5), 0, "Buffers not equal"); in ZTEST_USER()
110 uart_tx_u16(uart_dev, tx_buf, sizeof(tx_buf)/sizeof(uint16_t), 100 * USEC_PER_MSEC); in ZTEST_USER()
121 zassert_equal(memcmp(tx_buf, rx_buf+5, 5), 0, "Buffers not equal"); in ZTEST_USER()
/Zephyr-Core-3.6.0/drivers/sensor/ina23x/
Dina23x_common.c43 uint8_t tx_buf[3]; in ina23x_reg_write() local
45 tx_buf[0] = reg; in ina23x_reg_write()
46 sys_put_be16(val, &tx_buf[1]); in ina23x_reg_write()
48 return i2c_write_dt(bus, tx_buf, sizeof(tx_buf)); in ina23x_reg_write()
/Zephyr-Core-3.6.0/drivers/sensor/bme680/
Dbme680_spi.c36 struct spi_buf tx_buf = { in bme680_set_mem_page() local
41 .buffers = &tx_buf, in bme680_set_mem_page()
67 tx_buf.len = 2; in bme680_set_mem_page()
85 const struct spi_buf tx_buf = { in bme680_reg_write_spi() local
90 .buffers = &tx_buf, in bme680_reg_write_spi()
110 const struct spi_buf tx_buf = { in bme680_reg_read_spi() local
115 .buffers = &tx_buf, in bme680_reg_read_spi()
/Zephyr-Core-3.6.0/drivers/display/
Ddisplay_max7219.c71 uint8_t *tx_buf; member
79 const struct spi_buf tx_buf = { in max7219_transmit_all() local
80 .buf = dev_data->tx_buf, in max7219_transmit_all()
84 .buffers = &tx_buf, in max7219_transmit_all()
89 dev_data->tx_buf[i * 2] = addr; in max7219_transmit_all()
90 dev_data->tx_buf[i * 2 + 1] = value; in max7219_transmit_all()
102 const struct spi_buf tx_buf = { in max7219_transmit_one() local
103 .buf = dev_data->tx_buf, in max7219_transmit_one()
107 .buffers = &tx_buf, in max7219_transmit_one()
113 dev_data->tx_buf[i * 2] = MAX7219_REG_NOOP; in max7219_transmit_one()
[all …]
/Zephyr-Core-3.6.0/drivers/sensor/sgp40/
Dsgp40.c36 uint8_t tx_buf[2]; in sgp40_write_command() local
38 sys_put_be16(cmd, tx_buf); in sgp40_write_command()
40 return i2c_write_dt(&cfg->bus, tx_buf, sizeof(tx_buf)); in sgp40_write_command()
47 uint8_t tx_buf[8]; in sgp40_start_measurement() local
49 sys_put_be16(SGP40_CMD_MEASURE_RAW, tx_buf); in sgp40_start_measurement()
50 sys_put_be24(sys_get_be24(data->rh_param), &tx_buf[2]); in sgp40_start_measurement()
51 sys_put_be24(sys_get_be24(data->t_param), &tx_buf[5]); in sgp40_start_measurement()
53 return i2c_write_dt(&cfg->bus, tx_buf, sizeof(tx_buf)); in sgp40_start_measurement()
/Zephyr-Core-3.6.0/drivers/ieee802154/
Dieee802154_rf2xx_iface.c63 const struct spi_buf tx_buf = { in rf2xx_iface_reg_read() local
68 .buffers = &tx_buf, in rf2xx_iface_reg_read()
106 const struct spi_buf tx_buf[2] = { in rf2xx_iface_reg_write() local
117 .buffers = tx_buf, in rf2xx_iface_reg_write()
175 const struct spi_buf tx_buf = { in rf2xx_iface_frame_read() local
180 .buffers = &tx_buf, in rf2xx_iface_frame_read()
216 const struct spi_buf tx_buf[3] = { in rf2xx_iface_frame_write() local
231 .buffers = tx_buf, in rf2xx_iface_frame_write()
260 const struct spi_buf tx_buf[2] = { in rf2xx_iface_sram_read() local
271 .buffers = tx_buf, in rf2xx_iface_sram_read()
/Zephyr-Core-3.6.0/drivers/sensor/bmi270/
Dbmi270_spi.c28 const struct spi_buf tx_buf = { in bmi270_reg_read_spi() local
33 .buffers = &tx_buf, in bmi270_reg_read_spi()
65 const struct spi_buf tx_buf[2] = { in bmi270_reg_write_spi() local
70 .buffers = tx_buf, in bmi270_reg_write_spi()
71 .count = ARRAY_SIZE(tx_buf) in bmi270_reg_write_spi()
/Zephyr-Core-3.6.0/drivers/sensor/tcn75a/
Dtcn75a_trigger.c51 uint8_t tx_buf[3]; in tcn75a_attr_set() local
59 tx_buf[0] = TCN75A_THYST_REG; in tcn75a_attr_set()
62 tx_buf[0] = TCN75A_TSET_REG; in tcn75a_attr_set()
69 tx_buf[1] = (uint8_t)val->val1; in tcn75a_attr_set()
70 tx_buf[2] = TCN75A_SENSOR_TO_FIXED_PT(val->val2); in tcn75a_attr_set()
72 LOG_DBG("Writing 0x%02X to limit reg %s", *(uint16_t *)(tx_buf + 1), in tcn75a_attr_set()
73 tx_buf[0] == TCN75A_THYST_REG ? "THYST" : "TSET"); in tcn75a_attr_set()
75 return i2c_write_dt(&config->i2c_spec, tx_buf, 3); in tcn75a_attr_set()
/Zephyr-Core-3.6.0/subsys/mgmt/ec_host_cmd/backends/
Dec_host_cmd_backend_simulator.c34 struct ec_host_cmd_tx_buf *tx_buf) in ec_host_cmd_sim_init() argument
39 hc_sim->tx = tx_buf; in ec_host_cmd_sim_init()
60 struct ec_host_cmd_tx_buf **tx_buf) in ec_host_cmd_backend_sim_install_send_cb() argument
63 *tx_buf = hc_sim->tx; in ec_host_cmd_backend_sim_install_send_cb()
/Zephyr-Core-3.6.0/drivers/sensor/stmemsc/
Dstmemsc_spi.c26 const struct spi_buf tx_buf = { .buf = buffer_tx, .len = 2, }; in stmemsc_spi_read() local
27 const struct spi_buf_set tx = { .buffers = &tx_buf, .count = 1 }; in stmemsc_spi_read()
54 const struct spi_buf tx_buf[2] = { in stmemsc_spi_write() local
58 const struct spi_buf_set tx = { .buffers = tx_buf, .count = 2 }; in stmemsc_spi_write()
/Zephyr-Core-3.6.0/drivers/sensor/bmp388/
Dbmp388_spi.c29 const struct spi_buf tx_buf = { in bmp388_reg_read_spi() local
34 .buffers = &tx_buf, in bmp388_reg_read_spi()
69 const struct spi_buf tx_buf = { in bmp388_reg_write_spi() local
74 .buffers = &tx_buf, in bmp388_reg_write_spi()
/Zephyr-Core-3.6.0/drivers/sensor/bmm150/
Dbmm150_spi.c29 const struct spi_buf tx_buf = { in bmm150_reg_read_spi() local
34 .buffers = &tx_buf, in bmm150_reg_read_spi()
69 const struct spi_buf tx_buf = { in bmm150_reg_write_spi() local
74 .buffers = &tx_buf, in bmm150_reg_write_spi()
/Zephyr-Core-3.6.0/drivers/sensor/bme280/
Dbme280_spi.c29 const struct spi_buf tx_buf = { in bme280_reg_read_spi() local
34 .buffers = &tx_buf, in bme280_reg_read_spi()
69 const struct spi_buf tx_buf = { in bme280_reg_write_spi() local
74 .buffers = &tx_buf, in bme280_reg_write_spi()
/Zephyr-Core-3.6.0/samples/drivers/spi_bitbang/src/
Dmain.c35 struct spi_buf tx_buf = { .buf = buff, .len = len }; in test_basic_write_9bit_words() local
36 struct spi_buf_set tx_bufs = { .buffers = &tx_buf, .count = 1 }; in test_basic_write_9bit_words()
65 struct spi_buf tx_buf[2] = { in test_9bit_loopback_partial() local
74 struct spi_buf_set tx_set = { .buffers = tx_buf, .count = 2 }; in test_9bit_loopback_partial()
102 struct spi_buf tx_buf[1] = { in test_8bit_xfer() local
109 struct spi_buf_set tx_set = { .buffers = tx_buf, .count = 1 }; in test_8bit_xfer()
/Zephyr-Core-3.6.0/drivers/sensor/iis2dh/
Diis2dh_spi.c28 const struct spi_buf tx_buf = { in iis2dh_spi_read() local
33 .buffers = &tx_buf, in iis2dh_spi_read()
62 const struct spi_buf tx_buf[2] = { in iis2dh_spi_write() local
73 .buffers = tx_buf, in iis2dh_spi_write()
/Zephyr-Core-3.6.0/drivers/sensor/iis3dhhc/
Diis3dhhc_spi.c27 const struct spi_buf tx_buf = { in iis3dhhc_spi_read() local
32 .buffers = &tx_buf, in iis3dhhc_spi_read()
61 const struct spi_buf tx_buf[2] = { in iis3dhhc_spi_write() local
72 .buffers = tx_buf, in iis3dhhc_spi_write()
/Zephyr-Core-3.6.0/drivers/ethernet/
Doa_tc6.c15 struct spi_buf tx_buf = { .buf = buf, .len = sizeof(buf) }; in oa_tc6_reg_read() local
16 const struct spi_buf_set tx = { .buffers = &tx_buf, .count = 1 }; in oa_tc6_reg_read()
27 tx_buf.len -= sizeof(rvn); in oa_tc6_reg_read()
73 struct spi_buf tx_buf = { .buf = buf_tx, .len = sizeof(buf_tx) }; in oa_tc6_reg_write() local
74 const struct spi_buf_set tx = { .buffers = &tx_buf, .count = 1 }; in oa_tc6_reg_write()
85 tx_buf.len -= sizeof(rvn); in oa_tc6_reg_write()
275 struct spi_buf tx_buf[2]; in oa_tc6_chunk_spi_transfer() local
282 tx_buf[0].buf = &hdr; in oa_tc6_chunk_spi_transfer()
283 tx_buf[0].len = sizeof(hdr); in oa_tc6_chunk_spi_transfer()
285 tx_buf[1].buf = buf_tx; in oa_tc6_chunk_spi_transfer()
[all …]
/Zephyr-Core-3.6.0/drivers/sensor/iis2mdc/
Diis2mdc_spi.c28 const struct spi_buf tx_buf = { in iis2mdc_spi_read() local
33 .buffers = &tx_buf, in iis2mdc_spi_read()
67 const struct spi_buf tx_buf[2] = { in iis2mdc_spi_write() local
78 .buffers = tx_buf, in iis2mdc_spi_write()
/Zephyr-Core-3.6.0/drivers/sensor/ism330dhcx/
Dism330dhcx_spi.c28 const struct spi_buf tx_buf = { in ism330dhcx_spi_read() local
33 .buffers = &tx_buf, in ism330dhcx_spi_read()
68 const struct spi_buf tx_buf[2] = { in ism330dhcx_spi_write() local
79 .buffers = tx_buf, in ism330dhcx_spi_write()
/Zephyr-Core-3.6.0/drivers/sensor/i3g4250d/
Di3g4250d_spi.c25 const struct spi_buf tx_buf = { in i3g4250d_spi_read() local
30 .buffers = &tx_buf, in i3g4250d_spi_read()
62 const struct spi_buf tx_buf[2] = { in i3g4250d_spi_write() local
73 .buffers = tx_buf, in i3g4250d_spi_write()
/Zephyr-Core-3.6.0/samples/drivers/uart/echo_bot/src/
Dmain.c75 char tx_buf[MSG_SIZE]; in main() local
101 while (k_msgq_get(&uart_msgq, &tx_buf, K_FOREVER) == 0) { in main()
103 print_uart(tx_buf); in main()

12345678