AnsweredAssumed Answered

GPIO in PEx is so bizarre...

Question asked by dave408 on Mar 31, 2015
Latest reply on Apr 1, 2015 by dave408

I have GPIO in Atollic with PEx working (bitbanged SPI), using the BitIO component.  However, in KDS+PEx, I don't have that component for some reason.  My non-PEx bitbang SPI code doesn't work, so I decided to use PEx in KDS.


I tried fsl_gpio, but there seems to be a bug where I cannot assign the port.  If I select PORTD, for example, it switches back to PORTA as soon as I click somewhere else.  And of course, since I want two (different) ports, I get an additional error saying that the two components are sharing a port.

 

So I decided to move on to try the GenericBitIO component in KDS+PEx.  Setup seemed clear enough until I saw this GUI:

 

 

I already set the Direction under the Component Name, so I don't understand why I would have to set something in a Direction tab.  In addition, I tried to figure out the significance of PTADD_PTADD0, but I can't find any part of that in the reference manual.  Also, the checkbox should really just be labeled "Output" or "Is output".

 

I was going to keep moving forward and just ignore this detail regarding direction, but I also can't figure out what the valid port names or bit names are that I should be using.  When PEx uses a droplist with the header and pin number (e.g. J2_12), it's so much easier to configure.  Droplists >> textboxes!

 

I had BitIO in Atollic+PEx working in 5 minutes.  So far, I've spent over four hours trying to get my IO code working in KDS.  I'm not sure why this is, but I'm going to keep plugging away at it.

Outcomes