Montanamac!
So interesting: I also live off the grid, also have a diesel generator, and am also working on using an arduino to control it! My main source of power is the PV array, though. So I will be following this thread closely.
First of all, I am measuring the current consumed by the starter to know when the engine has started. When cranking, it absorbs over 100A. When started, consumption drops down to <50A. So a pretty visible change.
In my situation, I also had to install a solenoid to open the fuel valve, which was manual. I found a great universal car door lock 40N on eBay which came with brackets and rods. I could have used it also to shut off the valve, but the generator happens to already have a solenoid to shut it off.
I have no need to measure rpm, as the engine's governor takes care of that. I plan to control warm up and cool down by simply delaying and anticipating load connection. In other words I will have the arduino connect the battery charger only after 3 mins of running time. And when it receive shutoff signal, it will first disconnect the load via hi power relays, then let the engine run load free for 3mins, then kill the fuel line with the solenoid.
I do plan, though, to completely replace the dashboard with 8 LED displays, to monitor in real time volts and amps of each of the 3 phases and 12V. All over i2C and with a remote dashboard for the house.
And for power, I plan to power the arduino independently via a battery backpack: I cannot rely on the 12V starter battery as its voltage can oscillate a lot and drop very low when cranking the engine especially in the winter (when I need it the most). So it would make no sense for the arduino to reboot during cranking. I thinking of using the battery to charge the arduino. When the generator is off, it means I have enough power, so I can use the power from the house to keep the starter battery fully charged with a trickle charger.
I also don't need to develop a battery charger: i'm using a fantastic Swiss micro controlled sine wave inverter (studer-innotec C2600) which takes care of tripping a multipurpose relay when the battery bank is, say, at 10% and reverse it when at 90%. Which is perfect in my case, because it makes little sense for me to fully charge the bank today, if maybe tomorrow it's clear again, and the sun hits te PV array.
Exciting we are working on this together!
Keep in touch.