All the mail mirrored from lore.kernel.org
 help / color / mirror / Atom feed
From: William Huang <whuang8933@gmail.com>
To: linux-iio@vger.kernel.org
Subject: Can't find trigger_now for sysfs-based triggering
Date: Sat, 12 Jun 2021 12:43:12 -0400	[thread overview]
Message-ID: <CADa-vC0c4_0XiLd6GQto6f0h2BZi0CvWiP7v9NTjG9cgXTGoLw@mail.gmail.com> (raw)

Hi everyone,

I hope this is the right place to ask my noob question.
I'm trying to learn how to write an IIO driver and using a couple
books as my resource. I managed to write a simple one and perform
oneshot-based data reads (e.g. cat iio:device0/in_temp_raw).

Now, I'm trying to set up a trigger-buffered data read. I believe I
set up the triggers correctly:
cat trigger0/name > iio:device0/trigger/current_trigger
echo 1 > iio:device0/scan_elements/in_temp_en
echo 1 > iio:device0/buffer/enable
cat /dev/iio\:device0 | xxd -

Now, I'm not understanding how I should actually perform the trigger.
From my books, there should be a trigger_now file where I can echo 1
to trigger, but it's not available in my trigger0/ directory. Also,
the book references a add_trigger in /sys/devices/iio_sysfs_trigger/
directory, but that's nowhere to be found as well.

My .config also has CONFIG_IIO_SYSFS_TRIGGER=m.

Any help/advice would be appreciated!

Thanks,
William Huang

             reply	other threads:[~2021-06-12 16:44 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-06-12 16:43 William Huang [this message]
2021-06-13 11:18 ` Can't find trigger_now for sysfs-based triggering 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=CADa-vC0c4_0XiLd6GQto6f0h2BZi0CvWiP7v9NTjG9cgXTGoLw@mail.gmail.com \
    --to=whuang8933@gmail.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.