This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

HOW TO WRITE TO GPIOIS REGISTER

Hi

i was trying generate a interrupt on falling edge... when i gone through the data sheet i found that we need to write 0x00 to the GPIOIS registers to activate the edge triggered interrupts. can anyone please let know how to write to that register.... by using HWREG() functions we can write this much i know.. but not able find the syntax of that can any please help me out

thanku 

chethan kumar

  • Hi,

    Try this:

    GPIOIntTypeSet(uint32_t ui32Port, uint8_t ui8Pins, GPIO_FALLING_EDGE);

    But read the documentation of this function before...

    Petrei

  • Hi,

    have tried that it did not work... so i tried this 

    HWREG(GPIO_PORTE_BASE + 0x404)=0x00;
    HWREG(GPIO_PORTE_BASE + 0x408)=0xFF;
    HWREG(GPIO_PORTE_BASE + 0x40C)=0xFF;

    but still its not working

    0x404 is for GPIOIS, 408 for GPIOIBE and 40c is for GPIOIVE registers

    chethan

  • Perhaps it would be helpful if you posted a bit more of the code which doesn't work? It would also be good if you could explain what you have tried, what you expect to see happen and what you actually see happen. For example, you don't post any of the code you use to configure the pin and you don't say anything about the signal you are applying to the pin.

  • chethan kumar said:
    have tried that it did not work

    Famed, always precise, xtal-clear, "Did not Work!" still far too regularly - invades this hallowed space.

    Might a, "sticky" - boldly titled, "Did not Work - doesn't work HERE!" improve?

    Of course - that advisement is "buried" w/in, "guiding" sticky post.  Promotion to, "boldly titled sticky" - seems superior.  (and lessens needless "wear/tear" upon forum staff... perhaps worthy some consideration should NIH be momentarily relaxed...)

    We reap that which we sow - and present "forum user guide/alert" method - minus "forum police enforcement" - cannot be judged as, "stellar."  (i.e. it, "does not work!")

    An alternative method (likely deemed, "too harsh") via: "Did not Work is insufficient to provide any efficient, meaningful response.  Kindly present/comply with necessary detail - as outlined w/in "Sticky Post xxx" - located atop this forum."  Minus this correction/enforcement - "Did not work" is encouraged - lives/breathes/expands...  And that's a pity...