We can utilize the built-in 78M05 5V Voltage regulator to power the logic circuit when only a 12V supply is given for driving the logic and driver circuit. I hope now, you have some idea about L298N.