Forum Rule: Always post complete source code & details to reproduce any issue!
Results 1 to 8 of 8

Thread: Teeny based full featured radio control system

  1. #1
    Junior Member
    Join Date
    Jan 2021
    Location
    London England
    Posts
    19

    Teeny based full featured radio control system

    Hello!

    This is my first post - so I hope I do it right!
    I知 developing a full featured radio control system for models and I知 wondering if anyone else is interested.
    I知 using Teeny 4.1 in the transmitter, and a Teensy 4.0 in the receiver. I use a clone version of the nRF24L01+ transceivers, which is screened and
    Much more powerful than the original, giving a range of about 2 kilometers.
    The features I致e implemented so far are:
    8 channels
    4 flight modes
    User definable 5 point curves on all channels and modes.
    FHSS with my own method of identifying and avoiding busy channels in real time.
    16 mixes
    99 model memories
    TX Modes 1 and 2
    Timer
    Binding
    Full waveband graphic scanner.
    Telemetry
    Four Definable three-way switches.
    GUI on a Nextion 5 screen.
    PID gains editor - on the transmitter.
    So far, I致e flown some planes and a quadcopter with it. No problems.
    I知 now refining the PID stabilisation because I want it to be also a flybarless system for helicopters.
    Later I壇 like to add Gps, autopilot, and waypoint/return to home functionality.
    It痴 a perfect lockdown project.
    I知 considering making it open-source, and this really depends on whether anyone is interested.
    Ultimately it might equal or exceed commercial offerings, while being significantly cheaper to put together, and infinitely flexible as we have the source code.
    Oh - and huge fun of course.
    Is anyone interested?
    Malcolm Cassan Messiter
    Attached Thumbnails Attached Thumbnails Click image for larger version. 

Name:	20301FC1-AC2C-4E7F-9476-387D36E99448.jpg 
Views:	38 
Size:	122.2 KB 
ID:	23122   Click image for larger version. 

Name:	265D04FF-96C4-4013-A433-F42133F1254E.jpg 
Views:	42 
Size:	84.7 KB 
ID:	23125  


  2. #2
    welcome home, looks impressive, i'm sure someone will take advantage of any code /designs you make available.

  3. #3
    Member
    Join Date
    Jan 2020
    Location
    Port Elizabeth
    Posts
    71
    I am impressed by the ambitious scope of your project and by how much you have done so far.
    I’m considering making it open-source, and this really depends on whether anyone is interested.
    That is much recommended. The motto of a former boss was 'lead and others will follow'.
    Oh - and huge fun of course.
    The best reason of all. This kind of enthusiasm motivates all the best projects.
    Is anyone interested?
    We always learn from the way other people do things.

  4. #4
    Member
    Join Date
    Aug 2019
    Location
    Bucharest, Romania
    Posts
    86
    I am also interested if this will be open source.
    Also, how did you increase the range of the NRF module?

    Thanks.

  5. #5
    Junior Member
    Join Date
    Jan 2021
    Location
    London England
    Posts
    19

    nRF24L01 clone range.

    Quote Originally Posted by guzu View Post
    I am also interested if this will be open source.
    Also, how did you increase the range of the NRF module?

    Thanks.
    Hi!

    I did a series of range tests after buying many of these nRF24L01 transceivers from many sources, and making them 叢lug in to female headers on my circuit boards. I quickly learned that they vary enormously in several ways. Almost all of them work ok at very close range. Some fail after only a very few yards. Some go on working at 2 km. I have attached an image of my preferred type. These are encased in a metal screen. Here痴 a quote from their marketing specifications:

    鉄pecifications:
    Item Type: Wireless RF Module
    Model Number: nRF24L01P
    Default: 2.4GHz (16MHz oscillator)
    Working Frequency: 2400-2525MHz
    Transmitting Power: 20dBm
    Communication Distance: 2500m <覧覧 !!!!! 😳😃
    Communication Interface: SPI
    Package Type: DIP
    Air Data Rate: 250K-2Mbps
    Power Supply Voltage: 2-3.6V DC
    Transmitting Current: 130mA
    Sensitivity: -95dBm
    Wireless Type: SMA-K
    Material: Circuit Board
    Size: 33.4x18mm/1.3x0.7in
    Color: As shown
    Quantity: 1 Pc

    My tests confirm a real-world range of about 2km which I think is plenty for line of sight rc models. They are very cheap, so I have bought dozens. Production seems inconsistent probably because they池e so cheap. So I suggest test each one. Several I have thrown into the bin.
    I知 not an expert in any way. I知 an oboe player. But I致e learned a bit during lockdown just by experiment. I知 impressed by these chips especially when using Teensy because they池e so fast. I tried at first with an Arduino. This worked, but too slowly. The Teensy 4 seems to be 600x faster! When I very first Teensy arrived I tested with a bit of code that calculated the value of pi 50,000,000 times. An Arduino nano finished in ten minutes. A Teensy 4.0 finished in one second! I was impressed! What痴 more the Teensy gave greater precision - more decimal places.

    It痴 becoming clear that my radio project could be really useful to modellers after a bit more development so here痴 what I think I should do:
    A friend of mine is designing PCBs so that dangling wires are eliminated. When these are done and tested, I will post here the source code, and the pcb designs and the .stl files for the transmitter case. Then putting one together should be as easy as painting by numbers. What do you think?

    Malcolm
    Attached Thumbnails Attached Thumbnails Click image for larger version. 

Name:	1003718C-BE15-4902-AE99-3EA087A78DA2.jpg 
Views:	17 
Size:	48.1 KB 
ID:	23133  

  6. #6
    Senior Member
    Join Date
    Jul 2020
    Posts
    980
    What bandwidth do you actually need for this - the nRF24L01 only supports 250k/1M/2Mbaud, so its sensitivity is correspondingly poor.

    Sensitivity increases with narrower bandwidth, so if you only need 25kbaud (for instance) and use a 25kbaud transceiver you are likely
    to get more like -105dBm sensitivity, allowing more range (or less transmit power: 10dBm is the max legal TX power for 2.4GHz in the
    UK I believe).

    My preference is for lower frequency ISM bands where you get the advantage of more antenna gain (proportional to square of the
    wavelength in a LoS link). Thus 20dBm at 2.4GHz is roughly equivalent to 5dBm at 433MHz, all else being equal - this effect is
    purely due to the antennas being longer for lower frequencies. (All assuming quater-wave antenna).

  7. #7
    Junior Member
    Join Date
    Jan 2021
    Location
    London England
    Posts
    19

    I wish I knew!

    Quote Originally Posted by MarkT View Post
    What bandwidth do you actually need for this - the nRF24L01 only supports 250k/1M/2Mbaud, so its sensitivity is correspondingly poor.

    Sensitivity increases with narrower bandwidth, so if you only need 25kbaud (for instance) and use a 25kbaud transceiver you are likely
    to get more like -105dBm sensitivity, allowing more range (or less transmit power: 10dBm is the max legal TX power for 2.4GHz in the
    UK I believe).

    My preference is for lower frequency ISM bands where you get the advantage of more antenna gain (proportional to square of the
    wavelength in a LoS link). Thus 20dBm at 2.4GHz is roughly equivalent to 5dBm at 433MHz, all else being equal - this effect is
    purely due to the antennas being longer for lower frequencies. (All assuming quater-wave antenna).
    Hello Mark,

    Truth is I really don稚 know! I致e spent most of my life playing oboe, and flying RC models. I did write an 8086 assembler comms app in the early 80s, but my training was in 1968 at the Paris Conservatoire of music. I知 very keen to learn and I appreciate enormously all and any guidance from you, and others.

    I知 a complete beginner.

    Last May I bought an Arduino and a get-started book. It was and is my lockdown project. I knew nothing, except a bit of old 8086 assembler. So I had to learn some C++. I loved it, but I loved Teensy 4 approximately 600 times more!

    Because of my life long passion for flying RC models, I rather ambitiously decided that was going to be the project for me. I worked hard as there was nothing else to do. I assumed it壇 be just a bit of fun, but no real use - ever.

    So I have been very surprised how it痴 turning out. In late September I flew a model with it for the first time. The model setup involved several 僧ixes and my version of FHSS. I had dozens of flights with zero issues. I thought ... WOW! ... and backed up all the source code.

    Of course, these days there痴 really no point in creating a commercial radio system for sale. To much cheap competition. But we can have fun!

    Also, I reckon that at the current rate I might end up with a system that痴 as good as one costing >」1000, for only the cost of the components. To achieve this I may well need a bit of guidance from those with more experience.

    My work is almost entirely empirical. I implement an idea, test it, then keep it in, or discard it. I知 really glad the nRF24L01 does lots of the work for me. I did set it to lowest speed and highest power - to maximise range. But that痴 only two lines of code. I also had to slow down the SPI bus since the Teensy was at first rather to fast for it. The transceiver痴 殿ck payload feature handles telemetry perfectly, almost effortlessly.

    I致e tested massively. At home I can test with a toy car and the simulator (with RX2SIM). Of course there痴 masses of noise on 2.4 ghz from WiFi. So my transmitter system now scans the waveband for one second as it boots up. It records all channels that seem busy, and thereafter it won稚 hop to any of those. What痴 more, during a connection when a packet fails, the offending channel number is added to the array of channels to be avoided. The list can grow to about 70% of the waveband before new entries just overwrite the earliest ones. I thought it better not to avoid all!! This setup seems remarkably robust and has run for many hours continuously without problem.

    Please pardon me for waffling on excessively. I値l say good night from London now!

    Malcolm

  8. #8
    Junior Member
    Join Date
    Jan 2021
    Location
    London England
    Posts
    19
    Hello

    I thought I should explain briefly my recent silence.
    I think I shall make my radio control system open-source. But before I do, I need to do a little more work...
    Yesterday I increased the number of channels from 8 to 12. Two day before, I had added SBUS support to the receiver (using Brian Taylor’s excellent library!)
    These features need tidying and rigorous testing before I let others into the code because it’d be bad manners to release frustratingly buggy code!
    I’ve made the four three-way switches completely user definable- so I think I probably ought to make all sticks and knobs user defined too - rather than only an option for modes 1 and 2.

    I’ll get to it! I just hope lockdown and winter last long enough ... These are perfect coding conditions!

    Malcolm

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •