There is a (kind of outdated) how-to in the WiKi, too.
The easiest way to get started writing a plugin is to use the plugin wizard. This will create a working, compilable minimum project, and you can fill in whatever you want. Most of the functions that you need to fill in (OnAttach, OnDetach, OnExecute, etc.) are pretty much self-explanatory.
A profound knowledge about how wxWindows (especially event handling) works is recommended if you intend to write a plugin. If you are not firm in wx event handling, read
http://www.wxwidgets.org/manuals/2.6.2/wx_eventhandlingoverview.html before starting.
It may also help to look how existing plugins work.