It's a spectrometer. By measuring how different individual wavelengths of light interact with a chemical, you can make a profile of its atomic makeup. How accurate the device is depends on several factors, including which kind of spectroscopy the device is using, how pure the sample is, and what kind of substance it is. The device is almost certainly better at detecting drugs and explosives, for example, but would likely struggle to identify something more complex like mashed potatoes.
amateurneuron t1_itom4py wrote
Reply to Customs agents have a device where you put a substance on a small metal plate and it tells you exactly what it is (like cocaine etc). How does this work and how accurate is it? by Weird-Vagina-Beard
It's a spectrometer. By measuring how different individual wavelengths of light interact with a chemical, you can make a profile of its atomic makeup. How accurate the device is depends on several factors, including which kind of spectroscopy the device is using, how pure the sample is, and what kind of substance it is. The device is almost certainly better at detecting drugs and explosives, for example, but would likely struggle to identify something more complex like mashed potatoes.