Task:create a program for Arduino, using 2 or more familiar details (LEDs, button, Servo, photoresistor)
The idea was to create a circuit, using Servo and LED, in a way that potentiometer would control the rotation of the servo as well as the brightness of LED.
I started with the tests of circuits with servo and LED separately.
Onwards, I have tried to get them together in one unit.
I combined each of the blocks (‘define’, void setup, void loop) and it worked out perfectly.
Here is how the circuit works:
And the program itself: