There is a method in the Phone to read the logs. However I don't recommend you to implement such a system. It is more complicated than it may seem.
Also, how will you send the logs once your application crashes?
Applications uploaded to the market include this feature automatically. When there is a crash, the user is asked whether they want to send a crash report.