Design and Characterization of a Miniaturized Spectrometer for Wearable Applications