linux-iio.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: William Breathitt Gray <vilhelm.gray@gmail.com>
To: David Lechner <david@lechnology.com>
Cc: linux-iio@vger.kernel.org, linux-omap@vger.kernel.org,
	devicetree@vger.kernel.org, "Rob Herring" <robh+dt@kernel.org>,
	"Mark Rutland" <mark.rutland@arm.com>,
	"Benoît Cousson" <bcousson@baylibre.com>,
	"Tony Lindgren" <tony@atomide.com>,
	"Thierry Reding" <thierry.reding@gmail.com>,
	linux-kernel@vger.kernel.org, linux-pwm@vger.kernel.org
Subject: Re: [PATCH 2/4] counter: new TI eQEP driver
Date: Sat, 3 Aug 2019 01:40:45 +0900	[thread overview]
Message-ID: <20190802163926.GA29963@icarus> (raw)
In-Reply-To: <680ed555-c5db-6640-8fd3-121422077eff@lechnology.com>

On Fri, Aug 02, 2019 at 11:17:11AM -0500, David Lechner wrote:
> On 8/2/19 4:27 AM, William Breathitt Gray wrote:
> >> +static const struct counter_ops ti_eqep_counter_ops = {
> >> +	.count_read	= ti_eqep_count_read,
> >> +	.count_write	= ti_eqep_count_write,
> >> +	.function_get	= ti_eqep_function_get,
> >> +	.function_set	= ti_eqep_function_set,
> >> +};
> > Are you able to provide a signal_read function, or are the Signals not
> > exposed to the user by this device? Sometimes quadrature encoder devices
> > provide an instanteous read of the signal lines to tell whether they are
> > high or low, so I figured I'd ask.
> 
> No, it does not look like these signals can be read directly.

All right, in that case you can ignore signal_read.

> > 
> > You should define an action_get function as well along with Synapses
> > corresponding to each Signal. This will allow users to know whether the
> > Synapse fires on a rising edge, falling edge, no edge, or both edges.
> > 
> > For example, consider the drivers/counter/104-quad-8.c file. Each count
> > register has three associated signal lines: Quadrature A, Quadrature B,
> > and Index.
> > 
> > Quadrature A and B are your typical quadrature encoder lines and
> > depending on the function mode selected (quadrature x4, pulse-direction,
> > etc.) could have a Synapse action mode of none, rising edge, falling
> > edge, or both edges; see the quad8_synapse_actions_list array.
> > 
> > In contrast, the Index signal line only has two Synapse action modes:
> > rising edge (in the case preset functionality is enabled) or none.
> 
> The encoders I have don't use the index or strobe signals, so I was
> thinking maybe I should omit those two signals from the driver for the
> time being since I don't have a way of testing.

That should be fine for now. We can add them in a later patch down the
road and keep this introduction patch simple.

William Breathitt Gray

  reply	other threads:[~2019-08-02 16:41 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-07-22 15:45 [PATCH 0/4] new driver for TI eQEP David Lechner
2019-07-22 15:45 ` [PATCH 1/4] dt-bindings: counter: new bindings " David Lechner
2019-07-27 19:48   ` Jonathan Cameron
2019-08-02  7:25     ` William Breathitt Gray
2019-08-02 13:34       ` Rob Herring
2019-08-02 13:58         ` William Breathitt Gray
2019-07-22 15:45 ` [PATCH 2/4] counter: new TI eQEP driver David Lechner
2019-07-30 12:35   ` Uwe Kleine-König
2019-07-30 15:28     ` David Lechner
2019-08-02  9:27   ` William Breathitt Gray
2019-08-02 16:09     ` David Lechner
2019-08-02 16:17     ` David Lechner
2019-08-02 16:40       ` William Breathitt Gray [this message]
2019-07-22 15:45 ` [PATCH 3/4] ARM: dts: am33xx: Add nodes for eQEP David Lechner
2019-07-23  8:42   ` Tony Lindgren
2019-07-23 14:45     ` David Lechner
2019-07-23 14:51       ` Tony Lindgren
2019-07-22 15:45 ` [PATCH 4/4] ARM: dts: am335x-boneblue: Enable eQEP David Lechner
2019-07-25 12:40 ` [PATCH 0/4] new driver for TI eQEP William Breathitt Gray
2019-07-25 22:52   ` David Lechner
2019-07-27 19:45     ` Jonathan Cameron
2019-07-30  4:45     ` William Breathitt Gray
2019-08-01 17:37       ` David Lechner

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=20190802163926.GA29963@icarus \
    --to=vilhelm.gray@gmail.com \
    --cc=bcousson@baylibre.com \
    --cc=david@lechnology.com \
    --cc=devicetree@vger.kernel.org \
    --cc=linux-iio@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-omap@vger.kernel.org \
    --cc=linux-pwm@vger.kernel.org \
    --cc=mark.rutland@arm.com \
    --cc=robh+dt@kernel.org \
    --cc=thierry.reding@gmail.com \
    --cc=tony@atomide.com \
    /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;
as well as URLs for NNTP newsgroup(s).