* [PATCH v2 1/4] iio: hx711: add data-ready-delay-ns property in DT
@ 2018-06-25 15:18 Andreas Klinger
2018-06-30 17:32 ` Jonathan Cameron
0 siblings, 1 reply; 3+ messages in thread
From: Andreas Klinger @ 2018-06-25 15:18 UTC (permalink / raw)
To: jic23, knaack.h, lars, pmeerw, robh+dt, mark.rutland, mchehab,
davem, gregkh, akpm, linus.walleij, rdunlap, devicetree,
linux-iio, linux-kernel
add data-ready-delay-ns property for hx711 ADC
this is the delay after rising PD_SCK until DOUT is read and assumed to be
ready
Signed-off-by: Andreas Klinger <ak@it-klinger.de>
---
Documentation/devicetree/bindings/iio/adc/avia-hx711.txt | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/Documentation/devicetree/bindings/iio/adc/avia-hx711.txt b/Documentation/devicetree/bindings/iio/adc/avia-hx711.txt
index b3629405f568..d0c066e3df69 100644
--- a/Documentation/devicetree/bindings/iio/adc/avia-hx711.txt
+++ b/Documentation/devicetree/bindings/iio/adc/avia-hx711.txt
@@ -8,11 +8,18 @@ Required properties:
See Documentation/devicetree/bindings/gpio/gpio.txt
- avdd-supply: Definition of the regulator used as analog supply
+Optional properties:
+ - data-ready-delay-ns: additional delay in nanoseconds between rising of
+ PD_SCK until DOUT is ready
+ should be less then maximum PD_SCK high time which
+ is 50000 in the datasheet
+
Example:
weight@0 {
compatible = "avia,hx711";
sck-gpios = <&gpio3 10 GPIO_ACTIVE_HIGH>;
dout-gpios = <&gpio0 7 GPIO_ACTIVE_HIGH>;
avdd-suppy = <&avdd>;
+ data-ready-delay-ns = <1000>;
};
--
2.1.4
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH v2 1/4] iio: hx711: add data-ready-delay-ns property in DT
2018-06-25 15:18 [PATCH v2 1/4] iio: hx711: add data-ready-delay-ns property in DT Andreas Klinger
@ 2018-06-30 17:32 ` Jonathan Cameron
2018-07-03 21:48 ` Rob Herring
0 siblings, 1 reply; 3+ messages in thread
From: Jonathan Cameron @ 2018-06-30 17:32 UTC (permalink / raw)
To: Andreas Klinger
Cc: knaack.h, lars, pmeerw, robh+dt, mark.rutland, mchehab, davem,
gregkh, akpm, linus.walleij, rdunlap, devicetree, linux-iio,
linux-kernel
On Mon, 25 Jun 2018 17:18:02 +0200
Andreas Klinger <ak@it-klinger.de> wrote:
> add data-ready-delay-ns property for hx711 ADC
> this is the delay after rising PD_SCK until DOUT is read and assumed to be
> ready
>
> Signed-off-by: Andreas Klinger <ak@it-klinger.de>
Hmm. It's not particularly generic... I think this should have
have vendor prefix until we have some visibility of whether it
is a common thing we want to standardise around or not.
I'll also be waiting for a devicetree ack on this one as it's a
tiny bit unusual.
Thanks,
Jonathan
> ---
> Documentation/devicetree/bindings/iio/adc/avia-hx711.txt | 7 +++++++
> 1 file changed, 7 insertions(+)
>
> diff --git a/Documentation/devicetree/bindings/iio/adc/avia-hx711.txt b/Documentation/devicetree/bindings/iio/adc/avia-hx711.txt
> index b3629405f568..d0c066e3df69 100644
> --- a/Documentation/devicetree/bindings/iio/adc/avia-hx711.txt
> +++ b/Documentation/devicetree/bindings/iio/adc/avia-hx711.txt
> @@ -8,11 +8,18 @@ Required properties:
> See Documentation/devicetree/bindings/gpio/gpio.txt
> - avdd-supply: Definition of the regulator used as analog supply
>
> +Optional properties:
> + - data-ready-delay-ns: additional delay in nanoseconds between rising of
> + PD_SCK until DOUT is ready
> + should be less then maximum PD_SCK high time which
> + is 50000 in the datasheet
> +
> Example:
> weight@0 {
> compatible = "avia,hx711";
> sck-gpios = <&gpio3 10 GPIO_ACTIVE_HIGH>;
> dout-gpios = <&gpio0 7 GPIO_ACTIVE_HIGH>;
> avdd-suppy = <&avdd>;
> + data-ready-delay-ns = <1000>;
> };
>
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH v2 1/4] iio: hx711: add data-ready-delay-ns property in DT
2018-06-30 17:32 ` Jonathan Cameron
@ 2018-07-03 21:48 ` Rob Herring
0 siblings, 0 replies; 3+ messages in thread
From: Rob Herring @ 2018-07-03 21:48 UTC (permalink / raw)
To: Jonathan Cameron
Cc: Andreas Klinger, knaack.h, lars, pmeerw, mark.rutland, mchehab,
davem, gregkh, akpm, linus.walleij, rdunlap, devicetree,
linux-iio, linux-kernel
On Sat, Jun 30, 2018 at 06:32:32PM +0100, Jonathan Cameron wrote:
> On Mon, 25 Jun 2018 17:18:02 +0200
> Andreas Klinger <ak@it-klinger.de> wrote:
>
> > add data-ready-delay-ns property for hx711 ADC
> > this is the delay after rising PD_SCK until DOUT is read and assumed to be
> > ready
> >
> > Signed-off-by: Andreas Klinger <ak@it-klinger.de>
>
> Hmm. It's not particularly generic... I think this should have
> have vendor prefix until we have some visibility of whether it
> is a common thing we want to standardise around or not.
Agreed. Doesn't look like any interface I've seen before.
Since it's bit-banging, seems to me it would be better to specify the
frequency for PD_SCK and sample DOUT just before or after setting PD_SCK
low.
Rob
> I'll also be waiting for a devicetree ack on this one as it's a
> tiny bit unusual.
>
> Thanks,
>
> Jonathan
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2018-07-03 21:48 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-06-25 15:18 [PATCH v2 1/4] iio: hx711: add data-ready-delay-ns property in DT Andreas Klinger
2018-06-30 17:32 ` Jonathan Cameron
2018-07-03 21:48 ` Rob Herring
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).