def proc_emg(emg, moving): # create an array of ints for emg data # and moving data emgPub.publish(EmgArray(emg, moving)) # Package the IMU data into an Imu message