Implements a gdb-stub as described here http://davis.lbl.gov/Manuals/GDB/gdb_17.html#SEC140 Can be linked to a program.
See proram debug-test.c for an example how to use it. Module gdb_interface.c contains an example implementation of a serial port driver.