A Gray-code-based fiber optic liquid level transducer