View: 13580|Reply: 8

1wire kerner support

[Copy link]

1

threads

5

posts

35

credits

Novice

Rank: 1

credits
35
Published in 2015-11-3 23:23:31 | Show all floors |Read mode
Dear all, im a totally new in linux, so sorry for this stupid question...
is tere a way to enable the 1wire on OPi - like on RasPi - without the kerner modification?

If there would be someone, who explain it - I quess, im not the only one einterested in - would be more than welcome!!

I realized, i2c works fine, wiringpi is ported and works, only 1wire is the missing point in my case to replace raspi to opi.
thank you in advance for your kindly help and support!!

br
G

3

threads

96

posts

539

credits

Senior member

Rank: 4

credits
539
Published in 2015-11-4 01:26:28 | Show all floors
What image are you using? Pretty sure 1wire is working is working in latest loboris images. You don't have to actually build your own kernel. Just run his update scripts.
Orange Pi Plus

1

threads

5

posts

35

credits

Novice

Rank: 1

credits
35
 Author| Published in 2015-11-4 16:34:02 | Show all floors
Thanks a lot!! hopping you are right! I have run the update_kernel.sh , so basically have the latest kernel. Going to test today!
im using Debian_jessie_mini.img image.
have a nice day!
br
G

1

threads

5

posts

35

credits

Novice

Rank: 1

credits
35
 Author| Published in 2015-11-5 16:45:47 | Show all floors
Hi,
I have tried, but without success... im a little bit mixed, because of some experiments about raspi - not sure need to do the same on OPi...
Im using gpio 20, and  this is the /etc/modules:
#gpio-sunxi
w1-sunxi
w1-gpio
w1-therm
also I tried the
w1-therm pullup=1
without success....
this is only I have:
root@OrangePI:/sys/bus/w1/devices# ls
w1_bus_master1
root@OrangePI:/sys/bus/w1/devices# cd w1_bus_master1
root@OrangePI:/sys/bus/w1/devices/w1_bus_master1# ls
driver     w1_master_add              w1_master_pointer  w1_master_slave_count
power      w1_master_attempts         w1_master_pullup   w1_master_slaves
subsystem  w1_master_max_slave_count  w1_master_remove   w1_master_timeout
uevent     w1_master_name             w1_master_search

do you have any idea, what did I wrong?

thnak you in advance!!!
br
G

1

threads

15

posts

174

credits

Registered member

Rank: 2

credits
174
Published in 2015-11-6 21:37:41 | Show all floors
Edited by nitr0 at 2015-11-6 22:56

hi,

do you check dmesg if error during boot sequence ?
i will test 1wire thermal sensor DS18b20 in few days on OPi-PC/Debian_jessie

1

threads

15

posts

174

credits

Registered member

Rank: 2

credits
174
Published in 2015-11-7 05:08:56 | Show all floors

Glitch69 : "Im using gpio 20"

gpio 20 is GND.

1-wire need VCC,GND and data :

GPIO P01 for VCC : +3.3V
GPIO P06 for GND
GPIO P37 for data

1

threads

5

posts

35

credits

Novice

Rank: 1

credits
35
 Author| Published in 2015-11-9 20:15:30 | Show all floors
thank you very much for your notice!!!
it works for now!
I connected the ds data to pin38 /GPIO20 on raspi / instead of pin37.

the kernel update is a must!

1

threads

15

posts

174

credits

Registered member

Rank: 2

credits
174
Published in 2015-11-11 07:41:31 | Show all floors
hello Glitch69

nice, it's working now

have fun !!!!

0

threads

1

posts

50

credits

Registered member

Rank: 2

credits
50
Published in 2016-2-4 20:09:16 | Show all floors
Edited by blm at 2016-2-17 00:56

Hello,

This connection works fine, but how about parasite power?
After changing connection I've got some wired values:

root@OrangePI:~# cat /sys/bus/w1/devices/28-*/w1_slave
7c 05 4b 46 7f ff 0c 10 8b : crc=8b YES
7c 05 4b 46 7f ff 0c 10 8b t=87750

I found that instead of:
modprobe w1_therm   
modprobe w1_gpio  

we should use
modprobe w1_gpio pullup=1
modprobe w1_therm strong_pullup=1

but seams that our modules doesn't have this options (from dmesg)
w1_gpio: Unknown parameter `pullup'

Could you help?
Would be nice to have real OneWire (not two+gnd ;))

Thanks


[edit]

so far impossible, need to use this patch https://github.com/loboris/OrangePI-Kernel/pull/17
You need to log in before you can reply login | Register

Points Rule

Quick reply Top Return list