Navigation

    • Register
    • Login
    • Search
    • OpenHardware.io
    • Categories
    • Recent
    • Tags
    • Popular
    1. Home
    2. betonmoewe
    • Profile
    • Following
    • Followers
    • Topics
    • Posts
    • Best
    • Groups

    betonmoewe

    @betonmoewe

    0
    Reputation
    9
    Posts
    536
    Profile views
    0
    Followers
    0
    Following
    Joined Last Online

    betonmoewe Follow

    Best posts made by betonmoewe

    This user hasn't posted anything yet.

    Latest posts made by betonmoewe

    • RE: NodeManager: plugin for a rapid development of battery-powered sensors

      @user2684

      Hi,

      thanks again for your great work!

      As I said, I will try to include my Chirp module into 1.7 via a github branch/fork. You wrote in your explanation of "contributing to the code", that it is not allowed, to change config.h. But how should I include the lines for the chirp sensor?
      And in wich way can the documentation be modified? (chirp sensor paramaters)

      Best regards

      Betonmoewe

      posted in NodeManager
      betonmoewe
      betonmoewe
    • RE: How can I set parameter if there are multible instances of the sensor class?

      ok ok ... I found a way: the word static is the key !

      I have declared all my needed variables as static and do a global initialization in NodeManager.cpp just in front of the code for my Chirp methods. The -2 is not necessary any more and with a helper variable, (address of the sensor) there is only one sensor initialization/reset.

      Now, only question 2 is open ...

      posted in NodeManager
      betonmoewe
      betonmoewe
    • How can I set parameter if there are multible instances of the sensor class?

      Hi (once again),

      I just try to create my own sensor class within NodeManager. I have Chirp sensors (https://www.tindie.com/products/miceuz/i2c-soil-moisture-sensor/) at home for monitoring the mositure of the soil of my plants.
      My current (minimal) implementation of the class works fine, but now. I have 3 problems:

      1.) The sensor produces 3 sensor readings (Capacitance,Light and Temperature). This creates 3 instances of my new Chirp class. If I try to set the class specific parameter (I would like to set an individual capacitance measurement offset because of the scattering of each individual sensor hardware) like in your description:

      SensorCHIRP* myCHIRP = (SensorCHIRP*)nodeManager.getSensor(nodeManager.registerSensor(SENSOR_CHIRP));
      myCHIRP->setMoistureOffset(330);
      myCHIRP->setMoistureRange(520);
      myCHIRP->setRreturnMoistureNormalized(true);
      

      It sets the parameter only in the last instance of the class, but this is not the instance for moisture (ok, I can rearrange the initialization, but maybe there is a better way).
      The only way I found, is to substract 2 from the sensorID:

      (SensorCHIRP*)nodeManager.getSensor(nodeManager.registerSensor(SENSOR_CHIRP)-2);
      

      because it is the first created instance of the class.

      Maybe my last c++ project was tooooooo long ago ....

      2.) that means: if I want to set (as an example) the setTrackLastValue parameter, I have to do this for all 3 instances?

      3.) every instance of the Chirp class does its own sensor initialization. It there a way to do this only once?

      If my Chirp class have no further errors (and a way to deal with the above), you can include this class into your package, if you wish ...

      Best regards and THANKS for this really helpfull NodeManager library

      Frank (Betonmowew)

      posted in NodeManager
      betonmoewe
      betonmoewe
    • RE: NodeManager v1.6-dev: comments and issues

      ok ... if I change V_LEVEL to V_LIGHT_LEVEL in NodeManager.cpp, I got a reading ... strange

      By the way: I have a small problem with the BME Sensor: pressure and forecast have both the same ID

      mapReading_forecast4 4 forecast
      mapReading_pressure4 4 pressure

      is this correct?

      I have got a forcast reading only one time 😞

      Betonmoewe

      posted in NodeManager
      betonmoewe
      betonmoewe
    • RE: NodeManager v1.6-dev: comments and issues

      I will try tomorrow ...

      thanks for your help !

      posted in NodeManager
      betonmoewe
      betonmoewe
    • RE: NodeManager v1.6-dev: comments and issues

      okok ... my fault ... you are right LUX is int not float ...

      but no reading is send (I use fhem as reciever):

      2017-08-13 18:57:18 Global global ATTR MYSENSOR_113 mode node
      2017-08-13 18:57:18 Global global ATTR MYSENSOR_113 version 2.1.1
      2017-08-13 18:57:18 MYSENSORS_DEVICE MYSENSOR_113 parentId: 110
      2017-08-13 18:57:18 MYSENSORS_DEVICE MYSENSOR_113 SKETCH_NAME: MultiSensor_NM
      2017-08-13 18:57:19 MYSENSORS_DEVICE MYSENSOR_113 batterylevel: 100
      2017-08-13 18:57:19 MYSENSORS_DEVICE MYSENSOR_113 temperature2: 24.84
      2017-08-13 18:57:19 MYSENSORS_DEVICE MYSENSOR_113 humidity3: 50.85
      2017-08-13 18:57:19 MYSENSORS_DEVICE MYSENSOR_113 pressure4: 1007.90

      no brightness1 and I have no idea ...

      Best regards

      Betonmoewe

      posted in NodeManager
      betonmoewe
      betonmoewe
    • RE: NodeManager v1.6-dev: comments and issues

      hi,

      yes, there is a value, but there is no output (presentation) of the value ... the bme sensor works perfect. Wy is this an "I" value and not a "F" like the other values?

      AWAKE
      TSL I=1 L=2521
      SEND D=0 I=1 C=1 T=37 S= I=2521 F=0.00
      BME I=2 T=24.76
      SEND D=0 I=2 C=1 T=0 S= I=0 F=24.76
      BME I=3 H=52.88
      SEND D=0 I=3 C=1 T=1 S= I=0 F=52.88
      BME I=4 P=1007.86
      SEND D=0 I=4 C=1 T=4 S= I=0 F=1007.86
      SLEEP 60s

      Best regards

      Frank (Betonmoewe)

      posted in NodeManager
      betonmoewe
      betonmoewe
    • RE: NodeManager v1.6-dev: comments and issues

      Hi,

      I just try to get the TSL2561 Sensor (i2C) working, but without success! The nomal Arduino example scetch works perfect, but it seems, that the sensor would not be not initialized within nodemanager or something like that ...

      Here my code:

      int myTSL2561 = nodeManager.registerSensor(SENSOR_TSL2561);
      ((SensorTSL2561*)nodeManager.getSensor(myTSL2561))->setAddress(TSL2561_ADDR_FLOAT);
      ((SensorTSL2561*)nodeManager.getSensor(myTSL2561))->setGain(TSL2561_GAIN_16X);
      ((SensorTSL2561*)nodeManager.getSensor(myTSL2561))->setTiming(TSL2561_INTEGRATIONTIME_101MS);
      ((SensorTSL2561*)nodeManager.getSensor(myTSL2561))->setSpectrum(TSL2561_VISIBLE);
      //nodeManager.registerSensor(SENSOR_BME280);

      I also tried with only theregister line (nodeManager.registerSensor(SENSOR_TSL2561);), but the same. The BME280 works fine (if enabled).

      what confuses me:

      why is the constructor like that -> SensorTSL2561::SensorTSL2561(NodeManager* node_manager, int child_id): Sensor(node_manager, child_id,A2) ???

      The TSL2561 is connected at A4,A5 because of i2c, but the constructor uses A2 ???

      serial output:

      REG I=1 P=16 P=16 T=37
      NodeManager v1.6-dev
      LIB V=2.1.1 R=N T=N A=A S=- B=-
      INT P=3 M=255
      INT P=2 M=255
      RADIO OK
      PRES I=200, T=23
      PRES I=201, T=30
      BATT V=3.45 P=100
      SEND D=0 I=201 C=0 T=38 S= I=0 F=3.45
      PRES I=1 T=16
      READY

      MY I=113 M=1
      TSL I=1 L=19
      SEND D=0 I=1 C=0 T=37 S= I=19 F=0.00
      SLEEP 600s

      Does anybody have a solution?

      Best regards

      Frank (Betonmoewe)

      posted in NodeManager
      betonmoewe
      betonmoewe
    • can not get the BH1750 to work with NodeManager

      Hi,

      I have tried to convert (or recreate) my original mySensors 2.1.1 Sketch to a new NoteManager scetch because I love the idea behind the NodeManager (great work). I have a Sensor with the BH1750 and one DHT22 connected. With my old sketch, both sensors are working. With the new NodeManager based sketch, only the DHT22 produces a reading, the BH1750 is silent. I have tried the 1.5 and the 1.6 (beta) version (1.6 with the DHT library from the description) still nothing.

      Here are the relevant code:

      void before() {
      // setup the serial port baud rate
      Serial.begin(MY_BAUD_RATE);

      pinMode(BMPLUXPWR_PIN, OUTPUT); # to set PowerPin for BH... permanent high (works (tested via multimeter))
      digitalWrite(BMPLUXPWR_PIN, HIGH);
      delay(2000);
      /*

      • Register below your sensors
        */
        nodeManager.setSleepMinutes(10);
        nodeManager.setBatteryMin(1.8);
        nodeManager.setBatteryMin(3.2);
        nodeManager.registerSensor(SENSOR_DHT22,3);
        nodeManager.registerSensor(SENSOR_BH1750);
        nodeManager.setPowerPins(6,5,250); # Pin 5 is for the DHT Sensor

      /*

      • Register above your sensors
        */
        nodeManager.before();
        }

      all other code is unchanged.

      I can not enable debug because of too low memory 😞

      ok ok ... after disabling some default sensors (analog/digital) I have some debug output:

      REG I=1 P=3 P=6 T=0
      REG I=2 P=3 P=7 T=1
      REG I=3 P=18 P=16 T=37
      PWR G=6 V=5
      NodeManager v1.6-dev
      LIB R=N T=N A=A S=- B=-
      INT P=3 M=255
      INT P=2 M=255
      RADIO OK
      PRES I=200, T=23
      PRES I=201, T=30
      BATT V=3.34 P=100
      SEND D=0 I=201 C=0 T=38 S= I=0 F=3.34
      PRES I=1 T=6
      PRES I=2 T=7
      PRES I=3 T=16
      READY

      MY I=109 M=1
      ON P=5
      DHT I=1 T=28.90
      SEND D=0 I=1 C=0 T=0 S= I=0 F=28.90
      DHT I=2 H=98.40
      SEND D=0 I=2 C=0 T=1 S= I=0 F=98.40
      BH1 I=3 L=0
      SEND D=0 I=3 C=0 T=37 S= I=0 F=0.00
      OFF P=5
      SLEEP 600s

      AWAKE
      ON P=5
      DHT I=1 T=nan
      DHT I=2 H=98.40
      SEND D=0 I=2 C=1 T=1 S= I=0 F=98.40
      BH1 I=3 L=0
      SEND D=0 I=3 C=1 T=37 S= I=0 F=0.00
      OFF P=5
      SLEEP 600s

      AWAKE
      ON P=5
      DHT I=1 T=28.70
      SEND D=0 I=1 C=1 T=0 S= I=0 F=28.70
      DHT I=2 H=nan
      BH1 I=3 L=0
      SEND D=0 I=3 C=1 T=37 S= I=0 F=0.00
      OFF P=5
      SLEEP 600s

      The Humidity reading of the BHT sensor is a little bit wired, but this is the same with my old sketch (defect?)

      Maybe someone have the right idea????

      Best regards and thanks

      Frank (Betonmoewe)

      posted in NodeManager
      betonmoewe
      betonmoewe