Hi!
We use the following approach:
- If the pin is configured using nrf_gpio_cfg_input we read the pin value via nrf_gpio_pin_read;
- If the pin is configured using nrf_gpio_cfg_output we read the pin value via nrf_gpio_pin_out_read;
We use nrf_gpio_pin_write to write the pin value (as I see it uses nrf_gpio_pin_set to write the value).
But after writing via nrf_gpio_pin_write we see the different value when reading via nrf_gpio_pin_out_read. As I see nrf_gpio_pin_set sets the value of OUTSET using nrf_gpio_port_out_set. And nrf_gpio_pin_out_read reads the value of OUT.
My question is what is the difference between nrf_gpio_port_out_set and nrf_gpio_port_out_write? When can we use nrf_gpio_pin_out_read to read the last written value?