1.8.13.5 PIO_PortSet Function

C

void PIO_PortSet(PIO_PORT port, uint32_t mask)

Summary

Set the selected IO pins of a port.

Description

This function sets (to '1') the selected IO pins of a port.

Precondition

None.

Parameters

Param Description
port One of the IO ports from the enum PIO_PORT
mask A 32 bit value in which positions of 0s and 1s decide which IO pins of the selected port will be set.
  • 1's Will set corresponding IO pins to high (to 1).

  • 0's Will remain unchanged.

Returns

None.

Example

// Set PC5 and PC7 pins to 1
PIO_PortSet(PIO_PORT_C, 0x00A0);

Remarks

If the port has less than 32-bits, unimplemented pins will be ignored. Implemented pins are Right aligned in the 32-bit value.