Basys MX3™ Board Reference Manual
Name
IR_TX
IR_RX
The IRDA_PDOWN and IR_TX must be defined as digital outputs and disable the analog functionality on IR_TX:
TRISGbits.TRISG1 = 0; //set RG1 (IRDA_PDOWN) as an output
TRISBbits.TRISB7 = 0; //set RB7 (IR_TX) as an output
ANSELBbits.ANSB7 = 0; //disable analog functionality on RB7 (IR_TX)
The IR_RX must be defined as digital input and the analog functionality disabled:
TRISBbits.TRISB6 = 1; //set RB6 (IR_RX) as an input
ANSELBbits.ANSB6 = 0; //disable analog functionality on RB6 (IR_RX)
16.2 Functionality
The control of the IrDA module is implemented in the IrDA library of the Basys MX3 library pack. Library features
include:
IRDA_PDOWN is used as a basic digital output pin.
IRDA communication signals are mapped over the UART5 communication signals:
o
U5RXR = 0x05; // IR_RX (RB6) -> U5RX
o
RPB7R = 0x04; // IR_TX (RB7) -> U5TX
UART5 interface is configured in the IrDA mode (the IREN bit is set) with 9600 baud and used for sending
and receiving data to IrDA module.
If the users want to use the IrDA module without the IrDA library, they need to implement their own IrDA
functionality.
Copyright Digilent, Inc. All rights reserved.
Other product and company names mentioned may be trademarks of their respective owners.
PIC32 pin
PGED2/AN7/RPB7/CTED3/RB7
PGEC2/AN6/RPB6/RB6
Table 16.1. IrDA connectivity.
IRDA module pin
TXD
RXD
Page 38 of 56
Need help?
Do you have a question about the Basys MX3 and is the answer not in the manual?
Questions and answers