<div dir="ltr"><div dir="ltr"><br></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Sat, Feb 13, 2021 at 11:58 AM Trevor Woerner <<a href="mailto:twoerner@gmail.com">twoerner@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Hi,<br></blockquote><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
<br>
It's true that you do need a device tree overlay to tell the kernel that you<br>
want to use the 1-wire bus, and you have to tell the kernel which GPIO pin you<br>
want to use as the 1 wire, but after that, attaching DS18B20 devices to a<br>
running system works quite magically.[4]<br>
<br>
Each DS18B20 has a unique 64-bit number burned into it, the first 8 bits<br>
specify the device type (i.e. the DS18B20), the next 48 bits are a unique<br>
serial number, and the last 8 bits are a CRC of the previous 56 bits. Due to<br>
the inclusion of the 8-bit device type, when I plug a DS18B20 into my board,<br>
the kernel automatically creates a sysfs entry for it with a "temperature"<br>
file that I can read to obtain the temperature in Celcius.<br>
<br></blockquote><div><br></div><div>so, this device looks discoverable on a bus,</div><div>once you know the bus is there.</div><div>thats the 1st distinction to make.</div><div>there are degrees/features.</div><div>Id also ask:</div><div>is that ID at a standard location ?</div><div>via some base transaction that all devices support ?<br></div><div><br></div><div>in my own house, I can find a switch in the dark.</div><div>I dont have Alexa listening to render help.</div><div><br></div><div><br></div><div><br></div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
I don't know if that qualifies as "discoverable"? It's certainly a lot more<br>
discoverable than I2C or SPI, although maybe not quite as discoverable as,<br>
say, PCI. Specifying the 1 wire is not discoverable, but plugging 1-wire<br>
devices into my board is maybe something that could be described as<br>
discoverable?<br>
<br>
Best regards,<br>
        Trevor<br>
<br>
[1] <a href="https://www.youtube.com/watch?v=a9CZ1Uk3OYQ" rel="noreferrer" target="_blank">https://www.youtube.com/watch?v=a9CZ1Uk3OYQ</a><br>
[2] <a href="https://twoerner.blogspot.com/2020/12/temperature-readings-with-ds18b20-and.html" rel="noreferrer" target="_blank">https://twoerner.blogspot.com/2020/12/temperature-readings-with-ds18b20-and.html</a><br>
[3] <a href="https://twoerner.blogspot.com/2021/01/sensing-temperature-with-raspberrypi.html" rel="noreferrer" target="_blank">https://twoerner.blogspot.com/2021/01/sensing-temperature-with-raspberrypi.html</a><br>
[4] <a href="https://twoerner.blogspot.com/2020/12/multiple-ds18b20-temperature-probes.html" rel="noreferrer" target="_blank">https://twoerner.blogspot.com/2020/12/multiple-ds18b20-temperature-probes.html</a><br>
<br>
_______________________________________________<br>
Kernelnewbies mailing list<br>
<a href="mailto:Kernelnewbies@kernelnewbies.org" target="_blank">Kernelnewbies@kernelnewbies.org</a><br>
<a href="https://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies" rel="noreferrer" target="_blank">https://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies</a><br>
</blockquote></div></div>