1 Introduction

A smart streetlight system enhances public safety and well-being. Tactic deployment of streetlights is important to reduce not only energy consumption but also the crime rate [1]. In conventional streetlight systems, a huge amount of power is consumed in powering the streetlights as they glow from 6 pm to 6 am continuously without considering the presence of traffic or human movement. The increasing energy price, plus the significant maintenance costs and always there is increasing expectations manifested by the public put continuous pressure on the lighting budgets. Now with the advancement in semiconductor technologies and wireless technologies, we are closer to developing technologies that can help cities better monitor and controlling of energy resources. Here we propose a cost-effective solution to control the street lighting budget and support the life cycle management of the streetlight system in an efficient way as shown in Fig. 1.

Fig. 1
figure 1

Life cycle of energy efficient street light system

In smart street lighting systems, the basic working principle is to automatically turn on/off and dim according to the activity on the road and pavement. This way, the streetlights are off throughout the night when there is no activity on the road. Also, if any light is faulty, we can detect it without human intervention. The advantages of this method are the usage of energy and costs decline as lights dim at night when there is low activity. And, the system automatically detects the faulty light using a web application. With less energy, CO2 emissions can be reduced with improved safety as the streetlights are dimmed, but not turned off completely.

This paper proposes a unique solution that uses a combination of PIR, IR, and ultrasonic sensors to accurately determine vehicles and pedestrians. Based on the merits of regular and optical control, a new smart streetlight controller is designed, with dual functions including timing control and automatic photoelectric control. It allows streetlights to automatically light up in the evening with adjustable timing. The terminal controller has a wake-up function to enable the streetlights to function based on the movement of vehicles or pedestrian with the assumption that the pedestrians always walk on the pavement. The main objectives of the proposed system are:

  1. (i)

    To minimize the energy costs while improving safety and ensuring economic control of lighting, especially on roads with scarce traffic, parking lots, and organizations.

  2. (ii)

    Cutting down the operating and maintenance costs by implementing a self-monitoring, modular, and fault-tolerant system.

  3. (iii)

    Implementing smart IoT solutions to the existing streetlights, making them flexible and easy to control/operate with the help of a mobile application.

The main contributions of the proposed work include:

  1. (i)

    Design and develop a prototype of secured smart street light system based on wireless sensing technology for energy saving and easy maintenance.

  2. (ii)

    Reconfigurable LED and dynamic programming of brightness levels based on ambient light, movement of pedestrians, and vehicles.

  3. (iii)

    Remote monitoring and troubleshooting of street lights in a secured manner.

The proposed intelligent street lighting system uses WSN which consists of a smart sensing module that comprises a set of different sensors programmed to sense the required objects based on predefined algorithms. Using a mobile application, the brightness levels of the lights are controlled in an encrypted form so that an unauthorized person will not be able to modify the settings. An nRF24L01 radio transceiver is installed in the streetlights that provides a secured communication link to operate the streetlights.

The rest of the paper is structured as follows: Sect. 2 discuss the state-of-the-art literature on intelligent street lighting systems, Sect. 3 presents the block diagram and circuit level details of the proposed model, Sect. 4 discuss the results, and Sect. 5 mention the conclusions and future scope of the research work.

2 Related work

There are several case studies and models on streetlight systems that are very essential in constructing smart cities [2]. A typical smart streetlight system architecture consists of LDR, IR, LED, UART, and a microprocessor. LDR is a light-sensitive device used for detecting ambient temperature and controlling the functioning of LED streetlights (on/off). IR sensors are used to detect the moving objects and report to the processor. LED emits light that depends on ambient lighting and a relay is used for controlling (on/off) the streetlight. UART controls the street light system via the processor interface.

In cities, one of the main reasons for energy consumption is streetlight systems and it is essential to reduce their energy consumption as well as maintenance cost. Based on the literature, it shows that streetlight system in cities consumes 18%-38% of power resources. Using optimized systems and techniques it is possible to minimize power consumption without compromising human safety. The recent research on smart streetlight systems is focused on minimizing human intervention, power consumption, and cost. The existing systems mainly use the controller and various sensors to automate the switching activity and intensity of lights [3]. It is essential to analyze the installations of different types of street lights, potential power savings, and quality of lighting [4]. To reduce greenhouse effect gas emissions, different countries have focused on energy-efficient techniques and the design of smart street lights in terms of technology, types of lights, functioning patterns, and communication [5]. Most conventional street lighting control systems have a simple timing control circuitry for switching on/off of the lights and need human involvement. However, they do not have considered the ambient brightness and movement of objects. The functioning of street lights (on/off) should be based on any moving object and ambient lighting in order to save the energy of the street lighting system [6]. Vehicle movement and detection-based street light control systems can minimize the energy consumption in street light systems [7]. Controlling the functioning of street lights based on the movement of pedestrians and vehicles minimizes power consumption [8]. An adaptive control system for smart street lighting in a city infrastructure saves energy by up to 35% compared to the predefined and fixed behavior of a control system [9]. EN15323 standard-based street light building automation and control systems can minimize the power consumption by 45% compared with conventional systems [10]. The usage of the three-phase lighting system and design of a control unit for controlling the dimming of luminaire gives better efficiency than a single-phase street lighting system. The distance between poles, numbers of the luminaire, the dimming ratio on the outdoor lighting, environmental conditions, wires conductivity, and the sand category of streets are the factors that affect the active loss reduction [11].

A smart street light system can be built with LED lights, brightness sensors, motion sensors, and a low-range communication network. The LED lights will turn on/off based on pedestrian and vehicles movements to reduce power consumption [12]. The dynamic LED luminary dimming profile and traffic intensity data can achieve maximum energy savings and more safety respectively [13]. Microcontroller-based energy-efficient LED street lights system controls five different light brightness levels that depend on weather and daylight conditions using various sensors like light, rain, laser, etc., to have a low-cost solution that minimizes power consumption [14].

The inclusion of wireless communication technologies in streetlight systems enhances the energy efficiency, ease of installation, and degree of adaptability [15]. The remote control of street lights (on/off) using a Wi-Fi switch does not need any major modifications in the current systems [16]. Integration of LED lights with a low-power communication protocol like Zig Bee becomes cost-effective which facilitates a centralized control system for remote monitoring and controlling the LED lights [17]. A smart lighting system based on a low-power ZigBee network uses electronically controlled LED lights that are adaptable to ambient illumination and traffic flow on roads to achieve maximum energy efficiency. This system was installed on a university campus and the experimental results show 68%–82% energy savings compared to metal halide lighting [18]. Intelligent controlling is essential in LED-based smart street lighting systems to have power optimization. This can be achieved by controlling the brightness levels based on the moving of objects like cars, cyclists, and pedestrians where higher levels of intensity are maintained for high-speed objects. This type of system can be designed using LED, battery, infrared sensor, and LDR, and these systems can achieve 40% of energy savings per month [19].

Solar-based autonomous street lighting systems can be implemented with GPS-based security features for humans in emergency situations in addition to automating the illumination intensity levels. The emergency services include fire, ambulance, and police station [20]. In an autonomous street lighting system that is powered by solar panels, the brightness levels and energy consumptions are adaptive and it depends on solar radiation and weather forecasts. In these systems, the probability of having a critical level of batteries does not cross 0.10% under random weather conditions [21]. Ease of maintenance, minimal manual involvement, and energy efficiency are the key priorities in a smart street lighting system. WSN-based adaptive control street light systems can achieve these priorities with 48% energy savings compared to conventional systems [22].

IoT technologies made the development of smart cities easier and faster [23]. IoT plays a major role in automating the smart street light system with the help of various sensors and components [24]. An AI-based Intelligent lighting control system is used in a smart street light system for delivering automated services. IoT enables smart street light systems to be cost-effective by automating the services and provides easier solutions for the timing, connectivity, manual involvement, and maintenance issues. In an IoT-based smart street light system, installation of sensors and actuators in lampposts that actively monitor and create alerts for maintenance of lights. Using cloud computing techniques, energy utilization can be tracked through intelligent energy meters and analysed the reports for reducing the system cost [25]. In an IoT-based smart street light system, the switching of lights (between on/off) and their intensity levels are adaptive. This system can also be equipped with multiple sensors like a depth sensor to detect flooding on the streets and send this data to a server that can warn the vehicles intending to travel through that road [26]. A low-cost web-based street light control system can replace the conventional controllers with IoT devices. The application at the server device manages and controls the lights and the user application schedules the on/off pattern of the lights to optimize energy consumption [27]. The conventional ways of controlling the street lights (on/off) with human involvement are not effective in terms of power consumption. Integration of control and monitoring modules based on IoT can improve power savings with low maintenance. The sensors like PZEM-004 T, LDR, and microprocessors such as Arduino Mega 2560 can be used for the implementation of such systems [28]. The IoT-based smart LED street lighting is an automated system that eliminates human intervention and minimizes power consumption based on object movement. Simple devices like LDR and IR sensors detect the ambient light and object movements respectively. The sensor data is analysed and stored in cloud platforms like Thinkspeak for further analysis [2, 29, 30]. A mobile application that uses deep learning techniques and IoT can monitor accidents on roads and the light intensity of street lights on a real-time basis [31]. The usage of LED lamps and solar panels enhances the energy efficiency in an IoT-based intelligent and smart street lighting system [32].

3 Methodology

The proposed streetlight control system uses an ATmega328P microcontroller which is based on Atmel’s AVR architecture (modified Harvard architecture, 8-bit RISC) and the peripheral components as shown in Fig. 2. It has 23 GPIO pins (out of which 6 pins for ADC, 6 pins for PWM), 32 Kb flash memory, and 16 MHz external crystal support. nRF24L01 RF transceiver module is a low-cost RF module that works in the 2.4 GHz ISM band. It is connected using SPI via multiple channels in low power modes to transmit message packets that support auto-retransmit and auto-acknowledgment of packet deliveries. Each MCU can cover fifteen immediate streetlights with an optimal communication range of 150 m and data transmission rate of 2 Mbps. The sensors that we have used in the implementation have a wide lens range. HC-SR04 Ultrasonic Sensor’s response gives accurate distance measurement which is not dependent on the surface colour or optical reflectivity of the object. HC-SR501 Passive/Pyroelectric Infrared Sensor detects infrared light with a range of several feet, depending on how the device is calibrated and it is independent of the ambient light conditions, hence it can be used at any time of the day. HC-05 Bluetooth module is used which is cost effective and most suitable for small-scale/range applications. IRFZ44N n-channel MOSFET provides extremely low on-resistance per silicon area. This feature combined with the fast-switching speed proves useful in the dimming of the LED bulbs. USB Type-B Connector makes it easy for the device to be connected to a wall plug adapter or a laptop USB port. AMS1117 Voltage Regulator is being used to power up the transceiver module, which requires a regulated supply of 3.3 V. 10W LED that provides high luminous intensity rating and supports dimming using an external circuit. Dimmer and failsafe circuits are used for high-speed switching of LED and the dimming effects are achieved through PWM as shown in Fig. 3. As part of the failsafe mechanism, if the MCU malfunctions, a relay is connected in parallel across the MOSFET and connects the LED to a constant high. Relay SPDT 5 V is being used as a failsafe in the circuit to switch the lamps to full brightness in case of hardware failure.

Fig. 2
figure 2

Block diagram of the proposed system

Fig. 3
figure 3

Dimming circuit

The detection of pedestrians and vehicles is achieved using a combination of an ultrasonic sensor and a passive IR sensor. Each pole has got its own sensor module, making the system fault-tolerant. The sensor module that detects the presence of pedestrians/vehicles will send this information across the network to ensure that the connected streetlights will glow. The nRF24L01 transceivers are used at a 2 Mbps data rate with auto-acknowledgment and retry up to 10 times if the receiver doesn't acknowledge. This makes the device reliable and extremely responsive, which is required when vehicles are moving at high speeds. Upon detection of moving objects, a certain number of streetlights are switched on and driven to a certain brightness, ahead of the vehicle/pedestrian. The streetlights are dimmed if there are no vehicles or pedestrians after a certain ‘timeout period’.

Android Studio based mobile application (mAP) is developed using GenY motion Device Manager android phone emulator and its GUI is shown in Fig. 4. It enables communication with the master streetlight controller to control the functioning of streetlights and their brightness levels. The master node uses an HC-05 Bluetooth on the serial port to pair with the mobile devices. The mAP transmits active mode brightness and idle mode brightness levels to the master node and the master node relay this information to all other nodes. The streetlights will then operate at the newly received brightness levels until they receive the change in brightness levels. An authentication process in the mAP restricts access to only authorized personnel with a username and password.

Fig. 4
figure 4

GUI of the developed android application

The data exchange among the network nodes occurs in the form of packets of length 7 bytes and the format is shown in Fig. 5. The first byte indicates the number of adjacent lamps to be turned on in active mode. The ‘0’ value of this byte represents the broadcast packet and the data is accepted by all the devices in the network. e.g. in case of a new brightness level setting in the mAP. The second and third fields represent the addresses of the transmitter and receiver respectively. The fourth and fifth fields define the type and value of parameters to be updated which will be received from the master device.

Fig. 5
figure 5

Message packet format

To support the speed of operations and less memory constraints of sensors in the streetlight system, Rivest Cipher (RC4) stream cipher is used to encrypt the message packets with 128-bit key length. Stream ciphering is typically faster than block ciphers and requires less memory. Block ciphering encrypts the whole block at a time and they are more susceptible to noise during the transmission. Whereas with stream ciphers, bytes are individually encrypted with no connection to other chunks of data, and provide support for interruptions on the line. The key is used at each device to facilitate the encryption and decryption process. From Fig. 6, we input the variable length (0–255 Bytes) messages along with a secret key of length 128-bit. The encryption engine (Sbox) generates the keystream in systematic randomization form at multiple stages. The final keystream is used to perform the XOR operation with plain text in a byte by byte manner to produce cipher text. During the decryption at the receiver, the same key is used to perform the XOR operation with cipher text and generate the original message.

Fig. 6
figure 6

RC4 Encryption flow chart

The circuit is designed using the KiCAD PCB designing tool as shown in Fig. 7. The proposed system consists of one master device with a Bluetooth module (for updating the streetlight functioning settings) and multiple slave devices. Figure 8 shows the labelled hardware circuit of the master node in the proposed system. The hardware architecture of master and slave nodes are the same except for the presence of Bluetooth device in the master node. For experimental purpose, one master node with two slave nodes are used as shown in Fig. 9. The sensor module detects moving objects based on their type (like vehicles and pedestrians). The sensed data is collected and transmitted through the RF module across the network in an encrypted form. This data is used to decide the required number of streetlights to be on. The brightness of the streetlights is controlled by a MOSFET and the lights are switched off or dimmed after a certain “time-out” period. LDRs are used to detect the ambient light and if the ambient light is more than a threshold value, the streetlights will be switched off. The LDR’s resistance changes based on the light falling on it, the voltage across it changes using voltage divider circuit as shown in Fig. 10. The sensed analog voltage is converted into an equivalent 10-bit digital value and fed to the MCU. The circuit shown in Fig. 10 also ensures a switching function based on ambient weather conditions. A relay acts as a failsafe for the streetlights and these lights will be switched to full brightness when there is a circuit failure. The idle mode and active mode brightness can be changed using the mAP. The operation of master and slave nodes are shown in Figs. 11 and 12 respectively in the form of a flowchart.

Fig. 7
figure 7

Circuit level representation of the proposed model

Fig. 8
figure 8

Complete working prototype of the master node

Fig. 9
figure 9

Complete setup with master and slave nodes

Fig. 10
figure 10

Ambient light sensing circuit

Fig. 11
figure 11

Operations at master device

Fig. 12
figure 12

Operations at slave device

4 Result analysis

The experimental setup uses 10W 12 V DC LEDs that produce an output of 675–765 lumens which is equivalent to a 13-15W CFL bulb or a 60W incandescent bulb. Thus, the LEDs for the same units of lumens require significantly lesser power. To calculate power savings, we first calculate the maximum power dissipated based on existing LED based street lighting methods without any moderation of the streetlights as shown in Table 1. Therefore, considering full brightness or 100% duty cycle for the LEDs and the streetlights are operational for a period of 12 h; hence the power consumed will be 63.6 Watt-Hour as shown in Fig. 13 and it is less than an ordinary street light system whose power consumption is 72.0 Watt-Hour [22].

Table 1 Power consumption in the existing LED based streetlight system
Fig. 13
figure 13

Current, Voltage, and Power readings in the existing LED based Streetlight system

In a day, it is assumed that 6 pm to 11 pm is the active period, 11 pm to 6 am is the idle period, and the remaining period of the day is inactive. However, based on ambient light during a cloudy environment the smart lights will function with defined brightness levels. The power consumption calculations of LED lights are performed by considering the brightness levels as 10%, 20%, 30%, and 50% in the idle period as shown in Fig. 14. The brightness levels are kept at 80%, 90%, and 100% in the active period as traffic is expected to be high during that time. Accordingly, the values of power consumption are computed in idle and active periods, and their sum is the total power consumption. This total power is subtracted from the amount of total power consumption without moderation (which is 63.6 Watt-hour) to define the saved power. The total average power consumed during the operating period is equal to the average power consumed during the time when the streetlights are idle and the average power consumed during the time when the streetlights are active.

Fig. 14
figure 14

Power saving calculations for brightness control with 10%, 20%, 30% and 50% duty cycles

In Fig. 14, case 1 considers the idle mode brightness to be set at 10% duty cycle. The active mode brightness levels of 80%, 90%, and 100% are used to calculate the savings in each case. Similarly, in case 2, case 3, and case 4, the idle mode brightness levels are 20%, 30%, and 50% respectively. The average percentage of power saved is 53.45%, 44.76%, 39.39%, and 32.25% in case 1, case 2, case 3, and case 4 respectively. From the overall results shown in all the cases, we can effectively control the brightness of lamps and there is a significant amount of power savings.

The power savings are calculated based on different brightness levels as shown in Table 2 to Table 5. In Table 2, the first column represents the LED light brightness levels in the active period, i.e. between 6 to 11 pm when high traffic is expected. The second column represents the active mode power consumption of an LED light in an hour at different brightness levels. The fourth column represents the corresponding total power consumption in active mode duration i.e. 6 pm to 11 pm. In the idle mode period, the brightness levels are reduced to 10% and power consumption is 0.8 Watts per hour. Since the idle mode period is defined as seven hours (i.e. between 11 pm and 6 am), the third column represents the total power consumption during that period. The fifth column defines the total power consumption which is the addition of power consumptions in active mode and idle mode periods. The last column of Table 2 represents the amount of power saved by maintaining different brightness levels compared to the fixed brightness level. Similarly, the power saving calculations are shown in Tables 3, 4 and 5 by considering the idle mode power consumptions at 20%, 30%, and 50% brightness levels.

Table 2 Idle mode Power is equal to 0.8 Watts at 10% brightness levels
Table 3 Idle mode Power is equal to1.59 W–h at 20% brightness levels
Table 4 Idle mode Power is equal to 2.09 W–h at 30% brightness levels
Table 5 Idle mode Power is equal to 3.32 W–h at 50% brightness levels

5 Conclusions and future scope

The energy efficient streetlight systems are essential for smart cities. In this paper, a secured and reconfigurable LED based smart streetlight system is implemented for enhancing energy efficiency. A mobile application is developed with security features to manage and control the brightness levels of lamps in an efficient way so that the overall power consumption of the system is minimized. A failsafe mechanism is implemented in the modules for streetlight operation in the case of module failures. Using reconfigurable hardware and functional modes, the functioning of streetlights and their brightness levels are adjusted based on the ambient light, movement and density of vehicles, and pedestrians. The designed prototype gives enhanced performance if the streetlamps are placed near the footpath for pedestrians and the road is a few meters away. The proposed system saves the average power consumption of 53.45%, 44.76%, 39.39%, and 32.25% respectively for 10%, 20%, 30%, and 50% idle mode brightness compared to the state-of-the-art techniques. The results show that in all cases, monitoring and controlling the brightness levels of streetlights are effective and secured. As a part of the future scope, an IoT platform called BLYNK can be used for remote monitoring of the streetlight system. It enables us to view the data, control the hardware, and detect faults remotely through a mAP. More efficient security techniques like RSA, DES, and AES techniques can be used in place of RC4. A cloud based platform can be developed using collected information from the sensor module to perform further data analysis and achieve easier remote monitoring and maintenance of the system. The collected data can also be used to develop an algorithm that can predict situations and help surveillance.