A 1-DOF Planar Vertical Take-Off and Landing (P-VTOL) platform developed for studying system modeling, state-feedback control, embedded systems, and real-time communication between Arduino and LabVIEW.
The project demonstrates the complete workflow from mechanical design and fabrication to controller implementation and experimental validation on a physical system.
The objective of this project is to stabilize and control the angular position of a rotating beam actuated by two BLDC motors.
The project is divided into the following stages:
- Mechanical Design
- Mathematical Modeling
- Sensor Measurement and State Estimation
- State-Feedback Controller Design
- Arduino Implementation
- LabVIEW Monitoring and Analysis
- Real-Time Communication using NI-VISA
- Experimental Validation
The mechanical structure was designed using SolidWorks and fabricated using 3D printing.
Main components include:
- Main Beam
- Motor Holders
- Bearing Supports
- Sensor Mounts
- Bearing Retainers
- Teflon Base Plate
- 6201 Bearings
- Flexible Shaft Coupling
The system is modeled as a rigid beam rotating about a fixed pivot.
Differential thrust generated by the two BLDC motors produces the control torque acting on the beam.
The resulting equation of motion is:
Jθ̈ + bθ̇ = u
where:
- J : Moment of inertia
- b : Damping coefficient
- θ : Angular position
- u : Control input
The model is converted into state-space form and used for controller design and analysis.
An MPU6050 IMU is mounted near the pivot point to estimate the system states.
Measured quantities:
- Angular Position (θ)
- Angular Velocity (ω)
The accelerometer is used to estimate beam angle, while the gyroscope provides angular velocity measurements.
To improve estimation accuracy, a complementary filter is implemented to combine accelerometer and gyroscope measurements.
A state-feedback controller is used to stabilize the system and track reference angles.
The implemented control law is:
du = -(Kθ(θ - θref) + Kωω)
where:
- Kθ : Position gain
- Kω : Velocity gain
- θref : Desired angle
The controller uses:
- Angle error for position correction
- Angular velocity feedback for damping
Additional implementation features include:
- PWM Saturation
- Slew-Rate Limiting
- Reference Tracking
The complete controller implementation is located inside the Controller directory.
Controller/
├── RootLocusSF.vi
├── UI_VISA.vi
├── SF_Servo.vi
└── SF_Control/
└── SF_Control.ino
This LabVIEW VI was developed for controller design and system analysis.
Functions:
- Enter system parameters
- Construct the state-space model
- Analyze open-loop dynamics
- Calculate state-feedback gains
- Plot root locus
- Compare system response before and after control
This VI was used to determine suitable controller gains before implementing them on the physical system.
This LabVIEW VI was developed for simulating tracking problem of the system (as it is type 1, with integrator).
This Arduino program implements the real-time controller.
Responsibilities:
- Read MPU6050 measurements
- Estimate angle and angular velocity
- Execute the state-feedback control law
- Generate ESC commands
- Apply PWM saturation and slew-rate limiting
- Send measurements and control signals to LabVIEW
- Receive controller gains and reference angle from LabVIEW
The Arduino serves as the embedded controller responsible for executing the control loop in real time.
This LabVIEW VI provides the user interface used during experiments.
Functions:
- Send reference angle (θref)
- Send controller gains (Kθ and Kω)
- Receive system measurements
- Receive motor commands
- Plot real-time data
- Monitor system performance
- Tune controller parameters online
This allows controller gains and setpoints to be modified during operation without reprogramming the Arduino.
Communication between Arduino and LabVIEW is achieved through NI-VISA serial communication.
- Reference Angle (θref)
- Position Gain (Kθ)
- Velocity Gain (Kω)
- Angular Position (θ)
- Angular Velocity (ω)
- Motor Command u1
- Motor Command u2
This bidirectional communication enables real-time monitoring, controller tuning, and experimental validation.
The state-feedback controller successfully stabilizes the beam and tracks reference angles in real time.
During operation:
- LabVIEW sends controller gains and desired setpoints.
- Arduino executes the control algorithm.
- Sensor measurements are acquired and processed.
- Control commands are sent to the motors.
- System states and actuator commands are streamed back to LabVIEW for visualization and analysis.
The complete experimental demonstration is available below.
├── Controller/
│ ├── RootLocusSF.vi
│ ├── UI_VISA.vi
│ └── SF_Control/
│ └── SF_Control.ino
│
├── images/
│
├── Videos/
│
├── CAD/
│
├── STL/
│
├── Docs/
│
└── README.md
Possible extensions of this project include:
- LQR Control
- LQG Control
- Kalman Filtering
- Fuzzy Logic Control
- Model Predictive Control (MPC)
- Vision-Based Feedback
- Adaptive Control
Ali Gamal Ali
Mail: ali.gamal@ejust.edu.eg
LinkedIn: https://www.linkedin.com/in/ali-gamal
GitHub: https://github.com/AliOmran88







