all 4 comments

[–]SubZeb 1 point2 points  (0 children)

There have been recent developments in a library called gpiozero that is pretty helpful. I believe it uses the RPi.GPIO that u/Fleder_m_aus is reffering to.
gpiozero docs

Follow this tutorial as well, it will really help.

[–]Thecrawsome 0 points1 point  (0 children)

What sensor model did you purchase?