Port-arm archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: DS1307 on NetBSD 9 RPI2 and RPI3
Jason Thorpe <thorpej%me.com@localhost> writes:
>> On Apr 23, 2020, at 11:57 AM, Brad Spencer <brad%anduin.eldar.org@localhost> wrote:
>>
>> Michael van Elst <mlelstv%serpens.de@localhost> writes:
>>
>> [snip]
>>
>> Thanks... I still can't get it to work, but the information was
>> helpful...
>>
>> I have a overlay with this in it:
>>
>> /dts-v1/;
>>
>> / {
>> compatible = "brcm,bcm2835-i2c";
>
> Your compatible string should match one of the root node's compatible strings, so:
>
> compatible = "brcm,bcm2835";
>
> (Or "brcm,bcm2836" or "brcm,bcm2837" or whatever.)
>
> ...but maybe it doesn't matter because...
Yes, I see (well, not really, but I am starting to get used to it).. as
this is a RPI2 Model B, it probably should be brcm,bcm2836
>> This does prevent the uninteresting i2c buses from attaching and allows
>> just the one with the DS1307 on it to be available. I can see the
>> device with i2cscan:
>>
>> /dev/iic0: found device at 0x68
>> /dev/iic0: 1 devices found
>>
>> ofctl
>> 00002e30: /i2c@7e804000
>> 00002f28: /dsrtc@68
>>
>>
>> [ 1.000003] bsciic0 at simplebus1: Broadcom Serial Controller
>> [ 1.000003] iic0 at bsciic0: I2C bus
>> [ 1.000003] dsrtc at iic0 addr 0x68 not configured
>>
>> Does not attach... I know that the kernel has the dsrtc driver compiled
>> into it.
>
> What is the EXACT line in your kernel config file where "dsrtc" is declared?
Well, it would have been a hold over from the previous way this all
worked, so:
dsrtc* at iic2 addr 0x68 flags 1307
so, according to this, it would (might?) be looking for it on the wrong
bus I suppose?? Yes??? When I did this originally, there was some
reason or other I tied it to iic2 (sorry don't remember why).. can one
get away with using iic? now?? It would seem that the addr and flags
are a bit redundant with what the overlay says to do, so I suppose one
should leave those off?? That seems to be permitted from what
sys/dev/i2c/files.i2c says.
> -- thorpej
--
Brad Spencer - brad%anduin.eldar.org@localhost - KC8VKS - http://anduin.eldar.org
Home |
Main Index |
Thread Index |
Old Index