Page 1 of 1

Using digital PIN as output with LabView

Posted: Thu May 19, 2016 10:40 am
by ithemba
Hello,
I have been trying to set a digital pin to a high level with LABVIEW but for some reason it doesn't work.
It works when I use a LED for example "LED1" instead of a digital pin.
Here it's the LABVIEW code, both versions don't work.
Image

Did I miss something in my code ?

Thank you.

Re: Using digital PIN as output with LabView

Posted: Fri Jul 08, 2016 9:11 pm
by Primoz Perusek
hi ithemba!

The only thing I can think of now is that one version of RP ecosystem didn't have working GPIO pin commands while the LEDs were working.
So the first question would be: Did you download the OS from that page? http://redpitaya.com/quick-start/

Re: Using digital PIN as output with LabView

Posted: Thu Aug 25, 2016 5:21 pm
by drale85
Hi, I am having the exact same problem here. Have you managed to find a solution?

Re: Using digital PIN as output with LabView

Posted: Mon Aug 29, 2016 5:46 pm
by viseng
I too have been unable to get the following LV functions working
digital pin i/o (except for LED i/o which is fine)
arbitrary waveform generation.

I have used Wireshark to snoop on the commands sent, but can find no protocol errors - all strings sent seem to comply with the SCPI_Commands_beta_release.pdf and the SCPIAPI_Commands.odt
formats. Have tried both 0.95 and latest rev of 0.96. Standard waveform generation and capture seem to be fine.

Can anyone confirm that digital i/o has (ever) functioned, and if so, which ecosystem was in play at the time?


Many thanks in advance,

Rob

Re: Using digital PIN as output with LabView

Posted: Mon Aug 29, 2016 7:51 pm
by Nils Roos
It's a known bug that the "DIG:PIN:DIR" documentation is wrong with regards to the direction parameter.

What commands did you find with Wireshark (I don't have access to Labview, so I can't try it myself) ?

Re: Using digital PIN as output with LabView

Posted: Mon Aug 29, 2016 9:24 pm
by viseng
Hi,
for the dig pin example, dio5_n set to out, state = high, wireshark captured:
DIG:PIN:DIR OUTP,DIO5_N;crlf
DIG:PIN: DIO5_N,1;crlf
DIG:PIN? DIO5_Ncrlf

so, it will fail if the scpi code actually requires OUT not OUTP.

Rob

Re: Using digital PIN as output with LabView

Posted: Mon Aug 29, 2016 11:34 pm
by Nils Roos
so, it will fail if the scpi code actually requires OUT not OUTP.
Indeed. The Labview integration should be corrected to use OUT instead. That is confirmed to work.

Re: Using digital PIN as output with LabView

Posted: Mon Aug 29, 2016 11:37 pm
by viseng
Thanks Nils yet again for your help, I need to remember to look at those issues lists on github in addition to this forum!
The INP, OUTP can be easily deleted from the combo box Connected to the DIO DIRection.vi and replaced with IN,OUT. Now works fine.

Regards,
Rob