Optionally include platform-specific end reason codes
Rename end code to platform_code to indicate ad-hoc nature
Merge pull request #71 from rayo/rayo_end_reason_code

Optionally include platform-specific end reason codes