1.2.17.13 1.3.19.13 1.4.17.13 1.5.18.13 1.29.18.13 1.30.13.13 1.31.13.13 1.32.20.13 1.33.13.13 1.37.14.13 1.38.17.13 1.39.14.13 1.40.16.13 PORT_GroupSet Function

C

void PORT_GroupSet(PORT_GROUP group, uint32_t mask)

Summary

Set the selected IO pins of a group.

Description

This function sets (drives a logic high) on the selected output pins of a group. The mask parameter control the pins to be updated. A mask bit position with a value 1 will cause that corresponding port pin to be set. A mask bit position with a value 0 will cause the corresponding port pin to stay unaffected.

Precondition

The PORT_Initialize() function should have been called.

Parameters

Param Description
group One of the IO ports from the enum PORT_GROUP.
mask A 32 bit value in which a bit represent a pin in the group. If the value of the bit is 1, the corresponding port pin will driven to logic 1. If the value of the bit is 0. the corresponding port pin will stay unaffected.

Returns

None.

Example

// Set PC5 and PC7 pins to 1
PORT_GroupSet(PORT_GROUP_C, 0x00A0);

Remarks

If the port pin within the the group is not configured for output and has the pull feature enabled, driving a logic 1 on this pin will cause the pull up to be enabled.