A plugin is software that bridges the gap between the hardware and Mach allowing them to communicate.
I have no experience of writing plugins so afraid I can be of no help. There is a section of the forum dedicated to plugins, you may get some info there.
Hood