adding Jeremy's Arduino code