Home
last modified time | relevance | path

Searched +full:i2c +full:- +full:errors (Results 1 – 25 of 54) sorted by relevance

123

/Zephyr-latest/drivers/i2c/
DKconfig.sc18im7042 # SPDX-License-Identifier: Apache-2.0
5 bool "NXP SC18IM704 I2C controller driver"
10 Enables NXP SC18IM704 I2C controller driver
15 int "SC18IM704 I2C init priority"
18 SC18IM704 I2C controller initialization priority.
23 bool "Verify SC18IM704 I2C transfers"
26 Verify the I2C state register after I2C transfers to detect errors.
Di2c_sam0.c4 * SPDX-License-Identifier: Apache-2.0
13 #include <zephyr/drivers/i2c.h>
21 #include "i2c-priv.h"
73 while ((regs->SYNCBUSY.reg & SERCOM_I2CM_SYNCBUSY_MASK) != 0) { in wait_synchronization()
77 while ((regs->STATUS.reg & SERCOM_I2CM_STATUS_SYNCBUSY) != 0) { in wait_synchronization()
86 struct i2c_sam0_dev_data *data = dev->data; in i2c_sam0_terminate_on_error()
87 const struct i2c_sam0_dev_config *const cfg = dev->config; in i2c_sam0_terminate_on_error()
88 SercomI2cm *i2c = cfg->regs; in i2c_sam0_terminate_on_error() local
90 if (!(i2c->STATUS.reg & (SERCOM_I2CM_STATUS_ARBLOST | in i2c_sam0_terminate_on_error()
107 if (cfg->dma_channel != 0xFF) { in i2c_sam0_terminate_on_error()
[all …]
Di2c_cc32xx.c4 * SPDX-License-Identifier: Apache-2.0
13 #include <zephyr/drivers/i2c.h>
22 #include <driverlib/i2c.h>
29 #include "i2c-priv.h"
44 (((const struct i2c_cc32xx_config *const)(dev)->config)->base)
53 * I2C API without having to re-read I2C registers.
56 /* I2C was primed for a write operation */
58 /* I2C was primed for a read operation */
60 /* I2C error occurred */
91 return -EINVAL; in i2c_cc32xx_configure()
[all …]
Di2c_mchp_xec_v2.c5 * SPDX-License-Identifier: Apache-2.0
16 #include <zephyr/drivers/i2c.h>
25 #include "i2c-priv.h"
34 /* I2C timeout is 10 ms (WAIT_INTERVAL * WAIT_COUNT) */
40 /* I2C Read/Write bit pos */
43 /* I2C recover SCL low retries */
45 /* I2C recover SDA low retries */
47 /* I2C recovery bit bang delay */
49 /* I2C recovery SCL sample delay */
52 /* I2C SCL and SDA lines(signals) */
[all …]
/Zephyr-latest/include/zephyr/drivers/i2c/
Drtio.h4 * SPDX-License-Identifier: Apache-2.0
11 #include <zephyr/drivers/i2c.h>
19 * @brief Driver context for implementing i2c with rtio
55 * @brief Initialize an i2c rtio context
57 * @param ctx I2C RTIO driver context
58 * @param dev I2C bus
63 * @brief Signal that the current (ctx->txn_curr) submission has been completed
65 * @param ctx I2C RTIO driver context
66 * @param status Completion status, negative values are errors
82 * @brief Configure the I2C bus controller
[all …]
/Zephyr-latest/drivers/sensor/silabs/si7055/
Dsi7055.c5 * SPDX-License-Identifier: Apache-2.0
14 #include <zephyr/drivers/i2c.h>
27 struct i2c_dt_spec i2c; member
34 * -EIO for I/O and checksum errors
38 struct si7055_data *si_data = dev->data; in si7055_get_temperature()
39 const struct si7055_config *config = dev->config; in si7055_get_temperature()
47 retval = i2c_burst_read_dt(&config->i2c, SI7055_MEAS_TEMP_MASTER_MODE, in si7055_get_temperature()
51 * https://www.silabs.com/documents/public/data-sheets/Si7050-1-3-4-5-A20.pdf in si7055_get_temperature()
59 return(-EIO); in si7055_get_temperature()
62 si_data->temperature = (temp[SI7055_TEMPERATURE_DATA_BYTE_0] in si7055_get_temperature()
[all …]
/Zephyr-latest/doc/build/dts/
Dtroubleshooting.rst1 .. _dt-trouble:
8 See :ref:`dt-howtos` for other "HOWTO" style information.
10 .. _dt-trouble-try-pristine:
17 See :ref:`west-building-pristine` for examples, or just delete the build
39 .. code-block:: c
43 where ``NODE_ID`` is a valid :ref:`node identifier <dt-node-identifiers>`, but
53 = "okay";``; see :ref:`dt-important-props` for more information about
71 the node you are interested in is ``/soc/i2c@deadbeef``:
73 .. code-block:: none
88 * 15 /soc/i2c@deadbeef
[all …]
/Zephyr-latest/dts/bindings/sensor/
Dti,tmag5273.yaml2 # SPDX-License-Identifier: Apache-2.0
5 Texas Instruments Low-Power Linear 3D Hall-Effect Sensor with an I2C interface.
7 See the specification for the default I2C address.
17 #include <zephyr/dt-bindings/sensor/tmag5273.h>
27 include: [sensor-device.yaml, i2c-device.yaml]
30 operation-mode:
38 - 0 # TMAG5273_DT_OPER_MODE_CONTINUOUS (continuous)
39 - 1 # TMAG5273_DT_OPER_MODE_STANDBY (standby)
49 - 0 # TMAG5273_DT_AXIS_NONE
50 - 1 # TMAG5273_DT_AXIS_X
[all …]
/Zephyr-latest/doc/hardware/peripherals/
Dsmbus.rst13 System Management Bus (SMBus) is derived from I2C for communication
17 report errors, accept control parameters, etc.
30 a three-bytes message to a special address "SMBus Host (0x08)" with own
43 .. _smbus-controller-api:
Di3c.rst3 Improved Inter-Integrated Circuit (I3C) Bus
6 I3C (Improved Inter-Integrated Circuit) is a two-signal shared
18 .. _i3c-controller-api:
36 .. code-block:: c
82 for example, at power-on. So it is a good idea to reset and
113 the assignment process and errors out.
133 #. Do ``ENEC`` to re-enable events from devices.
135 * The helper function, :c:func:`i3c_bus_init`, only re-enables
136 hot-join events. IBI event should only be enabled when
139 In-Band Interrupt (IBI)
[all …]
/Zephyr-latest/drivers/sensor/sensirion/sgp40/
Dsgp40.c4 * SPDX-License-Identifier: Apache-2.0
10 #include <zephyr/drivers/i2c.h>
35 const struct sgp40_config *cfg = dev->config; in sgp40_write_command()
40 return i2c_write_dt(&cfg->bus, tx_buf, sizeof(tx_buf)); in sgp40_write_command()
45 const struct sgp40_config *cfg = dev->config; in sgp40_start_measurement()
46 struct sgp40_data *data = dev->data; 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()
61 struct sgp40_data *data = dev->data; in sgp40_attr_set()
[all …]
/Zephyr-latest/drivers/sensor/ti/tmag5273/
Dtmag5273.c4 * SPDX-License-Identifier: Apache-2.0
15 #include <zephyr/dt-bindings/sensor/tmag5273.h>
21 #include <zephyr/drivers/i2c.h>
39 * Since the register counting is zero-based, one byte needs to be added to get the correct size.
44 (TMAG5273_REG_RESULT_END - TMAG5273_REG_RESULT_BEGIN + 1 + TMAG5273_CRC_I2C_SIZE)
48 struct i2c_dt_spec i2c; member
77 int16_t x_sample; /** measured B-field @x-axis */
78 int16_t y_sample; /** measured B-field @y-axis */
79 int16_t z_sample; /** measured B-field @z-axis */
82 uint16_t xyz_range; /** magnetic range for x/y/z-axis in mT */
[all …]
/Zephyr-latest/drivers/usb_c/tcpc/
Dtcpci.c3 * SPDX-License-Identifier: Apache-2.0
212 int tcpci_read_reg8(const struct i2c_dt_spec *i2c, uint8_t reg, uint8_t *value) in tcpci_read_reg8() argument
217 ret = i2c_write_read(i2c->bus, i2c->addr, &reg, sizeof(reg), value, sizeof(*value)); in tcpci_read_reg8()
225 LOG_ERR(LOG_COMM_ERR_STR, i2c->bus->name, i2c->addr, "r8", reg, *value); in tcpci_read_reg8()
231 int tcpci_write_reg8(const struct i2c_dt_spec *i2c, uint8_t reg, uint8_t value) in tcpci_write_reg8() argument
237 ret = i2c_write(i2c->bus, buf, 2, i2c->addr); in tcpci_write_reg8()
245 LOG_ERR(LOG_COMM_ERR_STR, i2c->bus->name, i2c->addr, "w8", reg, value); in tcpci_write_reg8()
251 int tcpci_update_reg8(const struct i2c_dt_spec *i2c, uint8_t reg, uint8_t mask, uint8_t value) in tcpci_update_reg8() argument
256 ret = tcpci_read_reg8(i2c, reg, &old_value); in tcpci_update_reg8()
264 ret = tcpci_write_reg8(i2c, reg, old_value); in tcpci_update_reg8()
[all …]
/Zephyr-latest/drivers/sensor/apds9306/
Dapds9306.c2 * Author: Daniel Kampert <DanielKampert@kampis-Elektroecke.de>
7 #include <zephyr/drivers/i2c.h>
53 struct i2c_dt_spec i2c; member
86 const struct apds9306_config *config = dev->config; in apds9306_enable()
88 return i2c_reg_update_byte_dt(&config->i2c, APDS9306_REGISTER_MAIN_CTRL, in apds9306_enable()
94 const struct apds9306_config *config = dev->config; in apds9306_standby()
96 return i2c_reg_update_byte_dt(&config->i2c, APDS9306_REGISTER_MAIN_CTRL, in apds9306_standby()
107 struct apds9306_data *data = item->dev->data; in apds9306_worker()
108 const struct apds9306_config *config = item->dev->config; in apds9306_worker()
110 if (i2c_reg_read_byte_dt(&config->i2c, APDS9306_REGISTER_MAIN_STATUS, &buffer[0])) { in apds9306_worker()
[all …]
/Zephyr-latest/include/zephyr/audio/
Dcodec.h4 * SPDX-License-Identifier: Apache-2.0
53 AUDIO_PCM_WIDTH_16_BITS = 16, /**< 16-bit sample width */
54 AUDIO_PCM_WIDTH_20_BITS = 20, /**< 20-bit sample width */
55 AUDIO_PCM_WIDTH_24_BITS = 24, /**< 24-bit sample width */
56 AUDIO_PCM_WIDTH_32_BITS = 32, /**< 32-bit sample width */
133 int vol; /**< Volume level (codec-specific) */
141 /** Output over-current */
144 /** Codec over-temperature */
153 /** Output direct-current */
162 * @param errors Device errors (bitmask of @ref audio_codec_error_type values)
[all …]
/Zephyr-latest/drivers/sensor/ams/ccs811/
Dccs811.c5 * SPDX-License-Identifier: Apache-2.0
12 #include <zephyr/drivers/i2c.h>
26 const struct ccs811_config *config = dev->config; in set_wake()
28 gpio_pin_set_dt(&config->wake_gpio, enable); in set_wake()
42 const struct ccs811_config *config = dev->config; in fetch_status()
46 if (i2c_reg_read_byte_dt(&config->i2c, CCS811_REG_STATUS, &status) < 0) { in fetch_status()
48 return -EIO; in fetch_status()
55 if (i2c_reg_read_byte_dt(&config->i2c, CCS811_REG_ERROR_ID, &error_id) < 0) { in fetch_status()
57 return -EIO; in fetch_status()
73 struct ccs811_data *drv_data = dev->data; in ccs811_result()
[all …]
/Zephyr-latest/drivers/i3c/
Di3c_mcux.c6 * SPDX-License-Identifier: Apache-2.0
129 * @param reg Pointer to 32-bit Register.
135 * @retval -ETIMEDOUT Timedout without matching.
143 * quickly (some sub-microseconds) so no extra in reg32_poll_timeout()
147 return -ETIMEDOUT; in reg32_poll_timeout()
155 * @param reg Pointer to 32-bit Register.
173 * @param reg Pointer to 32-bit register.
190 * @param reg Pointer to 32-bit register.
209 uint32_t intmask = base->MINTSET; in mcux_i3c_interrupt_disable()
211 base->MINTCLR = intmask; in mcux_i3c_interrupt_disable()
[all …]
/Zephyr-latest/doc/releases/
Drelease-notes-2.1.rst13 * Expanded support for ARMv6-M architecture.
36 * Use logging for userspace errors
50 hardware-based stack overflow detection) in ARMv6-M architecture
51 * Added QEMU support for ARMv6-M architecture
52 * Extended test coverage for ARM-specific kernel features in ARMv6-M
54 * Enhanced runtime MPU programming in ARMv8-M architecture, making
55 the full partitioning of kernel SRAM memory a user-configurable
57 * Added CMSIS support for Cortex-R architectures.
59 * Added missing Cortex-R CPU device tree bindings.
60 * Fixed incorrect Cortex-R device tree specification.
[all …]
Drelease-notes-1.11.rst12 * Thread-level memory protection on x86, ARC and Arm, userspace and memory
15 * Initial Armv8-M architecture support.
20 * Firmware over-the-air (FOTA) updates over BLE using MCUmgr.
32 * SMP-aware scheduler
47 * Armv8-M initial architecture support, including the following cores:
49 * Arm Cortex-M23
50 * Arm Cortex-M33
74 * Refactored dts.fixup so common SoC-related fixes are in arch/<*>/soc
75 and board dts.fixup is only used for board-specific items.
81 * Fixed ESP32 I2C driver
[all …]
Drelease-notes-2.3.rst18 with future support for features like 64-bit and absolute timeouts in mind
21 * Zephyr now integrates with the TF-M (Trusted Firmware M) PSA-compliant
24 * The CMSIS-DSP library is now included and integrated
33 * CVE-2020-10022: UpdateHub Module Copies a Variable-Sized Hash String
34 into a fixed-size array.
35 * CVE-2020-10059: UpdateHub Module Explicitly Disables TLS
37 * CVE-2020-10061: Improper handling of the full-buffer case in the
39 * CVE-2020-10062: Packet length decoding error in MQTT
40 * CVE-2020-10063: Remote Denial of Service in CoAP Option Parsing Due
42 * CVE-2020-10068: In the Zephyr project Bluetooth subsystem, certain
[all …]
Drelease-notes-1.13.rst16 * Support for IEEE 802.1AS-2011 generalized Precision Time Protocol (gPTP)
23 * Basic support for Arm TrustZone in Armv8-M
42 * arch: arm: implement ARMv8-M MPU driver
44 * arch: arm: macro API for defining non-secure entry functions
48 * arch: ARM: Change the march used by cortex-m0 and cortex-m0plus
50 * arch: arm: basic Arm TrustZone-M functionality for Cortex-M23 and Cortex-M33
51 * arch: arm: built-in stack protection using Armv8-M SPLIM registers
52 * arch: arm: API for using TT intrinsics in Secure/Non-Secure Armv8-M firmware
63 * riscv32: riscv-privilege: Microsemi Mi-V support
92 * i2c: Added support for STM32F7
[all …]
Drelease-notes-2.4.rst33 * CVE-2020-10060: UpdateHub Might Dereference An Uninitialized Pointer
34 * CVE-2020-10064: Improper Input Frame Validation in ieee802154 Processing
35 * CVE-2020-10066: Incorrect Error Handling in Bluetooth HCI core
36 * CVE-2020-10072: all threads can access all socket file descriptors
37 * CVE-2020-13598: FS: Buffer Overflow when enabling Long File Names in FAT_FS and calling fs_stat
38 * CVE-2020-13599: Security problem with settings and littlefs
39 * CVE-2020-13601: Under embargo until 2020/11/18
40 * CVE-2020-13602: Remote Denial of Service in LwM2M do_write_op_tlv
50 <https://github.com/zephyrproject-rtos/zephyr/issues?q=is%3Aissue+is%3Aopen+label%3Abug>`_.
62 * The :c:func:`wdt_feed` function will now return ``-EAGAIN`` if
[all …]
/Zephyr-latest/include/zephyr/drivers/
Di3c.h5 * SPDX-License-Identifier: Apache-2.0
29 #include <zephyr/drivers/i2c.h>
42 * - BCR[7:6]: Device Role
43 * - 0: I3C Target
44 * - 1: I3C Controller capable
45 * - 2: Reserved
46 * - 3: Reserved
48 * - BCR[5]: Advanced Capabilities
49 * - 0: Does not support optional advanced capabilities.
50 * - 1: Supports optional advanced capabilities which
[all …]
/Zephyr-latest/drivers/counter/
Drtc_mcp7940n.c2 * Copyright (c) 2019-2020 Peter Bigot Consulting, LLC
5 * SPDX-License-Identifier: Apache-2.0
18 #include <zephyr/drivers/i2c.h>
45 * errors.
51 struct i2c_dt_spec i2c; member
80 struct mcp7940n_data *data = dev->data; in decode_rtc()
84 time.tm_sec = RTC_BCD_DECODE(data->registers.rtc_sec.sec); in decode_rtc()
85 time.tm_min = RTC_BCD_DECODE(data->registers.rtc_min.min); in decode_rtc()
86 time.tm_hour = RTC_BCD_DECODE(data->registers.rtc_hours.hr); in decode_rtc()
87 time.tm_mday = RTC_BCD_DECODE(data->registers.rtc_date.date); in decode_rtc()
[all …]
/Zephyr-latest/doc/project/
Ddev_env_and_tools.rst1 .. _dev-environment-and-tools:
42 code-owner review. Additionally, some changes might require further discussions
50 :figclass: align-center
55 ---------
57 - An author of a change can suggest in his pull-request which category a change
61 - The project will use the label system to categorize the pull requests.
62 - Changes should not be merged before the minimal time has expired.
65 -----------------
82 Trivial changes are those that appear obvious enough and do not require maintainer or code-owner
86 - Documentation changes
[all …]

123