I went to try and see if I could find out what Code 31 meant... and on an M104 motor (93-97), it said that code 31 was Not Used. This might not necessarily be the correct info though. Try searching yourself and see what you come up with...
You can also try searching at http://OBDII.com
and see if you can come up with anything... although I'm having trouble searching, I think because you need the full code.
Anyway, good luck, and keep us posted.