Electronic warning signs triggered by vehicles driving the wrong way onto motorways are being trialled in Scotland following a series of fatal crashes.

Seven people have been killed over the last four years from such incidents.

The 'no entry' signs would be triggered by a vehicle going the wrong way.

READ MORE: Tired Edinburgh taxi driver killed after horrific crash on A1 slip road in East Lothian

The system involves flashing lights and no entry symbols being illuminated when drivers take a wrong turning onto a slip road.

The UK-first technology is being tested at junctions on the M9 in West Lothian and the A1 in East Lothian where there have been fatal crashes.

Watch the video demonstration HERE.

If successful, it could be extended across the trunk road network.

The signs could also be linked to the Traffic Scotland control room so other motorists could be warned about any wrong-way driver who still drove past them. The police would also be automatically alerted.

In 2016, four people died and two were seriously injured after a male van driver heading the wrong way on the M9 crashed into a car carrying a couple and their nine-year-old daughter.

The same year, a male Edinburgh cab driver died in a head-on collision on the A1 after going down a slip road the wrong way. He had been disorientated because of tiredness after a 13-hour shift, a sheriff determined at a fatal accident inquiry.

Road maintenance firm Amey is trialling the signs at junction two of the M9 at Philipstoun, and at Wallyford on the A1.

"Its spokeswoman said: “Accident statistics, along with police reports of incidents not leading to a collision have shown this is a recurring problem at several junctions on the network.

“An accident investigation identified these two junctions as being particularly at risk due to several fatal accidents.

“Research showed there was a lack of innovative methods to solving the issue of drivers entering slip roads the wrong way, with the problem appearing common around the globe.

“Once on the slip road, there are currently no deterrent signs or markings to warn motorists they may be travelling the wrong way. That is where the idea for this innovative scheme developed.

“Amey partnered with Clearview Intelligence, a road system technology provider, to develop a wrong way detection system that used a combination of detection sensors, warning signs and alerts to prevent drivers continuing along the slip roads incorrectly.

“This technology is the first of its kind in the UK.”

A motoring group said the system should be deployed UK wide if successful since there had been similar crashes south of the Border.

READ MORE: Driver charged for travelling wrong way down the M9

Neil Greig, the Scotland-based policy and research director of IAM RoadSmart, said: “Following a spate of high profile wrong-way crashes across the UK, this is just the kind of action we have been calling for.

“Wrong way crashes tend to involve older drivers, and younger drivers under the influence of drink or drugs.

“Eradicating deliberate illegal behaviour may be more difficult but this system does look like an excellent solution for those drivers who may have been confused or momentarily distracted by the road layout.”

"A spokesman for Transport Scotland, which is responsible for trunk roads, said: “The use of vehicle-activated wrong direction signs on selected trunk road network off-slips is an important element in the successful delivery of our strategic road safety plan.

“It is our hope the innovative signage, along with associated signing and road marking, will help prevent serious accidents and incidents where drivers have travelled the wrong way along a slip road towards traffic moving at high speed, risking a head-on collision.

“The trial is still in the early stages. Full evaluation is required before a decision is taken on wider roll out of the signage.”