Example 1 Let $O(0,0), A(1,0), B(0,1)$, and $P$ be a moving point on the line segment $AB$, $\overrightarrow{A P}=\lambda \overrightarrow{A B}$. If
$$
\overrightarrow{O P} \cdot \overrightarrow{A B} \geqslant \overrightarrow{P A} \cdot \overrightarrow{P B} \text {, }
$$

then the range of the real number $\lambda$ is $\qquad$ .
$(2007$, National High School Mathematics League, Henan Province Preliminary (Grade 11))