Does that actually change the amount of vibration? I know the power LED is at 100% brightness at about 54 or so (and 55-255 don't make it any brighter) so I'm just wondering if this is the same and the motor only works when getting 100% power. I know you can control motors with a PWM in general but I wonder if the motor is attempting to draw more power at lower values than the PWM can produce. If so, maybe we can find a different motor, or perhaps soldering it to one of the spare LED pads on the top of the board might make more sense. In any event, an excellent experiment and something that can probably be recommended for the P2The vibration is really good and goes through the whole case. The motor can be operated with the values ~50 - 255 in /sys/class/leds/pandora::keypad_bl/brightness.
The video (actually the audio) demonstrates that there are certainly different amounts of vibration, because at higher values the sound has a higher pitch.
As for the script vs library: library would be better, calling scripts has some overhead (forking a process, loading bash, etc) which may not be a good idea if you want get good performance and low latency.