Reliable Folding Certification for Smartphones