A method to produce 5-hydroxymethylfurfural is described in which a reactant including cellulose, lignocellulose, or a combination thereof, in a reaction mixture of a polar, aprotic solvent and an acid is reacted for a time, at a temperature, and at a hydrogen ion concentration wherein at least a portion of the cellulose or lignocellulose present in the reactant is converted to HMF. The lens carrier includes at least one lens for focusing a radiation beam forming said light curtain and a lens mask having at least one opening for shaping the radiation beam to have a predetermined aperture. A nickel coating is formed on the contact pads and the connector pads, and a gold layer is formed on the nickel coating on the contact pads and the connector pads. The first light focusing device is in a first optical path between the light source and the first detector.