Why are there two voltage input ports in l298 motor driver.?

Like i dont understand tat why are their two ports of one 12v and 5v? Pleade explain me the uses of them.
Also i heard that if we supply around 7 - 12 volts to 12 volt port then we can run even arduino with it.
So i thought that i can use my powerbank which supplies 5v and use step up dc converter to convert the 5v of the powerbank to around 8 volts
So that i can run motors and arduino from one supply itself.

Is it possible? If so is it a good idea.
By the way, i will be using a hc 05, sd card module, 6 ohm- 9 watt speaker, two bo motor, one servo motor totally.
If you can suggest a good power sirce it would be great!

One is the input for the power that will drive the motor and the other (the 5v connection) is to power the integrated circuit within the L298.


Ok i understood the first part of the question.
But what about the second part?

To start off with I suggest you use two separate power supplies with a common GND. That way you are much less likely to run into problems. When it works with separate power supplies you can (if necessary) investigate using a single power supply knowing that your program and the first set of wiring connections works.


Using step up converter with powerbank wont damage the power bank right?

Ok i understood the first part of the question.
But what about the second part?

Many motor driver boards include a 5v regulator which can be used to derive a 5V
rail from the motor rail. If this regulator output is brought out to a connector you
can use it to power the Arduino. Details differ, you have to check.

You should post details of the 298 hardware you have: it's not clear (to me) if you have a loose 298 chip or a module with a 298 and other stuff on it, and if so, which one (there are loads of different makes).

I have l298 module.
I have attached the picture of it.

There's a surface mount device that's probably a 5V regulator in the middle of that board.

Can't see the markings for the 3-row terminal block at the front, but thats probably ground and the
two supplies, and the jumper behind it to select between external and on-board regulator for the
logic supply to the L298.

A bit more detective work is needed to confirm this.