<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: LLWU on PORTE not working in Kinetis Microcontrollers</title>
    <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/LLWU-on-PORTE-not-working/m-p/385213#M20712</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Rahul&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Since the location of the LLWU pins are not the same on all devices it is important to specify which part you are using - &lt;EM&gt;presumably a Kinetis K part&lt;/EM&gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Below is how I verify all 16 K64 LLWU interrupt (for example):&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE __default_attr="c++" __jive_macro_name="code" class="jive_text_macro jive_macro_code _jivemacro_uid_14263097136291946" jivemacro_uid="_14263097136291946"&gt;
&lt;P&gt;// Configure all 16 K64 LLWU pins&lt;/P&gt;
&lt;P&gt;//&lt;/P&gt;
&lt;P&gt;INTERRUPT_SETUP interrupt_setup; // interrupt configuration parameters&lt;/P&gt;
&lt;P&gt;interrupt_setup.int_type = PORT_INTERRUPT; // identifier to configure port interrupt&lt;/P&gt;
&lt;P&gt;interrupt_setup.int_port_sense = (IRQ_FALLING_EDGE | PULLUP_ON | ENABLE_PORT_MODE);&lt;/P&gt;
&lt;P&gt;interrupt_setup.int_type = WAKEUP_INTERRUPT; // configure as wake-up interrupt&lt;/P&gt;
&lt;P&gt;interrupt_setup.int_handler = test_irq_5;&lt;/P&gt;
&lt;P&gt;interrupt_setup.int_port = PORTA; // the port that the interrupt input is on&lt;/P&gt;
&lt;P&gt;interrupt_setup.int_port_bits = (PORTA_BIT4 | PORTA_BIT13);&lt;/P&gt;
&lt;P&gt;fnConfigureInterrupt((void *)&amp;amp;interrupt_setup); // configure wakeup pins on this port&lt;/P&gt;
&lt;P&gt;interrupt_setup.int_port = PORTB; // the port that the interrupt input is on&lt;/P&gt;
&lt;P&gt;interrupt_setup.int_port_bits = PORTB_BIT0;&lt;/P&gt;
&lt;P&gt;fnConfigureInterrupt((void *)&amp;amp;interrupt_setup); // configure wakeup pins on this port&lt;/P&gt;
&lt;P&gt;interrupt_setup.int_port = PORTC; // the port that the interrupt input is on&lt;/P&gt;
&lt;P&gt;interrupt_setup.int_port_bits = (PORTC_BIT1 | PORTC_BIT3 | PORTC_BIT4 | PORTC_BIT5 | PORTC_BIT6 | PORTC_BIT11);&lt;/P&gt;
&lt;P&gt;fnConfigureInterrupt((void *)&amp;amp;interrupt_setup); // configure wakeup pins on this port&lt;/P&gt;
&lt;P&gt;interrupt_setup.int_port = PORTD; // the port that the interrupt input is on&lt;/P&gt;
&lt;P&gt;interrupt_setup.int_port_bits = (PORTD_BIT0 | PORTD_BIT2 | PORTD_BIT4 | PORTD_BIT6);&lt;/P&gt;
&lt;P&gt;fnConfigureInterrupt((void *)&amp;amp;interrupt_setup);// configure wakeup pins on this port&lt;/P&gt;
&lt;P&gt;interrupt_setup.int_port = PORTE; // the port that the interrupt input is on&lt;/P&gt;
&lt;P&gt;interrupt_setup.int_port_bits = (PORTE_BIT1 | PORTE_BIT2 | PORTE_BIT4);&lt;/P&gt;
&lt;P&gt;fnConfigureInterrupt((void *)&amp;amp;interrupt_setup); // configure wakeup pins on this port&lt;/P&gt;
&lt;P&gt;&lt;/P&gt;
&lt;P&gt;fnSetLowPowerMode(LLS_MODE);&lt;/P&gt;

&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This is the LLWU method as used in the uTasker project - &lt;A href="http://www.utasker.com/kinetis/LLWU.html" rel="nofollow noopener noreferrer" title="http://www.utasker.com/kinetis/LLWU.html" target="_blank"&gt;µTasker LLWU Support&lt;/A&gt;&lt;/P&gt;&lt;P&gt;whereby this attaches each LLWU pin to the same interrupt (they can however each have their own or share interrupts in groups).&lt;/P&gt;&lt;P&gt;Notice that the interrupt sense is controlled by&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;interrupt_setup.int_port_sense = (IRQ_FALLING_EDGE | PULLUP_ON | ENABLE_PORT_MODE);&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;and all pins are set to falling edge sensitive.&lt;/P&gt;&lt;P&gt;At the same time the control flags PULLUP_ON and ENABLE_PORT_MODE are used. The first means that the pins characteristics are set to have a pullup (this is set in its GPIO mode) so that unconnected pins are held at '1' so that the falling edge can function.&lt;/P&gt;&lt;P&gt;The second (ENABLE_PORT_MODE) is also important because it specifies that the pin should be set to its GPIO mode.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;First I'll give two examples to explain why this is useful and then also explain why it can also be critical for the LLWU to operate correctly.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If a LLUW pin is used as a peripheral input - eg. UART0_RX (some chips share UART Rx with LLWU) I configure with &lt;STRONG&gt;interrupt_setup.int_port_sense = (IRQ_FALLING_EDGE | PULLUP_ON);&lt;/STRONG&gt; [pull up is optional] so that the original peripheral function is not disturbed. When in a low leakage mode the LLWU pin function becomes active and then it will wake on a falling edge on the input.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If the pin is not used for other functions it may default to disabled or an analogue peripheral function - in this case I use &lt;STRONG&gt;interrupt_setup.int_port_sense = (IRQ_FALLING_EDGE | PULLUP_ON | &lt;SPAN style="color: #ff0000;"&gt;ENABLE_PORT_MODE&lt;/SPAN&gt;); &lt;/STRONG&gt;which configures the pull-up AND sets the pin function to the GPIO mode (moving from an analogue or disabled mux setting).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;A potentially important fact about using the LLWU is to ensure that the LLWU is connected because what I find is that if the ENABLE_PORT_MODE control is not used on some pins (those that are disabled by default) the LLWU also doesn't operate. In the case of analogue inputs the pull-up is not connected, which can also mean that the wakeup doesn't operate because no falling edge is possible (in my test setup).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I don't know the methods that you are using but suggest that you examine the PORTx_CRn setting used to ensure that the pin MUX is not in the disabled state. My tests show that I can either get all LLWU inputs to work or else only a select few operate, the difference being pulely in the MUX setting used!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Mark&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Kinetis: &lt;A href="http://www.utasker.com/kinetis.html" rel="nofollow noopener noreferrer" title="http://www.utasker.com/kinetis.html" target="_blank"&gt;µTasker Kinetis support&lt;/A&gt;&lt;/P&gt;&lt;P&gt;LLWU: &lt;A href="http://www.utasker.com/kinetis/LLWU.html" rel="nofollow noopener noreferrer" title="http://www.utasker.com/kinetis/LLWU.html" target="_blank"&gt;µTasker LLWU Support&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;For the complete "out-of-the-box" Kinetis experience and faster time to market &lt;/EM&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sat, 14 Mar 2015 05:06:23 GMT</pubDate>
    <dc:creator>mjbcswitzerland</dc:creator>
    <dc:date>2015-03-14T05:06:23Z</dc:date>
    <item>
      <title>LLWU on PORTE not working</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/LLWU-on-PORTE-not-working/m-p/385212#M20711</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have a LLWU set up on PTB0/LLWU_P5 which works fine, generates the interrupt. I tried adding another one on PTE4/LLWU_P2 without any success.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;My setup code is,&lt;/P&gt;&lt;P&gt;LLWU_PE1_WUPE2(0x03) in init_lpm.c under LPM_OPERATION_MODE_STOP&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;GPIOE_PDDR&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0x00000000;&lt;/P&gt;&lt;P&gt;#define TW_WAKE_ID&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; (GPIO_PORT_E | GPIO_PIN4)&lt;/P&gt;&lt;P&gt;#define TW_WAKE_MUX&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; LWGPIO_MUX_E4_GPIO&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;My initialisation code is,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;static void tw_isr (void *pin)&lt;/P&gt;&lt;P&gt;{&lt;/P&gt;&lt;P&gt;//&amp;nbsp;&amp;nbsp;&amp;nbsp; lwgpio_toggle_value (&amp;amp;led1);&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; lwgpio_int_clear_flag (pin);&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; _lwevent_set (&amp;amp;app_event, PIN_EVENT_MASK);&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;}&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;static void tw_interrupt_init (void)&lt;/P&gt;&lt;P&gt;{&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; static LWGPIO_STRUCT sw;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; printf("Going to init tw interrupt\n");&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; //PTE4 llwu p2&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; //************************************************************************************&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; /* Set the pin to input */&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; if (!lwgpio_init(&amp;amp;sw, TW_WAKE_ID, LWGPIO_DIR_INPUT, LWGPIO_VALUE_NOCHANGE))&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; printf("\nSW initialization failed.\n");&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; _task_block();&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; /* Set functionality to GPIO mode */&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; lwgpio_set_functionality(&amp;amp;sw, TW_WAKE_MUX);&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; /* Enable pull up */&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; lwgpio_set_attribute(&amp;amp;sw, LWGPIO_ATTR_PULL_UP, LWGPIO_AVAL_ENABLE);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; /* Setup the pin interrupt mode */&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; if (!lwgpio_int_init(&amp;amp;sw, LWGPIO_INT_MODE_FALLING))&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; printf("Initializing SW for interrupt failed.\n");&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; _task_block();&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; /* Install gpio interrupt service routine */&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; _int_install_isr(lwgpio_int_get_vector(&amp;amp;sw), tw_isr, (void *) &amp;amp;sw);&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; /* Set interrupt priority and enable interrupt source in the interrupt controller */&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; _bsp_int_init(lwgpio_int_get_vector(&amp;amp;sw), 3, 0, TRUE);&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; /* Enable interrupt for pin */&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; lwgpio_int_enable(&amp;amp;sw, TRUE);&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;} &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;void initLowPower()&lt;/P&gt;&lt;P&gt;{&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; //configure pin interrupts&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; tw_interrupt_init();&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; _int_install_unexpected_isr();&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; _lpm_register_wakeup_callback(BSP_LLWU_INTERRUPT_VECTOR, BSP_LLWU_INTERRUPT_PRIORITY, NULL);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; /* Install interrupt for timer wakeup */&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; install_timer_interrupt();&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; /* Create global event */&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; if (_lwevent_create(&amp;amp;app_event, 0) != MQX_OK)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; printf("\nCreating app_event failed.\n");&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; _task_block();&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; if (_lpm_get_reset_source() != MQX_RESET_SOURCE_LLWU)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; printf("\nNormal hardware wakeup\n");&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; else&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; printf("\nWake up by reset from LLWU\n");&lt;/P&gt;&lt;P&gt;}&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The llwu code on the PORTB seems to work fine and is similar, not sure if there are any bsp specific changes needed for PORTE llwu.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Rahul&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 13 Mar 2015 20:17:15 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/LLWU-on-PORTE-not-working/m-p/385212#M20711</guid>
      <dc:creator>rahuludasi</dc:creator>
      <dc:date>2015-03-13T20:17:15Z</dc:date>
    </item>
    <item>
      <title>Re: LLWU on PORTE not working</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/LLWU-on-PORTE-not-working/m-p/385213#M20712</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Rahul&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Since the location of the LLWU pins are not the same on all devices it is important to specify which part you are using - &lt;EM&gt;presumably a Kinetis K part&lt;/EM&gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Below is how I verify all 16 K64 LLWU interrupt (for example):&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE __default_attr="c++" __jive_macro_name="code" class="jive_text_macro jive_macro_code _jivemacro_uid_14263097136291946" jivemacro_uid="_14263097136291946"&gt;
&lt;P&gt;// Configure all 16 K64 LLWU pins&lt;/P&gt;
&lt;P&gt;//&lt;/P&gt;
&lt;P&gt;INTERRUPT_SETUP interrupt_setup; // interrupt configuration parameters&lt;/P&gt;
&lt;P&gt;interrupt_setup.int_type = PORT_INTERRUPT; // identifier to configure port interrupt&lt;/P&gt;
&lt;P&gt;interrupt_setup.int_port_sense = (IRQ_FALLING_EDGE | PULLUP_ON | ENABLE_PORT_MODE);&lt;/P&gt;
&lt;P&gt;interrupt_setup.int_type = WAKEUP_INTERRUPT; // configure as wake-up interrupt&lt;/P&gt;
&lt;P&gt;interrupt_setup.int_handler = test_irq_5;&lt;/P&gt;
&lt;P&gt;interrupt_setup.int_port = PORTA; // the port that the interrupt input is on&lt;/P&gt;
&lt;P&gt;interrupt_setup.int_port_bits = (PORTA_BIT4 | PORTA_BIT13);&lt;/P&gt;
&lt;P&gt;fnConfigureInterrupt((void *)&amp;amp;interrupt_setup); // configure wakeup pins on this port&lt;/P&gt;
&lt;P&gt;interrupt_setup.int_port = PORTB; // the port that the interrupt input is on&lt;/P&gt;
&lt;P&gt;interrupt_setup.int_port_bits = PORTB_BIT0;&lt;/P&gt;
&lt;P&gt;fnConfigureInterrupt((void *)&amp;amp;interrupt_setup); // configure wakeup pins on this port&lt;/P&gt;
&lt;P&gt;interrupt_setup.int_port = PORTC; // the port that the interrupt input is on&lt;/P&gt;
&lt;P&gt;interrupt_setup.int_port_bits = (PORTC_BIT1 | PORTC_BIT3 | PORTC_BIT4 | PORTC_BIT5 | PORTC_BIT6 | PORTC_BIT11);&lt;/P&gt;
&lt;P&gt;fnConfigureInterrupt((void *)&amp;amp;interrupt_setup); // configure wakeup pins on this port&lt;/P&gt;
&lt;P&gt;interrupt_setup.int_port = PORTD; // the port that the interrupt input is on&lt;/P&gt;
&lt;P&gt;interrupt_setup.int_port_bits = (PORTD_BIT0 | PORTD_BIT2 | PORTD_BIT4 | PORTD_BIT6);&lt;/P&gt;
&lt;P&gt;fnConfigureInterrupt((void *)&amp;amp;interrupt_setup);// configure wakeup pins on this port&lt;/P&gt;
&lt;P&gt;interrupt_setup.int_port = PORTE; // the port that the interrupt input is on&lt;/P&gt;
&lt;P&gt;interrupt_setup.int_port_bits = (PORTE_BIT1 | PORTE_BIT2 | PORTE_BIT4);&lt;/P&gt;
&lt;P&gt;fnConfigureInterrupt((void *)&amp;amp;interrupt_setup); // configure wakeup pins on this port&lt;/P&gt;
&lt;P&gt;&lt;/P&gt;
&lt;P&gt;fnSetLowPowerMode(LLS_MODE);&lt;/P&gt;

&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This is the LLWU method as used in the uTasker project - &lt;A href="http://www.utasker.com/kinetis/LLWU.html" rel="nofollow noopener noreferrer" title="http://www.utasker.com/kinetis/LLWU.html" target="_blank"&gt;µTasker LLWU Support&lt;/A&gt;&lt;/P&gt;&lt;P&gt;whereby this attaches each LLWU pin to the same interrupt (they can however each have their own or share interrupts in groups).&lt;/P&gt;&lt;P&gt;Notice that the interrupt sense is controlled by&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;interrupt_setup.int_port_sense = (IRQ_FALLING_EDGE | PULLUP_ON | ENABLE_PORT_MODE);&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;and all pins are set to falling edge sensitive.&lt;/P&gt;&lt;P&gt;At the same time the control flags PULLUP_ON and ENABLE_PORT_MODE are used. The first means that the pins characteristics are set to have a pullup (this is set in its GPIO mode) so that unconnected pins are held at '1' so that the falling edge can function.&lt;/P&gt;&lt;P&gt;The second (ENABLE_PORT_MODE) is also important because it specifies that the pin should be set to its GPIO mode.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;First I'll give two examples to explain why this is useful and then also explain why it can also be critical for the LLWU to operate correctly.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If a LLUW pin is used as a peripheral input - eg. UART0_RX (some chips share UART Rx with LLWU) I configure with &lt;STRONG&gt;interrupt_setup.int_port_sense = (IRQ_FALLING_EDGE | PULLUP_ON);&lt;/STRONG&gt; [pull up is optional] so that the original peripheral function is not disturbed. When in a low leakage mode the LLWU pin function becomes active and then it will wake on a falling edge on the input.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If the pin is not used for other functions it may default to disabled or an analogue peripheral function - in this case I use &lt;STRONG&gt;interrupt_setup.int_port_sense = (IRQ_FALLING_EDGE | PULLUP_ON | &lt;SPAN style="color: #ff0000;"&gt;ENABLE_PORT_MODE&lt;/SPAN&gt;); &lt;/STRONG&gt;which configures the pull-up AND sets the pin function to the GPIO mode (moving from an analogue or disabled mux setting).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;A potentially important fact about using the LLWU is to ensure that the LLWU is connected because what I find is that if the ENABLE_PORT_MODE control is not used on some pins (those that are disabled by default) the LLWU also doesn't operate. In the case of analogue inputs the pull-up is not connected, which can also mean that the wakeup doesn't operate because no falling edge is possible (in my test setup).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I don't know the methods that you are using but suggest that you examine the PORTx_CRn setting used to ensure that the pin MUX is not in the disabled state. My tests show that I can either get all LLWU inputs to work or else only a select few operate, the difference being pulely in the MUX setting used!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Mark&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Kinetis: &lt;A href="http://www.utasker.com/kinetis.html" rel="nofollow noopener noreferrer" title="http://www.utasker.com/kinetis.html" target="_blank"&gt;µTasker Kinetis support&lt;/A&gt;&lt;/P&gt;&lt;P&gt;LLWU: &lt;A href="http://www.utasker.com/kinetis/LLWU.html" rel="nofollow noopener noreferrer" title="http://www.utasker.com/kinetis/LLWU.html" target="_blank"&gt;µTasker LLWU Support&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;For the complete "out-of-the-box" Kinetis experience and faster time to market &lt;/EM&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 14 Mar 2015 05:06:23 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/LLWU-on-PORTE-not-working/m-p/385213#M20712</guid>
      <dc:creator>mjbcswitzerland</dc:creator>
      <dc:date>2015-03-14T05:06:23Z</dc:date>
    </item>
    <item>
      <title>Re: LLWU on PORTE not working</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/LLWU-on-PORTE-not-working/m-p/385214#M20713</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Rahul Udasi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Please tell us the full name of your chp and the code you are refering, then we can help you better.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Waiting for your reply!&lt;/P&gt;&lt;P&gt;Jingjing&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 16 Mar 2015 06:01:07 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/LLWU-on-PORTE-not-working/m-p/385214#M20713</guid>
      <dc:creator>kerryzhou</dc:creator>
      <dc:date>2015-03-16T06:01:07Z</dc:date>
    </item>
  </channel>
</rss>

