gpio_cpu_configure - override defaults?

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

gpio_cpu_configure - override defaults?

Jump to solution
756 Views
w2vy
Contributor V

 gpio_cpu_configure is called often to update the pin configurations.

 

One problem.

 

It assumes GPIO or Alternate Function 2 for most (well I care about PORT TC) functions.

 

How do you select a different non-GPIO function?

 

If the pin usage is generally GPIO or non-GPIO maybe the BSP should add a table to define the Alt function.

Or is there a clean up function that can be called after gpio_cpu_configure() to fix the 'errors' induced?

 

I am using DTIM0 as a clock output... searching ther code I do not see anything in MQX that uses any of the DTIM registers

 

tom

0 Kudos
1 Solution
288 Views
w2vy
Contributor V

Ok after digging deeper I see that the code I was looking at leaves the bits alone that are not assigned as GPIO.

 

I just set the PAR bits and all is well.

View solution in original post

0 Kudos
1 Reply
289 Views
w2vy
Contributor V

Ok after digging deeper I see that the code I was looking at leaves the bits alone that are not assigned as GPIO.

 

I just set the PAR bits and all is well.

0 Kudos