Developer fincs is currently working on FeOS, an open source OS for Nintendo DS. Currently FeOS supports loading relocatable code, basic console I/O, ARM7 code loading support and a native libnds-based DS video API.

http://forum.gbadev.org/viewtopic.php?t=17761