Cannot get 1 wire pi plus to work on Raspberry pi 4
The 1 Wire Pi Plus and 1 Wire Pi Zero are a 1 Wire interface for the Raspberry Pi
29/01/2021
Posted by:
marksidell
root@mqtt:/home/pi# systemctl status owserver
â— owserver.service - Backend server for 1-wire control
Loaded: loaded (/lib/systemd/system/owserver.service; disabled; vendor preset: enabled)
Active: failed (Result: exit-code) since Fri 2021-01-29 10:40:45 EST; 6s ago
Docs: man:owserver(1)
Process: 2083 ExecStart=/usr/bin/owserver -c /etc/owfs.conf (code=exited, status=1/FAILURE)
Main PID: 2083 (code=exited, status=1/FAILURE)
Jan 29 10:40:45 mqtt.sidell.org systemd[1]: owserver.service: Service RestartSec=100ms expired, scheduling restart.
Jan 29 10:40:45 mqtt.sidell.org systemd[1]: owserver.service: Scheduled restart job, restart counter is at 5.
Jan 29 10:40:45 mqtt.sidell.org systemd[1]: Stopped Backend server for 1-wire control.
Jan 29 10:40:45 mqtt.sidell.org systemd[1]: owserver.service: Start request repeated too quickly.
Jan 29 10:40:45 mqtt.sidell.org systemd[1]: owserver.service: Failed with result 'exit-code'.
Jan 29 10:40:45 mqtt.sidell.org systemd[1]: Failed to start Backend server for 1-wire control.
I also tried the setup using the ds2482 kernel module described in another discussion. Nada.
Any suggestions?
29/01/2021
Posted by:
andrew
Have you gone through all of the steps in our OWFS tutorial? owfs with i2c support on raspberry pi.
29/01/2021
Posted by:
marksidell
30/01/2021
Posted by:
andrew
Do you have a spare SD card you could use to set up a clean install of the current version of Raspberry Pi OS? If OWFS works on your clean install then that would narrow the problem down to your current Linux install, if OWFS still fails then that would mean there is a problem with the 1 Wire Pi Plus.
02/05/2021
Posted by:
marksidell
There does seem to be one omission in the instructions. They say to enable the owserver service, but they don't say to start it. So after enabling the service, I rebooted. Presumably that would start the service. Also, since the instructions say to enable /mnt/1wire in the OWFS section of /etc/owfs.conf, it appears to be unnecessary to run the owfs command manually, as shown at the end of the instructions.
Anyhoo, it still doesn't work. I see none of my devices listed when I run the example Python program. Also, if I do "i2cdetect -y 1" I don't see the 1wire device at address 18, as I would expect.
So, wow, a lot of work for nothing.
Another bit of info. After I ran the Python program, I used journalctl -u owserver and saw the following. It would appear that the error message was logged at the moment the Python program tried to enumerate the 1wire devices.
root@raspberrypi:/home/pi# journalctl -u owserver -n 10
-- Logs begin at Sun 2021-05-02 09:35:22 EDT, end at Sun 2021-05-02 09:36:20 EDT. --
May 02 09:35:26 raspberrypi systemd[1]: Starting Backend server for 1-wire control...
May 02 09:35:26 raspberrypi owserver[386]: DEFAULT: ow_opt.c:(670) systemd mode -- ignore 'p' option
May 02 09:35:27 raspberrypi systemd[1]: Started Backend server for 1-wire control.
May 02 09:36:18 raspberrypi owserver[386]: DEFAULT: ow_reconnect.c:(69) Failed to reconnect DS2482-100 bus master!
02/05/2021
Posted by:
andrew
First, you will need to uninstall owfs.
sudo apt-get remove owfs python-ow ow-shell
Reboot your Pi and check that the 1 Wire Pi is available on 0x18 on the I2C port using
sudo i2cdetect -y 1
To enable the w1 subsystem run the three commands below
sudo modprobe ds2482
sudo sh -c "echo ds2482 0x18 > /sys/bus/i2c/devices/i2c-1/new_device"
sudo modprobe wire
If it works your 1-wire devices should be available in the /sys/bus/w1/devices/ directory.
You can enable the w1 subsystem at boot time by adding the three above commands without sudo to the /etc/rc.local file above the "exit 0" line.
If the 1-Wire Pi still does not work can you try checking the 5V and GND pins next to the RJ12 connector with a multimeter to make sure there is 5V getting to the board? If 5V is not present on those pins check that the jumper is installed on the J1 holes. If 5V is present then there could be a fault with the board in which case I will send you a replacement.
Note: documents in Portable Document Format (PDF) require Adobe Acrobat Reader 5.0 or higher to view.
Download Adobe Acrobat Reader or other PDF reading software for your computer or mobile device.