Building a Wireless Sensor Network with the nRF24L01 Part 1

Поделиться
HTML-код
  • Опубликовано: 6 дек 2015
  • This is part 1 in a series where we look at how to build a large wireless network using Arduino and the nRF24L01+ Transceiver Modules. At the end of this series you will have a reference design for a wireless sensor development board and the code needed to turn the wireless sensor developments boards into a network. You will be able to purchase all the hardware for this project at my site: www.forcetronics.com

Комментарии • 59

  • @davidjenkins8675
    @davidjenkins8675 8 лет назад +1

    I like the style of the lesson. The board that Forcetronics sell have worked flawlessly.

  • @BGLENN-dp4tx
    @BGLENN-dp4tx 5 лет назад +2

    GREAT video. Thanks. Hopefully the sequence continues... will check.

  • @jeffreyriedel
    @jeffreyriedel 4 года назад +1

    Thank you for posting your videos, very clear explanations.

  • @deangreenhough3479
    @deangreenhough3479 8 лет назад +2

    Looking forward to this series

  • @jpalm32
    @jpalm32 8 лет назад +1

    Very interesting project!

  • @vzveki
    @vzveki 8 лет назад +1

    Looking forward to part 2 :D

  • @yahayaabubakar2699
    @yahayaabubakar2699 5 лет назад

    Hey! I want to use a float sensor instead of the temp sensor, I'm having challenges incorporating GSM module to the WSN. Need help

  • @MrBobWareham
    @MrBobWareham 6 лет назад

    Thank you for the introduction I would like to make a door detector for my front door and also a door detector my workshop to notify me if the doors have been opened and closed with times and to email my phone, any suggestions would be good thanks Bob

    • @ForceTronics
      @ForceTronics  6 лет назад

      I would probably use a WiFi module like the ESP8266 or MKR1000. Combine with an IoT cloud platform like ThingSpeak (I have a video on ThingSpeak ruclips.net/video/X4r3QCaujOk/видео.html)

  • @vincewantuten8676
    @vincewantuten8676 6 лет назад

    sir need help!! im going to build a network where there will be nrf receiver in a lamp post and people in our community will be given a device with nrf also as a transmitter and everytime a person pressed a button on a device and they are on range with one of the lamp post with a nrf receiver, it will then send a message to a server pc and then the pc will show the info of the person who pressed the button and then it will show the lamp post that received the signal. how to do the network of the transmitter and receiver?? need help T.T

  • @mohammedzaman1937
    @mohammedzaman1937 6 лет назад

    i am trying to build a arduino/nFR24L01 with temp sensor so that at a particular set temp it sends a single to another arduino/nFR24L01 with relay to turn on a cooler/heater. what is your thoughts? thanks btw great presentation.

    • @ForceTronics
      @ForceTronics  6 лет назад

      What you are planning should be possible with Arduino and nRF24L01 transceivers

  • @vladimirzz93
    @vladimirzz93 8 лет назад

    Hello, I was wondering if I can use this modules to create a network in a star topology. What do you think about having 6 remote modules which are sending data to a main module? all of this modules are going to be connected to an arduino nano. What would yo recommend me? because I also was taking a look to the esp8266 modules, which one is better and great for the job?. Thank you so much. Cheers.

    • @ForceTronics
      @ForceTronics  8 лет назад

      You could configure these in a star configuration, but if you want leverage the RF24Network library you would have to have some of the modules communicate through a router because it does not support 6 end devices talking directly to the master. I have not used the ESP8266 so I can't comment there.

  • @murthynittala4934
    @murthynittala4934 6 лет назад

    Can I make 30 nrf24l01 Transmitters to communicate with 1 nrf24l01 receiver acting as a controller???

  • @BGLENN-dp4tx
    @BGLENN-dp4tx 5 лет назад +3

    13:37 typo correction from "Mainicbug" to "Maniacbug" .. (future reference)

  • @Bob-mp4sb
    @Bob-mp4sb 6 лет назад

    hello is there any alternative to the nRF24L01 shield for arduino or is it compulsory to use it in building a wireless network? because i live in Malaysia and i have a project similar to multi receiver. and i don't think the shield is available anywhere around. thanks

    • @ForceTronics
      @ForceTronics  6 лет назад

      The shield is not required to make the network work

  • @kumarjha1729
    @kumarjha1729 5 лет назад

    Hi can you provide me a ZigBee or other modules which support beacon, i.e. I want Guaranteed Time slot for different sensor nodes. In your video sensors nodes 1,2,3 and 9 data is not appearing in sequence.

  • @S0K0N0MI
    @S0K0N0MI 4 года назад +2

    Your house must be fun for the neighbors WiFi. :')

  • @hobbylab9362
    @hobbylab9362 7 лет назад

    Hi, i have followed your tutorials, but I'm having an error with the library "RF24Network" I downloaded the library in the link of the code but I have 2 errors, one in the function "WSNode :: setSleepInterval (unsigned char)" and another in the function "WSNode :: goToSleep ()", you could help me?

    • @ForceTronics
      @ForceTronics  7 лет назад

      Did you enable AVR sleep capability in the library config file? I show that in the part 6 video.

  • @robotynokia
    @robotynokia 7 лет назад

    I like your video
    But my problem is different, I want to extend the range of wifi inside the
    building / house. I am developing home automation using wifi.
    There is no video on you tube , on this topic.

  • @cravecode1742
    @cravecode1742 8 лет назад

    I just started watching these videos so I may not have gotten to the topic yet. Do you plan on using any encryption?

    • @ForceTronics
      @ForceTronics  8 лет назад

      +Cravecode Great question. No plan to get into encryption since this is just for home hobby use. But definitely an important aspect for commercial applications. A great future tutorial to look into.

    • @cravecode1742
      @cravecode1742 8 лет назад

      +ForceTronics Thanks for the response and the videos! I am planning on making a Wifi bridge via a ESP8266 for nRF24L01 nodes at my house. I'm making the bridge a MQTT broker for the nRF24L01 nodes. I'm in the encryption planning process now. I would love to hear suggestions from others.

  • @Dharmendrasavaliya012
    @Dharmendrasavaliya012 7 лет назад

    Hello sir
    Is NRF network compitible & reliable for home automation ?

    • @r.n.f.5428
      @r.n.f.5428 6 лет назад

      Please, I ask him also same question

  • @saajidthakur6027
    @saajidthakur6027 2 года назад

    Two set of network nrf24 overlapping, if node00, node01, node011 same.
    Is there any unique pipe address as nRF24 ?
    Kindly help

    • @ForceTronics
      @ForceTronics  2 года назад

      Setting different pipe addresses creates separate networks that can't communicate with each other

  • @neerajtenthouse-gosaipurse1190
    @neerajtenthouse-gosaipurse1190 5 лет назад

    Sir i want to make address of five digit Integer number
    like-
    this_Node = 31211 :
    Node1= 31222 :
    So, What i have to do sir
    or what are the changes i have to do,

    • @ForceTronics
      @ForceTronics  5 лет назад

      Either append the five digits to the long address that the Nordic hardware requires or embed the 5 digit address in the data packets

    • @neerajtenthouse-gosaipurse1190
      @neerajtenthouse-gosaipurse1190 5 лет назад

      sir, i am Sending a data from ( NRF24L01 transmitter) to ( NRF24L01 Receiver ) .
      but i want to put its ADDRESS in DECIMAL format
      like - ( this_Node = 12345 , Other_Node = 31296 ) .
      but the problem is.... , in Decimal format addressing , Data is unable to Send in my code . ( i think there is Addressing problem in my Code ) .
      I Had mail you my codes on your email - forcetronics@gmail.com
      i had attached my code , please Help me to Correct the Code .
      i will be too much thankful for your Help & Suggestions
      ....................................................................
      TRANSMITTER CODE
      ....................................................................
      #include
      #include
      #include
      #define button 2
      RF24 radio(10,A1);
      int buttonState = 0;
      RF24Network network(radio);
      const uint16_t this_node = 12345;
      const uint16_t other_node = 31296;
      void setup()
      {
      Serial.begin(500000);
      SPI.begin();
      radio.begin();
      network.begin(90,this_node);
      pinMode(button,INPUT);
      }
      void loop(){
      network.update();
      //---------TRANSMITTING----------//
      RF24NetworkHeader header(other_node,DEC);
      unsigned long buttonState = 311;
      bool ok = network.write(header,&buttonState, sizeof(buttonState));
      Serial.println(buttonState);
      }
      ............................................................................................
      RECEIVER CODE
      .............................................................................................
      #include
      #include
      #include
      #define led 3
      #define led2 4
      RF24 radio(10,9);
      byte guest=0;
      //#define buttonState1 8
      const int buttonState1 = 311;
      RF24Network network(radio);
      const uint16_t this_node = 31296;
      const uint16_t other_node = 12345;
      void setup()
      {
      Serial.begin(500000);
      SPI.begin();
      radio.begin();
      network.begin(90,this_node);
      pinMode(led,OUTPUT);
      pinMode(led2,OUTPUT);
      }
      void loop(){
      network.update();
      //---------RECEIVING 1 ----------//
      while( network.available() ) {
      RF24NetworkHeader header;
      unsigned long buttonState;
      network.read(header,&buttonState, sizeof(buttonState));
      Serial.println(buttonState);
      if(buttonState1==buttonState)
      {
      digitalWrite(led,HIGH);
      digitalWrite(led2,LOW);
      }
      else
      {
      digitalWrite(led2,HIGH);
      digitalWrite(led,LOW);
      }
      }
      }

  • @citizenresurrection8705
    @citizenresurrection8705 4 года назад

    I want to take cheap smart phones active them wire them to a motion sensor and a bluetooth speaker and or a microphone from a bluetooth device powered buy dollar store portable power supply and operate it from my cellphone. Is that possible and how hard would that be?

  • @marredcheese
    @marredcheese 8 лет назад

    Great videos. Regarding measuring the battery voltage with the voltage divider, I have a couple of questions:
    1) With such large resistors, do you have to worry about the measurement getting distorted by forming a secondary voltage divider with the internal impedance of the chip? If not, could those resistors be even higher to save power? (You're losing 13 microamps 24/7 to the divider.)
    2) Why didn't you use the technique that doesn't require a voltage divider at all to measure the battery's voltage, as in your video, "Utilizing the Arduino ADC Internal Reference." Is it because you came up with that after making these nRF24L01 videos? Is there any advantage to using the divider?

    • @ForceTronics
      @ForceTronics  8 лет назад

      +marredcheese I did take into account forming a secondary voltage divider with internal Z. If you watch later in the series I move away from the divider approach and use a method where I set the battery voltage as the ADC reference and measure the 1.1V reference.

    • @marredcheese
      @marredcheese 8 лет назад

      +ForceTronics Oh, ok. I'll go with the non-voltage-divider approach too then. Thanks!

  • @soorajjp1847
    @soorajjp1847 7 лет назад

    Guys can i have more than 6 NRF24L01 modules to communicate with each other. I know that it has 6 pipes and it can receive data from 6 pipes. But in my case i want all of them to transmit and receive in same pipe because the communication will happen at random and i cant specify when i will receive data from which transmiter. All the deveices will act as both transmiter and receiver. So Is it possible.

    • @ForceTronics
      @ForceTronics  7 лет назад

      If you watch this series there is an Arduino Open Source library called RF24Network that allows you to build large networks of nRF24L01. You can't have each node speak to any other node, but you can have each node talk to the coordinator and then have the coordinator send it out to the rest.

    • @soorajjp1847
      @soorajjp1847 7 лет назад

      Well i want to implement this modules and communicate between them for 10 vehicles. When any one of this vehicles comes in range with other vehicle they will share data with each other. So it is random can't say which vehicle will come in contact and when. So i cant make this type of complex network. Is there any way

    • @ForceTronics
      @ForceTronics  7 лет назад

      I am sure there is a way but the nRF24L01 is probably not the best platform for this application. I would recommend looking around at the major communication IC vendors and seeing what they have to offer. If the vehicles are in an area where there is cell coverage you could use GPS and the cloud so the vehicles can track when they are close enough to talk and then communicate. But that is a lot of work and you may want to put in some research hours to investigate an easier approach.

    • @soorajjp1847
      @soorajjp1847 7 лет назад

      thnx for info. Wat abt Xbee and HC-12 modules. Will they work

  • @nghiapham7255
    @nghiapham7255 8 лет назад

    lòng nhân từ để liên kết mã nguồn, cảm ơn rất nhiều

  • @avijitdas6872
    @avijitdas6872 4 года назад

    Voltage divider is wrong, currently it divides by 5, use 150K in place of 200K

  • @barthaezeleer2483
    @barthaezeleer2483 3 года назад

    just found this video, looks a lot like mysensors.org

  • @billysbikes8671
    @billysbikes8671 4 года назад

    maniacbug not manicbug!

  • @Corgitronics
    @Corgitronics 8 лет назад +1

    Good timing on the project. This is similar to some wireless nodes I have been working on, but I didn't plan on a multi-level network.
    I've been doing a lot of power consumption measurements, with a new report coming out soon showing long-term consumption. I look forward to seeing your performance using a coin cell.
    Is it really reporting the number in hex? So, where you print node 2 it's really 0x02, and it prints 9 but it's really 0x11 ? You could just print the hex value instead of the integer.

    • @ForceTronics
      @ForceTronics  8 лет назад

      +Corgitronics If your power consumption readings come out good please share some insight into your setup. I was thinking that it maybe a conversion thing, but 0x11 hex is 17 decimal not 9.

    • @Corgitronics
      @Corgitronics 8 лет назад

      +ForceTronics That's what I get for writing a reply late in the evening...
      Perhaps he is using only 3 bits per digit? But, that's really reaching, and I see no reason why to do that.
      I look forward to your next videos and I'll let you know how my power consumption results turn out.

    • @ForceTronics
      @ForceTronics  8 лет назад

      I wouldn't be surprised if it was some issue like that or a type conversion issue. Sounds good!

    • @woodworkingsmarter8241
      @woodworkingsmarter8241 8 лет назад +1

      +ForceTronics From memory reading the ManiacBug Github some time back, the Station IDs are Octal and 11 = 9 dec. You are about two weeks ahead of me on a very similar project so will be watching closely. For now I will stop work on that and go back to developing the windows software front-end to control Station 00.

    • @ForceTronics
      @ForceTronics  8 лет назад

      +SMTPFancy Gateway Thanks that makes sense. What is the plan for the Windows front-end software? What communication interface are you picturing between 00 and windows machine?