The pins are:
16 Vcc Input Voltage
8 GND Ground
15 A IN Input Bit 0
1 B IN Input Bit 1
10 C IN Input Bit 2
9 D IN Input Bit 3
11 LOAD IN Load Inputs - Inactive state HIGH. Go LOW/HIGH to load inputs.
3 QA OUT Output Bit 0
2 QB OUT Output Bit 1
6 QC OUT Output Bit 2
7 QD OUT Output Bit 3
14 CLEAR IN Reset Outputs - Inactive State LOW. Go HIGH/LOW to reset.
4 DOWN IN Count Down - Inactive state HIGH. Go LOW/HIGH to count down.
5 UP IN Count Up - Inactive State HIGH. Go LOW/HIGH to count up.
13 BORROW OUT Count has gone below 0000. Connect this to DOWN of IC below.
12 CARRY OUT Count has gone above 1111. Connect this to UP of IC above.
In this example below I have daisy chained 3x Philips 74HC193Ns together to produce a 12 bit value:
The red jump wires are connected to the UP input. Initially from an Arduino UNO providing a simple pulse with a 100ms delay, then from the CARRY to the UP of the next IC.
A/B/C/D and BORROW are not connected. LOAD and DOWN connected to +5V as I'm not going to load a value and I am not going to count down.
Just to show how this works I connect the outputs to some red LEDs followed by some inline 1K resistors (which are hidden behind the LEDs in the picture).
Using this method, these 3x 74193s create a 12 bit address line which could be used help program or read a 4K by 8 bit EEPROM.
Here's the Arduino code to pulse the 74193:
/*
74193 Synchronous 4 bit binary up/down counter
*/
int RESET = 2; // Connect to Pin 14 on the IC
int COUNT_UP = 3; // Connect to Pin 5 on the IC
void setup() {
// Initialise Pins
pinMode(RESET,OUTPUT);
pinMode(COUNT_UP,OUTPUT);
// Set default pin states
digitalWrite(COUNT_UP,HIGH);
digitalWrite(RESET,LOW);
// Perform a reset. Clears outputs to low state i.e. 0000
digitalWrite(RESET,HIGH);
digitalWrite(RESET,LOW);
}
void loop() {
// Clock Up Pulse
digitalWrite(COUNT_UP,LOW);
digitalWrite(COUNT_UP,HIGH);
delay(100);
}