Start with something small like Arduino and then move to STM32/ESP32. I suggest buying an MCU dev board and following some YT videos. Get the basic peripheral working and interfacing sensors & actuators. Also, check the event section in the server to learn more about embedded s/w development. The episodes of engineering hours will surely help you.
Best wishes!