Chandana Posted December 14, 2018 Share Posted December 14, 2018 I want to set a digital IO channel to LOW. In the process of setting it LOW, first the channel is enabled. But an error is reported at FDwfDigitalOutEnableSet( ) function call. Error is "dwf.DWFError: Error(0): DptiIO failed ERC:0X4." Can anyone help in troubleshooting this? Link to comment Share on other sites More sharing options...
JColvin Posted December 17, 2018 Share Posted December 17, 2018 Hi @Chandana, What board are you working with? An OpenScope MZ or an Analog Discovery 2? Or something else entirely? Thanks, JColvin Link to comment Share on other sites More sharing options...
Chandana Posted December 18, 2018 Author Share Posted December 18, 2018 Hi JColvin, I'm using Analog Discovery 2. Thanks, Chandana Link to comment Share on other sites More sharing options...
JColvin Posted December 18, 2018 Share Posted December 18, 2018 Hi @Chandana, I have moved your question to a more appropriate section of the forum where the engineers much more experienced with the Analog Discovery 2 look. I presume you are using SDK to program the digital IO channel? What version of Waveforms are you using and did you try out the Digital IO example that comes with WaveForms SDK in the example folder? Thanks, JColvin Link to comment Share on other sites More sharing options...
attila Posted December 19, 2018 Share Posted December 19, 2018 Hi @Chandana The error code indicates that your application is not connected to the device. const ERC ercCapabilityNotEnabled = 4; // The protocol is not enabled In such case you should get "Invalid device handle provided" error, but some old software version might return the error you got. Which WaveForms version are you using? Are you calling FDwfDigitalOutEnableSet function from another process than FDwfDeviceOpen? Could you post your code? Link to comment Share on other sites More sharing options...
Lakshmi Tejas M A Posted December 20, 2018 Share Posted December 20, 2018 Hello @attila Using waveform version 3.8.11 Running code: ao = dwf.DwfAnalogOut() do = dwf.DwfDigitalOut(ao) do.enableSet(4, True)//error occurs here Link to comment Share on other sites More sharing options...
attila Posted December 20, 2018 Share Posted December 20, 2018 Hi @Lakshmi Tejas M A These 3 lines of code don't look like WF SDK function calls... Please see the samples at: C:/Program Files (x86)/Digilent/WaveFormsSDK/samples/py/ Link to comment Share on other sites More sharing options...
Lakshmi Tejas M A Posted December 20, 2018 Share Posted December 20, 2018 Hello @attila We are using DWF lib. I have attached the example file. DigitalOut_Pins.py Link to comment Share on other sites More sharing options...
Lakshmi Tejas M A Posted December 26, 2018 Share Posted December 26, 2018 Hi @attila did you check this? Link to comment Share on other sites More sharing options...
attila Posted January 7, 2019 Share Posted January 7, 2019 Hi @Lakshmi Tejas M A I see you are using the 3rd party py/dwf I have installed this and the example is working for me with WF 3.8.11 and 3.9.1 Make sure to close WF app or other (custom) application that can keep the device busy. Only one application can be connected to a device at a time. C:\Users\#####>python DigitalOut_Pins.py DWF Version: 3.9.1 Opening first device Generating output counter for 10 seconds... Link to comment Share on other sites More sharing options...
Lakshmi Tejas M A Posted February 20, 2019 Share Posted February 20, 2019 On 1/7/2019 at 4:57 PM, attila said: Hi @Lakshmi Tejas M A I see you are using the 3rd party py/dwf I have installed this and the example is working for me with WF 3.8.11 and 3.9.1 Make sure to close WF app or other (custom) application that can keep the device busy. Only one application can be connected to a device at a time. C:\Users\#####>python DigitalOut_Pins.py DWF Version: 3.9.1 Opening first device Generating output counter for 10 seconds... Hi @attila thank you on checking on it. We think analog discovery 2 is getting disconnected because of noise entering USB. Not sure. wanted to know if we can close the device which is opened and reopen in this scenario. because WF is not open and some function are running but in middle this scenario is created. This doesn't happen every time. ty LT Link to comment Share on other sites More sharing options...
Question
Chandana
I want to set a digital IO channel to LOW. In the process of setting it LOW, first the channel is enabled.
But an error is reported at FDwfDigitalOutEnableSet( ) function call. Error is "dwf.DWFError: Error(0): DptiIO failed ERC:0X4."
Can anyone help in troubleshooting this?
Link to comment
Share on other sites
10 answers to this question
Recommended Posts
Archived
This topic is now archived and is closed to further replies.