Electronics: schematic and PCB
Flux is an AI hardware engineer. It designs the greenhouse monitor schematic and PCB alongside the enclosure, firmware, and manufacturing plan.
Use the schematic to define the probe, controller, power, charging, and status circuits. Use the Layout view to place and route the board inside the enclosure outline.
Overview
Ask Flux to plan the greenhouse monitor schematic and board work from the Project Specification.
This tutorial covers:
Schematic Editor
Flux's role in schematic design
Part Library
Inspector Panel
Build a reusable module
Adding parts
Wiring
Flux review
Design review
Schematic Editor
Ask Flux to complete this step before you use the editor controls.
The schematic editor is where you build and simulate circuit schematics. Unique to Flux, everything you do here is synced in real-time to the cloud, which brings a number of benefits.

Design with Flux
Ask Flux to complete this step before you use the editor controls.

Flux is an AI hardware engineer. The schematic and PCB editors are one part of Flux. Flux understands your schematics, components, electrical connections, and bill of materials.
Flux uses your project's components, connections, and part datasheets to help with part selection, alternate evaluation, design feedback, cost analysis, and design optimization. Read the Flux hardware engineer guide for an overview of Flux.
Part Library
Ask Flux to complete this step before you use the editor controls.
The project setup guide explains how to reuse projects. The Part Library contains parts and sub-layouts created by you and other designers.

Click and drag a part from the library into your schematic. Use the search box to find a part or sub-layout.
Inspector Panel
Ask Flux to complete this step before you use the editor controls.
Use the inspector to view more information and change configurations for components, objects, and the project. It's located inside the Inspect tab in the right drawer, a unit on the right side of the editor.
It's contextual to your selection. When an object is selected, you'll see info about that object. If no object is selected (like if you click on an empty section of the canvas), the inspector will show information about the project. It's also contextual to the mode you're in. When you're on the Schematic, you see different information than when you're on the PCB. And when you resize its width, it can show even more information.

Project Goals
Ask Flux to complete this step before you use the editor controls.
The greenhouse monitor measures soil moisture, reports readings, and runs from a battery or USB-C supply. Use a reusable power module when it helps organize the power circuit. Start by creating the buck converter as a module. A buck converter reduces an input voltage. The module represents the converter as one symbol in the main schematic.
Build the First Module
Ask Flux to complete this step before you use the editor controls.
Create a digitally adjustable buck converter with a 0–1.9 V output as a reusable module.
Build the module from parts, then convert it for reuse.
How to Create a Module
Create a new project, and as long as it has a layout, it can be published as a module.
Modules only interact with the outside world through terminals
In creating a module, drag in your desired terminals —in other words, your inputs and outputs.
For this module:
Set input to VIn, output as Vout, in addition to SPI bus
The module is a controllable buck converter. Set its description to 5V input to variable output controlled through SPI interface.
Make sure you've also added ground terminal
Then go ahead and publish it! As long as you've given the appropriate permissions, you should be able to access it in your library.

Accessing Preexisting Modules
Ask Flux to find a published module in the library and add it to the project.
You can also add the module in the editor. Add the module to the main project after you create it.
To find them in the library, make sure they're published first (ctrl+p)
To consume modules: you drag and drop them into your canvas
Setting permissions to anyone can view sets it so that anyone can go into the library and find your module
The module framework has basic inputs and outputs. Double-click it to edit it.

Adding a First Part into a Module
Ask Flux to find parts and add them to the module.
You can also add parts in the editor. Search for parts in LCSC, then drag them from the library into the canvas.
Many parts have the following details:
Which user posted the part
How many users it has
Component Stock
Component stock

Add manufacturer part numbers (MPNs) to parts for the bill of materials. For generic capacitors, choose a value, package, dielectric, and voltage rating.
Part Properties
Ask Flux to set the part properties that constrain the design.
To do it in the editor, add these two parts first:
A decoupling capacitor
A TPS563201DDCR IC
Use properties to constrain your design. For generic components such as capacitors, set the package property to match your performance requirements.
For this project, choosing an 0805 package for the 22uF output capacitor ensures a high-quality dielectric (X5R/X7R) and a 25V rating. This prevents common voltage derating issues, where a capacitor's effective capacitance drops significantly when operated near its rated voltage

Aligning and Orienting Parts
Ask Flux to arrange and align the parts in the schematic.
In the editor, you can drag parts around and utilize alignment markers between terminals.

To align multiple parts, select them, right-click, and choose an option from the Align menu.

Select the parts, then ask Flux to space them evenly. You can also use the Align menu to organize their positions.
Placing Remaining Parts in the Module
Ask Flux to add the remaining parts with their values.
You can also place the remaining parts in the module in the editor.
Connected to TPS563201DDCR
Resistors | Capacitors | Inductors |
|---|---|---|
R1: 6.8 kΩ R2: 10 kΩ R3: 10 kΩ | C1: 10 uF C2: 10 uF C3: 0.1 uF C4: 0.1 uF C5: 22 uF C6: 22 uF | L1: 2.2 uH |

Connected to MCP41010T-I/SN
Capacitors |
|---|
C7: 0.1 uF |
C8: 1uF |

Add the required input and output terminals, then add two capacitors, a resistor, an inductor, and the ground net.
Wiring
Ask Flux to wire the parts in the module.
You can also wire in the editor. To wire, hover over a routing touch point, click it, and start routing.
Press F to change the elbow direction
Click on the screen to lock what you can see
Click on another routing touch point to finish your connection
The wired module schematic looks like this:

Updating and Publishing Modules
Ask Flux to complete this step before you use the editor controls.
To publish a module to the library:
Open Flux menu → Publish changes....
OR
Ctrl + P
Add notes to record design decisions. After you finish the module, return to the top-level project.
The Value of Modules
Ask Flux to complete this step before you use the editor controls.
Reuse a module to add an existing design to a project.
Modules differ from parts in that they comprise multiple elements.
Modules can be shared and reused by others, fostering a community-driven approach to design.
The concept of modules extends to nesting, allowing for the integration of multiple sub-layouts within a project.
Publish a module to share it with other designers.
Working in the Top-Level Project
Ask Flux to complete this step before you use the editor controls.
After returning to the parent project, click on the pop-up menu to update your component across projects, found in the bottom left of the screen.

Select Receive latest drafts to receive updates to the module.
Adding Components to a Top-Level Design
Ask Flux to complete this step before you use the editor controls.
Add the remaining components to the top-level design.

Flux Design Review
Ask Flux to complete this step before you use the editor controls.
You can ask Flux for a design review:
Ask Flux to review the circuit against the device requirements.

Flux identified an unconnected enable pin and recommended a 10 kΩ pull-up resistor.
Use the power-input example to check the monitor supply and controller connections.
Schematic Design Summary: an In-Depth Dive
Ask Flux to complete this step before you use the editor controls.
The design has three sections.
Power Input
Ask Flux to complete this step before you use the editor controls.
USB-C and battery input.
The USB-C input provides regulated 5 V at 500 mA when connected to a computer. Use a 1 A power adapter and record this requirement in the project description.
Two 5.1 kΩ resistors support power negotiation with a USB-PD adapter.
A load switch prevents the battery and USB power from driving the circuit at the same time.

The programming module is a USB device with serial and UART output and flow control. The flow control and GPIO0 support programming the ESP32.

Resolve schematic issues
Ask Flux to complete this step before you use the editor controls.
Component Placement
Ask Flux to complete this step before you use the editor controls.
Alignment issues: If components aren't aligning properly, try using the alignment tools (right-click > Align) or keyboard shortcuts
Component orientation: Use the bracket keys [ ] to rotate components if they're not oriented correctly
Missing terminals: If you need additional inputs/outputs for your module, add them before wiring to avoid having to rewire connections
Wiring Problems
Ask Flux to complete this step before you use the editor controls.
Connection not forming: Ensure you're clicking directly on the routing touch points (small dots on pins)
Elbow direction: If the wire isn't bending as expected, press F to change the elbow direction
Net connections: Check that net labels and power symbols use the intended net names
Module Management
Ask Flux to complete this step before you use the editor controls.
Module not appearing in library: Check that you've published the module (Ctrl+P) and set appropriate permissions
Changes not propagating: If updates to a module aren't appearing in the parent project, check for the update notification in the bottom left or manually update
Module editing: If you can't edit a module, ensure you're double-clicking to enter edit mode
PCB layout and routing
Ask Flux to place and route the greenhouse monitor PCB inside the enclosure outline.
This tutorial covers:
PCB layout planning
Part Placement
Routing and associated routing tips
Final touch ups: board size, removing silk, mounting holes
Final Design Rules Check (DRC)
Place the probe, controller, power, charging, and status parts for the greenhouse monitor
Fit the board outline, mounting holes, probe cable, and connectors to the enclosure
Part Placement Intro
Ask Flux to complete this step before you use the editor controls.
The first step of the PCB layout is part placement. Start with the PCB for the buck converter module.
Go to the Layout tab of the Buck converter module
Here, parts can be dragged, rotated, and flipped on the Layout canvas or selected directly on the Objects tree
Select all components and press F to place them all in the bottom layer
Set a top-down board view before you place parts.
To move a component, left-click on it and drag it to the desired position. For rotating a part, there are two options:
Right-click on the part you want to rotate and select "Rotate right" or "Rotate Left"
To rotate parts quickly, use the open or close square brackets
[ ]

Your layout will then look something like this:

Aligning Parts
Ask Flux to complete this step before you use the editor controls.
If there's a series of components you'd like aligned in a specific way, see below.
Select the components > right click > Align > Align Top.
You can also space them evenly in the right-click menu.
Shift + drag to move objects on a straight axis.
To center the letters about the X-axis, you can add an object-specific rule.
Click edit on the Layout rule on the right in the inspector panel.
Add rule for Position Y and set it to 0 on the first letter 'O'.
Then, copy the layout rule and paste it on other letters
Terminals Pads in the PCB
Ask Flux to complete this step before you use the editor controls.
When you add a terminal it creates a test point object on the PCB to probe it later.

If you want to remove it you can add a property "Exclude from PCB" and set this value to true. This is found in the inspector panel on the right under properties, with the terminal selected.

You're also able to change the size of the test point to make it look smaller as desired by selecting it in the pcb editor and changing the diameter.
Part Placement Process
Ask Flux to complete this step before you use the editor controls.
Return to the Layout view. Airwires show the connections between parts. Arrange parts in a layout that follows the schematic where possible.
Switch between Schematic and PCB to know what part to place where.
C1, C2, and C3 should be placed near the Vdd pins.
Press bracket key [ or ] to rotate any parts
Place decoupling capacitors near the power supply pins to reduce parasitic inductance. Place lower-value capacitors closer to the Vdd pins.
To check the value of the pins, click on them and look at the inspector panel on the right
For spacing, keeping things dense is generally preferred
If you're unsure about collisions you can always go into the 3D Editor to see
After placement, the board looks like this. The buck converter module has two capacitors next to the Vdd pin.

Routing Intro
Ask Flux to complete this step before you use the editor controls.
After placing the parts, route the connections. Click a routing touch point to start a trace.
Press F to change the route/trace angle (elbow) direction and W to change the size of traces.
Connect the components based on the schematic and airwires
As you route, airwires disappear and copper replaces them. Press V to place a via and switch layers.

When you finish, publish the changes with
Ctrl+Pand you should see the change in the parent project
Changing Trace Width
Ask Flux to complete this step before you use the editor controls.
The buck converter module uses one trace width. Read Trace Width to change the width in the main project.
You can set a Preferred Trace Widths rule for your objects or nets by selecting the Nets object in the objects tree and adding the rule
Place the trace down and you will see its associated Net container highlighted in the object tree
You can also use a PCB trace width conversion calculator to find the required trace width

You can also change trace width by hovering on the trace segment and editing the width on the bar that pops up
You can add a parent rule on the RULES left panel; use selectors on the right to select the net (ex: #Net27), and add a trace width rule and an !important rule to override.
Impedance Control Routing
Ask Flux to complete this step before you use the editor controls.
The main board also has traces that require impedance-controlled routing, such as USB connections.
As a general tip for routing, route your high frequency signals first and then move on to power. In general, you want to make sure your most important signals have the cleanest path and the least amount of parasitics.
The highest priority high-speed signals on this board would be the USB data lines.
This USB data line uses an impedance-matched differential pair. Start routing it like any other trace. Two traces appear for pair routing.
Press Ctrl or CMD to toggle pair/single routing.
You can place your trace segment, right click to switch layers, and place another trace segment to finish your connection. Then you can drag the vias that should have appeared apart with Shift + Drag
The calculated values for this impedance controlled pair can be found in the net container. You can find the the actual and computed properties tab on right panel.
In order to set up an impedance control traced you have to configure it in your part.
If you double click the part you can see in its inspector panel that there is a 90 ohm controlled impedance with 15% tolerance.
How to Change Board Size
Ask Flux to complete this step before you use the editor controls.
Return to the main project and set the board size.
In Flux, change the board shape and size or use an SVG or DXF for a custom shape.
Click on the layout node either in the object tree or in the canvas
A bar comes up where you can edit the size and shape. You can also change the shape to be rounded, circular, or keep it as rectangular.
With the 'Layout' object selected, you can also add more rules to further modify the board

Add a stackup rule to the object-specific rules, changing it to a 4 layer board.
Bring your components to the board, press F to flip them to the bottom except the USB connector.
Finally, organize your components on the board. Here is the layout from the top view.
Copper GND Fills
Ask Flux to complete this step before you use the editor controls.
Toggle the visibility on the layer.

If you want to disable copper fills per layer, you can go into your object tree and under nets, you can find the ground fills.
Add an object specific rule: Connected Layers and here you can toggle which layers you want them to be connected to (ex: Top layer)
Use the Connected Layers rule on the GND net for copper fills. Use the Review tab to inspect design checks.
Stitching Vias
Ask Flux to complete this step before you use the editor controls.
To adjust the Stitching vias, go into the Nets section and find the ground layer
Add an object specific rule: Fill Stitching Density/Offset.
Set density to 0 to disable stitching vias
RF Copper Cutout
Ask Flux to complete this step before you use the editor controls.
If you're working with an ESP32 or any other RF product you can't keep copper underneath its antenna. For this reason you must add a copper cutout or keepout: go to components, add a cutout pad with the following object specific rules. Notice that connected layers is set to all and the pad-type is set to standard so it is applied to copper and all layers.
After laying out the top-side of the board and routing all connections together:


Mounting Holes
Ask Flux to complete this step before you use the editor controls.
In the schematic, search the Part Library for M3 Mounting Holes and place them in the greenhouse monitor schematic.

This will then sync with the PCB so you can place them in all four corners. You can then set their individual position.

Removing Silkscreen
Ask Flux to complete this step before you use the editor controls.
Sometimes, component density on the board may be too great that having large silkscreen text may reduce visibility or board aesthetic and comprehension. For this reason, it may be desirable to shrink the size or completely remove silkscreen text. An example would be the R10 designator text

This image shows the board before you remove the silkscreen text.

Switch from the schematic tab to the Layout tab in the top center navigation bar
Click on the RULES tab on left panel, activate "Hide Designator + Font Size" and "Remove All Values"
The next image shows the board after you remove the silkscreen text. To remove the 10kΩ text, create another rule with the selection criteria [name*=VALUE].

Checking For Problems Through the DRC
Ask Flux to complete this step before you use the editor controls.
The layout rules in Flux minimize errors, yet specific issues like overlapping traces, unrouted nets, and absent footprints need extra checks. Flux runs real-time Design Rule Checks (DRCs). View DRC errors and warnings in the Review tab.
Check DRC errors before you order a board. DRC errors can affect manufacturing, reliability, and compliance with industry standards. View them in the Review tab.

Check the airwires and all design-rule findings. Select an airwire to locate its open connection on the board.
DRC Errors Summarized
Ask Flux to complete this step before you use the editor controls.
Critical DRC errors are summarized below. Read the design rule check guide for details.
Overlapping Traces: A DRC violation occurs when two traces from different nets overlap.
Floating Copper: Detects unconnected via, trace, or copper fill island to any net, including isolated copper fill islands, floating vias/traces, and requires connection or appropriate stitching vias/keep out rule adjustments for resolution.
Board Layer with Multiple Copper Fills: Violation occurs when multiple copper fills from different nets are requested on a single layer, contradicting the Connected Layers rule for Net objects.
Troubleshooting Common Issues
Ask Flux to complete this step before you use the editor controls.
Component Placement
Ask Flux to complete this step before you use the editor controls.
Components not appearing in Layout view: Ensure components have valid footprints assigned in the schematic
Alignment difficulties: Use the alignment tools (right-click > Align) or keyboard shortcuts for precise alignment
Component collisions: Check for overlapping components in the 3D view and adjust placement accordingly
Routing Challenges
Ask Flux to complete this step before you use the editor controls.
Unable to change trace width: Verify that no !important rules are overriding your width settings
Differential pair routing issues: Make sure the part has proper impedance control settings in its properties
Via placement problems: Check your stackup configuration and ensure vias are properly sized for your manufacturer
Copper Fill Problems
Ask Flux to complete this step before you use the editor controls.
Ground fill not appearing: Verify the net is properly connected to ground and the fill is enabled
Multiple copper fills error: Ensure you're not trying to place different nets' copper fills on the same layer
Stitching vias not appearing: Check the Fill Stitching Density setting is not set to 0
Design Rule Checks
Ask Flux to complete this step before you use the editor controls.
Persistent DRC errors: Click on each error in the problems panel to locate and address the specific issue
Clearance violations: Adjust component placement or trace routing to meet clearance requirements
Unrouted connections: Check for airwires and complete all necessary connections
For more steps, see Schematic Design, PCB Design, Design Rule Checks, and project table views.
What's next
Ask Flux to review the schematic and layout together before you continue.
Ask Flux to review the completed schematic and board, then continue with Firmware, Simulation and checks, and Manufacturing.