AnsweredAssumed Answered

K60 PTE25 acts with problems in MQX4.0

Question asked by kk kk on Dec 11, 2013
Latest reply on Feb 15, 2014 by georgerouse

There are two problems with PTE24 and PTE25. I use MK60FN1M0VLQ12 with MQX 4.0. I modify the MQX4.0 hello2 sample code. I set these two pins as GPIO, there is my setting code:


LWGPIO_STRUCT Reset_FPGA,Power_EN;

BOOL status;

status=lwgpio_init(&Reset_FPGA,LWGPIO_PORT_E|LWGPIO_PIN24,LWGPIO_DIR_OUTPUT,LWGPIO_VALUE_LOW);

lwgpio_set_functionality(&Reset_FPGA,LWGPIO_MUX_E24_GPIO);
status=lwgpio_init(&Power_EN,LWGPIO_PORT_E|LWGPIO_PIN25,LWGPIO_DIR_OUTPUT,LWGPIO_VALUE_HIGH);

 

lwgpio_set_functionality(&Power_EN,LWGPIO_MUX_E25_GPIO);

 

I check the PTE registers, both registers are 0x000100. When I set PTE24 as high or low, PTE25 will automatically act at the same time . They act together.

 

I use gpio sample code from KINETIS_120MHZ_SC without MQX4.0 and set these two pins as GPIO:

PORTE_PCR24=(0|PORT_PCR_MUX(1));

PORTE_PCR25=(0|PORT_PCR_MUX(1));

GPIOE_PDDR=GPIO_PDDR_PDD(GPIO_PIN(24) | GPIO_PIN(25));

They can act dependently. How can I fix this problem with MQX4.0?

 

Another problem is the PTE25's VOL. When I set PTE24's VOH as 3.3V, I try to set PTE25 low and it hold at 2.3V and can't be under 0.5V.

It happens when I use MQX4.0.  Here is my code:

PORTE_PCR24=(0|PORT_PCR_MUX(1));

 

PORTE_PCR25=(0|PORT_PCR_MUX(1));

GPIOE_PDDR=GPIO_PDDR_PDD(GPIO_PIN(24) | GPIO_PIN(25));

When I use gpio sample code from KINETIS_120MHZ_SC without MQX4.0, PTE25 can be set under 0.5V.

PTE25 registor is 0x00000100 whenever MQX4.0 is used or not. How to fix this problem?

Outcomes