|||
Not Registered
Go AD FREE & get your membership medal
BRONZE
Less Ads
SILVER
GOLD
Ad Free
Cancel
Anytime
ยฃ2.50
ยฃ4.50
ยฃ6.50
Subscribe
Go AD FREE & get your membership medal
BRONZE
Less Ads
SILVER
GOLD
Ad Free
For A Whole Year!
ยฃ25
ยฃ45
ยฃ65
Donate
You Will Be Helping Towards:

  • Domain Fees
  • Security Certificates
  • iOS & Android App Fees
  • Website Hosting
  • Fast Servers
  • Data Backups
  • Upkeep & Maintenance
  • Administration Costs

    Without your support the website wouldn't be what it is today.

    Please consider donating towards these fees to help keep us afloat.

    Read more

    All donations are securely managed through PayPal.

    Many thanks for your kind support
  • Join Us On Social Media!
    Download The App!

    Login To
    Remove Ads
    Login To
    Remove Ads

    Model Boats Website
    Model Boats Website
    Home
    Forum
    Build Blogs
    Media Gallery
    Boat Clubs & Lakes
    Events
    Boat Harbour
    How-To Articles
    Plans & Docs
    Useful Links
    Search
    Search
    Forum
    Arduino Transmitter link up
    Example pulseIn() code to read
    RC RX
    pin (tested-working) /* This is example code for an RC switch */ unsigned long ch1; /* run setup code once*/ void setup() { pinMode(4, INPUT); // Set our input pins as such pinMode(3, OUTPUT); Serial.begin(115200); } /* loop code*/ void loop() { ch1 = pulseIn(4, HIGH, 22500); // Read the pulse width of the channel - timeout after X milliseconds if no change to pin if (ch1 > 0) { if (ch1 > 1700) { //assigned to a 2 position switch digitalWrite (3, HIGH); // turn on if (ch1 < 1300) { digitalWrite (3, LOW); // turn off } } Serial.println(ch1); // print value read to serial monitor } } Note: Pin 13 on many Arduino boards is connected to the onboard LED - This is great as a fast way to test code. Be aware that as the Arduino boots it normally flashes the led on pin 13 - so if you connect your switch circuit to pin 13 it will also switch on/off on board startup
    4 years ago by G6SWJ
    Forum
    Arduino Transmitter link up
    Hi Elsrickle, It's easy to connect an Arduino to an
    RC RX
    and read the PWM output(s) from the receiver channels and then apply some 'logic' to this/these readings/states and then act on that logic to do something e.g. switch something on/off Working backwards - what types of lights do you want to switch? And I would say YES - it's possible for someone new to Arduino to achieve what you want with some guidance - we all started somewhere! With most things to do with Arduino you don't start with a completely blank sheet - you often use someone elses code and modify/add to it - you will find that there is not much you can think of that hasn't been done by someone else before using the internet. Do be aware that some of the Arduino forums can be scary places even for seasoned Arduinoers... _._
    4 years ago by G6SWJ


    About This Website
    Terms of Service
    Privacy Policy