Navigation

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

    Topics created by yourry

    • yourry

      Array in send message command
      Development • • yourry  

      3
      0
      Votes
      3
      Posts
      29
      Views

      yourry

      Great, thanks for your reply and help. I was able to do what I wanted, I give you some code snippets to make several messages via a for loop, I'm not a code proffesional but this works: // Initialize messages MyMessage msgInA(0,V_CURRENT); MyMessage msgWhA(0,V_WATT); #define NSENSORS 6 //used current sensors void setup() { //initialize energy monitor CurrentSensor for (int i=0; i<NSENSORS; i++) { wh[i] = { 0.0 }; //initialize wh lwhtime[i] = {0}; //initialize time present(i, S_MULTIMETER); } for (int i=0; i<NSENSORS; i++) { present(i, S_POWER); } } void loop() { for (int i=0; i<NSENSORS; i++) { send(msgInA.setSensor(i).set(Irms[i], 1)); send(msgWhA.setSensor(i).set(wh[i], 1)); } } Thanks
    • yourry

      void receive not work with RelayActuator.ino ?
      Troubleshooting • • yourry  

      5
      0
      Votes
      5
      Posts
      53
      Views

      skywatch

      @Yveaux I'm sure it's in the forum posts somewhere but I don't have time to look for it. Maybe you could do a list of what is and isn't possible in void receive to mitigate further confusions?