nRF24L01 range test (arduino)

แชร์
ฝัง
  • เผยแพร่เมื่อ 6 ธ.ค. 2014
  • Testing bi-directional transmission between two high-power nRF24L01 radio modules.
    Additional notes:
    A 6 byte packet is sent to the receiver, which bounces the exact same packet back. The transmitter checks the time taken using millis() to determine a 'latency' value. The throughput speed degrades quickly as the packet size grows. 6 bytes is enough for 4 analog channels and 16 binary switches.
    Keep in mind though, this is the round-trip time taken for a confirmed receipt. If you're using one-way communication as would be more typical for RC vehicles, the 'latency' would be much much shorter.
    Messy source: www.iforce2d.net/rf24RangeTest...
    I had a lot of memory issues trying to get the OLED library, TinyGPS++ and the nRF24 library all working together on a 328p, so I have squeezed a lot of variables and extraneous stuff out. You may find that increasing the packet size or even adding a few more variables to the transmitter sketch will give you problems.
  • บันเทิง

ความคิดเห็น • 130

  • @tamarathompson9418
    @tamarathompson9418 6 ปีที่แล้ว +16

    Hi im using your videos (with allot of research ) as a basis to learn how to use arduino to do the things i want to learn and use . I just want to say thanks . Inspiring and so satisfying to watch and learn

  • @shresho2817
    @shresho2817 3 ปีที่แล้ว

    This video is really much more helpful considering it's 6 years old, where both Antenna module and normal module is tested for there ranges. I wanted a comparison so that I can choose the right module for the receiver part, which I didn't find in any video.

  • @RWBHere
    @RWBHere 5 ปีที่แล้ว +3

    In theory, using horizontally polarised antennae on both transmitters and receivers should give you longer, more reliable range. Also consider using a directional antenna on the handheld device. You could use a home-made helix, or a pair of phased, crossed Yagi antennae for the job. Either is easy enough to construct. Tune the array/ helix for the operating frequency, or the middle of the band of frequencies in use.If you want a really simple array, with a few decibels of gain, and less directivity, use a pair of crossed dipoles (sometimes called a turnstile, if phased), still tuned to the operating frequency range. Use of a carefully positioned reflector plate, or better still, a parabola, is also advantageous for gain, but might not be so practical. The 'rubber duck' you used is a low-cost compromise; a zero gain (actually less than zero, because of losses) device, best for short range omnidirectional work. Keep the antenna on the aircraft simple, and omnidirectional, because it will rarely be aligned with the controller!

  • @gizmoguyar
    @gizmoguyar 5 ปีที่แล้ว +1

    I really appreciate the time you put into videos like this. There's no substitute for empirical testing. What I'm trying to figure out, is the behavior/probability of packet loss in only one direction using this setup. i.e. if it were used for an RC aircraft, the aircraft receiving the commands is critical, but the transmitter receiving the ACK is not critical. If I recall correctly, the chips can retransmit up to 15 times if they don't receive an ACK packet. I'm hoping that someone good at statistics can figure out the full relationship, but I'm estimating that at a 50% round trip packet loss, there's only a 3% expected packet loss by the receiving module. This does, of course, assume that the probability of a packet loss is the same for the transmitted payload as well as the ACK packet. But it shows that even with a high % of packet loss as indicated by the transmitting module, you still have quite a good one way communication. I'd really love to test this out empirically as you did in this video. In order to have a measure of RSSI or communication integrity, it would be important to relate the round trip packet loss to the total reduction in communication speed as required by your application.

    • @iforce2d
      @iforce2d  5 ปีที่แล้ว

      The percentage of packets received as a fraction of the total sent is not as important as simply the number received. It seems like many people want to think of the link quality as a percentage as is done with RSSI for analog links. But at the end of the day, 80 packets per second is 80pps regardless of whether it's 80% of 100pps or 25% of 320pps, and the only meaningful (actionable) fact is that you have 80pps to work with. I would not recommend using an ACKed transmission for a lossy connection like R/C control where you want low latency and only the newest packet is important. Most R/C telemetry systems are run on a separate radio link to the direct control. If you're interested in range tests using a non-ACKed one-way transmission I have done a few of those too:
      th-cam.com/video/gtM832Z0ujE/w-d-xo.html
      th-cam.com/video/4XRp7pkZgPM/w-d-xo.html
      As you can see the antenna is very important :)

  • @electronic7979
    @electronic7979 6 ปีที่แล้ว

    Excellent project

  • @buncho888
    @buncho888 9 ปีที่แล้ว

    Very useful stuff. I plan on making a landing beacon with these modules for an autonomous helicopter or quad. Using 1 high powered transmitter as the landing beacon and 2 low powered receivers mounted on the vehicle. These receivers will be placed on either side of the vehicle and angled slightly towards the front. I was hoping these receivers would only work with line of sight at a distance so I could use them as a directional antenna and you've shown that they can.

    • @iforce2d
      @iforce2d  9 ปีที่แล้ว

      I've been looking into RDF techniques a lot over the last few months as well. I'm not so sure it's the best idea for what I'm doing, but for a landing beacon it might work fairly well. The problem is you need to broadcast a carrier wave, which the nRF24s can do apparently, but which stomps on all other 2.4ghz traffic in the vicinity, if I understand it correctly. You might be interested in this project: www.robowarner.com/robot/rdfbotarduino
      And also a question I asked about it here: electronics.stackexchange.com/questions/126120/radio-direction-finding-dependence-on-source-signal-type

    • @iforce2d
      @iforce2d  9 ปีที่แล้ว

      Ah, and also as the answerer mentions, the nRF24s do a lot of processing internally that may prevent you from getting at the basic signal you need. I bought some 433mhz transmitter and receiver modules to try this with eventually, but that frequency requires much larger antennas which is kind of a bummer when you want to put them on a quadcopter :) Most likely, I will end up using those modules as a 'fox' to find a model that has fallen into that thick grass you see in this video.

  • @chriswesley594
    @chriswesley594 9 ปีที่แล้ว +1

    Fascinating stuff, though I have the feeling I landed in the middle of something ongoing, but a question on latency. At these distances, the propagation time of the signal is negligible, so is the increased round-trip time is due to what - the transceivers doing transmit re-tries or something? Thanks.

    • @iforce2d
      @iforce2d  9 ปีที่แล้ว +4

      Exactly correct. The deterioration of signal quality at distance causes more failed crc checks, and more resends. So technically it's not really what 'latency' means but it's still a pretty reasonable term to use I think.

    • @chriswesley594
      @chriswesley594 9 ปีที่แล้ว +2

      *****
      Thanks. My question was for clarification of my understanding, not to criticise the term you used, which seems fine to me.
      PS: I'm looking forward to the other videos in your "cheap arsed" series. The first one was very impressive.

  • @carlosdavila2552
    @carlosdavila2552 7 ปีที่แล้ว

    cool project man

  • @vincewantuten8676
    @vincewantuten8676 6 ปีที่แล้ว

    can you use this for outside, one placed on a post and the other one on a person. when a device is pressed on the person end, the receiver will then be connected to a pc that will produce the persons info ( the one that pressed the device). then it will show the post that received the signal. is it possible?

  • @matthewparsons4955
    @matthewparsons4955 4 ปีที่แล้ว

    The thin connector wire between the receivers 'Duck' antenna and the nRF24L01 will surely lesson range?
    Also running a direct power line (thru 3.3v regulator) from the battery to nRF24. would be better than the Arduino's low power3.3v?
    Just a thought, I'm a NOOB. ;))

  • @VaibhavShelke017
    @VaibhavShelke017 7 ปีที่แล้ว +1

    @iforce2d what GPS module are you using ?

  • @1234thrashmetal
    @1234thrashmetal 3 ปีที่แล้ว

    Nice video, the percentage that you take off on the screen is the signal quality level? How did you get that percentage in the nrf24l01?

    • @iforce2d
      @iforce2d  3 ปีที่แล้ว +1

      I explained at 3:07
      If you send 100 packets per second and you only get acknowledgement for 90, that would be 90%.

  • @tothviktor5825
    @tothviktor5825 ปีที่แล้ว +1

    Hi iforce2d,
    how did you manage to show the distance between transmitter and receiver on the display? I am having a lot of trouble solving this problem. Thanks in advance for your reply.

    • @iforce2d
      @iforce2d  ปีที่แล้ว

      I used a GPS. Just record the location when it was turned on, and then show the difference. www.movable-type.co.uk/scripts/latlong.html

  • @bensge1
    @bensge1 9 ปีที่แล้ว

    Hmm, looks like enough bandwidth to send over some additional data back to the transmitter, every second or so (with the HP modules). Is that what you are going for?

    • @iforce2d
      @iforce2d  9 ปีที่แล้ว

      Yes, the vehicle can send back GPS info about where it is etc. I'll be using it at close range so I should be able to send back a decent amount of data in every packet, rather than just every second or so.

  • @RakshithPrakash
    @RakshithPrakash 4 ปีที่แล้ว +2

    I get a new idea about doing something and i google about it and boom! this iforce2d guy has done it years ago lol.

  • @ahsanfarooqi5663
    @ahsanfarooqi5663 3 ปีที่แล้ว

    Hi good evening. can we measure the signal distance? in arduino using any wireless module? please replay thank you

  • @dkeinys
    @dkeinys 8 ปีที่แล้ว +2

    Hi What can cause range problems?
    all i can get is 2M from me and its just cuts off
    both modules are high power with power adapters
    Regards

    • @42222
      @42222 7 ปีที่แล้ว

      Do you have the types with screw on antenna or just the normal ones?

    • @gregk5505
      @gregk5505 6 ปีที่แล้ว +2

      Maybe because 2.4 GHz is sooooooo crowded that there is a signal drowning yours! That is why I prefer 433 MHz or 915 MHz modules since they are better with obstructions and especially 433 MHz are not nearly as crowded. And if you have modules that can change channels you could use a cheap SDR like the RTL-SDR which only costs $10 but that is a whole different topic.

  • @tambourinemang
    @tambourinemang 8 ปีที่แล้ว

    Have you done a similar test with XBee? If so, how did they compare?

    • @iforce2d
      @iforce2d  8 ปีที่แล้ว

      tambourinemang no, never tried the xbee

  • @goanga3749
    @goanga3749 3 ปีที่แล้ว

    Hello, i'm new to using these nrf24 transcievers and i have a question . I want to use them to build a long range remote control car and i was wondering, will you gain more range if you use one high power nrf24 module for the transmitter and another high power nrf24 for the reciever, instead of using one high power nrf24 for transmitter and one normal pcb antenna for the reciever, the connection will be only one-way. Thank you in advance for the reply ! (i know the video is quite old but i hope you will reply)

    • @iforce2d
      @iforce2d  3 ปีที่แล้ว +1

      If you want any decent range don't use the pcb antennas ones. The "high power" versions usually have a LNA as well, for much better receiving sensitivity.

    • @goanga3749
      @goanga3749 3 ปีที่แล้ว

      @@iforce2d Thank you for the fast reply !

  • @arnzzz1
    @arnzzz1 9 ปีที่แล้ว

    Do you live in Tokyo?
    I thought that was Australia until you said that :)
    Are you a self employed software developer, or do you work for some company in Tokyo?
    Sorry if these are personal questions :(

    • @iforce2d
      @iforce2d  9 ปีที่แล้ว +2

      Yes to all questions :) I do about half my time freelance and the other half work for a company here.

    • @arnzzz1
      @arnzzz1 9 ปีที่แล้ว

      ***** cool, thanks for answering :) good luck with this project.

  • @error346
    @error346 9 ปีที่แล้ว +1

    you did a great job in this video!! but, how did you get the signal quality?? i'm trying to build an tricopter and it could be very useful to get the signal quality to know if i'm going out of range :P
    Thank you so much!!!

    • @iforce2d
      @iforce2d  9 ปีที่แล้ว

      The signal quality is represented by this packets per second number that I spend so much time looking at :)

  • @Bergosaurus
    @Bergosaurus 8 ปีที่แล้ว

    What kind of joystick is it that allows you to move it without resetting back to its original position? (you used it at 2:30~)
    I've been looking for days online trying to find a joystick module that I can use as a throttle for my Arduino project

    • @iforce2d
      @iforce2d  8 ปีที่แล้ว

      +Scott TheBot it's a gamepad controller joystick that I removed the springs from

    • @Bergosaurus
      @Bergosaurus 8 ปีที่แล้ว

      Oh wow I never thought of doing that. Thanks! (would love a video on this if you're short on vid ideas :P)

    • @Bergosaurus
      @Bergosaurus 8 ปีที่แล้ว

      Haha never mind I found the video where you do it :P

  • @rahmatabdurrahim7789
    @rahmatabdurrahim7789 4 ปีที่แล้ว

    hi, how you make your range measurement sir? do you have any tutorial to make that range measurement sir?
    thank you so much

    • @iforce2d
      @iforce2d  4 ปีที่แล้ว

      struct geoloc {
      float lat;
      float lon;
      geoloc(float x = 0, float y = 0, int32_t a = 0) { lat = x; lon = y; }
      };
      // www.movable-type.co.uk/scripts/latlong.html
      float geoDistance(struct geoloc &a, struct geoloc &b) { // meters
      const float R = 6371000; // km
      float p1 = a.lat * DEGTORAD;
      float p2 = b.lat * DEGTORAD;
      float dp = (b.lat-a.lat) * DEGTORAD;
      float dl = (b.lon-a.lon) * DEGTORAD;
      float x = sin(dp/2) * sin(dp/2) + cos(p1) * cos(p2) * sin(dl/2) * sin(dl/2);
      float y = 2 * atan2(sqrt(x), sqrt(1-x));
      return R * y;
      }

  • @kareemahmed8814
    @kareemahmed8814 9 ปีที่แล้ว

    any idea about the range without the antenna ? or would it even work without it ?

    • @iforce2d
      @iforce2d  9 ปีที่แล้ว +1

      You would most likely fry the chip if you ran it without the antenna for any length of time. So I guess you could say it would work, for a while :) Range with no antenna would probably be about 15 meters (just a guess).

  • @jijeshkorothpoyil2697
    @jijeshkorothpoyil2697 4 หลายเดือนก่อน

    What is minimum guaranteed distance for pa+lna modules when operated in non line of sight scenarios having obstructions and vegetations in the direct path when used in lowest possible data rate ?

    • @iforce2d
      @iforce2d  4 หลายเดือนก่อน

      There are no guarantees, especially in non-line-of-sight situations. Also, this is not a simple yes/no thing to answer, because you can still get some packets even with obstructions - the question is whether it's sufficient for what you're doing. For example a balloon tracker might be ok with a few packets per minute, but flying a fast FPV drone will need 50 or more per second with good consistency. So you will just have to try and find out for your situation.

    • @jijeshkorothpoyil2697
      @jijeshkorothpoyil2697 4 หลายเดือนก่อน

      HC -12 433mhz serial module has 100mW transmission power and maximum range more than 1km line of sight.
      But STX882 is saying also 100mW(max 20dBm@5v) in their datasheet but is saying only100 metre range in open field
      Why ?
      Both are 433mhz and of same rf power and also stx882-srx882 pair is of lower data rate

    • @iforce2d
      @iforce2d  4 หลายเดือนก่อน

      I have no idea about those, never used them. Try asking me a question related to this video. Maybe they have different antennas, or one has a PA/LNA and the other doesn't, or maybe one is exaggerating to make more sales.

  • @A1yazAhmad
    @A1yazAhmad ปีที่แล้ว

    Hey, i just wanna test my antenna using these modules can i replace the antenna provided with 14 dbi patch antenna?

    • @iforce2d
      @iforce2d  ปีที่แล้ว

      Should be fine. I have used large yagi antennas with these and they worked great, look around for some of my other videos about it.

  • @peterkarstensen3720
    @peterkarstensen3720 8 ปีที่แล้ว +1

    Hey
    Where have you bought your nRF24L01 modules?

    • @iforce2d
      @iforce2d  8 ปีที่แล้ว

      +Peter Karstensen usually from here: goo.gl/Urax2F
      or here: goo.gl/y5h5v2

    • @peterkarstensen3720
      @peterkarstensen3720 8 ปีที่แล้ว

      +iforce2d
      Cool. I was just wondering if the modules from China were good and working right, since I had some troubles with other wireless modules from China. I'm buying mine from miniinthebox.
      Very good video by the way!

  • @EvopicsDe
    @EvopicsDe 8 ปีที่แล้ว

    there is a "RAW"-Pin on the pro mini, so you dont need a voltage regulator.

    • @iforce2d
      @iforce2d  8 ปีที่แล้ว +3

      +muddanundvoddan the voltage regulator is for the nRF24 module, it takes 3.0v

  • @8829david
    @8829david 9 ปีที่แล้ว

    What is the hight-power reciver is this one: nRF24L01 (Second 11:16 of your video)

    • @iforce2d
      @iforce2d  9 ปีที่แล้ว

      goo.gl/hYkCqg

    • @8829david
      @8829david 9 ปีที่แล้ว

      ***** Thank you a lot!!

  • @tropicaljantie
    @tropicaljantie 7 ปีที่แล้ว

    specs of this antenna?

  • @CoderTronics
    @CoderTronics 9 ปีที่แล้ว

    Hi,
    Thanks for sharing the video, you mention you were testing some single direction (removing the ACK function) data test with a high power master module and a basic nRF24L01+ module. Did you carry out any range tests on this?
    Regards,
    Ant

    • @iforce2d
      @iforce2d  9 ปีที่แล้ว

      I think theoretically the range should be the same if the receiver was not a high-power module, provided you were using the same antennas. I have not come across any basic modules that have an external antenna connection to try it though. I have flown my quadcopter up to about 200m with a basic module receiver and a whip antenna on the transmitter, is about all I can say for sure.

    • @CoderTronics
      @CoderTronics 9 ปีที่แล้ว

      ***** Hi,
      Thanks for the prompt reply. Your quadcopter test sounds promising and stands to reason that a amplified Master sending omni-directional traffic to a basic low power receiver, will extend the range. I am only interested in 80m range in open air and flat terrain, however the receiver will be on the ground elevated by about 10cm.
      Cheers,
      Ant

    • @iforce2d
      @iforce2d  9 ปีที่แล้ว

      Ant Scranney
      I should probably mention, 200m is where it crashed :) so that's probably the absolute upper maximum. 80m at such a low elevation is probably pushing it as well (the quadcopter had very clear line-of-sight). Anything you can do to improve the antenna situation will help a great deal though.

  • @EdwarRinaldo
    @EdwarRinaldo 6 ปีที่แล้ว

    why your left joystick can like that, not return to center position ? where are you have bought it ? thank you

    • @iforce2d
      @iforce2d  6 ปีที่แล้ว

      I removed the spring.

    • @EdwarRinaldo
      @EdwarRinaldo 6 ปีที่แล้ว

      what the right to left and left to right axis is still use after that ?, i want to make like that, but i want to make the yaw ini my radio control prototype... thank you

    • @EdwarRinaldo
      @EdwarRinaldo 6 ปีที่แล้ว

      may i know the step to remove the spring ?

    • @iforce2d
      @iforce2d  6 ปีที่แล้ว

      No springs anymore. So it just stays where ever you move it to.

    • @EdwarRinaldo
      @EdwarRinaldo 6 ปีที่แล้ว

      thank you so much

  • @amjadali7691
    @amjadali7691 3 ปีที่แล้ว

    i need very simple seniro just calculate the distance using NRF24 without lcd or ps

  • @yxhankun
    @yxhankun 2 ปีที่แล้ว

    the messy source is also point back to this clip.

    • @iforce2d
      @iforce2d  2 ปีที่แล้ว

      It's a conspiracy!

  • @myildirim
    @myildirim 8 ปีที่แล้ว

    Hi, I wanna send instructions to my dog with this device. What is the effective urban range to send and receive instructions ? There will be houses / trees/ cars etc between the transmitter and the receiver ? How much range can we get with this ? If its not an efficient way, which other devices can i use to send and receive information ? I'm thinking about doing a device to send instructions to my dog to buy a pack of beers from the local convenience shop :) So there will be a buzzer, gps and microcontroller with wireless transmission ability.

    • @iforce2d
      @iforce2d  8 ปีที่แล้ว +1

      +M. Yıldırım I've only tested the clear line of sight (as much as possible) so I wouldn't really know what the results would be through buildings etc. It would depend on what the buildings are made of, how tall and what's in them. I would guess the range would be cut to half, maybe even less than half.

    • @myildirim
      @myildirim 8 ปีที่แล้ว

      +iforce2d well i would die to get a 100 m coverage in cbd area between the concrete buildings taller than 10 floors. :( hope it covers

    • @iforce2d
      @iforce2d  8 ปีที่แล้ว +1

      +M. Yıldırım I think 100m would be no problem. Then again, it would not take long to walk that far and the beer would not be as shaken up as your dog will make it :)

    • @42222
      @42222 7 ปีที่แล้ว

      maybe you could find modules with lower frequency because the lower the frequency the better it is able to penetrate through buildings etc...

  • @sanu7210
    @sanu7210 5 ปีที่แล้ว

    If i installed bigger antena is it effects mt nrf24l01 module

    • @iforce2d
      @iforce2d  5 ปีที่แล้ว

      I think as long as the antenna has the correct impedance (50ohm?) it should be ok.

    • @sanu7210
      @sanu7210 5 ปีที่แล้ว

      @@iforce2d no in my walki talki project i use NRF24LO1+pla+pa antena module and i attached 2 antena i dont know its effect my nrf or not

  • @tropicaljantie
    @tropicaljantie 7 ปีที่แล้ว

    adding a reflector does that help

    • @iforce2d
      @iforce2d  7 ปีที่แล้ว

      Only if you get it exaaactly right, otherwise it can make things worse. I wouldn't bother with it.

  • @caracasultrarunners
    @caracasultrarunners 7 ปีที่แล้ว

    Friends, thank you for your videos, excellent. I proposed to my university project similar to what we present..
    I have two Arduino Nano 3.x (ATmega328), each has connected a nRF24L01. One acts as transmitter and the other as receiver.
    The receiver has connected a uOLED-96-G1. My questions:
    It is possible with this infrastructure in uOLED-96-G1 can observe distance (yards or meters) between the transmitter and receiver ?. I do not have a TinyGPS.
    How do I know the distance between the transmitter and the receiver without having a TinyGPS?.
    Please help me, thanks for your replies

    • @iforce2d
      @iforce2d  7 ปีที่แล้ว +1

      Maybe take a look at google maps and measure the distance? Use a laser range finder? Measure it with a surveyor's wheel? It's just a simple distance measurement, there are many ways to do it without a GPS.

    • @caracasultrarunners
      @caracasultrarunners 7 ปีที่แล้ว

      Ok, thanks, but if I have only arduino nano+nRF24L01+uOLED96G1, no more, is possible with this infrastructure observe distance (yards or meters) between the transmitter and receiver ? or see in the oLED96G1 if the intensity of the transmitter signal is high or low?

    • @iforce2d
      @iforce2d  7 ปีที่แล้ว +1

      Of course you can display radio intensity on the screen, but I don't see how you can measure distance with only a radio module and a screen :)

    • @caracasultrarunners
      @caracasultrarunners 7 ปีที่แล้ว

      good, very good, thanks for you replies, congratulation for you videos...

    • @42222
      @42222 7 ปีที่แล้ว +1

      You could calculate the distance between the two by measuring how long it took the signal to to travel, wich will be at light speed. The Distance is speed of light times the duration it took to travel.... They use this method to calculate position in gps systems.

  • @JulianIlett
    @JulianIlett 9 ปีที่แล้ว +8

    When you held the transmitter near your computer and could hear the transmissions, what's the gap? Is it the time it takes to update the OLED?

    • @iforce2d
      @iforce2d  9 ปีที่แล้ว

      Yes. I'm running the radio transmission + timing for one second, then displaying the screen.

    • @JulianIlett
      @JulianIlett 9 ปีที่แล้ว +1

      I'm finding the Adafruit OLED library very slow to write to the display. I'm doing some tests on both the SPI and I2C types. The library also uses a lot of memory.

    • @iforce2d
      @iforce2d  9 ปีที่แล้ว +1

      Julian Ilett
      Yeah, I find myself using the "measure for one second and then display" method for quite a few things where measurements are time-sensitive, and the memory use is a bit of a bummer too. These little screens are still pretty cool though :)

  • @N.g.Chanal
    @N.g.Chanal 3 ปีที่แล้ว

    you must use lcd display out side of home for clear vison. this my free advise..

    • @VoidNumber
      @VoidNumber 2 หลายเดือนก่อน

      this dude no need advces

  • @neerajtenthouse-gosaipurse1190
    @neerajtenthouse-gosaipurse1190 5 ปีที่แล้ว +1

    Hii sir,
    sir, i am Sending a data from ( NRF24L01 transmitter) to ( NRF24L01 Receiver ) Using Aduino Uno.
    but i want to put its Nodes 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
    i had also attached my code below , Sir 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);
    }
    }
    }

  • @CYBER4NARCHIST
    @CYBER4NARCHIST 7 ปีที่แล้ว

    Yea those rubber ducky antennas are never famous for their range. They look great and get the job done though.

  • @Diymakervn
    @Diymakervn 2 ปีที่แล้ว

    I need the code, tks!

  • @lmhfd2573
    @lmhfd2573 2 ปีที่แล้ว

    Apakah ada tutorial ini?

  • @d_z_a_i_r_o
    @d_z_a_i_r_o 9 ปีที่แล้ว

    Hi. I look to your video .. I try module nRF24L01+PA+LNA .. but still have distance around 30m .. no more .. use ATmega328p , internal 8Mhz RC , for firmware use MySensors.org , gateway use 3.3V from USB + big capacitor .. in sensor is used ATmega328p , 8Mhz internal RC , 2xAA battery , both board use nRF24L01+PA+LNA with big capacitor.. still have range around 40m .. no more .. use standard antenna from WIFi router.. any idea why have this trouoble ..??? best regards..

    • @iforce2d
      @iforce2d  9 ปีที่แล้ว

      I still have not managed to get a reliable connection, I guess this was a lucky day. There seems to be a very annoying habit for these things to work very well one day, and then the next day they are terrible. My "cheapass transmitter" currently gets about 10-20m range, but previously it was getting 300m, and I don't really know why, I've tried all the tips that I've heard about.

    • @d_z_a_i_r_o
      @d_z_a_i_r_o 9 ปีที่แล้ว

      ehm.. that means .. right now you also have only short range ??? what module you tested?? what PA setting you have (+0dB) set in nRF register? you tested it in video longer time .. and get very good data what happened ? I ry contact manufacturer .. but not respond .. in one forum I find interesting information ... some chip have maximum power output +5dB .. but if want use with external PA (around +20dB) then must use seting for +0dB only .. if not then damage external PA .. I tested my module with maximum output power in nRF register.. all saler say 1100m with 250kbp .. but if ask for schematic .. or more information .. then no one have it ..
      best regards

    • @iforce2d
      @iforce2d  9 ปีที่แล้ว

      Ševc Dominik As said, I had 300m and then only about 20m, without changing anything. I don't really have anything useful to help you unfortunately.

    • @d_z_a_i_r_o
      @d_z_a_i_r_o 9 ปีที่แล้ว

      ***** Hi. hehe.. I do right now big test ... I do this .. in nRF24L01 setting register set output power to -12dB and free area have more then 1000m ... to this time I test only with +0dB setting .. now working .. (range around 40m) .. but now set - RF_PWR set to -12dB .. and have 600m in free area (no buildiing around) .. but I tested with external PA only in one side .. not tested with external PA in both side.. later make bigger test.. regards..

    • @d_z_a_i_r_o
      @d_z_a_i_r_o 9 ปีที่แล้ว

      Ševc Dominik ..ehm I forgot..look at this : similar chip (is possible replace with nRF24L01+) www.inhaos.com/product_info.php?products_id=35 and have maximum output +5dB .
      but better with SMA connector .. to connet standard antenna.
      best regards

  • @fork04
    @fork04 9 ปีที่แล้ว +1

    Change the camera please !

  • @surenbono6063
    @surenbono6063 9 หลายเดือนก่อน

    ...a simple non-spi hc-12 gives better ranges...

    • @iforce2d
      @iforce2d  8 หลายเดือนก่อน +1

      This video was made in 2015. With the right antenna and conditions these radios can do 35km or more. But yes, there are probably hundreds of systems out there with better range.

    • @surenbono6063
      @surenbono6063 8 หลายเดือนก่อน

      @@iforce2d ... can't we do it on other pin instead of the SPI...I might need the SPI for display or other modules..what about the i2c bus instead..apart from the slower UART..in i2c you have specific module addressed..

    • @iforce2d
      @iforce2d  8 หลายเดือนก่อน +1

      nRF24 is an SPI device, you don't get to decide that. With SPI you can use the 'slave select' aka 'chip select' line to switch between devices on the bus, a bit like I2C addressing but faster, and needs an extra wire.

    • @surenbono6063
      @surenbono6063 8 หลายเดือนก่อน

      ... ok.. but I need the display for a led matrix that occupy the SPI ... so I'm testing a UART hc-12 ... also wandering if there is any rf modules for i2c.. where I could daisy chain modules on a i2c bus .. which is simpler & addressed..

    • @surenbono6063
      @surenbono6063 8 หลายเดือนก่อน

      ... so I tested range with piezo & tested msg with moving target.. I found that there was more error or noise on the msg received while moving than a stationary reception ...