The invention could prevent amputations and death for thousands of patients.