1 Project Introduction
The simple star-shaped breathing light is composed of LM358 operational amplifier and peripheral circuits, and 20 LEDs are arranged in a five-pointed star pattern.
2 Circuit Principle
2.1 Chip Introduction
LM358 is composed of two independent operational amplifiers, with high gain, high common mode rejection ratio and strong stability. It is suitable for single power supply with a wide power supply voltage range, and is also suitable for dual power supply working mode. It has a wide range of applications.

Figure 2-1 LM358 pin diagram (SOP-8)
Table 2-1 LM358 pin description
Pin
name
Description
1
OUTPUT1
output terminal 1
2
INPUT1 (-)
reverse input terminal 1
3
INPUT1 (+)
same direction input terminal 1
4
VEE/GND
power supply ground
5
INPUT2 (+)
same direction input terminal 2
6
INPUT2 (-)
reverse input terminal 2
7
OUTPUT2
output terminal 2
8
VCC
input power positive
2.2 Typical application
The LM358 and peripheral circuits form a triangle wave signal generator; the triode forms a common collector circuit, which amplifies the triangle wave signal added to the base, and because the base voltage is a triangle wave clamped on the DC signal, the output voltage of the emitter is an upward-shifted triangle wave signal, which can control the brightness of the LED lamp and form a breathing effect.

Figure 2-2 LM358 classic application circuit diagram
In Figure 2-2: The potentials of pins 3 and 6 of LM358 are fixed. When the potential of pin 2 is lower than that of pin 3, pin 1 outputs a high level, that is, T1 is turned on and the LED is on. The potential of pin 2 is provided by pin 7. When the potential of pin 5 is higher than that of pin 6, pin 7 outputs a high level. The two op amps form an interconnected comparator to intermittently turn on T1 and light up the LED.
3 Schematic Design
3.1 New Project
Open Jiali Chuang EDA Professional Edition, create a project and name it [Analog Circuit] LM358 Star-Shaped Breathing Light, and name the schematic file: SCH_LM358 Star-Shaped Breathing Light. Draw the circuit schematic according to the following circuit.

Figure 3-1 SCH_LM358 Star-Shaped Breathing Light
3.2 Device Selection
In the selection of components for this project, all components can be directly searched in the component library of Jiali Chuang EDA. If you are not familiar with the components, you can also search by copying the product number in the material (each component has a unique product number in Li Chuang Mall).

Figure 3-2 Schematic diagram of component search

Figure 3-3 Schematic diagram of searching by product number
3.3 Bill of Materials
LM358 Star Breathing Light Item Bill of Materials No.
Name
Parameter
Device
Position No.
Quantity
Package
Product No.
1
Resistor
47kΩ
R1,R3,R5
3
R0805
C136580
100kΩ
R4
1
C118844
22Ω
R6
1
C17561
2
Potentiometer
50kΩ
R2
1
RES-ADJ-SMD_VG039NCH
C145161
3
Capacitor
100nF
C1
1
C0805
C38141
47uF
C2
1
C16780
4
LED
white light
LED0~LED19
20
LED0805
C434434
5
Transistor
SS8050
Q1
1
SOT-23
C2150
6
Slide switch
MST22D18G2 125
SW1
1
SMD-6Pin
C2906280
7
USB
TYPE-C
USB1
1
TYPE-C-31-M-29
C2689969
4 Border design

Figure 4-1 Star border design
Change the line 45° to a free angle in the top toolbar, place a line fold line (shortcut key: Alt + L), press the Tab key to lock the entered value and switch the input length and angle. The side length of the five-pointed star is 36mm, and the angle is shown in the figure above. Start drawing from the top.

Figure 4-2-1 Star border drawing 1

Figure 4-2-2 Star border drawing 2

Figure 4-2-3 Star border drawing 3

Figure 4-2-4 Star border drawing 4

Figure 4-2-5 Star border drawing 5

Figure 4-2-6 Star border drawing 6

Figure 4-2-7 Star border drawing 7

Figure 4-2-8 Star border drawing 8

Figure 4-2-9 Star border drawing 9

Figure 4-2-10 Star border drawing 10
After completing the five-pointed star drawing, select the entire five-pointed star, right-click the mouse, add a 2mm round chamfer to reduce the sharpness of the five-pointed star, make it smoother and safer.

Figure 4-3 Enter the value of the chamfer radius

Figure 4-4 Five-pointed star border design Figure
5 PCB design
After completing the schematic design and checking the circuit and network connection correctly through DRC, click "Design" → "Schematic to PCB" in the top menu bar (the shortcut key is Alt+I), save the PCB file to the same project and name it: PCB_LM358 star breathing light.
5.1 PCB layout
When laying out the components, 20 LEDs are arranged and placed in the shape of a five-pointed star, and the remaining components are placed on the back. TYPE-C is placed under the five-pointed star. The layout reference is shown in Figure 5-1.

Figure 5-1 PCB layout reference Figure
5.2 PCB routing
PCB routing, the full name is printed circuit board wiring (PCB LAYOUT). Since the circuit board has two surfaces, the top and bottom surfaces, the PCB routing can be divided into top and bottom routing. The top routing is red by default, and the bottom is blue. You can also set other colors according to your personal preferences. Routing is to connect the wires in the circuit board according to the flying wires to connect the same network. The top LED can be routed according to the five-pointed star shape.
The routing reference is shown in Figure 5-2. For the first design, you can refer to the figure below for routing.

Figure 5-2-1 PCB routing reference diagram - top layer

Figure 5-2-2 PCB routing reference diagram - bottom layer
5.3 Copper coating and silk
screen After the PCB routing is drawn, copper coating is performed, and the GND network can be connected. The silk screen characters follow the principle of from left to right and from top to bottom. Mark the project name and logo, and annotate the direction of the switch opening.

Figure 5-3-1 PCB copper cladding and silk screen reference diagram - top layer

Figure 5-3-2 PCB copper cladding and silk screen reference diagram - bottom layer
6 Circuit debugging
6.1 Device welding
can refer to the welding sequence: first solder the LED on the top surface, then solder the Type-C connector/slide switch; secondly solder the LM358 op amp chip; then solder the resistor/capacitor/adjustable resistor; the circuits are all SMD devices, and the welding can be carried out from low to high.

Figure 6-1-1 PCB empty board - top surface

Figure 6-1-2 PCB empty board - bottom surface
Pay attention to electrical safety during welding. Do not touch the soldering iron tip with your hands to avoid burns. Align the components during welding and check whether the model is correct. During the welding process, pay attention to whether the tin wire is cold soldered or leaked to avoid affecting the circuit performance and causing the circuit to not work properly.

Figure 6-2-1 PCBA physical picture - top surface

Figure 6-2-2 PCBA physical picture - bottom surface

Figure 6-3-1 3D rendering - top surface

Figure 6-3-2 3D rendering - bottom surface
6.2 Hardware debugging
After welding is completed, you need to use a multimeter to check whether the power supply and ground are short-circuited, and whether there is a short circuit or open circuit during the welding process. Only after the inspection is correct can the power-on test be carried out. After
TYPE-C is connected, turn on the toggle switch, the board starts to work, and the LED produces a breathing flashing effect. Adjust the resistance value of the adjustable resistor to change the flashing frequency of the breathing light.

Figure 6-4 Simple star-shaped breathing light working diagram