Pass the device to InitializeEffect and return the error enum from it