Code
This is the third time we have made flowing water light. In this project, we solder a completely new circuit for
flowing water light. Additionally, the program is also different from previous ones. When this light flows, it will
bring a long tail.
C Code 27.2.1 LightWater03
First observe the project result, and then analyze the code.
1. Use cd command to enter 27.2.1_LightWater03 directory of C code.
cd ~/Freenove_Ultimate_Starter_Kit_for_Raspberry_Pi/Code/C_Code/27.2.1_LightWater03
2. Use following command to compile “LightWater03.c” and generate executable file “LightWater03”.
gcc LightWater03.c -o LightWater03 -lwiringPi
3. Then run the generated file “LightWater03”.
sudo ./LightWater03
After the program is executed, the LEDs will light up in the form of flowing water and carry a long tail.