I'm new to EE. I burned out a Raspberry Pi by running an electric motor directly from its GPIO pins, and then I learned about transistors. I now have another RasPi, but I'm not sure what transistors to buy. I plan on using the RasPi's 3.3v GPIO pins for the base and a 4 AA batteries connected for the collector. What NPN transistor should I buy (or what pack of general-use NPN transistors should I buy that I can adapt to fit) for this project? Are there any methods to determine which transistor values are required? If it's best to just get a pack of general-purpose transistors, what do I need to do to accomodate for the difference in voltage/amperage tolerance? Would any capacitors be required in the circuit to account for the motor's interference? If I wanted to replace the motor with an antenna, would I have to change anything?
Let me know if my phrasing is unclear. Thanks for any replies, I know that this kind of thing must be annoying to you.
Edit: The motor is an example. I just wanted to know what to use for that current.