Thank you Runaway Pancake,
Would putting such low resistor help in protecting my arduino pin (pin 9)?
If something shorts out then I think it can just destroy my PWM pin 9.
How did you calculate it though?
I tried to do this without a arduino board connected, I took the same 9v supply and connected it to the base with value of 100 Ohms, Motor did turn, however, the transistor was very hot, and by hot I mean really very very hot.
I think that I might have passed excessive current through the transistor.
Just would like to know how experienced guys come up with values and component selections and what care should be taken to protect the components that are involved in the circuit.
I would never like to do is burn up pins from arduino board.
Thanks.