Calendar Latest Topics
 
 
 


Reply
  Author   Comment  
qizilbash

Avatar / Picture

Junior Member
Registered:
Posts: 16
Reply with quote  #1 
Hi,

I'm using advantech card to data acquisition,
I have 4 Digital I/O port.
1st and 2nd are inputs and 3rd and 4th are output,
I've checked outputs and i can see digital signal on the outputs.

but when i assign 3rd port to "Behavioral Codes" and 1 bit to strobe bit separately and push check button i get these Errors:

Error using digitalio/addline (line 211)
Port dose not support requested direction. For valid port directions, see your hardware specification sheet.

dose any one know why this problem appear?

thanks in advance
 
   
0
Wael.Asaad

Administrator
Registered:
Posts: 51
Reply with quote  #2 
Did you check to see if your hardware actually supports configurable "in" and "out" on individual ports, or if particular ports are hard-wired to support only one direction?
0
qizilbash

Avatar / Picture

Junior Member
Registered:
Posts: 16
Reply with quote  #3 
I have PCI-1711 advantech card and it has 16 bit defined input and 16 bit output.

I attached its connector pins assignment if you want to see.

as I mentioned when I test these ports in monkeylogic there is no problem with them and i can see square wave with oscilloscope in output pins.

and when i test input pins there is "read only error" which is rational and it seems that monkey logic can detect them as input and output correctly.




 

Attached Images
png Untitled.png (28.83 KB, 16 views)

0
Wael.Asaad

Administrator
Registered:
Posts: 51
Reply with quote  #4 
What happens when you try to assign digital codes to lines on the other ports (including the ones that shouldn't work, within the digital "in" ports)?
0
qizilbash

Avatar / Picture

Junior Member
Registered:
Posts: 16
Reply with quote  #5 
i get same error 
0
qizilbash

Avatar / Picture

Junior Member
Registered:
Posts: 16
Reply with quote  #6 
I solved the problem.

monkeylogic does not send port numbers in my case, it sends pin number only.

for example for 4 port with 8 pin, it codes pins from 0 to 31 and in this way my 0 to 15 pins are inputs and 16 to 31 are outputs.

but i don't know why monkeylogic only send 0 to 7 when i assign 3rd port pins.

I changed pin names manually to 16-23 then it worked.



 
0
Previous Topic | Next Topic
Print
Reply

Quick Navigation:

Easily create a Forum Website with Website Toolbox.