In theory, what you describe might work, but manufacturing insulin isn't easy. Peptide sequencers are quite big and bulky and still can't produce high molar mass proteins without the statistics of 99 % reaction yields starting to add up to junk protein after 30 or 40 mers. Additionally, the pancreas has the advantage of being linked to the brain. If an insulin producing device were made and miniaturized, I'm not sure that simply pumping out a steady concentration of insulin would be sufficient. You might need to have a feedback system that monitors blood sugar levels and adjusts after eating, sleeping or exercise. Finally, you have to understand where you get the power from, where the waste goes, where to position it and biocompatibility. An endeavor that crosses many disciplines (Physics, Chemistry, Engineering, Biology)
Watch out for professors that lure you in with "cancer-curing" projects. If successful, you can get a blockbuster patent or paper in Nature or Science. If the technology isn't feasible, be sure to work on an easier novel side project so that funding can be continued to pursue the ultimate goal. I worked on something vaguely resembling this a few years ago. It was a collaboration with a medical school (evidently, there is a lot of paperwork in the US needed before one works on animals) and the physics department. The people in the medical school kept quitting and the people in the Physics department didn't do anything. The project became a political stalemate. It was only through side-projects that I got a few publications from the ordeal.