IV Swinger 2 - PCB (PV Cell, EMR)

1,580

4

About: I used to get paid for designing computer and networking hardware and software. Now I design stuff for fun and give it away.

This Instructable is a variant of the original IV Swinger 2:

https://www.instructables.com/id/IV-Swinger-2-a-50-IV-Curve-Tracer/

If you came here from there, welcome!

Otherwise, please visit that Instructable first. You may or may not end up back here depending on which variant you have chosen.

Teacher Notes

Teachers! Did you use this instructable in your classroom?
Add a Teacher Note to share how you incorporated it into your lesson.

Step 1: Understand the HW Design / Choose Variant

Please refer to Step 1 in the original Instructable:

https://www.instructables.com/id/IV-Swinger-2-a-50-IV-Curve-Tracer/

If you are back here, it means you have chosen:

PCB - PV cell version, electromechanical relay (EMR)

Attached to this step are the following:

  • PDF of the steps of this Instructable
  • PDF of the schematic of this version
  • PDF with images of the top and bottom of the PCB

Step 2: Install Software

Before spending time building the hardware, install the Arduino software and the IV Swinger 2 application on the laptop that you’ll be using.

  • Install Arduino IDE:

https://www.arduino.cc/en/Main/Software

  • Install IV Swinger 2 app:

https://github.com/csatt/IV_Swinger/releases

Make sure both of the above come up before proceeding. If necessary, upgrade the OS on your computer

Step 3: Order PCB

Currently, the PCB must be purchased from a manufacturing house that will actually fabricate it for your order. The downside of this is that you’ll probably have to buy more than you need. I have used the following two:

OSH Park:

PCBWay:

Amazingly, I have put in orders to PCBWay on a Monday and had the boards in my hands in California on Friday.

I have shared this PCB design on PCBWay, and you can order it directly using the following link:

https://www.pcbway.com/project/shareproject/IV_Swinger_2_cell_Rev_A_2019_01_06.html

Alternately, you can order PCBs from OSH Park (or anywhere else) by uploading the ZIP archive of the Gerber files, which are found in the GitHub repository:

IV_Swinger/PCB/IV_Swinger_2_cell/Gerber/*.zip

Soon, I hope to find someone who wants to sell individual PCBs on eBay (possibly in kits, that include all the other parts too).

Step 4: Buy Other Parts

The other necessary parts to build an IV Swinger 2 can all be purchased online from Amazon and Digi-Key.

The EMR PV cell version bill of materials (BOM) is attached to this step. It can also be downloaded from:

https://github.com/csatt/IV_Swinger/raw/master/PCB/BOM/emr_cell_BOM.pdf

The BOM has an Amazon link and a Digi-Key link at the bottom. The Amazon link is a “wish list” that can be used to populate your cart. Some of the items come in quantities larger (in some cases much larger) than needed to build a single IV Swinger 2. You may, of course, choose to find equivalents that are offered in smaller quantities. Also, many of the items are things that you may already have, so don’t necessarily just blindly order everything on the list.

The Digi-Key link is a pre-populated shopping cart. Again, you’ll want to check if you already have any of the items before ordering.

In both cases, it is possible (or probable) that certain items will go out of stock or be discontinued, so you’ll have to find suitable substitutions. Note that there are some of the Digi-Key items have *ALTERNATE* in the “Customer Reference field. These should only be ordered if the primary version of the same part is marked as “backorder”.

Also included below is the link to donate to the original Arduino developers. I donate $5 for each $10 Arduino clone that I buy. This is your choice, but I think it is the right thing to do.

Donate to Arduino.cc:

https://www.arduino.cc/en/Main/Contribute

Step 5: Gather / Buy Tools

  • Holding:
    • Vise
    • 3rd hand tool with magnifying glass
    • Tape (preferably Kapton, but Scotch ok)
    • Long/needle-nosed pliers
  • Soldering:
    • Soldering iron (preferably temp controlled solder station)
    • Tip cleaner
    • Rosin core solder
    • Solder sucker or solder wick
  • Cutting:
    • Wire cutter (flush cut)
    • Wire stripper
  • Drilling:
    • Drill
    • 1/16" bit (pilot for 9/64")
    • 9/64" bit (standoffs)
    • 11/64" bit (pilot for 13/64")
    • 13/64" bit (binding posts)
    • 3/8" Forstner bit (preferred - USB cable hole)
      • Alternate: 1/8”, 3/16”, 7/32”, 1/4”, 9/32”, 5/16”, 11/32”, 3/8”, and 25/64” normal bits
  • Other:
    • Digital Multimeter (DMM)
    • Small Phillips screwdriver
    • 1.5V battery
    • Sharpie
    • Ruler
    • Water spray bottle

Step 6: Manually Test the Relay Module

NOTE: the video above is for the 1-channel relay used for the PV module version. The process is basically the same for the 2-channel relay, but there are some minor differences.

This will confirm that your 2-channel relay module is the correct type (active-low trigger) and that it is functional.

  • With Arduino powered off:
    • Connect relay module GND to Arduino GND with female-to-male jumper___________
    • Connect relay module VCC to Arduino 5V with female-to-male jumper ___________
    • Connect female-to-male jumper to relay module IN1 (male end not connected) ___________
  • Connect Arduino to laptop with USB cable:
    • Arduino: green LED should be on ___________
    • Arduino: yellow LED should be blinking once per second (assuming fresh-out-of box Arduino, running the default "Blink" sketch) ___________
    • Relay module: no LEDs should be on ___________
    • Relay module (K1 screw terminal): C (middle) terminal should have continuity with NC (bottom) terminal and no continuity with NO (top) terminal ___________
  • Connect the male end of the jumper from the relay module IN1 pin to the GND socket near the blinking yellow LED on the Arduino ___________
    • Relay module: should click and IN1 LED should come on ___________
    • Relay module (K1 screw terminal): C (middle) terminal should have continuity with NO (top) terminal and no continuity with NC (bottom) terminal ___________
  • Connect the male end of the jumper from the relay module IN1 pin to the "13" socket near the blinking yellow LED on the Arduino ___________
    • Relay module: should click once per second ___________
    • Relay module: IN1 LED should blink exactly opposite from the Arduino's yellow LED ___________

NOTE: If your relay module behaves in the opposite manner to that described in each of the above three steps, that indicates that it is the wrong type, i.e. it has an active-high trigger instead of an active-low trigger. Your relay module may have a jumper that selects active-high/low, in which case you should change the jumper and try again. Otherwise, don’t despair – there is a configuration setting in the software Preferences that will allow you to use your active-high relay.

Repeat all of the above for the IN2 input and test the continuity on the screw terminal block K2.

Step 7: Prepare for Soldering

Soldering NOTES:

  • If you don't have a lot of soldering experience, read this:
    Adafruit: Common Soldering Problems
  • Soldering components to the PCB is pretty mistake-proof, but doing it in the order described is recommended (shortest -> tallest).
  • Some components have a correct and an incorrect orientation and some don’t matter. Pay attention to the instructions.
  • I highly recommend using 63/37 0.031” (or 0.8mm) rosin core solder. Yes, it is 37% lead, but it is not a health risk for you (really), and environmentally insignificant when used by hobbyists. You’ll solder like a pro.

Step 8: 1/4W Resistors

Solder 1/4W resistors to PCB:

  • Resistors can be inserted in either orientation. It is very important to use the correct value for each, however.
  • Insert all resistors before soldering. Tape down on front to hold in place OR bend leads slightly on back.

    PV cell version (EMR) – 16 joints:
    • R3 (1k): _______
    • R4 (1k): _______
    • R5 (22k): _______
    • R6 (22k): _______
    • R7 (22k): _______
    • RF (75k): _______
    • RF1 (680k): _______
    • Rg (1k): _______
  • Flip board upside down and hold with vise or 3rd hand tool OR tape board to work surface. Solder all 16 leads
    _______
  • Inspect with magnifying glass to make sure all joints are good and there are no solder bridges _______
    NOTE: A solder bridge is ok between the ends of RF and RG
  • Trim all leads
    _______

Use multimeter to measure exact resistances of soldered resistors:

  • With the PCB still upside down, measure the resistances with a DMM. The resistances (but unfortunately not the names) are marked on the back. Record the exact values of the ones marked with an asterisk (*) below – these values will be used later (“Step 28: Apply resistor calibration”). The others should just be close to their specified value (should be 1%, but don’t worry as long as it is < 10%) - the main point is to catch any mistakes you might have made.

    PV cell version (EMR):
    • R3 (1k): _______
    • R4 (1k): _______
    • R5 (22k): _______
    • R6 (22k): _______
    • R7 (22k): _______
    • RF (75k): _______ *
    • RF1 (680k): _______ *
    • RG (1k): _______ *

Step 9: IC Sockets

Solder IC sockets to PCB – 16 joints:

  • Insert both sockets before soldering. Tape down on front to hold in place.
  • Make sure notch is on the left end as marked on the PCB
  • Flip board upside down and hold with vise or 3rd hand tool OR tape board to work surface and solder all 16 pins
    ________
  • Inspect with magnifying glass to make sure all joints are good
    ________

If you have opted not to use sockets, solder the ICs directly to the PCB instead of the sockets. Make sure dot is on the left end of the TLV2462 (pin 1). Make sure notch and dot are on the left end of the MCP3202 (pin 1).

Step 10: Horizontal Shunt Resistor

The shunt resistor lies flat on the PCB and should be soldered down at this point.

Solder horizontal shunt resistor to PCB – 2 joints:

  • Insert 5mΩ shunt resistor (either way). Tape down to hold in place.
    • SHUNT: ________
  • Flip board upside down and hold with vise or 3rd hand tool OR tape board to work surface and solder both leads
    ________
  • Trim both leads
    _______
  • Re-flow/add solder on both leads
    _______
    (This is because leads are thick, and may not have heated well before trimming)
  • Inspect with magnifying glass to make sure joints are good
    ________

Step 11: Stacking Connectors and Female Header

Solder stacking connectors and female header to PCB – 30 joints:

  • Insert stacking connectors A1, A2, and A3 and female header FH. These connectors are symmetrical, so there’s no “backwards”. Tape down to hold in place.
    • A1 (10 pin): ________
    • A2 (8 pin): ________
    • A3 (8 pin): ________
    • FH (4 pin): ________

      NOTES: Stacking connector A4 is not needed. Stacking connector A1 can be 8-pin (pins 9 and 10 are not used).
  • Flip board upside down and hold with vise or 3rd hand tool OR tape board to work surface and solder all pins
    ________
    NOTE: the pins on A1, A2, and A3 that are actually used on the PCB are circled on the back of the PCB. Soldering the others provides physical support only.
  • Inspect with magnifying glass to make sure joints are good and there are no solder bridges
    ________

Step 12: DIP Switch or Jumper Header

The cell versions need either a x1 DIP switch or a 2-pin jumper header. Both have the same purpose – to select whether current measurements are multiplied by a factor of approximately 10 (for lower power PV cells). Only one of these should be installed.

Solder x1 DIP switch (or jumper header) to PCB – 2 joints:

  • Insert x1 DIP switch with the “ON” end toward the top of the board. Tape down to hold in place. OFF=LO_CUR: ________ (PHOTOS SHOW THIS OPTION)

-OR-

  • Insert 2-pin jumper header. Tape down to hold in place.
    JP: ________
  • Flip board upside down and hold with vise or 3rd hand tool OR tape board to work surface and solder both pins
    ________
  • Inspect with magnifying glass to make sure joints are good and there are no solder bridges
    ________

Step 13: Screw Terminal Blocks

Solder screw terminal blocks to PCB – 4 joints:

  • Insert screw terminal blocks with the openings facing left. Tape down to hold in place.
    • J1: ________
    • J2: ________
      NOTE: The screw terminal blocks may be omitted entirely, soldering the 18ga wire directly to the holes in the PCB (later).
  • Flip board upside down and hold with vise or 3rd hand tool OR tape board to work surface and solder all joints
    ________
  • Inspect with magnifying glass to make sure joints are good and there are no solder bridges
    ________

Step 14: Filter Capacitors

The small filter capacitors are not polarized, so it doesn’t matter which lead goes in which hole.

Solder 0.1uF capacitors to PCB - 4 joints:

  • Insert both capacitors before soldering. Bend leads on back to hold in place.
    • C3: ________
    • C6: ________
  • Flip board upside down and hold with vise or 3rd hand tool and solder all four joints
    ________
  • Inspect with magnifying glass to make sure joints are good and there are no solder bridges
    ________
  • Trim all 4 leads
    _______

Solder 2.2nF (2200pF) capacitors to PCB - 4 joints:

  • Insert both capacitors before soldering. Bend leads on back to hold in place.
    • C4: ________
    • C5: ________
  • Flip board upside down and hold with vise or 3rd hand tool and solder all four joints
    ________
  • Inspect with magnifying glass to make sure joints are good and there are no solder bridges
    ________
  • Trim all 4 leads
    _______

Step 15: Bypass Diode

The purpose of the bypass diode is to protect the electronics in case the PV is connected to the IV Swinger 2 backwards.

The cell versions require one 15A, 45V bypass diode (15SQ045).

Solder bypass diode to PCB – 2 joints:

  • Bend lead on striped end of diode around the diode so that it points in the same direction as the other lead.
  • Insert leads as follows:
    • Pad D1, striped end (top): ________
    • Pad D2, non-striped end (bottom): ________
  • Flip board upside down and hold with vise or 3rd hand tool and solder both (or all four) leads
    ________
  • Trim leads
    _______
  • Re-flow/add solder on both/all leads
    _______
    (This is because leads are thick, and may not have heated well before trimming)
  • Inspect with magnifying glass to make sure joints are good
    ________

Step 16: Load Capacitors

Solder load capacitors to PCB:

Cell versions use 22000µF, 6.3V load capacitors.

These are polarized electrolytic capacitors, so orientation is important.

  • Insert load capacitors in position. Stripe side (shorter lead) goes to the right – this is the negative lead. Tape to hold in place.
    • C1 ________
    • C2 ________
  • Flip board upside down and hold with vise or 3rd hand tool
    ________
  • Solder all 4 leads
    ________
  • Trim all 4 leads
    _______
  • Re-flow/add solder on all 4 leads
    _______
    (This is because leads are thick, and may not have heated well before trimming)
  • Inspect with magnifying glass to make sure joints are good
    ________

Step 17: Optionally Clean Flux Residue From PCB

Some people think it is important to clean off the flux residue from the PCB after soldering. It makes it looks nicer, but since the PCB sits on top of the Arduino, you don’t see the back anyway.

Functionally, it shouldn’t matter. The solder manufacturer Kester says this:

  • “Rosin flux residues are non-conductive and non-corrosive. Under normal circumstances they do not have to be removed from a printed circuit assembly. Rosin residue removal would be for cosmetic considerations. In an environment where the working temperature of the assembly will exceed 200°F the rosin residues will melt and become conductive, in these situations flux removal is required.”

If you do want to clean it off, see this Instructable:

https://www.instructables.com/id/Cleaning-up-your-PCB/

Step 18: Check for Shorts

Using the digital multimeter (DMM) set on the continuity check (beep), check that there is no continuity between the following:

Power to ground (mandatory):

  • Left IC socket, pin 8 to pin 4
    OR
  • Right IC socket, pin 8 to pin 4

Other (recommended):

  • All “neighbor” pins or solder joints. None should indicate continuity, except the pairs circled in the pictures which are connected.
  • The idea is to find solder bridges that you didn’t see visually

Step 19: Insert ICs

Static electricity can destroy ICs. Take off your shoes and touch something metal connected to ground before handling them, if possible.

  • Insert TLV2462 in left socket _________
    • Make sure dot is on the left end (pin 1)
    • Legs may have to be bent inward slightly
  • Insert MCP3202 in right socket __________
    • Make sure notch and dot are on the left end (pin 1)
    • Legs may have to be bent inward slightly

Step 20: Prepare Load Circuit Wires

Prepare load circuit wires:

NOTE: This can be any stranded AWG 18 or AWG 16 insulated wire such as from a typical household extension/lamp cord or heavier speaker wire. AWG 18 solid core is fine too. If solid core is used, ignore the instructions to twist and “tin” the strands.

  • "BLK1": BLK1 (lower black) binding post to B1 screw terminal on PCB (J1)
    • Cut to length: 9 cm
      ________
    • Strip 1 cm on each end and twist strands
      ________
    • Crimp cable ring connector on one end using pliers (or vise / ViseGrips / crimping tool)
      ________
    • Heat crimp with the soldering iron and flow solder into strands
      ________
    • Heat the strands of the other twisted end and flow solder into the strands (i.e. "tin" it)
      ________
  • "RED1_A": RED1 (lower red) binding post to relay module #1 NO terminal and to R1 screw terminal on PCB (J1)
    This is a “Y” with a cable ring connector in the middle.
    • Cut two wires to length: 9cm each
      1: ________
      2: ________
    • Strip 1 cm on each end of both and twist strands
      1: ________
      2: ________
    • Insert one end of each into the cable ring connector and crimp cable ring connector using pliers (or vise / ViseGrips / crimping tool)
      ________
    • Heat crimp with the soldering iron and flow solder into strands
      ________
    • Heat the strands of the other twisted ends and flow solder into the strands (i.e. "tin" them)
      ________
  • “RED_1B”: RED1 (lower red) binding post to relay module #2 NC terminal
    “BLK2”: BLK2 (upper black) binding post to relay module #2 NO terminal
    “RED2”: RED2 (upper red) binding post to relay module #2 C terminal
    • Cut to length: 9 cm
      RED_1B: ________
      BLK2: ________
      RED2: ________
    • Strip 1 cm on each end and twist strands
      RED_1B: ________
      BLK2: ________
      RED2: ________
    • Crimp cable ring connector on one end using pliers (or vise / ViseGrips / crimping tool) RED_1B: ________
      BLK2: ________
      RED2: ________
    • Heat crimp with the soldering iron and flow solder into strands
      RED_1B: ________
      BLK2: ________
      RED2: ________
    • Heat the strands of the other twisted end and flow solder into the strands (i.e. "tin" it)
      RED_1B: ________
      BLK2: ________
      RED2: ________
  • "Relay C": Relay module #1 C terminal to Relay C screw terminal on PCB (J2)
    “Relay NC”: Relay module #1 NC terminal to Relay NC screw terminal on PCB (J2)
    • Cut two wires to length: 9 cm each
      Relay C: ________
      Relay NC: ________
    • Strip 1 cm on each end of each and twist strands
      Relay C: ________
      Relay NC: ________
    • Heat the strands of both ends of each and flow solder into the strands (i.e. "tin" them) Relay C: ________
      Relay NC: ________

Step 21: Make Load Circuit Connections

Refer to the drawings of off-PCB connections for this step. These connections use the load circuit wires that were prepared in the previous step.

Make binding post connections:

  • Remove outer nuts and washers from threaded posts
    ________
  • Insert threaded post of black side through the cable ring connector on load circuit wire:
    “BLK1"
    ________
  • Insert threaded post of red side through the cable ring connectors on load circuit wires:
    “RED1_A” and “RED_1B”
    ________
  • Insert threaded post of black side of second binding post through the cable ring connector on load circuit wire
    “BLK2”
    ________
  • Insert threaded post of red side of second binding post through the cable ring connector on load circuit wire “RED2“
    ________
  • Put washers back on
    ________
  • Put nuts on and tighten
    ________

Make PCB connections:

  • Loosen screw and insert the twisted/soldered end of the load circuit wire from the black binding post into the lower hole of screw terminal J1 and tighten down the screw.
    “BLK1”
    _________
  • Loosen screw and insert the twisted/soldered end of the load circuit wire from the red binding post into the adjacent hole of screw terminal J1 and tighten down the screw.
    “RED1_A”
    _________
  • Loosen screw and insert one twisted/soldered end of the “RELAY NC” load circuit wire into the upper hole of screw terminal J2 and tighten down the screw.
    “RELAY NC”
    _________
  • Loosen screw and insert one twisted/soldered end of the “RELAY C” load circuit wire into the lower hole of screw terminal J2 and tighten down the screw.
    “RELAY C”
    _________

Make relay module switching side (screw-down) connections:

  • Loosen screw and insert the twisted/soldered end of the “RED1_A” load circuit wire into the top (“Normally Open” - NO) screw terminal hole on the relay #1 module (lower module) and tighten down the screw. “RED1_A”
    _________
  • Loosen screw and insert the end of the “RELAY C” load circuit wire into the center (“Common” - C) screw terminal hole on the relay #1 module (lower module) and tighten down the screw.
    “RELAY C”
    _________
  • Loosen screw and insert the end of the “RELAY NC” load circuit wire into the bottom (“Normally Closed – NC) screw terminal hole on the relay #1 module (lower module) and tighten down the screw.
    “RELAY NC”
    __________
  • Loosen screw and insert the twisted/soldered end of the “BLK2” load circuit wire into the top (“Normally Open” - NO) screw terminal hole on the relay #2 module (upper module) and tighten down the screw. “BLK2”
    _________
  • Loosen screw and insert the end of the “RED2” load circuit wire into the center (“Common” - C) screw terminal hole on the relay #2 module (upper module) and tighten down the screw.
    “RED2”
    _________
  • Loosen screw and insert the end of the “RED1_B” load circuit wire into the bottom (“Normally Closed – NC) screw terminal hole on the relay #2 module (upper module) and tighten down the screw.
    “RED1_B”
    __________

Step 22: Make Relay Power/control Side Connections

Refer to the drawings of off-PCB connections for this step. These connections use the 4-inch male-to-female jumpers.

Make relay module control/power side (jumper) connections:

  • Connect the BLUE jumper from PCB connector A2, pin 6 (Arduino pin D2) to the IN pin on the relay module (IN1 pin on 2-relay module)
    __________
  • Connect the WHITE jumper from PCB connector A2, pin 4 (Arduino pin D4) to the IN2 pin on the 2-relay
    __________
  • Connect the BLACK jumper from PCB connector A3, pin 7 (Arduino, GND) to the GND pin on the relay module
    __________
  • Connect the RED jumper from PCB connector A3, pin 5 (Arduino, +5V) to the VCC pin on the relay module
    __________

Step 23: Check All Off-PCB Connections

Check all off-PCB connections:

  • Use the drawing of off-PCB connections and double-check that all connections match the drawing.
    __________
  • Tug all wires connected to screw-terminal blocks gently to make sure they are securely connected.
    __________

Step 24: Mate PCB With Arduino

Mate PCB with Arduino:

  • Put tape on metal USB connector housing where PCB will touch it
    ________
  • Line up stacking connector pins on bottom of the PCB with the corresponding connectors on the top of the Arduino and press the boards together, taking care not to bend any of the pins.
    ________
  • For now, move the slider on the DIP switch that was installed in “Step 12: DIP switch or jumper header” above to the ON position. If you opted to install jumper header JP instead, slide the jumper over the pins to short them together.
    __________

Step 25: Smoke Test

NOTE: The video above is from the original non-PCB Instructable. It was much easier to see the Arduino LEDs without a PCB on top of it!

Smoke test:

  • Connect Arduino to laptop via USB
    • Check for smoke ☺
      _______
    • Check that relay module LEDs are off
      ________
    • Check that Arduino yellow LED is blinking once per second (assuming that it’s still loaded with “Blink” sketch)
      _______

Step 26: Load Arduino Sketch

NOTE: The video above is also from the original non-PCB Instructable.

Load IV Swinger 2 Arduino sketch:

  • Open Arduino application on your computer
    ________
  • Find where the Arduino software looks for sketches:
    Arduino->Preferences->Sketchbook location
  • Use your browser to go to:
    https://raw.githubusercontent.com/csatt/IV_Swinger/master/Arduino/IV_Swinger2/IV_Swinger2.ino
  • Right-click and use “Save As” to save IV_Swinger.ino to the Arduino sketchbook folder found above (make sure your browser doesn’t add an extension like .txt to the file name)
  • Go back to the Arduino application and find the IV_swinger2.ino sketch using:
    File->Open
    The Arduino application will inform you that IV_Swinger2.ino must be in a folder named IV_Swinger2 and it will offer to do that for you. Accept its kind offer.
  • Click on arrow button or select “Upload” from “Sketch” menu
    _________
  • Check Arduino LEDs: Yellow LED should be blinking. This is not the same yellow LED that the Blink sketch controls.
    _________

Step 27: Connect Via IV Swinger 2 App

NOTE: The video above is also from the original non-PCB Instructable. It also includes the first test of Step 29 in this Instructable

Connect via IV Swinger 2 application:

  • Open the IV Swinger 2 application
    ________
  • Verify that “Swing!” button text changes to RED and the message below it changes from “Not connected” to “Connected” (briefly, then disappears). The yellow LED should no longer be on.
    _________
    If not, pull down the “USB Port” menu and select the correct port. If it isn’t obvious which one to select:
    • Close the IV Swinger 2 application and disconnect the IV Swinger 2 USB cable from the laptop
    • Re-open the IV Swinger 2 application (leave the cable disconnected)
    • Pull down the USB Port menu and take note of the listed ports
    • Connect the USB cable from the IV Swinger 2 hardware to the laptop
    • Pull down the USB Port menu and select the port that is new to the list

Step 28: Apply Resistor Calibration

Apply resistor calibration:

  • In the IV Swinger 2 app, select “Resistors” from the “Calibrate” menu
    ________
  • Enter the values you measured and recorded in “Step 8: 1/4W resistors” above.
    • Values are in ohms
    • IMPORTANT: You must enter a value of 0.0 for R1 (which does not exist on cell versions). Do not change the value for R2.
    • Note that there is no RF1 value to enter. This is by design. Later (not now!), you will enter the value of RF+RF1 for RF if you set the DIP switch to the OFF position (or remove the jumper).________

Step 29: Sanity Tests

NOTE: The video above is also from the original non-PCB Instructable. It shows using a 9V battery, but for the cell version, you need to use a 1.5V battery. The "nothing connected" test is in the video attached to Step 27.

Sanity tests:

  • “Nothing connected” test
    • Click the “Swing!” button. You should hear the relay click twice and see an error dialog saying “ERROR: Voc is zero volts”
      _________
  • Battery test
    Use 1.5V battery
    • Strip both ends of two wires and screw one end of each into the side holes of the binding posts. If you happen to have a battery connector or holder with wires, use that. Use the RED1 and BLK1 binding posts. Leave RED2 and BLK2 unconnected.
      _________
    • Connect the wire from the RED1 binding post to the positive terminal of the battery (you can either tape it or hold it with your thumb/finger)
      _________
    • Connect the wire from the BLK1 binding post to the negative terminal of the same battery
      _________
    • Click the “Swing!” button. You should get an IV curve that looks like the photo.
      _________
    • If you get an error dialog that says: “ERROR: Voc is zero volts” check that you don’t have the battery backwards and that the wires are making good contact with the terminals.
    • If you get an error dialog that says: “ERROR: Timed out polling for stable Isc”
      • Click on Preferences, click on Arduino tab, change value of “Isc stable ADC” to 500, click OK
      • Retry the battery test; it should work
      • Click on Preferences, click on Arduino tab, click on “Restore Defaults”, click OK

Step 30: Prepare for Case and Final Assembly

The acrylic baseball display case used for the IV Swinger 2 enclosure needs to have several holes drilled through it for attachments.

Case side definitions (see photo):

  • Front: side with the USB connector
  • Back: side opposite from front
  • Left: side with binding posts and relay module
  • Right: side opposite from left
  • Bottom: side with Arduino
  • Top: side above PCB

The case comes in two U-shaped halves:

  • Base: Left / Bottom (with fins) / Right
  • Lid: Front / Top / Back

All the attachments are made to the base half. The lid half has nothing attached to it, but does need a 3/8” hole in the front for the USB cable.

Care must be taken when drilling acrylic or else it will crack:

  • Use a drill press if you have one
  • Use vise (with rubber guards) to hold case
  • Position so that the hole being drilled is close to the vise jaw
  • Start with 1/16” pilot for all holes
  • Drill slowly with light pressure
  • Spray water on hole as it is being drilled to cool
  • Use a Forstner bit to drill the 3/8” hole for the USB cable. Otherwise, you’ll have to start with 1/16” pilot and drill incrementally larger holes until you get to 3/8” (actually 25/64”)

Step 31: Mark Holes for Arduino Standoffs

IMPORTANT: For this step and the next three, look straight down with one eye when making the Sharpie dots (the plastic distorts/refracts if you look at an angle, and you’ll miss the mark).

Mark holes for Arduino standoffs:

  • Attach four 15mm standoffs to Arduino:
    • Unplug the USB cable from the Arduino
      _______
    • Carefully remove the PCB from the Arduino
      _______
    • Insert threaded/male end of each standoff through its hole in the Arduino from the back
      ________
    • Screw nuts onto the threaded ends of the standoffs on the front of the Arduino – hold the nut with your finger and turn the standoff to tighten it. Use pliers to tighten more.
      NOTE: The hole nearest the Arduino reset button doesn’t have room for a nut
      ________
  • Place the Arduino in position, standing on its standoffs (including the one without a nut). The Arduino should be touching the right side of the case, with the USB connector facing the front. The single fin should be facing toward you so the fins look like a “Y”. See photo.
    ________
  • PUT LID ON THE CASE. This is important because the fit is very tight!
    ________
  • Turn the case over and look at it from the bottom. The Arduino will probably stay in place, but you can make sure by squeezing the front and back together with the hand you’re holding it with. Use a Sharpie to mark the centers of the four holes.
    ________
  • Remove the lid from the case and remove the Arduino
    ________

Step 32: Mark Holes for Relay Module Standoffs

Mark holes for relay module:

  • Attach 4 standoffs to relay module:
    • Disconnect all wires from relay module
      ________
    • Insert threaded/male end of each standoff through its hole in the relay module from the back
      ________
    • Screw nut on the threaded end on the front of the relay module and tighten it
      ________
  • Use the Sharpie to make a dot on the left side of the case at the following position:
    • 0.5 cm from the left (i.e. back) edge
    • 0.5 cm from the top edge
      ________
  • Hold the relay in position inside the case, with the hole of the upper left standoff aligned with the Sharpie dot. You can hold it with one hand and mark with the other – or use a small clamp to hold it in place.
    _________
  • Use Sharpie to mark the centers of the other three holes
    _________

Step 33: Mark Holes for Binding Posts

Mark holes for binding posts:

  • Remove top nuts, washers, cable rings, and bottom nuts from the binding posts. Remove the black plastic backing plate.
    ________
  • Hold the plastic backing plate in position on the inside of the left side of the case. It should be about 1mm from the front inner edge of the case and about 1mm from the bottom.
    ________
  • Use Sharpie to mark the centers of the two holes
    ________
  • Repeat the above for the upper pair of binding posts, which goes immediately above the first pair, with the top of the backing plate 1mm from the top
    _______

Step 34: Drill Marked Holes

NOTE: The video above is also from the original Instructable which has a slightly different hole pattern. But it is very similar. Note that I've had complete success without using water.

Drill 12 marked holes:

  • Use something pointy to make an indentation in the middle of each of the Sharpie marks. The tip of the Forstner bit is perfect for this, but you can also use a needle or the tip of an X-acto blade (poke and twirl). This will keep the drill bit centered when you start drilling the hole.
    ________
  • Drill 1/16” pilot holes
    ________
  • Switch to 9/64” bit and re-drill all holes
    ________

Enlarge holes for binding posts:

  • Switch to 11/64” bit and re-drill the binding post holes
    ________
  • Switch to 13/64” bit and re-drill the binding post holes one more time
    ________

Clean up case:

  • Remove burrs around holes with X-acto knife or your fingernails
    ________
  • Wash case off and dry
    ________

Step 35: Install Binding Posts

Install binding posts:

  • Insert the binding posts through their holes with the RED terminals toward the TOP of the case
    ________
  • Slide backing plates over the posts on the inside of the case
    ________
  • Thread nuts on the posts and tighten down
    ________

Step 36: Install Arduino and PCB

Install Arduino (without PCB) in case:

  • Attach the one Arduino standoff that won’t have a nut onto the bottom of the case with an M3 screw
    ________
  • Insert the Arduino, put the lid on the case, and screw down the other three standoffs with M3 screws.
    TIP: start all screws before tightening any of them.
    ________
  • Remove the lid
    ________

Mate PCB back onto Arduino:

  • Load circuit wires should still be screwed to PCB. If not, insert them back to into their correct screw terminal block openings and tighten them down.
    ________
  • Line up stacking connector pins on bottom of the PCB with the corresponding connectors on the top of the Arduino and press the boards together, taking care not to bend any of the pins.
    ________

Step 37: Install Relay Module

Reconnect wires to screw-down side of relay module:

This needs to be done BEFORE the relay module is attached to the case, while you still have screwdriver access.

  • Restore connections as before, following the off-PCB connections drawing.
    _________

Install relay module in case:

  • Insert the relay module into the case and screw down its standoffs with four M3 screws.
    TIP: start all screws before tightening any of them.
    ________

Restore relay module control/power side (jumper) connections:

  • Restore connections as before, following the off-PCB connections drawing.
    _________

Step 38: Restore Binding Post Connections

Restore connections to binding posts:

  • Restore connections as before, following the off-PCB connections drawing. Tighten nuts securely.
    _________

Step 39: Drill USB Connector Hole

Drill USB connector hole:

  • Put the lid on the case
    _________
  • Make indentation in the exact center of the USB connector using the tip of the Forstner bit (or whatever pointy thing you used for the other drill-starting indentations). NOTE: it is very important that this hole is precisely centered. You need to look at it from all four directions before making the indentation since the refraction through the plastic distorts the apparent position (you’ll see what I mean as soon as you turn it 90 degrees).
    _________
  • Use 3/8” Forstner bit to drill the hole
    • Drill slowly, spraying with water often
    • Reduce pressure when hole is getting close to “punching through”
    • Alternative to Forstner bit is to use following succession of normal bits: 1/16”, 1/8”, 3/16”, 7/32”, 1/4”, 9/32”, 5/16”, 11/32”, 3/8”, 25/64”
      _________
  • Clean up the edge of the hole with X-acto knife or your fingernail
    __________
  • Wash lid off and dry
    ________
  • Put lid on and insert the USB cable to make sure it fits
    ________
    • If it doesn’t, try loosening the Arduino standoff screws. This might give you enough “play” to get the connector in. Then, with the connector still in, re-tighten the screws
    • If that isn’t enough, you may have to enlarge the hole with a round file or some other way

Step 40: Final Test

Your IV Swinger 2 is now complete!

Repeat the tests you did in “Step 29: Sanity tests” to make sure everything got hooked back up correctly.

You may now test it with a real PV cell. Refer to the IV Swinger 2 User Guide for information on how to build and connect a bias battery, which is necessary for typical high power PV cells.

If accuracy is important to you, see the IV Swinger 2 User Guide for instructions on how to perform a calibration. There is also a Help dialog available from the Calibrate menu in the application

Be the First to Share

    Recommendations

    • Assistive Tech Contest

      Assistive Tech Contest
    • Reuse Contest

      Reuse Contest
    • Made with Math Contest

      Made with Math Contest

    Discussions