public inbox for linux-iio@vger.kernel.org
 help / color / mirror / Atom feed
From: Jonathan Cameron <Jonathan.Cameron@Huawei.com>
To: Alexandru Ardelean <ardeleanalex@gmail.com>
Cc: "Ekin Böke" <ekin_boke@arcelik.com>,
	"linux-iio@vger.kernel.org" <linux-iio@vger.kernel.org>,
	"cengiz@kernel.wtf" <cengiz@kernel.wtf>
Subject: Re: Control Register device tree binding request for Opt3001
Date: Thu, 18 Feb 2021 12:15:02 +0000	[thread overview]
Message-ID: <20210218121502.00002014@Huawei.com> (raw)
In-Reply-To: <CA+U=DspfyuxyhPfPrGDaU5nDQVaO5p3ha-5hwpzVX69p1P60WA@mail.gmail.com>

On Thu, 18 Feb 2021 10:35:27 +0200
Alexandru Ardelean <ardeleanalex@gmail.com> wrote:

> On Thu, Feb 18, 2021 at 7:27 AM Ekin Böke <ekin_boke@arcelik.com> wrote:
> >
> > Hi,
> >
> > We are using Opt3001 for a day light control system and according to the data sheet it has 2 conversion time modes
> > that are 100 ms(CT=0) and 800 ms(CT=1) . Configuration register field CT controls the conversion time and we want to set the CT parameter at the initialization to 0 at all times. We could do it by using the in_illuminance_integration_time sysfs node at the runtime.
> >
> > Should we add a parameter to the device tree bindings or is there another way to set the CT parameter at the initialization?  
> 
> It's usually a good idea to use the sysfs attribute, if it's already available.
> Maybe during system boot-up, you can add some service init call to
> initialize to 100 ms or right before starting to read data from the
> sensor.
> 
> For kernel people, these initialization device-tree attributes seem convenient.
> But in this case, CT is a parameter of the chip and not a hard-wired
> configuration of the board [which needs to be described in DT].

As described, what you want to control here is policy, not a characteristic
of the hardware.   Normally we don't use DT to make such decisions, as it should
be controlled at runtime.

So basically what Alex said :)

Jonathan

> 
> >
> >
> > Best Regards
> >
> > Ekin
> >
> >
> >
> > Bu e-posta mesaji kisiye ozel olup, gizli bilgiler iceriyor olabilir. Eger bu e-posta mesaji size yanlislikla ulasmissa, icerigini hic bir sekilde kullanmayiniz ve ekli dosyalari acmayiniz. Bu durumda lutfen e-posta mesajini kullaniciya hemen geri gonderiniz ve tum kopyalarini mesaj kutunuzdan siliniz. Bu e-posta mesaji, hic bir sekilde, herhangi bir amac icin cogaltilamaz, yayinlanamaz ve para karsiligi satilamaz. Bu e-posta mesaji viruslere karsi anti-virus sistemleri tarafindan taranmistir. Ancak yollayici, bu e-posta mesajinin - virus koruma sistemleri ile kontrol ediliyor olsa bile - virus icermedigini garanti etmez ve meydana gelebilecek zararlardan dogacak hicbir sorumlulugu kabul etmez. This message is intended solely for the use of the individual or entity to whom it is addressed , and may contain confidential information. If you are not the intended recipient of this message or you receive this mail in error, you should refrain from making any use of the contents and fr
 om opening any attachment. In that case, please notify the sender immediately and return the message to the sender, then, delete and destroy all copies. This e-mail message, can not be copied, published or sold for any reason. This e-mail message has been swept by anti-virus systems for the presence of computer viruses. In doing so, however, sender cannot warrant that virus or other forms of data corruption may not be present and do not take any responsibility in any occurrence.  


  reply	other threads:[~2021-02-18 15:26 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-02-18  5:18 Control Register device tree binding request for Opt3001 Ekin Böke
2021-02-18  8:31 ` Matt Ranostay
2021-02-18  8:35 ` Alexandru Ardelean
2021-02-18 12:15   ` Jonathan Cameron [this message]
2021-02-18 12:38     ` Cengiz Can
2021-02-21 12:26       ` Jonathan Cameron

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20210218121502.00002014@Huawei.com \
    --to=jonathan.cameron@huawei.com \
    --cc=ardeleanalex@gmail.com \
    --cc=cengiz@kernel.wtf \
    --cc=ekin_boke@arcelik.com \
    --cc=linux-iio@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox