2 Comments

  1. Hello! I would like to control/regulate the luminous power with the TX potentiometer. (VrA or VrB) Can you write me a code for that? Thanks!

  2. int led = 9;

    int chan = 5;

    int Channel;

    void setup()

    {

    pinMode(chan, INPUT);

    pinMode(led, OUTPUT);

    Serial.begin(9600);

    }

    void loop()

    {

    Channel = (pulseIn(chan,HIGH));

    Serial.println(Channel);

    if (Channel > 1900 )

    {

    digitalWrite(led,HIGH);

    }

    if (Channel < 1000)

    {

    digitalWrite(led,LOW);

    }

    }

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.