PID Schematic

I'm an undergraduate chemistry researcher and I need a way to log and control two different heating elements and two different probes. I thought it could be a good learning experience to try my hand at circuit/instrument design and coding as future projects are going to need experience in this. I've been working on a schematic for the past few months but before I actually order any of the components I'd like some feedback from people who know what they're doing. I'll go over the elements of my design.

I'll be using an Arduino Mega as the main microcontroller. I tried adding as many redundancies as possible for lab saftey too. I know a lot of the logic componenets aren't really needed but I wanted to make the control circuitry as independent of coding as possible. This way if I mess up the coding and something bad happens there could be a built in redundancy for the system to not turn on or shut off.

Each heating element will have three possible voltages; first is just regular 120 V mains. Second is a variable transformer that is rated at 0-140 V at 14 A. This will be fed to a voltmeter so the user can see what voltage they are selecting. The third will be two 240 V power inputs with independent power sockets. Each heater can be turned on/off so that the RTD's can be either used as part of a PID or as a thermometer. Each probe can have data logged and they can also be turned on/off. IC5 (AND gate) is there so that data is logged only if the probe is on and if the "log data" switch is high.

For saftey reasons, there will be a switch (heaters on/off) which will control if all the heaters are on/off. This will go to a NOR gate (IC23); if it is high it will send a high signal, if it is low it will "send" a low signal. When the Arduino is booting, it will also send a high signal to IC 23. This will control an N-MOSFET (Q1) giving power to IC-10. IC-10 is a zero-crossing phototriac which controls +120 Vac mains to RY-1 which itself controls the power to RY-2 and RY-3 which are used to power heating elements 1 and 2. IC4 is a NOT gate connected to IC23 and will display if the heaters are on or off, independent of the Arduino.

I tried my hand at some bootleg sequential booting. So for power rails I have +9 V, +3V3, and +5 V. The arduino will run on +9 V. N-MOSFETs will have arduino inputs to control power on sequences; +9 V will turn on first, the +5 V then +3V3. IC14 (AND gate) and IC13 (NOR gate) monitor the +5 V and +3V3 power rails. At power on the Arduino will initiate a boot sequence. If both rails are off, then IC13 will output a high value and tell the arduino that the system is "OFF". If both rails are high, then IC14 will output a high value and tell the Arduino the system is "ON". IC14 and IC13 are fed into IC15 (NOR gate). If both values are low, then it will output a high value to IC18 (OR gate). IC18 monitors IC15 and Switch 4-2 ("Heaters ON/OFF") and if it is high it will tell the Arduino that the system is in "standby".

I chose 4 wire RTDs (Pt100s) because I wanted to avoid using thermocouples and 4 wires offer the most accuracy. The two RTDs are muxed (IC12) then sent to a MAX31865 for processing. I based the wiring for the MAX31865 off of the Arduino's breakout module for the chip. For balancing, R22, 23, 24, 25, 26, and 27 are placed on wires 2 and 3 of the RTDs. R22-25 are for independently calibrating the RTDs and placed before the RTDs are muxed. R26 and 27 are for fine tuned system calibrations and are placed after the RTDs are muxed.

Most people in my lab don't know anything about electronics so I tried to impliment as many visual components as I could. I'll also have labels on the panel (and a proper machined cut out after it is prototyped) along with those visual cues. This will allow easy visual cues as to what's going on. LED's with different functions will have different shapes as well allowing quick visual identification of its use. The neon lights indicate the status of the fuse it is attached to. I chose bulbs with very low current draws (300 uA iirc).

IC11, 17, 19, 20, 21, 22, and 24 are level shifters for inputs/outputs to/from the arduino.

I've never designed a circuit before and I came into this not knowing anything about circuits. So I'd really appreciate any feedback anyone has! I'm fully aware this whole thing could be completley wrong hahaha.

Thanks for reading this far!

  • \$\begingroup\$ Have you tried simulating the various parts? \$\endgroup\$
    – Andy aka
    Commented Dec 11, 2022 at 0:13
  • 2
    \$\begingroup\$ All your VSS pins should connect directly to ground, not to a capacitor to ground. \$\endgroup\$
    – td127
    Commented Dec 11, 2022 at 1:02
  • \$\begingroup\$ Please clarify your specific problem or provide additional details to highlight exactly what you need. As it's currently written, it's hard to tell exactly what you're asking. \$\endgroup\$
    – Community Bot
    Commented Dec 11, 2022 at 2:29
  • 2
    \$\begingroup\$ The one sheet does all approach to design does not always work when you are dealing with mains and micros. Easy to miss a critical detail. \$\endgroup\$ Commented Dec 11, 2022 at 3:04
  • \$\begingroup\$ @td127 That MAY be his way if showing that Vss pins connect to a ground plane or trace BUT each pin with a cap shown has a local decoupling cap to ground. \$\endgroup\$
    – Russell McMahon
    Commented Dec 11, 2022 at 5:31

1 Answer 1


There are many issues in this circuit.

  1. As others mentioned, the VSS pins of the logic gates, RTC, LCD and the SD card must be connected to GND directly, not via capacitors.
  2. After rectification of 24 VAC you can expect 32-33 VDC at the inputs of all linear regulators. The power loss is needlessly high there, 9-12 VAC are sufficient.
  3. Q1-Q3 use a P-FET symbol while IRFD014 is an (obsolete) N-FET which needs around 5.5 V Vgs to turn on. This will work for Q1 but not for Q2 and Q3. I assume D_48 and D_49 are MCU outputs, but you need around 11 V to turn on the 5 V line via Q2. A combination of NFET and PFET would work.
  4. IC13 and IC14 have a 9V supply and therefore need >= 6 V at their inputs to "see" a logical high. So they at least will not recognize the "on" state of the 3.3 V supply line, the 5 V line may or may not be recognized.
  5. IC17 (pin 15) is not able to provide the current needed for the LCD backlight. Since the gate is static high you should connect the backlight to 3.3 V directly anyway.
  6. C81 prohibits the intended function of R34, same problem with C59, C60, C66, C72
  7. There are three outputs driving signal D_50.
  8. As I understand the datasheet of the serial RAM MR10Q010 (IC8), it can only work with 1.8V bus signals and not the way it is connected here. The circuit connected to VDDQ is not the intended way to provide the I/O bus voltage and not a workaround to use 3.3 V bus signals.
  9. Many logic gates receive their input signals from relay contacts. These inputs have a floating, undefined signal level if the relay contact is open. An LED with resistor in series does not provide a proper "low" level.
  10. R12 (32 kΩ) will provide only a very weak LED light.
  11. Same GND symbol used for HV and LV circuit, I hope they are not connected.
  12. Feeding IC4 (5 V supply) input with 9 V output from IC23 may destroy IC4.
  13. The PT100 interface looks strange to me, but I didn't go into details.
  14. Undefined signal level at A_15 if switch D-E in encoder is open.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.