Kinetis processor port features unavailable when using non-GPIO mux features?

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Kinetis processor port features unavailable when using non-GPIO mux features?

Jump to solution
1,497 Views
rickstuart
Contributor V

We are using the I2C feature in a KL03 Kinetis processor.  Some of our boards have pull up resistors on the I2C data and clock lines.  Some do not.  All boards are running the same code which activates the KL03 Kinetis internal pull up/down resistors and connects the pull up resistor in particular.  This pull up resistor is assumed to be between 20K and 50K ohms.  Roughly 8 to 10 times the normal I2C pull up.  Still, I would have expected marginal to good results as there is only one slave on the bus which is likely less then 2 cm long.  The activity we saw on the bus could be attributed to noise.  After installing physical pull up resistors external to the processor the bus behaved as expected.

When switching in the I2C feature on the KL03 are we also switching out all other pin features?  In this case, specifically, the pull up / down feature?

In general, exactly what can we expect when switching in other KL03 features for the default pin function?  Are features like pin direction, pull up / down resistors and output states controlled by the switched in feature.  Or are they still the responsibility of the programmer?

0 Kudos
Reply
1 Solution
1,264 Views
mjbcswitzerland
Specialist V

Hi

Below is the pin overview showing nothing special for PTA3 and PTA4; there is no relation between mux setting and characteristic.

It is probably purely an electrical issue.

Regards

Mark

pastedImage_1.png

View solution in original post

0 Kudos
Reply
6 Replies
1,264 Views
mjbcswitzerland
Specialist V

Hi

You need to check the configuration of the chip that you are using. The feature set varies between parts but each user manual has a list of the features and defaults of each pin so this is best used as reference when starting.

Generally, features such as pull-ups/downs, driver strength etc. are valid for whatever peripheral function has been selected (eg. one can choose to have a UART RXD line with or without pull-up or what slew-rate and drive strength its UART TXD has).

Don't rely on automation tools since they are only as good and accurate as set up by a anonymous person so I would prefer to invest a few minutes to be sure rather than rely on chance and later lose time and expense in case you get unlucky.

Beware that some ports on the KL03 are true open-drain so need external resistors. The uTasker KL03 project signals this in its KL03 emulation as shown below to help users not overlook the detail.

Regards

Mark

pastedImage_1.png

0 Kudos
Reply
1,264 Views
rickstuart
Contributor V

We are using ports A3 on pin 5 and A4 on pin 6. I am not sure what uTasker is, but from your screen shot it appears that there is no "^" but a "P" for those pins.  My assumption is that "P" designates a normal port pin with pull up resistor capability even if that pin is disconnected from GPIO and reconnected to I2C.  But when we (thought we) activated the pull enable and the pull ups for A3 and A4 we did not see any difference in the I2C activity (still looked like noise).  After adding external pull up resistors as Kerry Zhou recommended the I2C activity appeared normal.

Where in the KL03 specifications are there indications that pull up resistors are available for a particular pin and for a particular MUX setting?

-thanks

0 Kudos
Reply
1,265 Views
mjbcswitzerland
Specialist V

Hi

Below is the pin overview showing nothing special for PTA3 and PTA4; there is no relation between mux setting and characteristic.

It is probably purely an electrical issue.

Regards

Mark

pastedImage_1.png

0 Kudos
Reply
1,264 Views
rickstuart
Contributor V

Ah, so because A3 and A4 are not listed in chapter 12, it can be inferred that they behave "normally".  That is, they should have pull up / down capability.  Well, it didn't look like they did when I turned it on / off in the software.  But as Kerry Zhou points out, they are weak.

0 Kudos
Reply
1,264 Views
kerryzhou
NXP TechSupport
NXP TechSupport

Hi rick stuart,

   Actually, even the pin have the internal pull up, the pull up is weak, in the application like I2C, NMI, reset pin, we highly recommend you to use the external pull up resistor to keep the working stability.

Wish it helps you!


Have a great day,
Kerry

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

0 Kudos
Reply
1,264 Views
kerryzhou
NXP TechSupport
NXP TechSupport

Hi Rick Stuart,

   Which pin you are using as the I2C function?

   From the reference manual, you can find PTB3, PTB4 is the true open drain pin, so you must add external pull up resistor, normally, add 10K pull up.

pastedImage_1.png

Please add the external pull up, then try again.


Have a great day,
Kerry

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

0 Kudos
Reply