is there any project of an rtos that works on arduino ?
I have been using FemtoOS in few projects and it works very well.
If you need simple multithreading on to of "bare-metal", then I'd recommend Protothreads which are rather easy to use and there is very tiny overhead (just a few bytes)!
I haven't tested Protothreads in the Arduino Library context, though this should work and as I can see someone already done it.
Protothreads are also part of Contiki OS which is an excellent solution for wireless sensor network applications. There had been some effort of porting Contiki to run a few popular Arduino boards.
A git repository of the orginal port can be found here, though I have attempted to update it more recent version Contiki and it is here. This code works as far as some basic "Hello World!" examples are concerned and it will require some extra work to get networking (i.e. 6loWPAN/uIP), though beware that if you don't need networking there no much benefit of using Contiki and if you have an Ethernet Shield, you don't need the networking as such, because that is implemented.
I've been looking at atomthreads. That should run on avr's but I don't know if you can merge any of the fw/sw parts of Arduino into it.