Some resources to help you getting started with STM32 programming.
The 2N2222 is a common NPN bipolar junction transistor used for general purpose low-power amplifying or switching applications. It is designed for low to medium current, low power, medium voltage, and can operate at moderately high speeds. It is made in the TO-18 metal can as shown in the picture. Replacements are commonly available now in the cheaper TO-92 packaging, where it is known as the PN2222 or P2N2222, which has similar specifications except for the lower maximum collector current.
The 2N2222 is considered a very common transistor, and is used as an exemplar of an NPN transistor. It is frequently used as a small-signal transistor, and it remains a small general purpose transistor of enduring popularity.