Shifting voltage level for reading sensor output on microprocessor
A reliable way to convert the 5V sensor output to a 3.3V operational domain is to use an NPN transistor as below. Note that the transistor will cause an inversion of the logic for the sensor such that the LPO (Lo Pulse Occupancy time) will get converted to a HPO (Hi Pulse Occupancy time) at the target device. 







simulate this circuit &ndash; Schematic created using CircuitLab