Bar Logo Dual Active Bridge Development Board (Part-No. )
 
Content
     
Loading...
Searching...
No Matches

The Pin Driver directs the operation and function of the selected device pins using dsPIC MCUs. More...

+ Collaboration diagram for Pins Driver:

Files

file  pins.c
 This is the generated driver source file for PINS driver.
 

Macros

#define GPIO_1_SetHigh()   (_LATC10 = 1)
 Sets the RC10 GPIO Pin which has a custom name of GPIO_1 to High.
 
#define GPIO_1_SetLow()   (_LATC10 = 0)
 Sets the RC10 GPIO Pin which has a custom name of GPIO_1 to Low.
 
#define GPIO_1_Toggle()   (_LATC10 ^= 1)
 Toggles the RC10 GPIO Pin which has a custom name of GPIO_1.
 
#define GPIO_1_GetValue()   _RC10
 Reads the value of the RC10 GPIO Pin which has a custom name of GPIO_1.
 
#define GPIO_1_SetDigitalInput()   (_TRISC10 = 1)
 Configures the RC10 GPIO Pin which has a custom name of GPIO_1 as Input.
 
#define GPIO_1_SetDigitalOutput()   (_TRISC10 = 0)
 Configures the RC10 GPIO Pin which has a custom name of GPIO_1 as Output.
 
#define GPIO_2_SetHigh()   (_LATC11 = 1)
 Sets the RC11 GPIO Pin which has a custom name of GPIO_2 to High.
 
#define GPIO_2_SetLow()   (_LATC11 = 0)
 Sets the RC11 GPIO Pin which has a custom name of GPIO_2 to Low.
 
#define GPIO_2_Toggle()   (_LATC11 ^= 1)
 Toggles the RC11 GPIO Pin which has a custom name of GPIO_2.
 
#define GPIO_2_GetValue()   _RC11
 Reads the value of the RC11 GPIO Pin which has a custom name of GPIO_2.
 
#define GPIO_2_SetDigitalInput()   (_TRISC11 = 1)
 Configures the RC11 GPIO Pin which has a custom name of GPIO_2 as Input.
 
#define GPIO_2_SetDigitalOutput()   (_TRISC11 = 0)
 Configures the RC11 GPIO Pin which has a custom name of GPIO_2 as Output.
 
#define DPD_TP31_SetHigh()   (_LATC14 = 1)
 Sets the RC14 GPIO Pin which has a custom name of DPD_TP31 to High.
 
#define DPD_TP31_SetLow()   (_LATC14 = 0)
 Sets the RC14 GPIO Pin which has a custom name of DPD_TP31 to Low.
 
#define DPD_TP31_Toggle()   (_LATC14 ^= 1)
 Toggles the RC14 GPIO Pin which has a custom name of DPD_TP31.
 
#define DPD_TP31_GetValue()   _RC14
 Reads the value of the RC14 GPIO Pin which has a custom name of DPD_TP31.
 
#define DPD_TP31_SetDigitalInput()   (_TRISC14 = 1)
 Configures the RC14 GPIO Pin which has a custom name of DPD_TP31 as Input.
 
#define DPD_TP31_SetDigitalOutput()   (_TRISC14 = 0)
 Configures the RC14 GPIO Pin which has a custom name of DPD_TP31 as Output.
 
#define IO_RD2_SetHigh()   (_LATD2 = 1)
 Sets the RD2 GPIO Pin which has a custom name of IO_RD2 to High.
 
#define IO_RD2_SetLow()   (_LATD2 = 0)
 Sets the RD2 GPIO Pin which has a custom name of IO_RD2 to Low.
 
#define IO_RD2_Toggle()   (_LATD2 ^= 1)
 Toggles the RD2 GPIO Pin which has a custom name of IO_RD2.
 
#define IO_RD2_GetValue()   _RD2
 Reads the value of the RD2 GPIO Pin which has a custom name of IO_RD2.
 
#define IO_RD2_SetDigitalInput()   (_TRISD2 = 1)
 Configures the RD2 GPIO Pin which has a custom name of IO_RD2 as Input.
 
#define IO_RD2_SetDigitalOutput()   (_TRISD2 = 0)
 Configures the RD2 GPIO Pin which has a custom name of IO_RD2 as Output.
 
#define LED_GREEN_SetHigh()   (_LATD7 = 1)
 Sets the RD7 GPIO Pin which has a custom name of LED_GREEN to High.
 
#define LED_GREEN_SetLow()   (_LATD7 = 0)
 Sets the RD7 GPIO Pin which has a custom name of LED_GREEN to Low.
 
#define LED_GREEN_Toggle()   (_LATD7 ^= 1)
 Toggles the RD7 GPIO Pin which has a custom name of LED_GREEN.
 
#define LED_GREEN_GetValue()   _RD7
 Reads the value of the RD7 GPIO Pin which has a custom name of LED_GREEN.
 
#define LED_GREEN_SetDigitalInput()   (_TRISD7 = 1)
 Configures the RD7 GPIO Pin which has a custom name of LED_GREEN as Input.
 
#define LED_GREEN_SetDigitalOutput()   (_TRISD7 = 0)
 Configures the RD7 GPIO Pin which has a custom name of LED_GREEN as Output.
 
#define LED_RED_SetHigh()   (_LATD8 = 1)
 Sets the RD8 GPIO Pin which has a custom name of LED_RED to High.
 
#define LED_RED_SetLow()   (_LATD8 = 0)
 Sets the RD8 GPIO Pin which has a custom name of LED_RED to Low.
 
#define LED_RED_Toggle()   (_LATD8 ^= 1)
 Toggles the RD8 GPIO Pin which has a custom name of LED_RED.
 
#define LED_RED_GetValue()   _RD8
 Reads the value of the RD8 GPIO Pin which has a custom name of LED_RED.
 
#define LED_RED_SetDigitalInput()   (_TRISD8 = 1)
 Configures the RD8 GPIO Pin which has a custom name of LED_RED as Input.
 
#define LED_RED_SetDigitalOutput()   (_TRISD8 = 0)
 Configures the RD8 GPIO Pin which has a custom name of LED_RED as Output.
 
#define FAULT_SetHigh()   (_LATD9 = 1)
 Sets the RD9 GPIO Pin which has a custom name of FAULT to High.
 
#define FAULT_SetLow()   (_LATD9 = 0)
 Sets the RD9 GPIO Pin which has a custom name of FAULT to Low.
 
#define FAULT_Toggle()   (_LATD9 ^= 1)
 Toggles the RD9 GPIO Pin which has a custom name of FAULT.
 
#define FAULT_GetValue()   _RD9
 Reads the value of the RD9 GPIO Pin which has a custom name of FAULT.
 
#define FAULT_SetDigitalInput()   (_TRISD9 = 1)
 Configures the RD9 GPIO Pin which has a custom name of FAULT as Input.
 
#define FAULT_SetDigitalOutput()   (_TRISD9 = 0)
 Configures the RD9 GPIO Pin which has a custom name of FAULT as Output.
 
#define TP_PIM_SetHigh()   (_LATD12 = 1)
 Sets the RD12 GPIO Pin which has a custom name of TP_PIM to High.
 
#define TP_PIM_SetLow()   (_LATD12 = 0)
 Sets the RD12 GPIO Pin which has a custom name of TP_PIM to Low.
 
#define TP_PIM_Toggle()   (_LATD12 ^= 1)
 Toggles the RD12 GPIO Pin which has a custom name of TP_PIM.
 
#define TP_PIM_GetValue()   _RD12
 Reads the value of the RD12 GPIO Pin which has a custom name of TP_PIM.
 
#define TP_PIM_SetDigitalInput()   (_TRISD12 = 1)
 Configures the RD12 GPIO Pin which has a custom name of TP_PIM as Input.
 
#define TP_PIM_SetDigitalOutput()   (_TRISD12 = 0)
 Configures the RD12 GPIO Pin which has a custom name of TP_PIM as Output.
 
#define LED_DP_PIM_SetHigh()   (_LATD15 = 1)
 Sets the RD15 GPIO Pin which has a custom name of LED_DP_PIM to High.
 
#define LED_DP_PIM_SetLow()   (_LATD15 = 0)
 Sets the RD15 GPIO Pin which has a custom name of LED_DP_PIM to Low.
 
#define LED_DP_PIM_Toggle()   (_LATD15 ^= 1)
 Toggles the RD15 GPIO Pin which has a custom name of LED_DP_PIM.
 
#define LED_DP_PIM_GetValue()   _RD15
 Reads the value of the RD15 GPIO Pin which has a custom name of LED_DP_PIM.
 
#define LED_DP_PIM_SetDigitalInput()   (_TRISD15 = 1)
 Configures the RD15 GPIO Pin which has a custom name of LED_DP_PIM as Input.
 
#define LED_DP_PIM_SetDigitalOutput()   (_TRISD15 = 0)
 Configures the RD15 GPIO Pin which has a custom name of LED_DP_PIM as Output.
 

Functions

void PINS_Initialize (void)
 Initializes the PINS module.
 

Detailed Description

Macro Definition Documentation

◆ DPD_TP31_GetValue

#define DPD_TP31_GetValue ( )    _RC14
Parameters
none
Returns
none

Definition at line 181 of file pins.h.

◆ DPD_TP31_SetDigitalInput

#define DPD_TP31_SetDigitalInput ( )    (_TRISC14 = 1)
Parameters
none
Returns
none

Definition at line 189 of file pins.h.

◆ DPD_TP31_SetDigitalOutput

#define DPD_TP31_SetDigitalOutput ( )    (_TRISC14 = 0)
Parameters
none
Returns
none

Definition at line 197 of file pins.h.

◆ DPD_TP31_SetHigh

#define DPD_TP31_SetHigh ( )    (_LATC14 = 1)
Precondition
The RC14 must be set as Output Pin
Parameters
none
Returns
none

Definition at line 155 of file pins.h.

◆ DPD_TP31_SetLow

#define DPD_TP31_SetLow ( )    (_LATC14 = 0)
Precondition
The RC14 must be set as Output Pin
Parameters
none
Returns
none

Definition at line 164 of file pins.h.

◆ DPD_TP31_Toggle

#define DPD_TP31_Toggle ( )    (_LATC14 ^= 1)
Precondition
The RC14 must be set as Output Pin
Parameters
none
Returns
none

Definition at line 173 of file pins.h.

◆ FAULT_GetValue

#define FAULT_GetValue ( )    _RD9
Parameters
none
Returns
none

Definition at line 385 of file pins.h.

◆ FAULT_SetDigitalInput

#define FAULT_SetDigitalInput ( )    (_TRISD9 = 1)
Parameters
none
Returns
none

Definition at line 393 of file pins.h.

◆ FAULT_SetDigitalOutput

#define FAULT_SetDigitalOutput ( )    (_TRISD9 = 0)
Parameters
none
Returns
none

Definition at line 401 of file pins.h.

◆ FAULT_SetHigh

#define FAULT_SetHigh ( )    (_LATD9 = 1)
Precondition
The RD9 must be set as Output Pin
Parameters
none
Returns
none

Definition at line 359 of file pins.h.

◆ FAULT_SetLow

#define FAULT_SetLow ( )    (_LATD9 = 0)
Precondition
The RD9 must be set as Output Pin
Parameters
none
Returns
none

Definition at line 368 of file pins.h.

◆ FAULT_Toggle

#define FAULT_Toggle ( )    (_LATD9 ^= 1)
Precondition
The RD9 must be set as Output Pin
Parameters
none
Returns
none

Definition at line 377 of file pins.h.

◆ GPIO_1_GetValue

#define GPIO_1_GetValue ( )    _RC10
Parameters
none
Returns
none

Definition at line 79 of file pins.h.

◆ GPIO_1_SetDigitalInput

#define GPIO_1_SetDigitalInput ( )    (_TRISC10 = 1)
Parameters
none
Returns
none

Definition at line 87 of file pins.h.

◆ GPIO_1_SetDigitalOutput

#define GPIO_1_SetDigitalOutput ( )    (_TRISC10 = 0)
Parameters
none
Returns
none

Definition at line 95 of file pins.h.

◆ GPIO_1_SetHigh

#define GPIO_1_SetHigh ( )    (_LATC10 = 1)
Precondition
The RC10 must be set as Output Pin
Parameters
none
Returns
none

Definition at line 53 of file pins.h.

◆ GPIO_1_SetLow

#define GPIO_1_SetLow ( )    (_LATC10 = 0)
Precondition
The RC10 must be set as Output Pin
Parameters
none
Returns
none

Definition at line 62 of file pins.h.

◆ GPIO_1_Toggle

#define GPIO_1_Toggle ( )    (_LATC10 ^= 1)
Precondition
The RC10 must be set as Output Pin
Parameters
none
Returns
none

Definition at line 71 of file pins.h.

◆ GPIO_2_GetValue

#define GPIO_2_GetValue ( )    _RC11
Parameters
none
Returns
none

Definition at line 130 of file pins.h.

◆ GPIO_2_SetDigitalInput

#define GPIO_2_SetDigitalInput ( )    (_TRISC11 = 1)
Parameters
none
Returns
none

Definition at line 138 of file pins.h.

◆ GPIO_2_SetDigitalOutput

#define GPIO_2_SetDigitalOutput ( )    (_TRISC11 = 0)
Parameters
none
Returns
none

Definition at line 146 of file pins.h.

◆ GPIO_2_SetHigh

#define GPIO_2_SetHigh ( )    (_LATC11 = 1)
Precondition
The RC11 must be set as Output Pin
Parameters
none
Returns
none

Definition at line 104 of file pins.h.

◆ GPIO_2_SetLow

#define GPIO_2_SetLow ( )    (_LATC11 = 0)
Precondition
The RC11 must be set as Output Pin
Parameters
none
Returns
none

Definition at line 113 of file pins.h.

◆ GPIO_2_Toggle

#define GPIO_2_Toggle ( )    (_LATC11 ^= 1)
Precondition
The RC11 must be set as Output Pin
Parameters
none
Returns
none

Definition at line 122 of file pins.h.

◆ IO_RD2_GetValue

#define IO_RD2_GetValue ( )    _RD2
Parameters
none
Returns
none

Definition at line 232 of file pins.h.

◆ IO_RD2_SetDigitalInput

#define IO_RD2_SetDigitalInput ( )    (_TRISD2 = 1)
Parameters
none
Returns
none

Definition at line 240 of file pins.h.

◆ IO_RD2_SetDigitalOutput

#define IO_RD2_SetDigitalOutput ( )    (_TRISD2 = 0)
Parameters
none
Returns
none

Definition at line 248 of file pins.h.

◆ IO_RD2_SetHigh

#define IO_RD2_SetHigh ( )    (_LATD2 = 1)
Precondition
The RD2 must be set as Output Pin
Parameters
none
Returns
none

Definition at line 206 of file pins.h.

◆ IO_RD2_SetLow

#define IO_RD2_SetLow ( )    (_LATD2 = 0)
Precondition
The RD2 must be set as Output Pin
Parameters
none
Returns
none

Definition at line 215 of file pins.h.

◆ IO_RD2_Toggle

#define IO_RD2_Toggle ( )    (_LATD2 ^= 1)
Precondition
The RD2 must be set as Output Pin
Parameters
none
Returns
none

Definition at line 224 of file pins.h.

◆ LED_DP_PIM_GetValue

#define LED_DP_PIM_GetValue ( )    _RD15
Parameters
none
Returns
none

Definition at line 487 of file pins.h.

◆ LED_DP_PIM_SetDigitalInput

#define LED_DP_PIM_SetDigitalInput ( )    (_TRISD15 = 1)
Parameters
none
Returns
none

Definition at line 495 of file pins.h.

◆ LED_DP_PIM_SetDigitalOutput

#define LED_DP_PIM_SetDigitalOutput ( )    (_TRISD15 = 0)
Parameters
none
Returns
none

Definition at line 503 of file pins.h.

◆ LED_DP_PIM_SetHigh

#define LED_DP_PIM_SetHigh ( )    (_LATD15 = 1)
Precondition
The RD15 must be set as Output Pin
Parameters
none
Returns
none

Definition at line 461 of file pins.h.

◆ LED_DP_PIM_SetLow

#define LED_DP_PIM_SetLow ( )    (_LATD15 = 0)
Precondition
The RD15 must be set as Output Pin
Parameters
none
Returns
none

Definition at line 470 of file pins.h.

◆ LED_DP_PIM_Toggle

#define LED_DP_PIM_Toggle ( )    (_LATD15 ^= 1)
Precondition
The RD15 must be set as Output Pin
Parameters
none
Returns
none

Definition at line 479 of file pins.h.

◆ LED_GREEN_GetValue

#define LED_GREEN_GetValue ( )    _RD7
Parameters
none
Returns
none

Definition at line 283 of file pins.h.

◆ LED_GREEN_SetDigitalInput

#define LED_GREEN_SetDigitalInput ( )    (_TRISD7 = 1)
Parameters
none
Returns
none

Definition at line 291 of file pins.h.

◆ LED_GREEN_SetDigitalOutput

#define LED_GREEN_SetDigitalOutput ( )    (_TRISD7 = 0)
Parameters
none
Returns
none

Definition at line 299 of file pins.h.

◆ LED_GREEN_SetHigh

#define LED_GREEN_SetHigh ( )    (_LATD7 = 1)
Precondition
The RD7 must be set as Output Pin
Parameters
none
Returns
none

Definition at line 257 of file pins.h.

◆ LED_GREEN_SetLow

#define LED_GREEN_SetLow ( )    (_LATD7 = 0)
Precondition
The RD7 must be set as Output Pin
Parameters
none
Returns
none

Definition at line 266 of file pins.h.

◆ LED_GREEN_Toggle

#define LED_GREEN_Toggle ( )    (_LATD7 ^= 1)
Precondition
The RD7 must be set as Output Pin
Parameters
none
Returns
none

Definition at line 275 of file pins.h.

◆ LED_RED_GetValue

#define LED_RED_GetValue ( )    _RD8
Parameters
none
Returns
none

Definition at line 334 of file pins.h.

◆ LED_RED_SetDigitalInput

#define LED_RED_SetDigitalInput ( )    (_TRISD8 = 1)
Parameters
none
Returns
none

Definition at line 342 of file pins.h.

◆ LED_RED_SetDigitalOutput

#define LED_RED_SetDigitalOutput ( )    (_TRISD8 = 0)
Parameters
none
Returns
none

Definition at line 350 of file pins.h.

◆ LED_RED_SetHigh

#define LED_RED_SetHigh ( )    (_LATD8 = 1)
Precondition
The RD8 must be set as Output Pin
Parameters
none
Returns
none

Definition at line 308 of file pins.h.

◆ LED_RED_SetLow

#define LED_RED_SetLow ( )    (_LATD8 = 0)
Precondition
The RD8 must be set as Output Pin
Parameters
none
Returns
none

Definition at line 317 of file pins.h.

◆ LED_RED_Toggle

#define LED_RED_Toggle ( )    (_LATD8 ^= 1)
Precondition
The RD8 must be set as Output Pin
Parameters
none
Returns
none

Definition at line 326 of file pins.h.

◆ TP_PIM_GetValue

#define TP_PIM_GetValue ( )    _RD12
Parameters
none
Returns
none

Definition at line 436 of file pins.h.

◆ TP_PIM_SetDigitalInput

#define TP_PIM_SetDigitalInput ( )    (_TRISD12 = 1)
Parameters
none
Returns
none

Definition at line 444 of file pins.h.

◆ TP_PIM_SetDigitalOutput

#define TP_PIM_SetDigitalOutput ( )    (_TRISD12 = 0)
Parameters
none
Returns
none

Definition at line 452 of file pins.h.

◆ TP_PIM_SetHigh

#define TP_PIM_SetHigh ( )    (_LATD12 = 1)
Precondition
The RD12 must be set as Output Pin
Parameters
none
Returns
none

Definition at line 410 of file pins.h.

◆ TP_PIM_SetLow

#define TP_PIM_SetLow ( )    (_LATD12 = 0)
Precondition
The RD12 must be set as Output Pin
Parameters
none
Returns
none

Definition at line 419 of file pins.h.

◆ TP_PIM_Toggle

#define TP_PIM_Toggle ( )    (_LATD12 ^= 1)
Precondition
The RD12 must be set as Output Pin
Parameters
none
Returns
none

Definition at line 428 of file pins.h.

Function Documentation

◆ PINS_Initialize()

void PINS_Initialize ( void  )
Parameters
none
Returns
none

Setting the Output Latch SFR(s)

Setting the GPIO Direction SFR(s)

Setting the Weak Pull Up and Weak Pull Down SFR(s)

Setting the Open Drain SFR(s)

Setting the Analog/Digital Configuration SFR(s)

Set the PPS

Definition at line 46 of file pins.c.

+ Here is the caller graph for this function: