PN7462 Using GPIO14 as GPIO Output?

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

PN7462 Using GPIO14 as GPIO Output?

Jump to solution
1,736 Views
EE_Ark
Contributor II

Hi,

How can I configure GPIO14(CLK_AUX) as GPIO output and set it's value?

I know I should use "ph_Reg.h" file but couldn't find out what should i do exactly.

 

Thanks.

 

0 Kudos
Reply
1 Solution
1,721 Views
danielchen
NXP TechSupport
NXP TechSupport

Hi @EE_Ark :

 

In order to config GPIO output,  you can try API: phhalPcr_ConfigOutput  () and PH_HAL_GPIO_SETGPIOVAL ()

You can refer to pphhalPcr_GpioInit() function in phhalGpio.c

 

Regards

Daniel

 

 

 

 

View solution in original post

0 Kudos
Reply
2 Replies
1,729 Views
EE_Ark
Contributor II

I tried these codes without success.

 

PH_REG_SET_BITN(PCR_PAD_CLK_AUX_REG,PCR_PAD_CLK_AUX_REG_CLK_AUX_GPIOMODE_EN_POS);

//PH_REG_SET_FIELD( PCR_PAD_CLK_AUX_REG , CLK_AUX_PUPD,0x2);//pull up
//PH_REG_SET_FIELD( PCR_PAD_CLK_AUX_REG , CLK_AUX_PUPD,0x3);//pull down

PH_REG_SET_BIT(PCR_PADOUT_REG,PADOUT_CLK_AUX); //Set CLK_AUX HIGH
PH_REG_CLEAR_BIT(PCR_PADOUT_REG,PADOUT_CLK_AUX); //Set CLK_AUX LOW

0 Kudos
Reply
1,722 Views
danielchen
NXP TechSupport
NXP TechSupport

Hi @EE_Ark :

 

In order to config GPIO output,  you can try API: phhalPcr_ConfigOutput  () and PH_HAL_GPIO_SETGPIOVAL ()

You can refer to pphhalPcr_GpioInit() function in phhalGpio.c

 

Regards

Daniel

 

 

 

 

0 Kudos
Reply