One other point: most cellphones simply aren’t case hardened for long term operation as vibration or tilt sensors. Let alone the heat and humidity in a typical laundry room. Add to that the (relatively) appalling battery cost, and you’re not doing yourself any long term favors.
Instead, I’d just buy a sensor intended for the purpose.
The old phone can then be better purposed for a controller app, like SharpTools or SmartTiles. (See forum discussions.)
If you don’t want the old android device as some type of app host for your home automation, considering donating it to “cellphones for soldiers.” AT&T and other carriers recycle the phones and in exchange give the charity free minutes used to connect service persons with their families back home. Your local USO probably has a drop off, or you can use the military.com charity list to connect online.
If you’re not in the US, I’m sure other countries have similar programs.
Or I’m sure there are similar charities for other causes.