MPL3115A2 pressure sensor Plugin

Moderators: grovkillen, Stuntteam, TD-er

Post Reply
Message
Author
interhard
New user
Posts: 1
Joined: 21 Sep 2016, 18:15

MPL3115A2 pressure sensor Plugin

#1 Post by interhard » 25 Sep 2016, 13:18

Hello. A few days ago I made a plugin for I2C MPL3115A2 pressure sensor . If anyone needed - is a plugin here:https://yadi.sk/d/pbVAdMcGvgFVk
Datasheet for sensor - http://www.nxp.com/files/sensors/doc/da ... 3115A2.pdf
Attachments
screenshot.png
screenshot.png (37.53 KiB) Viewed 3529 times

ananke
New user
Posts: 2
Joined: 07 Dec 2016, 00:09

Re: MPL3115A2 pressure sensor Plugin

#2 Post by ananke » 12 Dec 2016, 05:23

Thanks! I just got a couple of those sensors to play with, and was hoping to get them going with espeasy.

This is first time I'm trying to get a plugin working, so excuse if this is an obvious problem. I can get espeasy compiled as is, but when I drop this plugin in, I get the following errors:

Code: Select all

_P037_MPL3115A2:11: error: 'Adafruit_MPL3115A2' does not name a type
 Adafruit_MPL3115A2 baro = Adafruit_MPL3115A2();
 ^
/Users/dom/Workspace/esp8266/ESPEasy/_P037_MPL3115A2.ino: In function 'boolean Plugin_037(byte, EventStruct*, String&)':
_P037_MPL3115A2:53: error: 'baro' was not declared in this scope
         if (baro.begin()) 
             ^
Multiple libraries were found for "Servo.h"
 Used: /Users/dom/Library/Arduino15/packages/esp8266/hardware/esp8266/2.3.0/libraries/Servo
 Not used: /Applications/Arduino.app/Contents/Java/libraries/Servo
exit status 1
'Adafruit_MPL3115A2' does not name a type
Any clue what's going on? Adafruit's library is present. Servo.h errors don't show up without this plugin either.

Cheers!

abial
New user
Posts: 4
Joined: 26 Jan 2017, 18:57

Re: MPL3115A2 pressure sensor Plugin

#3 Post by abial » 26 Jan 2017, 19:12

Including the library fixed it for me - in ESPEasy.ino:

Code: Select all

#include <Adafruit_MPL3115A2.h>

Post Reply

Who is online

Users browsing this forum: No registered users and 16 guests