<?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 GPIO Outputs in Kinetis Microcontrollers</title>
    <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/GPIO-Outputs/m-p/1065394#M57199</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Micro: &lt;STRONG&gt;MKV10Z32VLF7&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;IDE: &lt;STRONG&gt;MCUXpresso&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am trying to configure two pins on this micro to be digital outputs: PTC6 (pin 39) &amp;amp; PTC7 (pin 40). Code as follows:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;gpio_pin_config_t PortC6 = {kGPIO_DigitalOutput,1};&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;// LED0, startup as HI&lt;/P&gt;&lt;P&gt;gpio_pin_config_t PortC7 = {kGPIO_DigitalOutput,1};&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;// LED1, startup as HI&lt;/P&gt;&lt;P&gt;.&lt;/P&gt;&lt;P&gt;.&lt;/P&gt;&lt;P&gt;.&lt;/P&gt;&lt;P&gt;void BOARD_InitPins(void)&lt;BR /&gt;{&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; CLOCK_EnableClock(kCLOCK_PortC);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; PORT_SetPinMux(PORTC, 6U, kPORT_MuxAsGpio);&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; PORT_SetPinMux(PORTC, 7U, kPORT_MuxAsGpio);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; GPIO_PinInit(GPIOC,6U,&amp;amp;PortC6);&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; GPIO_PinInit(GPIOC,7U,&amp;amp;PortC7); &lt;/P&gt;&lt;P&gt;}&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;After running the above code, neither of the pins are high. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I read back the following registers:&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;GPIOC_PDIR: 0x0 - &lt;STRONG&gt;Incorrect&lt;/STRONG&gt;, read only register, should be 0xC0&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;GPIOC_PDDR: 0xC0 - Correct (both pins assigned as outputs)&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;GPIOC_PDOR: 0xC0 - Correct (both pins assigned level '1')&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;A value of "0" in the "GPIOC_PDIR" register indicating:"&lt;EM&gt;0 Pin logic level is logic 0, &lt;SPAN style="text-decoration: underline;"&gt;or is not configured for use by digital function&lt;/SPAN&gt;.&lt;/EM&gt;"&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;What this is telling me is that I cannot assign these two pins as digital logic. Surely this is not correct? What am I missing here?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Sean&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sat, 23 May 2020 17:54:13 GMT</pubDate>
    <dc:creator>seanmccartan</dc:creator>
    <dc:date>2020-05-23T17:54:13Z</dc:date>
    <item>
      <title>GPIO Outputs</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/GPIO-Outputs/m-p/1065394#M57199</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Micro: &lt;STRONG&gt;MKV10Z32VLF7&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;IDE: &lt;STRONG&gt;MCUXpresso&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am trying to configure two pins on this micro to be digital outputs: PTC6 (pin 39) &amp;amp; PTC7 (pin 40). Code as follows:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;gpio_pin_config_t PortC6 = {kGPIO_DigitalOutput,1};&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;// LED0, startup as HI&lt;/P&gt;&lt;P&gt;gpio_pin_config_t PortC7 = {kGPIO_DigitalOutput,1};&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;// LED1, startup as HI&lt;/P&gt;&lt;P&gt;.&lt;/P&gt;&lt;P&gt;.&lt;/P&gt;&lt;P&gt;.&lt;/P&gt;&lt;P&gt;void BOARD_InitPins(void)&lt;BR /&gt;{&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; CLOCK_EnableClock(kCLOCK_PortC);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; PORT_SetPinMux(PORTC, 6U, kPORT_MuxAsGpio);&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; PORT_SetPinMux(PORTC, 7U, kPORT_MuxAsGpio);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; GPIO_PinInit(GPIOC,6U,&amp;amp;PortC6);&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; GPIO_PinInit(GPIOC,7U,&amp;amp;PortC7); &lt;/P&gt;&lt;P&gt;}&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;After running the above code, neither of the pins are high. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I read back the following registers:&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;GPIOC_PDIR: 0x0 - &lt;STRONG&gt;Incorrect&lt;/STRONG&gt;, read only register, should be 0xC0&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;GPIOC_PDDR: 0xC0 - Correct (both pins assigned as outputs)&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;GPIOC_PDOR: 0xC0 - Correct (both pins assigned level '1')&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;A value of "0" in the "GPIOC_PDIR" register indicating:"&lt;EM&gt;0 Pin logic level is logic 0, &lt;SPAN style="text-decoration: underline;"&gt;or is not configured for use by digital function&lt;/SPAN&gt;.&lt;/EM&gt;"&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;What this is telling me is that I cannot assign these two pins as digital logic. Surely this is not correct? What am I missing here?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Sean&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 23 May 2020 17:54:13 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/GPIO-Outputs/m-p/1065394#M57199</guid>
      <dc:creator>seanmccartan</dc:creator>
      <dc:date>2020-05-23T17:54:13Z</dc:date>
    </item>
    <item>
      <title>Re: GPIO Outputs</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/GPIO-Outputs/m-p/1065395#M57200</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I found the answer:"&lt;EM&gt;PTC6 and PTC7 are true open drain pins. These pins cannot drive a logic one without a &lt;/EM&gt;&lt;EM&gt;pull-up resistor&lt;/EM&gt;."&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 24 May 2020 07:41:09 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/GPIO-Outputs/m-p/1065395#M57200</guid>
      <dc:creator>seanmccartan</dc:creator>
      <dc:date>2020-05-24T07:41:09Z</dc:date>
    </item>
  </channel>
</rss>

