## 3 The Proposed IoT-Based Master-Slave Regionalized Intelligent LED Light-Controlling System
### Hardware Implementation of the Proposed System
\begin{table}
\begin{tabular}{c c c c c c} \hline \hline
**Parameters** & \multicolumn{3}{c}{**Preset Value**} & \multicolumn{2}{c}{**Settable Ranges**} \\ \hline Field (F) & \begin{tabular}{c} Parking \\ lot \\ \end{tabular} & Corridor & Stairwell & Toilet & \begin{tabular}{c} 1: Parking lot \\ 2: Corridor \\ 3: Stairwell \\ 4: Toilet \\ 5. User definition \\ \end{tabular} \\ \hline \begin{tabular}{c} High-light mode \\ power (W\({}_{\rm H}\)) \\ \end{tabular} & 100\% & 100\% & 100\% & 100\% & 60–100\% \\ \hline \
\begin{tabular}{c} Low-light mode \\ power (W\({}_{\rm L}\)) \\ \end{tabular} & 10\% & 20\% & 20\% & 40\% & 10–50\% \\ \hline
\begin{tabular}{c} High-light \\ duration (T) \\ \end{tabular} & 30 s & 20 s & 20 s & 120 s & 10–180 s \\ \hline \hline \end{tabular}
\end{table} 
Table 4: An example of the preset values and settable ranges of the proposed IoT-based intelligent LED light parameters. Figure 7: The prototype of the proposed IoT-based intelligent LED light. The LED brightness control module controls the brightness percentage of the high-light and low-light modes. It adjusts the output power of the high-light and low-light modes through pulse-width modulation (PWM) and then changes its brightness. For example, in Table 4, the setting range of the power \(\mathrm{W_{H}}\) in the high-light mode is 60-100%, and the setting range of the power \(\mathrm{W_{L}}\) in the low-light mode is 10-50%. When no one is passing by, the proposed IoT-based intelligent LED lights in the same zone will operate in \"low-light mode\" simultaneously. When any one of the proposed IoT-based intelligent LED lights in this zone detects a person passing by (as shown in Figure 8), the wireless transmission module transmits the message to other IoT-based intelligent LED lights in the same zone and adjusts the brightness to the \"high-light mode\"; at the same time, instead of sequentially lighting up the proposed IoT-based intelligent LED lights. The communication module in Figure 7 adopts a Wi-Fi 2.4 GHz wireless transmission module. This module manages the data transmission to the cloud and transmits signals among the proposed IoT-based intelligent LED lights. The transmission method between the proposed IoT-based intelligent LED lights is only the proposed IoT-based intelligent LED lights set to the same channel and will be sent or received from the other proposed IoT-based intelligent LED lights. For example, we suppose the proposed Master IoT-based intelligent LED light channel in Figure 9 is set to \"000\" (dip switch is set to \"000\"). In this case, the set parameters transmit to other channels and put them to \"000\" for the proposed slave IoT-based intelligent LED lights via wireless communication. As for the proposed IoT-based intelligent LED lights of different channels, this message will not be received. Please note that the MAC address is not used to facilitate the user in setting the area number arbitrarily because it is more convenient and direct to select the channel via a DIP switch. Using DIP switches instead of MAC addresses for group planning is to facilitate responses to future equipment failures. Field maintenance personnel can quickly replace faulty equipment by setting the same DIP-switch channel to reduce the chance of technicians coming to the scene. If the MAC address is used for group planning, IT staff should be asked to add and delete related MAC address groups every time the faulty device is replaced. Therefore, the adopted DIP-switch method is more user-friendly and in line with actual usage. Moreover, when installing an extensive new parking lot lighting system, LED lights are vast. We suppose the group planning is carried out by the MAC address method at the bottom layer. In that case, the staff must enter the system to set the MAC address group to distinguish which LEDs belong to that group, but when the DIP switch is used to set the group in the field, the grouping speed will be much faster, thus the reason for adopting a DIP-switch-based scheme for setting the group in the zones.