The assignment of roles to virtual organizations of agents will ensure system flexibility and will provide us with the ability to add new functionalities, creating a completely transparent layer for the applications that are developed for the user. The communication between the different components of the system must be efficient and low power consuming, since it must be capable of operating without direct sunlight. The proposed system must be able to monitor a crop and automatically supply the amount of water needed, this will be done through a predictive model with input variables regarding the climate, humidity of the subsoil, the force of wind, sunlight, temperature and the time of the day. Fields generally have very vast areas of land and sensors often have to be installed at large distances from one another, this is why a wireless connection between them is necessary. To this end, a network of autonomous sensors has been designed, with manageable battery consumption, which coordinates and generates different events produced in the system. Wireless Sensor Networks (WSNs)  are used to analyse environmental behaviour and the existing interaction between different sensors, they make decisions automatically on a daily basis .