Interesting project! The one thing I want to suggest for thought would be putting a debounce in your trigger pin reading. It may not be needed but, I am wondering.
val = digitalRead(triggerPin); // Read trigger input value and store it in val
if (val == HIGH) { // Check if trigger has been tripped