The power of a lens is related to its focal length by the formula:
\[
P = \frac{1}{f}
\]
where \( P \) is the power of the lens and \( f \) is the focal length.
Given that the power of the lens is \( P = -0.5 \, \text{D} \), we can calculate the focal length as follows:
\[
f = \frac{1}{P} = \frac{1}{-0.5} = -2 \, \text{m}
\]
Thus, the focal length of the lens used in the spectacles is \( \boxed{-2 \, \text{m}} \).