Vehicular traffic is endlessly increasing everywhere in the world and can cause terrible traffic congestion at intersections. Most of the traffic lights today feature a fixed green light sequence, therefore the green light sequence is determined without taking the presence of the emergency vehicles into account. Therefore, emergency vehicles such as ambulances, police cars, fire engines, etc. stuck in a traffic jam and delayed in reaching their destination can lead to loss of property and valuable lives. This paper presents an approach to schedule emergency vehicles in traffic. The approach combines the measurement of the distance between the emergency vehicle and an intersection using visual sensing methods, vehicle counting and time sensitive alert transmission within the sensor network. The distance between the emergency vehicle and the intersection is calculated for comparison using Euclidean distance, Manhattan distance and Canberra distance techniques. The experimental results have shown that the Euclidean distance outperforms other distance measurement techniques. Along with visual sensing techniques to collect emergency vehicle information, it is very important to have a Medium Access Control (MAC) protocol to deliver the emergency vehicle information to the Traffic Management Center (TMC) with less delay. Then only the emergency vehicle is quickly served and can reach the destination in time. In this paper, we have also investigated the MAC layer in WSNs to prioritize the emergency vehicle data and to reduce the transmission delay for emergency messages.We have modified the medium access procedure used in standard IEEE 802.11p with PE-MAC protocol, which is a new back off selection and contention window adjustment scheme to achieve low broadcast delay for emergency messages. A VANET model for the UTMS is developed and simulated in NS-2. The performance of the standard IEEE 802.11p and the proposed PE-MAC is analysed in detail. The NS-2 simulation results have shown that the PE-MAC outperforms the IEEE 802.11p in terms of average end-to-end delay, throughput and energy consumption. The performance evaluation results have proven that the proposed PE-MAC prioritizes the emergency vehicle data and delivers the emergency messages to the TMC with less delay compared to the IEEE 802.11p. The transmission delay of the proposed PE-MAC is also compared with the standard IEEE 802.15.4, and Enhanced Back-off Selection scheme for IEEE 802.15.4 protocol [EBSS, an existing protocol to ensure fast transmission of the detected events on the road towards the TMC] and the comparative results have proven the effectiveness of the PE-MAC over them. Furthermore, this research work will provide an insight into the design of an intelligent urban traffic management system for the effective management of emergency vehicles and will help to save lives and property.