Short answer, yes you can apply from shore.
Long answer, the seniority cutoff depends on your platform, career choices, and timing. The current rule-of-thumb for application cutoff is when you no longer have time for TPS (1 year) plus a 2 year test tour prior to your NLT DH date.
You can- and should- apply from your first sea tour if you are interested. However, if you don't get in, don't expect to be told why, or even whether you were a qualified candidate. Boards are not known for being forthcoming with information. I recommend using the methods I stated earlier to determine your academic go/no-go status prior to your first application, so that you can prioritize appropriately.
FWIW, many of my classmates applied multiple times to TPS. I applied 3 times, and a classmate of mine applied 5 times. The record so far (anecdotally at least) is seven times. YMMV, but most candidates seem to have sufficient opportunity to apply multiple times.