Concept 1 will not work as soon when phone is locked unfortunately, due to cordova limitations. Generally should probably be done with the accelerometer data.
Concept 2 It is possible to send some push notifications with some third party services via js api but it brings you back to problem with concept one , as far as app can not properly run in a background.
Still idea is cool , and you can probably easily create it with more standart and application(not a game) focused tools like Android studio/Xcode.