From: Stefano Babic <sbabic@denx.de>
To: u-boot@lists.denx.de
Subject: [U-Boot] i.MX51 How to use and program LED's
Date: Thu, 25 Mar 2010 17:51:32 +0100 [thread overview]
Message-ID: <4BAB9494.7000709@denx.de> (raw)
In-Reply-To: <aa75524c1003250838l4cfb3d72wd4967a0935a0b235@mail.gmail.com>
Carlo McKee wrote:
> Hello,
>
> I need help on how to write a simple routine in C to turn on and off the
> general purpose diagnostic LED's of the iMX51 EVK board.
> I am developing under Linux. Any help appreciated.
As I cann see from schematics, the diagnostic led is connected with
GPIO2_6. At the moment, there are no accessors function to access the
gpio, in the same way we have for i.MX31. It should be nice to have it,
however ;)
Anyway, you can directly access to the gpio controller with readl/writel
accessors. You can see an example (read) in mx51evk.c in board_mmc_getcd().
Check the gpio controller part of the manual, you need at least to set
the direction as output for the GPIO2_6 pin before setting it.
Regards,
Stefano Babic
--
=====================================================================
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: +49-8142-66989-0 Fax: +49-8142-66989-80 Email: office at denx.de
=====================================================================
next prev parent reply other threads:[~2010-03-25 16:51 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-03-25 15:38 [U-Boot] i.MX51 How to use and program LED's Carlo McKee
2010-03-25 16:51 ` Stefano Babic [this message]
2010-03-25 19:09 ` Wolfgang Denk
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=4BAB9494.7000709@denx.de \
--to=sbabic@denx.de \
--cc=u-boot@lists.denx.de \
/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.