Whe i arrived home tonight i smelled burning electrical i realized it was my truck i got it parked and turned off the key but the engine kept running [5.9 diesel/auto] i opened the hood the smoke was coming from the fusebox in the ebgine bay i ran to the garage to get tools to remove the battery cables when i got back the engine had shutoff i removed the cables and accessed the damage. I found a ground wire that had been dangling in the area of the air heat relays [two small coil looking things under the drivers battery] it had touched one of the positive posts of those and shorted out melting off the insulation and causing the smoke i don't know what else was melted have not tore into it. Once i found the culprate it was removed and i hooked up one battery to test and see what did not work lights,signals,blower motor ect works. I hooked up both batterys and went for a start she fired up and died right away tried a second time same result but i noticed that i had no wait to start light so i turned the key to on and everything else came on [self test] as advertised but no wait to start light this is where i stopped and disconnected the batterys so no more damage is done and i'm unsure of what to do next. I'm thinking that i may have fried sonething in the fuel shutoff either the relays or the shutoff solenoid but i'm not a diesel mechanic i'm an old school hot rod guy. Any help would be appreciated.