You can do a M502 followed by a M503 to print out what the bulk of your settings are. At worst case, that gives you a very very good head start towards modifying a new Configuration.h file so you can rebuild the firmware.