Scientists have successfully tested a "bionic pancreas" on 20 adults and 32 teenagers with Type 1 diabetes for five days, reports the Associated Press. The pancreas is a wearable device that continuously monitors a patient's blood sugar levels and administers insulin automatically, when needed. And, unlike other wearables currently in the works, this one was able to correct low blood sugar levels, as well as high.

In the study, 20 adult participants were asked to stay in a hotel room for five days. They could eat and behave normally, but were asked to limit their alcohol intake, reports Time. The teenagers, on the other hand, were sent to a summer camp. During these experiments, the researchers said, the device performed better than conventional pumps and insulin monitors. These results were presented at the American Diabetes Association conference in San Francisco on Sunday, and the study was published in The New England Journal of Medicine.

The device itself has three parts: two cell-phone sized pumps that administer insulin and glucagon, as well as an iPhone that connects to a glucose monitor. This might not seem like the best setup, but Kristina Herndon told the Associated Press that her 13-year-old son — one of the study's participants — clearly preferred wearing the device over pricking his finger up to 10 times each day.

E59a4c9bb847f687192a47953628b48d_7ttc

(Boston University Department of Biomedical Engineering)

Now that the bionic pancreas has passed this short test, researchers at Boston University and the Massachusetts General Hospital are starting a new trial. This time, 40 adults will use the device for 11 days. The scientists also plan to combine the three parts in a single unified pancreas, and they hope try it out over the course of the next year. But testing it on larger groups for longer periods will take some time, so it probably won't revolutionize diabetes management just yet. Still, these results are promising.

"My goal," said Boston University researcher Ed Damiano, "is to have this device done by the time my kid, who has Type 1 diabetes, goes to college." And according to the Associated Press, his teenager will be hitting university in the next three years.