This is a demo project for the Pmod OC1 made by Digilent. This module contains 4 BJT transistors in open collector configuration. To control the Pmod, an Arduino UNO is used.
In this application, the anodes of 4 LEDs are connected to 5V, and their cathodes are connected to 330 ohm resistors. The other ends of the resistors are connected to the output of Pmod OC1 (to the collector of the BJTs). The input of the peripheral module (the base of the BJTs) is connected to the Arduino UNO. When a HIGH value is set on a pin, the respective transistor saturates, and the LED connected to it will light up, as connection to the ground will be realized.