I'm back to thinking it's a problem with the ECU. I'm on my third ECU (or fourth, whichever way you want to count). The first one gave the original owner all sorts of grief, like running on one cylinder. I explained earlier how I fixed that when I bought the bike. It never failed in that way anymore, but instead I used to get various error codes, mostly 34.0 (barometric pressure sensor). It still ran OK, but not fine. Then, it started giving charging overvolt errors, yet when measuring charge, it was all within specs. Because I was being offered an exchange ECU, keys and dash (this was way before DucatiDiag!) I decided to try a swap and voila! Problem gone! Well, not really: I was still getting the occasional 34.0 and running was still only OK (no power under 4k rpm).
Then that ECU died two months ago. No more spark on the front cylinder and error 10.2 and that was permanent.
I then got two 2nd hand ECU's, one 59M as fitted and one 5AM. Flashed them with DD, disabling the immo function and using more suitable maps for my bike (03 999s with 57mm full race system). Right now the 5AM ECU is on the bike and I have had no more error codes since, plus the bike really runs well now.
So, the short of the long is: I would get a replacement ECU, 2nd hand, preferably a 5AM and give it a try. The 59M are notoriously unreliable.
If indeed your bike has the older 59M. First thing to check. The 5AM became standard in 05, but some were also fitted to 04 bikes, it seems.