The incessant development of High Quality (HQ) multimedia contents and the trend towards the use of wireless technologies have as a consequence the need for providing the users with an adequate level of Quality of Service (QoS) in IEEE 802.11 networks. The IEEE 802.11e amendment aims to overcome this situation by introducing the Enhanced Distributed Channel Access (EDCA) access method. This new method is characterised through a group of Medium Access Control (MAC) parameters, which are able to classify and prioritize the different types of traffic. In this regard, the most determining parameter is the Arbitration Inter-Frame Space Number (AIFSN). On this basis, we propose a new adaptation scheme that makes use of a M5 regression model with the aim of improving the voice and video performance offered by EDCA. Our proposal is able to determine dynamically the optimum AIFSN values with regard to the network conditions, maintaining the backward compatibility with the stations that use the original IEEE 802.11 standard. The prediction algorithm is only queried by the Access Point (AP), without introducing additional control traffic into the network, making it possible to use it in real-time. With respect to the standard EDCA values, the results show an enhancement in the voice+video normalized throughput and a significant reduction in the number of the retransmission attempts.