This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

When configuring a pin as a task pin in GPIOTE, is it still possible to use the input buffer?

Hi there,

The PS says that a pin configure as a task will get the output overrided, but does it also get the input overrided?

Regards

Parents Reply Children
  • Hi Hakon,

    I am not planning on connect the same pin to 2 GPIOTE events.

    I only need to connect 2 events to master SCL & SDA, and 2 tasks to slave SCL & SDA, but I need to be able to read the actual state on the task pins.

    That is why I am asking about if the task configuration will force the INPUT OVERRIDE or only the DIR OVERRIDE.

    Can you confirm that?

    By software I can reverse the direction anytime it needs to, and checking the input value of an output task I can decide if the direction reverses or if the master inputs are forced down.

  • David Fernandez said:
    I only need to connect 2 events to master SCL & SDA, and 2 tasks to slave SCL & SDA, but I need to be able to read the actual state on the task pins.

    Taking two events and triggering two tasks in another peripheral is no problem, using individual PPI channels, so lets forget about that scenario.

    You want to read the state of a task pin - what do you mean by this? Do you want to read the actual state of the GPIO taken by a peripheral, or do you want to trigger something when that task occurs?

    It still sounds to me like you want to connect several peripherals to the same GPIO, ie: TWIS and GPIOTE to operate on the same pin.

     

    Best regards,

    Håkon

  • Hi Hakon,

    What I mean by reading the state of a task pin is that:

    1. I want the input buffer to be connected to the pin.

    2. I want to get the value seen by the input buffer.

    Since the task pin will be configured as S0D1 or H0D1, the interesting thing is to read it when the task sets it.

  • Hi,

     

    If I understand correctly, you want to read the input of an GPIO configured as output (overridden by a peripheral). That is not possible. You need to then connect that specific pin to another GPIO (configured as input) to do this.

     

    Kind regards,

    Håkon

Related