Yesterday, I shared my strong opinion that the vast majority of algorithms implemented in FPGAs should be treated as software, not hardware, and should be subjected to a proper design control process like IEC 62304.
I don’t want to turn this into the FPGA blog, but I chatted about the subject with a colleague (un-named) who has more experience than I do in implementing FPGAs in medical devices. His insights are worth sharing.
As a reminder, here were my reasons to NOT try to avoid 62304 activities by stuffing your code into an FPGA.
- It’s disingenuous
- Your risk analysis shouldn’t allow it
- It probably won’t pass FDA
My point applies equally to code that is developed for an FPGA because that is the best platform for it.
My colleague made an additional argument for following a proper design control process when developing code for an FPGA:
It’s cheaper.
It is about ten times as difficult to develop and debug a given set of functionality on an FPGA as opposed to a microcontroller.
- The vendor-supplied development tools are universally terrible.
- Debugging niceties like breakpoints, stepping through code, and inspecting registers don’t exist.
- It is more difficult to find expert practitioners who can develop competently for an FPGA.
If you don’t methodically plan, design, review, unit test, and integration test your FPGA code, you will be in for a world of pain when it’s time to test your device.
My colleague spends a LOT of time debugging the mess that someone else left behind when they implemented signal processing on an FPGA without design controls. It always would have been cheaper and faster to do it the right way the first time.
Funny. Methodically planning, designing, reviewing, unit testing, and integration testing code is exactly what you do when you follow IEC 62304!
Following a rigorous, standardized development process will save you from yourself when you develop for a complex and difficult platform like an FPGA. The earlier in the development process you find and fix bugs, the cheaper and faster it will be.
The right process ensures that will happen.
Happy developing!