More information. This code is running in a VI called by TestStand. Turns out that I don't need to power cycle the device, but do need to restart TestStand (and LabVIEW). If I open MAX I can reserve the chassis, open and run the tasks I have set up but until I restart TestStand, I can't get past the error.
What I have found is that my problem occurs when I try to run a task without the task started. I have restructured my code now so that it should be impossible to run a task if it is not "active" and have had no issues since. My question though is about recovering from this situation. Why should this be unrecoverable? Isn't there a way to reset DAQmx programatically without shutting down TestStand and LabVIEW?