Development of an optical-chemical sensor for the detection of ammonium ions