Skip to content

FliesLikeABrick/apc-79xx-salvage

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 

Repository files navigation

apc-79xx-salvage

Information on salvaging parts such as i2c relay boards from APC 79xx PDUs - understanding, reusing, reducing waste

Goals

The information here is provided and maintained with the following goals, in no particular order:

  • Enable re-use of parts salvaged from APC 79XX-series PDUs, such as the AP7990, AP7930, and many others
  • Provide information in an application-indepdent manner, and call out application-specific explanations if present
  • Encourage collection of parts from datacenter/industrial e-waste

AP79xx Theory of Operation

The system consists of 3 types of modules, referred to as the following:

  • Power supply - consists of two switch-mode power supplies and a section with one or more current transfomrers (CTs) for monitoring power flow
  • Relay Board - each board contains 8 relays that operate independently, taking independent from an I2C interface present at the bottom of the board
  • Embedded control system - microcontroller-based, typically containing a 10/100 Ethernet interface and RS-232 serial interface. This module consumers the power supply and controls the relay banks/boards.

The control system provides multiple IP and serial-based interfaces to monitor the distribution of power to end network and computer systems. Many models of AP79xx allow for switching of the output ports on/off based on inputs from interactive (web UI, SSH/Telnet) or programmatic (onboard scheduling, SNMPv1/3) sources. The system also provides power consumption data from its onboard current transformer(s), via these same interfaces.

The embedded control system communicates via I2C to one or more relay boards. The addressing schema of the daisy-chained banks is not yet known.

The embedded control system and relay boards are connected via 10-pin (2x5) ribbon cable. Each relay board has headers at each end, allowing the power and data bus to be passed through

Each relay is SPST, typically rated for 20A @ 250V. One leg of the coil is connected directly to +24V.

The relay boards use a PCF8574 I2C I/O expander to activate 8 independent outputs. The output passes from the PCF8574, through a NOR-based inverter, to a NPN transistor that activates the ground side of the associated relay coil. Per the PCF8574 datasheets "At power on, the I/Os are high"; this is why the inverter is used on each output so that the default state is for the relays to be off/open.

The 24V and 5V power are tied to a common ground for the transistor to function correctly.

It is possible that the system can operate sufficiently on 3.3v VCC instead of 5v, this has not been tested but the datasheets linked below indicate everything should function on 3.3v. It is not known if the transistor or other components may operate correctly, or if the LED brightness would be significantly impacted.

Header Pinout

Header Pinout

Pinout Markup

Below is the pinout of the 3 main ICs, marked with labels to show how they are interconnected from header to I/O expander to NOR gates/inverters to coil drivers.

Jumper

  • Yellow/Black SCL: I2C clock
  • Green/Black SDA: I2C Data
  • Black/White GND: Common ground (24v and 5v both are referenced from this ground). Notice that there are two ground pins, so it could be convenient to connect 5v ground and 24v ground each to one, as they will be tied together by the relay board.
  • Orange/Black VCC: 5V supply for logic
  • Red/Black 24V: 24V to drive the relay coils

PCF8574

  • Pink/Black P0 through P7 - logic outputs
  • LightBlue/Black A0 through A2 - Address inputs/configuration

74AC02

  • LightBlue/Black O1 through O7 - inverted outputs which connect to respective transistor base legs

NPN Transistor

  • LightBlue/Black O1 through O7 - Base - connected to (in example below) O7 for output/relay #7
  • White/Black GND - Emitter
  • Red/Black COIL - Collector - 24V from coil, which the transistor grounds to activate the coil/relay

Header Pinout

Usage

  • Provide +24v (coil voltage) from a power supply to the ground and +24v pins (middle two pins in the header)
  • Provide +5v (VCC) from a Raspberry pi or power supply; connect negative/ground to the same ground as the 24v source's ground
  • The datasheets linked below describe communication with the PCF8574. However, this is a common component and libraries exist in Python and other languages to simplify usage. With lower-level I2C communication, a byte can be written to set all 8 outputs in a single command, versus other example code that sets one output bit/pin at a time.

Components / Variants

  • Some of the 10-pin headers/jumpers between boards are keyed, some are not

  • I2C Remote I/O Expander IC:

    • Texas Instruments PCF8574
    • NXP PCF8574
  • Quad dual-input NOR gate IC:

    • ONSemi AC02G - MC74AC02
    • Fairchild 74AC02
  • NPN Transistor:

    • Marked "ZCW", possibly NXP/Nexperia PBSS4350T

Example Code

This repository contains extremely basic code examples. Rather than use raw I2C, the example code uses the python package pcf8574 to simplify interaction.

The main code provided is a helper function that takes one or more values or pins and sets the output accordingly

The code makes use of resources from two packages:

  • Apt/Yum or equivalent i2c-tools (sudo apt-get install i2c-tools)
  • pypi pcf8574 (python3 -m pip install pcf8574, suggested to run this from a virtual environment instead of using root to install in the main system: python3 -m venv ap79xx; source ap79xx/bin/activate; python3 -m pip install pcf8574)

Useful Resources

Data Sheets

Future Work

  • Identify pinout and other information to reuse the PDU 5V and 24V power supplies
  • Identify pinout and other information to reuse the current transformer (CT) section of the power board
  • Evaluate the possibility of using the embedded control system in other contexts. This may be of limited value due to the ubiquity of Arduino, Raspberry Pi, ESP32and similar systems available; however the academic exercise could be valuable and any opportunity to re-use waste should be inherently valuable

About

Information on salvaging parts such as i2c relay boards from APC 79xx PDUs - understanding, reusing, reducing waste

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages