Access ports wordwise

cancel
Showing results for 
Search instead for 
Did you mean: 

Access ports wordwise

116 Views
Contributor II

Hi,

         I would like to know whether we can write to multiple pins of a port in one instant by using some sort of write to port register where each bit of the register will be the port pin. After going through the documentation I was unable to find the same. For applications where the parallel buses can be used such as character LCD/ digital attenuators/potentiometers, it would be helpful.

Labels (1)
3 Replies

45 Views
NXP TechSupport
NXP TechSupport

Hi Sion,

Yes, of course. Kinetis MCU's gpio is grouped into several port. There are up to 32 gpio in each port. There are also some 32 bit wide register to control these gpio. Write to there 32bit register can read/write pins simultaneously. Please see the GPIO chapter in reference manual.

Regards,

Jing

45 Views
Contributor II

Hope GPIOx_PDOR registers are the one you are referring to. Since the API's were not using this register I was not able to find. Also the manual has got these registers hidden towards the end of the document in memory mapping section.

0 Kudos

45 Views
NXP TechSupport
NXP TechSupport

Hi,

Yes, it is. And you can use GPIOx_PCOR and GPIOx_PSOR to make the work easier.

Regards,

Jing

0 Kudos