Inspiration

I wanted to build a simple smart home simulation project to practice object-oriented programming concepts in C++. Instead of only learning theory in class, I wanted to create a project that simulates real smart devices such as thermostats, security cameras, and smart lights.

What it does

This project is a smart device management system written in C++. Users can add different smart devices, view all devices, read sensor values, and activate or deactivate actuators. The system supports multiple device types and simulates interactions between sensors and actuators in a smart home environment.

How I built it

I built the project using C++ and object-oriented programming principles such as inheritance, polymorphism, abstract classes, dynamic memory allocation, and virtual functions. STL vectors were used to manage device pointers dynamically. The project was developed in Visual Studio.

Challenges I ran into

One challenge was managing dynamic memory correctly when devices inherited from both Sensor and Actuator classes. Another challenge was preventing duplicated device names and handling user input validation inside the menu system.

Accomplishments that I'm proud of

I'm proud that the system supports multiple device types while keeping the code organized and scalable. I also successfully implemented polymorphism and abstract base classes in a larger project instead of only using them in small exercises.

What I learned

I learned how object-oriented design works in larger projects, especially inheritance, virtual functions, const references, and dynamic memory management. I also learned how to organize multi-file C++ projects more effectively.

What's next for Smart Device Management System

In the future, I would like to add file saving, graphical interfaces, automatic device behaviors, and real-time smart home simulations.

Built With

  • c++
  • inheritance
  • object-oriented-programming-(oop)
  • polymorphism
  • stl
  • vector
  • visual-studio
Share this project:

Updates