tag:blogger.com,1999:blog-79535913372206656102024-03-07T23:52:46.652-08:00The FleschAFhttp://www.blogger.com/profile/11627950462016636737noreply@blogger.comBlogger2125tag:blogger.com,1999:blog-7953591337220665610.post-27484174585830298492013-07-04T06:33:00.001-07:002013-07-04T06:33:22.295-07:00Linux Kernel and I2C SlaveHi,<br />
<br />
If you will review the Linux kernel sources you will notice that there is absolutely no support for I2C slave - I guess this is logic since it is very rare to use a Linux base system as I2C device. It is also not simple because the Master may have timing issues.<br />
<br />
But, unfortunately, sometimes it is required - so, if you are using Freescale's I2C controller (of course it can be done only with a controller - do it with GPIOs is much more complicated) I can help you.<br />
<br />
I did it for device based on Freescale's PQII pro MPC8308 chip that is based on PPC core, but I believe it should not be a problem to do it also to other Freescale's chips that base on ARM core and has the same I2C controller unit.<br />
<br />
I hope to expand the information on that issue here, but anyway if you need help, I'll be happy to assist. <br />
<br />
AvnerAFhttp://www.blogger.com/profile/11627950462016636737noreply@blogger.com0tag:blogger.com,1999:blog-7953591337220665610.post-39724244119309151772012-11-07T07:48:00.002-08:002012-11-08T00:21:04.445-08:00Linux USB host driver for Freescale's MPC83XXRecently I got a project to set MPC8308RDB USB to host mode and support serial USB driver.<br />
MPC8308RDB is evaluation board for PQII-Pro MPC8308 supplied by Freescale.<br />
<br />
First of all I configured the Linuk kernel:<br />
<br />
<i><span style="font-family: "Courier New",Courier,monospace;">make ARCH=powerpc CROSS_COMPILE=ppc_6xx- mpc83xx_defconfig </span></i><br />
<br />
Thus how I got the default <b><i>.config</i></b> file for my board.<br />
Then I did:<br />
<br />
<i><span style="font-family: "Courier New",Courier,monospace;">make ARCH=powerpc CROSS_COMPILE=ppc_6xx- xconfig </span></i><br />
<br />
And I changed the configuration according to my needs (USB, USB Host, USB Serial, etc.)<br />
<br />
Then I burn this Kernel image to the flash - but got nothing...<br />
<br />
I googled about it, tried to get answer in some related mailing list, ask for support request by Freescale - but no one really managed to help me solve this problem.<br />
<br />
Eventually I checked my DTS file, and there were the answer - you must configure correctly the USB.<br />
Unfortunately, there is no documentation for the DTS file (correct me if I am wrong).<br />
Anyway, this is how USB Host should be configured in the DTS file for MPC83xx processors (I assume it is true also for other Freescale's processors):<br />
<br />
<span style="font-family: "Courier New",Courier,monospace;"> usb@23000 {<br /> compatible = "fsl-usb2-dr";<br /> reg = <0x23000 0x1000>;<br /> #address-cells = <1>;<br /> #size-cells = <0>;<br /> interrupt-parent = <&ipic>;<br /> interrupts = <38 0x8>;<br /> dr_mode = "host";<br /> phy_type = "ulpi";<br /> };</span><br />
Good Luck<br />
<br />
AvnerAFhttp://www.blogger.com/profile/11627950462016636737noreply@blogger.com0