From: Sascha Hauer <s.hauer@pengutronix.de>
To: Marcel Behlau <marcel.behlau@elfin.de>
Cc: barebox@lists.infradead.org
Subject: Re: Usage of i2c_-Tools in Barebox
Date: Tue, 5 May 2015 17:54:50 +0200 [thread overview]
Message-ID: <20150505155450.GB6325@pengutronix.de> (raw)
In-Reply-To: <5548DA0A.3050408@elfin.de>
Hi Marcel,
On Tue, May 05, 2015 at 04:56:10PM +0200, Marcel Behlau wrote:
> Hi,
>
> i'm using a phyFLEX-i.MX6 SBC and want to communicate with an
> external µC over I2C. I only want to read/set 1 register, so i tried
> to use the builtin i2c_read and i2c_write-Commands. The µC is
> connected to i2c-bus 1 of the device, so i tried to probe the hole
> bus with "i2c_bus 1 3 30". The command only answered with
> "i2c_probe: No such device". I tried also the busses 0-3, with the
> same result. I searched in the board.c sourcecode of the phyflex,
> but couldn't find i2c related stuff, so i think, i have to add the
> initalisation for the i2c.
>
> Do i have to add the i2c-init in the boards/phytec-pfla02/board.c
> -file? Is there some documenation about this stuff?
The phyFLEX board is device tree based. You have to enable the i2c
controller in the dts file (same as you would do in the kernel).
Usually a:
&i2c0 {
status = "okay";
};
Should be enough. You probably also have to add the proper pinctrl node.
Sascha
--
Pengutronix e.K. | |
Industrial Linux Solutions | http://www.pengutronix.de/ |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 |
Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
next prev parent reply other threads:[~2015-05-05 15:55 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-05-05 14:56 Marcel Behlau
2015-05-05 15:54 ` Sascha Hauer [this message]
2015-05-06 7:12 ` Uwe Kleine-König
2015-05-07 11:24 ` Marcel Behlau
2015-05-08 5:12 ` Sascha Hauer
2015-05-20 6:34 ` Marcel Behlau
2015-05-22 6:41 ` Sascha Hauer
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=20150505155450.GB6325@pengutronix.de \
--to=s.hauer@pengutronix.de \
--cc=barebox@lists.infradead.org \
--cc=marcel.behlau@elfin.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox