Input issue (contact) with GPIO binding

Hi guys, i have problem with GPIO binding, i can’t see the pin state through openhab, i download pi4j binding but i don’t know how do i use.

GPIO binding: Contact PIR “PIR” { gpio="pin:24 " }
pi4j binding: ??? i don´t know what is the correct form to declare.

sorry but I’m beginner if the question is silly.

According to the wiki you don’t need a pi4j library. What version of openHAB are you using? Where did you get this pi4j file and what tutorial are you following that has you use it?

Typically what you need to do is install the binding, in this case the GPIO binding (if using OH 1.8 download and extract from the addons jar the file named org.openhab.binding.gpio-1.9.0.jar and put it in your addons folder, if using OH 2 install the GPIO binding through PaperUI, Habmin, Karaf console, or add “gpio” to addons.cfg). Then configure the binding (edit openhab.cfg for OH 1.8 or gpio.cfg for OH 2) per the isntructions on the wiki, and then create your Items with the proper binding config as you appear to be doing.

thanks, my problem is that mi rpi version has problem with inputs of GPIO, i am trying to use other version but i have problem with openhab is not online never. i read that i have to change my java version but when i did, this install new version 111 and not 101 what i need.

Since pi4j is not yet an official binding I think you need to contact the developer on github, if he doesn’t respond here.

NOTE: you need version 111 or greater to use my.openhab.

And if your problem is openHAB is never online then getting this binding to work is the least of your problems.

HI @rlkoshak

where can i get gpio binding 1.9.0…
will you please suggest a link to download below 2 binding

org.openhab.binding.gpio-1.9.0.jar
org.openhab.io.gpio-1.9.0.jar

Thanks,
shrikant

I you are using OH 2.0 look in PaperUI.

If you are using OH 1.8, you can get the latest versions of bindings from cloudbees.

ok @rlkoshak

thanks