tag:blogger.com,1999:blog-5189771804288006363.post1432049200160017704..comments2024-02-14T08:40:52.818+00:00Comments on Maker's Blog: Making yet another Internet Radio project with Raspberry PiMaker's Bloghttp://www.blogger.com/profile/03673194184565944945noreply@blogger.comBlogger6125tag:blogger.com,1999:blog-5189771804288006363.post-66289953986108368262014-03-31T22:52:27.116+01:002014-03-31T22:52:27.116+01:00Hi Andrey,
Well thats weird. First I ran it out of...Hi Andrey,<br />Well thats weird. First I ran it out of the box and got 0 for both temp & pressure.<br />Then I removed RPI2C_RS_READ as you said and got 0xEE for ID instead of 0xC4.<br />So I replaced RPI2C_RS_READ and now get 0xC4 and correct temperature & pressure.<br />Being curious I removed RPI2C_RS_READ again but it still works fine.<br />Finally, I powered down the board and powered it up again and it still works fine.<br />The bottom line is that it works for which I'm eternally grateful, buts its niggling that I don't still do't fully understand what happened.<br /><br />Thanks again,<br />DavidUnknownhttps://www.blogger.com/profile/16147205033313994680noreply@blogger.comtag:blogger.com,1999:blog-5189771804288006363.post-9672801798353543742014-03-30T22:21:13.877+01:002014-03-30T22:21:13.877+01:00Just tried it - works perfect. I've added main...Just tried it - works perfect. I've added main.c and Makefile to the repo.<br />This time I did not modify breakout, just connected it to RPi.<br />Actually i2cdetect does not detect MPL3115A2 sensor, because of repeated start? In your case it detects it, so maybe your version does not require repeated start? You can try to remove RPI2C_RS_READ from mpl_config() and rpi_i2c_read_regs() call in the main.<br /><br />Regards, Andrey Maker's Bloghttps://www.blogger.com/profile/03673194184565944945noreply@blogger.comtag:blogger.com,1999:blog-5189771804288006363.post-4993580011466794092014-03-30T21:15:44.264+01:002014-03-30T21:15:44.264+01:00Actually I removed pullups from Sparkfun breakout ...Actually I removed pullups from Sparkfun breakout board, so I use pullups which are on RPi itself. As I remember, initially I had some problems with this breakout but it turned out to be just a bad connection on my breadboard. <br />I have spare MPL3115 breakout board so I can try it sometime this week whith my example code and will let you know.<br /><br />Regards, AndreyMaker's Bloghttps://www.blogger.com/profile/03673194184565944945noreply@blogger.comtag:blogger.com,1999:blog-5189771804288006363.post-48557083252390112722014-03-30T21:02:39.131+01:002014-03-30T21:02:39.131+01:00Thanks for the help.
When I run the code I get
+++...Thanks for the help.<br />When I run the code I get<br />++++++++++++++++++<br />Invalid device ID: 01, must be C4<br />t=200.88 P= 0kP<br />+++++++++++++++++<br />i.e. in mpl_config the rpi_i2c_read_reg returns NACK<br />so nothing has changed.<br />I know the device is hooked up OK because i2cdetect shows device address 0x60 present (have to do modprobe i2c_bcm2708, modprobe i2c-dev for that to work.<br />How did you hook up the mpl3115, with discrete pullups or is it in a breakout board?<br /><br />Regards, DavidUnknownhttps://www.blogger.com/profile/16147205033313994680noreply@blogger.comtag:blogger.com,1999:blog-5189771804288006363.post-7991415364735118382014-03-30T16:26:47.887+01:002014-03-30T16:26:47.887+01:00Hi,
I've created new repo https://github.com/a...Hi,<br />I've created new repo https://github.com/achilikin/mpl3115 with two header files. Example main() is in readme.md, have not tried it, just created extraction from my code for the radio. Let me know how it works for you.<br /><br />Regards,<br />AndreyMaker's Bloghttps://www.blogger.com/profile/03673194184565944945noreply@blogger.comtag:blogger.com,1999:blog-5189771804288006363.post-77985493805039740812014-03-29T21:34:48.586+00:002014-03-29T21:34:48.586+00:00I'm really interested to see how you control t...I'm really interested to see how you control the MPL3115 as I've been battling this for a couple of days.<br />Following your lead I installed the bcm2835 library but even Mikes examples I can't get working, all I/O reports NAK.<br />I know the device I have is OK, its on a Sparkfun breakout board with builtin pullups and works fine on Arduino.<br />Any insight gratefully received.Unknownhttps://www.blogger.com/profile/16147205033313994680noreply@blogger.com