I've played on the same mouthpiece since I was in high school - my teacher handed me an old Conn Helleberg style mouthpiece when I was 16, and with the exception of a few brief periods of experimentation, I have not strayed far away from that. I'm always amused at my trumpet playing friends who seem to endlessly quibble over leadpipes, heavy valve caps, bell weight, and modified mouthpieces.
Apparently, this has always been the case.
Here is the quick and breezy primer to the most common trumpets.
Setting aside for a moment instruments equipped with a 4th valve and the piccolo trumpets, all trumpets have a written range of F#3 (3 lines below treble clef staff) to X. F#3 is the lowest written pitch attained when all three valves are engaged. In the upper range, I say X because the limits depend a lot on the player and the style of music. There are lead trumpet players that can play notes only a dog can hear with reliability (or so us humans have been led to believe).
Click here to watch and listen to one of my favorite Derek Watkins clips. I love the xylophone player at the end trying to figure out what pitch he just played.
For professional classical players, you'll be golden up to a written C6 (2 lines above the staff); higher pitches are possible but depend a lot on the player.
On three valve instruments, written notes below F#3 are not practical and can only be played as false tones.
The open tube lengths listed below are GROSS approximations only intended to frame the relative size of the instruments - the physics and math involved in stating a precise tube length is WAY above my paygrade. There are plenty of discussions and arguments regarding overtones, wavelengths, and precise tube lengths on the internet.
I also mention the cornet equivalents here - cornets are more conical and have a slightly rounder tone quality and don't project as well as the trumpet equivalent. Cornets and flugelhorns lose some of their characteristic sound in the extreme high written range of the instrument. The sound of a well-played cornet or flugelhorn is lovely and I depend on it (particularly flugel) a lot.
This is NOT a comprehensive list – this discussion only covers the most commonly available instruments. If you write for instruments other than these, make sure you consider an alternative part.
Trumpet in E flat - common and my personal lynchpin. The open tube (leadpipe to bell flare with no valves engaged) is approximately 3.25 feet long with a fundamental sounding pitch of E flat 3. The transposition interval is a minor 3rd (a written C will produce a sounding pitch of E flat a minor third above). There is a cornet equivalent (same length and transposition). If you write for E flat trumpet, an alternate part for C or B flat trumpet is a good idea - you'll get asked for it anyway.
Trumpet in D - most pros have one in the closet. Britten and Bernstein both liked this instrument. The open tube is approximately 3.5 long with a fundamental sounding pitch of D3. The transposition interval is a M2 (a written C will produce a sounding D a major second above). Pairs well with A piccolo. Make and alternate part, please.
Trumpet in C - modern go-to orchestral instrument. The open tube is approximately 4 feet long with a fundamental sounding pitch of C3. Sounds as written. There is a cornet equivalent.
Trumpet in B flat - modern trumpet found in every public-school band room in the United States. The open tube is approximately 4.5 feet long with a fundamental sounding pitch of B flat 2. Transposition interval is M2 (a written C will produce a sounding B flat a M2 below). There is a cornet equivalent and a flugelhorn.
Trumpet in A - modern versions are rare. The open tube is approximately 5 feet long with a fundamental sounding pitch of A2. Transposition interval is a m3 (a written C will produce an A a minor third below). There is a cornet equivalent which I believe is actually more common now. It doesn't make sense to write for A trumpet, or for an A cornet for that matter - just not enough of them around.
Trumpet in F alto - modern versions are rare. The open tube is approximately 6 feet long with a fundamental pitch of F2. Some romantic composers wrote for this instrument, but it should not be confused with the F soprano/piccolo trumpet. Transposition interval is a P5 (a written C will produce a sounding F a perfect fifth below). There are reasons why some instruments go extinct.
Bass Trumpet in B flat - most notably, Wagner (Ring Cycle) and Stravinsky (Rite of Spring) wrote for this instrument. The open tube is approximately 9 feet long (same as a trombone, euphonium, and baritone). Usually 3 valves and played with a tenor trombone mouthpiece (or modification thereof). Transposition interval is a M9 (a written C will produce a sounding B flat one octave and a major second below). I think this instrument is also unsuccessful.
Generally - written range is still F#3 to X. Lower pitches are possible with a fourth valve - but why would you want to? Again, the upper limits depend on the player and the context. Typically, I try to not write higher than a G5 (first space above the treble clef staff). Also, I typically confine the range to C4 to E5, keeping it mostly in the staff. Some trumpet players like to see pitches written in the octave that they sound, but generally the transposition interval is an octave (minus).
Piccolo in C - kind of rare, but modern examples exist and it's becoming more popular. Open tube length is half that of a standard C trumpet or approximately 2 feet with a fundamental pitch of C4. I would write for C piccolo one octave lower than the sounding pitch and indicate in the part "sounds 8va higher" You are much safer writing for B flat or A piccolo, though good trumpet players can transpose.
Piccolo in B flat - very common. The open tube is approximately 2.25 feet long and has a fundamental sounding pitch of B flat 3. Transposition interval is a m7 (a written C will produce a B flat a minor 7 above.
Piccolo in A - also very common. The open tube is approximately 2.5 feet long and has a fundamental sounding pitch of A3. Transposition interval is a m6 (a written C will produce an A a minor 6 above).
Piccolo in G - available; some players really love this instrument as do I, but I rarely write for it due to the fact that relatively few even own one. The open tube is approximately 2.75 feet long with a fundamental sounding pitch of G2. Transposition interval is P5 (a written C will produce a G a perfect fifth higher).
Piccolo in F - same availability concerns; I also really love the sound of an F trumpet. Open tube is approximately 3 feet long with a sounding fundamental pitch of F2. Transposition interval is a P4 (a written C will produce an F a perfect fourth higher). I wish this instrument would catch on, but until then E flat trumpet is the next best thing.
Quick postscript - a friend just corrected my piccolo trumpet transposition and I have corrected what I wrote above. Two big takeaways: 1) I shouldn't try to be such a smarty pants at 4:30 in the morning; and 2) I forgot to mention that when I'm writing for trumpets, horns, and clefs for trombones, I am long past the time where I am actively thinking about interval transpositions. That is to say that transposition is a background sub routine in my head. The only transposition that gives me a migraine is A (clarinet or trumpet) - I just don't use it that often.
I do all my work right into a transposed score. I'll turn off the transposition temporarily only if I'm seeking out a particularly difficult note bug.
Practice makes permanent.