Misiu
( )
April 5, 2019, 9:35pm
1
Platform information:
Hardware: Raspberry PI 3B
OS: openhabian
openHAB version: 2.4.0-1
I’m trying to use new onewire binding based on OWFS.
Unfortunately, I get errors in log and my OW Server has status: OFFLINE - COMMUNICATION_ERROR
I get this entries all the time:
2019-04-05 23:16:54.872 [hingStatusInfoChangedEvent] - ‘onewire:owserver:27dbecfc’ changed from OFFLINE (COMMUNICATION_ERROR) to ONLINE
2019-04-05 23:16:54.891 [hingStatusInfoChangedEvent] - ‘onewire:owserver:27dbecfc’ changed from ONLINE to OFFLINE (COMMUNICATION_ERROR)
What have I done so far:
using raspi-config I’ve enabled 1-Wire and I2C
using openhabian-config I’ve installed owserver.
This is content of my /etc/owfs.conf:
I have two DS18B20 connected to GND, 3.3V and GPIO4 (I’ve added 4,7k resisor between 3.3V and GPIO4)
And this is how my Thing config looks like:
I’m not sure what lines I should change in owfs.conf.
I’m not using any USB device for 1-Wire devices, but as I understand correctly I can use Raspberry PI .
Do I must change something in Rapberry PI?
J-N-K
(Jan N. Klug)
April 5, 2019, 9:41pm
2
Can you reach the owhttpd?
Misiu
( )
April 5, 2019, 9:53pm
3
Sorry for maybe a dumb question but how to check that?
I’ve just tried sudo service owserver status and got this:
● owserver.service - LSB: 1-wire TCP server
Loaded: loaded (/etc/init.d/owserver; generated; vendor preset: enabled)
Active: active (exited) since Fri 2019-04-05 23:44:33 CEST; 6min ago
Docs: man:systemd-sysv-generator(8)
Process: 1115 ExecStop=/etc/init.d/owserver stop (code=exited, status=0/SUCCESS)
Process: 1123 ExecStart=/etc/init.d/owserver start (code=exited, status=0/SUCCESS)
CGroup: /system.slice/owserver.service
Apr 05 23:44:31 openHABianPi systemd[1]: Starting LSB: 1-wire TCP server…
Apr 05 23:44:31 openHABianPi OWFS[1129]: DEFAULT: ow_daemon.c:(144) Entered background mode, quitting.
Apr 05 23:44:31 openHABianPi OWFS[1129]: DEFAULT: owlib.c:(52) No valid 1-wire buses found
Apr 05 23:44:33 openHABianPi owserver[1123]: Starting 1-Wire TCP Server: owserver failed!
Apr 05 23:44:33 openHABianPi systemd[1]: Started LSB: 1-wire TCP server.
EDIT:
after doing ‘sudo service owhttpd status’ I get this error:
Unit owhttpd.service could not be found.
I don’t understand. Shouldn’t it get installed with sudo openhabian-config?
When I try to reinstall 1wire I get this:
ow-shell is already the newest version (3.1p5-1).
owserver is already the newest version (3.1p5-1).
usbutils is already the newest version (1:007-4).
nothing about owhttpd
I’ve verified that my PI has connected two DS18B20 sensors by going to /sys/bus/w1/devices.
When I list folders I get this:
28-01186dcdaaff 28-01186e0b6aff w1_bus_master1
J-N-K
(Jan N. Klug)
April 6, 2019, 5:48am
5
Not sure. But look at the owserver log: no bus found. You have to configure a bushmaster.
Misiu
( )
April 6, 2019, 6:40am
6
@J-N-K sorry for another silly question, but how to do that?
I don’t want to use USB device ot another server. I have DS18B20 connected directly to Raspberry PI 3B.
J-N-K
(Jan N. Klug)
April 6, 2019, 6:53am
7
You can’t use owfs then. OWFS needs a busmaster. You could try the onewire-gpio binding.
Misiu
( )
April 6, 2019, 7:34am
8
That’s what I thought
Openhabian-config tool is quite confusing. There should be an option to install/configure raspberry to support 1wire via gpio (without installs owfs) and another for owfs.
I’d like to ask also for clarification in docs, because now it is confusing. I thought I should use newest binding, but I lost two evenings because I picked the wrong binding
J-N-K
(Jan N. Klug)
April 6, 2019, 7:49am
9
Both bindings are at the same version. Onewire GPIO binding documentation is quite clear:
This binding reads temperature values from OneWire bus sensors connected to the GPIO bus on Raspberry PI
I’ll add a note to the Onewire binding to make it more clear.
1 Like
Misiu
( )
April 6, 2019, 9:25pm
11
I’ve searched a bit more and found this question on StackOwerflow: 1 wire - Problems with OWFS over the w1 kernel module - Raspberry Pi Stack Exchange
From this I understand that OWFS can handle w1 kernel busmaster (see Release 3.1p1 · owfs/owfs · GitHub )
Anyone else was able to use OWFS with GPIO?
From my understanding by default OWFS expose two fake devices:
server: FAKE = DS18S20,DS2405
in my case, the problem is the communication between owserver and openHAB.
As I wrote I’m using openHAB 2.4.
With fake server I don’t need real devices, so I should be able to check everything.