Pull down SDA pin i2c

Good day

I am developing on the nrf9160dk with a tag reader using i2c and am wanting to know if there is a function to pull down the SDA or SCL pins during operation in order to wake up the slave device.

Thank you in advance.

Kind regards,

Hassan

Parents Reply
  • My code is as follows:

    main.c
    
    #include 	<zephyr/zephyr.h>
    #include 	<drivers/i2c.h>
    #include	<stdio.h>
    #include 	<nrfx_twim.h>
    #include 	<C:\nordicsemi\v2.1.1\modules\hal\nordic\nrfx\hal\nrf_gpio.h>
    #include 	<hal/nrf_twim.h>
    
    
    
    
    
    /** I2C address to be used for ST25DV Data accesses. */
    #define ST25DV_ADDR_DATA_I2C                 0x53
    /** I2C address to be used for ST25DV System accesses. */
    #define ST25DV_ADDR_SYST_I2C                 0x57
    
    
    void Delay(int n)
    {
       int c, d;
       
       for (c = 1; c <= n; c++)
           for (d = 1; d <= n; d++)
           {}
           
       return 0;
    }
    
    
    
    void main(void)
    {   
    	// *************START************* //  
    	
    
      const struct device * i2c_dev;
       i2c_dev = DEVICE_DT_GET(DT_NODELABEL(i2c2));
      if (i2c_dev == NULL) {
    		printk("Unable to bind !\n");
    		return;
    	 }
    
    	 //************** DEVICE SELECT CODE**************//
    
    	const uint8_t devSelCode[8] = {1, 0, 1, 0, 0, 1, 1, 0};
    	 
    	int err1 = i2c_write(i2c_dev,devSelCode,8,ST25DV_ADDR_DATA_I2C);
    	printk("Device select msg: %d", err1);
    
         
    	 
    	
    }
    
    
    
    prj
    
    
    CONFIG_STDOUT_CONSOLE=y
    CONFIG_PRINTK=y
    
    CONFIG_I2C=y
    
    # CONFIG_LOG=y

    Is there possibly something wrong in my configuration that I am not seeing an output in my specified i2c2 pins?  Thank you for your help!

Children
Related