I2C Issues on mDot

Home Forums mDot/xDot I2C Issues on mDot

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #16309
    Andrew Lindsay
    Participant

    Hi,

    I’ve been scratching my head on this one. I’mm seeing failures in reading I2C devices when using the single byte write functions compared to the block write functions. Example:

        i2c.start();
        i2c.write(ADDR);
        i2c.write(READ_RH);
        i2c.stop();

    This does not work on the mDot, but does work correctly on the LPC1768 mbed module.

    When using an analyser, it appears that the stop bit is being sent after the first byte has been sent, this is not correct.

    Is there an issue in the way the I2C has been implemented on the mDot or the I2C driver for the STM32F411RET Processor itself?

    Do you know where I can find the actual code?

    Thanks

    Andrew

    #16313
    Mike Fiore
    Blocked

    Andrew,

    AFAIK there is no I2C code specific to the mDot – it simply uses the I2C driver for the STM32F4 family. All mbed library source is on GitHub: https://github.com/ARMmbed/mbed-os/

    There are release branches for mbed-os-5.1, mbed-os-5.2, and mbed-os-5.3 while master is bleeding edge development. Obviously you’ll want to look at the same version you were testing.

    The STM32F4 cmsis I2C code is in the mbed-os/targets/TARGET_STM/TARGET_STM32F4/device directory.

    Cheers,
    Mike

Viewing 2 posts - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.