Wireless sensor network (WSN) is the network of hundreds and thousands of micro-sensor nodes,
connecting each other by a wireless medium.WSN provide reliable sensing of the environment, detecting
and reporting events to the sink. One of the most important constraints of WSN is energy consumption.
Since the micro sensors are small in dimension, batteries are necessary to produce power to the network. In
this paper, we have proposed an algorithm for hierarchy based protocols of wireless sensor networks,
which consist of two groups of sensor nodes in a single cluster node. Each cluster consists of a three cluster
head. The event driven data sensing mechanism is used in this paper and this sensed data is transmitted to
the master section head. The gathered data is transmitted to the sink via mobile agent. Hence efficient way
of data transmission is possible with larger group of nodes. In this approach of using hierarchy based
protocols; the lifetime of the sensor network is increased. This paper proposes an innovative approach of
cluster head election. The results are compared with LEACH protocol and proved to be energy efficient.