Summary of Arduino-STM32 Bluepill Button using BluePill with Proteus Simulation
This project demonstrates digital input and output control using an STM32 BluePill board. A push button acts as the primary input, directly toggling both an external red LED and the board's built-in LED. Developed in Visual Designer for Arduino STM32 and verified via Proteus simulation, the system includes a 250 ms delay to stabilize operations. It serves as an ideal beginner resource for learning embedded systems logic and DIY electronics.
Parts used in the Arduino-STM32 Bluepill Button Project:
- STM32F103C8T6 BluePill board
- Push button / Arduino button breakout board
- External red LED
- Built-in BluePill LED
- 330 ohm resistor for the external LED
- 1k resistor used with the button section
- Proteus schematic connections
- Visual Designer for Arduino STM32 firmware flow
Introduction
This Arduino-STM32 Bluepill Button project is a simple and practical microcontroller project built around the STM32 BluePill board.
It demonstrates how a push button can control LED outputs in an embedded system.
The project is designed in Visual Designer for Arduino STM32 and tested as a Proteus simulation.
It is useful for beginners who want to understand digital input, digital output, and basic firmware logic.
This is a clean example of DIY electronics, practical electronics, and STM32-based embedded systems development.

How the Project Works
The project uses a push button as the input device and LEDs as output indicators.
From the schematic and flowchart, the button is connected as BTN1, while the output is connected to LED1 and the BluePill’s built-in LED. During the main loop, the controller reads the current state of the button and applies the same state to both LEDs.
When the button state changes, the LED output follows it. A small delay of 250 ms is included in the loop, which makes the operation stable and easy to observe during the Proteus simulation.
Workflow Explanation
The working principle is straightforward:
Push Button Input
↓
STM32 BluePill reads BTN1 state
↓
Button state is sent to LED1
↓
Button state is also sent to Built-in LED
↓
250 ms delay
↓
Loop repeats continuously
Flowchart-Based Workflow
The flowchart shows two main parts:
- Setup
- The setup section starts and ends without any extra configuration block shown.
- Loop
- Read the state of BTN1
- Set LED1 according to the button state
- Set the BluePill built-in LED according to the button state
- Wait for 250 ms
- Repeat the process
Key Features
- Simple STM32 BluePill button control project
- Designed for Arduino-STM32
- Built using Visual Designer for Arduino STM32
- Includes Proteus simulation
- Demonstrates digital input reading using a push button
- Controls an external LED through the button state
- Also controls the BluePill built-in LED
- Uses a 250 ms loop delay for visible simulation behavior
- Good beginner-level embedded systems and DIY electronics example
Components Used
Based on the schematic, the project uses:
- STM32F103C8T6 BluePill board
- Push button / Arduino button breakout board
- External red LED
- Built-in BluePill LED
- 330 ohm resistor for the external LED
- 1k resistor used with the button section
- Proteus schematic connections
- Visual Designer for Arduino STM32 firmware flow
Applications
This type of button-based microcontroller project is useful in many practical electronics systems, such as:
- Basic digital input testing
- LED control circuits
- User interface button testing
- Embedded systems learning projects
- STM32 BluePill practice circuits
- DIY electronics control
- panels
- Simple start/stop control logic
- Input-output demonstration projects in Proteus
Explanation of Code
The project logic is created using Visual Designer for Arduino STM32, so the flow is represented visually instead of a traditional written source code file.
At a high level, the firmware performs these tasks:
Button Input Module
The controller reads the current state of BTN1. This button acts as the main digital input for the project.
LED Output Module
The state read from the button is directly assigned to LED1. This means the external LED behaves according to the button condition.
Built-in LED Control
The same button state is also assigned to the BluePill’s built-in LED using the CPU built-in LED control block.
Timing / Delay
A 250 ms delay is used inside the loop. This delay controls the refresh rate of the button reading and LED update process.
Flowchart
Proteus Simulation
In the Proteus simulation, the STM32 BluePill board is connected with a push button and LED output circuit.
When the simulation runs, the BluePill continuously checks the button state. The same state is applied to the external red LED and the built-in LED. This makes the circuit easy to test visually because pressing or releasing the button changes the LED behavior inside Proteus.
The simulation is mainly useful for understanding the working principle, testing the circuit diagram, and verifying basic firmware behavior before working with real hardware.
Conclusion
The Arduino-STM32 Bluepill Button using BluePill with Proteus Simulation is a clean beginner-level project for learning digital input and output control. It shows how a button can control both an external LED and the built-in LED of the STM32 BluePill board. This project is useful for understanding embedded systems basics, Proteus simulation behavior, and simple STM32 firmware workflow.
Complete File
Arduino-STM32 Bluepill Button using BluePill with Proteus Simulation
- What components are required for this project?
The project requires an STM32F103C8T6 BluePill board, a push button, an external red LED, the built-in BluePill LED, a 330 ohm resistor, a 1k resistor, and Proteus simulation software. - How does the button control the LEDs?
The controller reads the state of BTN1 and applies that same state directly to both the external LED1 and the BluePill built-in LED. - Why is a 250 ms delay included in the loop?
The 250 ms delay makes the operation stable and easy to observe during the Proteus simulation by controlling the refresh rate. - Can this project be tested without real hardware?
Yes, the project was designed in Visual Designer and tested as a Proteus simulation to verify basic firmware behavior before working with real hardware. - What tool is used to create the firmware flow?
The project logic is created using Visual Designer for Arduino STM32, representing the flow visually instead of traditional written source code. - Does the external LED behave differently than the built-in LED?
No, the same button state is assigned to both the external red LED and the built-in LED simultaneously. - What is the main purpose of this project for beginners?
It is useful for understanding digital input reading, digital output control, and basic firmware logic in embedded systems. - Is this project suitable for learning STM32 development?
Yes, it is a clean example of DIY electronics and practical STM32-based embedded systems development.

