Check your rpi board version and other bits programatically.
Node Module to control Adafruits MotorHAT for the RaspberryPi