Understanding the Project and the Blocks Used
This project includes several interconnected blocks. Below are the main blocks and their functions:
startAllstartAll:
Ensures the system initializes only once after power-up.
Controls the I2C communication with the MPU6050 sensor.
Manages and retrieves data from the inertial sensor.
arctanCORDIC (two instances):
Computes the tilt angles on two axes using the CORDIC algorithm.
lowPassFilter (two instances):
Filters the angle signals to smooth out noise and fluctuations.
closeLoop (two instances):
Feedback controllers that compare measured angles with the level reference and generate correction commands.
servo (two instances):
Drives the servo motors according to the control signals.
inverterC and
Used for logic control of the SDA line during I2C communication.