lonedemon / Mysterious Azure Time Machine

Loaded

0

0

Files

Schematic

PCB

Log InSign Up

Casual Greeting with AI

flux

1:49

Below is a complete schematic update suggestion covering all 4 isolated 24 V-to-3.3 V input channels and 4 isolated outputs with a transistor driver stage. You can apply these changes in two phases: first updating the schematic (with component additions and wiring) and then using these guidelines for your PCB layout.

A. Schematic Update Suggestion 1. Isolated 24 V Input Channels (×4)
For each channel, add the following:
  1. 24 V Signal Conditioning:
    • Series Resistor:
      • Place a resistor (use a standard value near 2.2kΩ calculated as:
        R=24V−VLED(≈1.2V)10mA≈2.28kΩR = \frac{24V - V_{LED} (≈1.2V)}{10mA} \approx 2.28kΩR=10mA24V−VLED​(≈1.2V)​≈2.28kΩ
        Use 2.2kΩ or 2.4kΩ as available.)
    • RC Low-Pass Filter:
      • Optionally, add a small capacitor (0.1 µF) in parallel after the resistor to ground to filter high-frequency noise.
    • TVS Diode Protection (Optional):
      • Place a TVS diode across the 24 V input and the high-voltage ground to clamp transients.
  2. Optocoupler (e.g., PC817) – Input Side:
    • LED Connection:
      • Connect the anode of the optocoupler’s LED to the output of the series resistor (after any filtering/protection) and the cathode to the 24 V ground.
    • Transistor Side (Output):
      • Connect the collector of the optocoupler’s transistor through a pull-up resistor (e.g., 10kΩ) to the 3.3 V supply of the Raspberry Pi.
      • Tie the emitter to the Raspberry Pi’s ground.
    • This arrangement converts the 24 V signal (with isolation) into a 3.3 V logic level input.
Repeat the above for Channels 1 to 4.

2. Isolated Output Channels with Transistor Stage (×4)
For each channel, add the following:
  1. Raspberry Pi Drive:
    • Optocoupler (e.g., PC817) – LED Side:
      • Connect the Raspberry Pi 3.3 V GPIO to the anode of the optocoupler LED through a 220Ω resistor.
      • Connect the cathode of the LED to the Raspberry Pi ground.
  2. Isolated Signal Transfer:
    • Optocoupler Transistor Side:
      • Use the transistor output from the optocoupler. Through a base resistor (choose a value between 1kΩ–4.7kΩ, say 1kΩ to start), drive the base of a switching transistor.
  3. Transistor Driver Stage:
    • Switching Transistor:
      • Use a transistor such as the TIP120 (Darlington) to switch the 24 V load.
      • Connect the emitter of the TIP120 to the 24 V ground.
      • Connect the collector to one end of the load. The other end of the load goes to the +24 V supply.
  4. Additional Protection & Filtering (Optional on the output side):
    • If the 24 V load is inductive or located in a noisy environment:
      • Add a TVS diode (or snubber network) across the load.
      • Consider a small RC filter on the input of the optocoupler’s LED side if needed.
Repeat the above for Channels 1 to 4.

3. Summary of Key Components (per channel)


FunctionComponentSuggested Value / NoteLink
High-Voltage Series ResistorResistor for LED current limiting2.2kΩ (or 2.4kΩ)(Standard resistor from your library, e.g. R?)
RC Filter CapacitorFilter capacitor on the 24 V input0.1 µF(Choose a generic capacitor, e.g. C?)
TVS Diode (Optional)Transient voltage suppression diodeValue based on expected voltage transientsTVS Diode
Optocoupler (Input Side)Isolates the 24 V from the Pi and converts the signalPC817PC817
Pull-Up ResistorOn the transistor side of the input optocoupler10kΩ to 3.3 V rail(Generic resistor, e.g. R?)
Optocoupler (Output – LED Side)Provides isolation on the output channelPC817PC817
LED Side Series ResistorCurrent limiting resistor for the optocoupler LED on the output side (Pi side)220Ω(Standard resistor, e.g. R?)
Base Resistor for DriverLimits current to the base of the transistor~1kΩ (tune as necessary)(Standard resistor, e.g. R?)
Transistor DriverSwitches the 24 V loadTIP120TIP120
Note: Replace placeholder resistor/component designators with those in your project (e.g., [R2], [C2], etc.) as you add the four channels.

B. PCB Layout Guidelines
  1. Domain Separation:
    • High-Voltage Section (24 V):
      • Group all components handling 24 V signals (input-side resistors, TVS diodes, TIP120 drivers, load connectors) in one area.
    • Low-Voltage Section (3.3 V / Raspberry Pi side):
      • Place the optocoupler transistor outputs with their pull-up resistors and the optocoupler LED circuits for the outputs near the Raspberry Pi interface.
    • Isolation Clearance:
      • Maintain ample clearance and, if possible, add a controlled isolation gap between the two domains (refer to your fabrication guidelines for working with 24 V isolation).
  2. Decoupling & Grounding:
    • Place 0.1 µF decoupling capacitors near the power inputs of sensitive elements (e.g., near pull-up resistors on the Pi side).
    • Use separate ground planes/nets for the 24 V and 3.3 V sides, with a defined isolation boundary at the optocoupler interfaces.
  3. Routing Considerations:
    • Keep traces carrying the 24 V signals short and wide enough to handle the expected current.
    • Route low-voltage (3.3 V) traces on a separate layer where possible.
    • For additional EMI reduction, consider using ground pours and proper trace spacing.
  4. Connector/Interface Placement:
    • Define clear connector footprints for both the 24 V signals (inputs and outputs) and the Raspberry Pi connection.
    • Mark test points for critical nodes to help debug isolated channels.

Next Steps
You can use the "Apply changes" option to update the schematic with these design suggestions. Once the schematic is updated, you can use the PCB layout guidelines to route and organize the board accordingly.
Let me know if you need further details on any part of the schematic or additional guidance on the PCB layout!
407 days
lonedemon

lonedemon

Can you also add mosfet on the 24v inputs
407 days

flux

0:25

Before proceeding, can you clarify the intended role of the MOSFET on the 24 V inputs? For example:
  1. Do you want the MOSFET to act as a protection element (e.g., reverse polarity protection or voltage clamping)?
  2. Or should it serve as a high-side switch to enable/disable the 24 V signal for each channel?
Please let me know which functionality you prefer.
Use MOSFET for switching
407 days

​
Sign up to send

To get started, talk to Flux or create a New Document.

Reviews

Documents

    Documents are markdown text files which describe project goals, capture details, or even simulation outputs.

    Assets

    No assets added.

    Mysterious Azure Time Machine

    Mysterious Azure Time Machine thumbnail
    Welcome to your new project. Imagine what you can build here.

    Properties

    Properties describe core aspects of the project.

    Pricing & Availability

    Distributor

    Qty 1

    Arrow

    $0.82–$1.54

    Digi-Key

    $3.79–$4.26

    LCSC

    $1.66–$2.36

    Mouser

    $2.53–$2.58

    Verical

    $0.97–$1.43

    Controls

    Welcome 👋

    Flux helps you build PCBs faster with an AI teammate!

    Create your account to collaborate, stay updated, fork your own version, and get instant answers from our AI agent.

        Introducing AI Placement!
        AI Placement Demo

        AI-Powered Component Placement

        Let AI place your components intelligently. AI Placement analyzes your schematic and positions components for optimal routing, signal integrity, and board density.

        From Schematic to Layout in Seconds

        Skip the tedious manual placement. AI Placement generates a starting layout you can refine, saving hours of repetitive work on every new design.

        Works With Auto-Layout

        Pair AI Placement with Auto-Layout for a complete AI-driven PCB design flow — from component placement through trace routing, all with one click.

        Try it