• 0
Assane

JTAG-HS3 connection with API (DmgrOpen)

Question

Hi everyone !

I'd like to use the JTAG-HS3 cable to work on a project which consists in testing several interconnections between devices on a board.

I'm using DJTG and DMGR APIs and i'm connected via ssh to the computer which has the cable plugged on.

My question is: 

How do i connect to the board with the DMGR API? I know that i have to use DmgrOpen() function but it requires a "device name", which i don't have.

 

Thanks in advance !

Have a nice day !

Share this post


Link to post
Share on other sites

9 answers to this question

Recommended Posts

  • 0

Hi Assane,

I'm not the most familiar with the Adept API, but it looks like you can use the DmgrGetInfo() command with the "dinfoUsrName" parameter value to query the device to find out it's name since I imagine it's something like "HS3". I found these in the DMGR Progammer's Reference Manual on page 2 and the Digilent Adept System Programmers Reference Manual on page 8 that came with the Adept SDK download. Again, I'm not the most familiar with this so I personally can't speak towards the accuracy of this, but I'll make sure you get the help you need.

Thanks,
JColvin

Share this post


Link to post
Share on other sites
  • 0

Hi Colvin,

Sorry for my late reply...

I was busy with something else, but i promise i'll try your suggestion and come back to you as soon as i can.

I believe the DmgrEnumDevices() will resolve my problem and i missed it.

Thanks a lot Colvin !!

Share this post


Link to post
Share on other sites
  • 0

Hi again ! 

The DmgrEnumDevices() function keeps returning 0, but when I use the Linux command "libusb", the cable is in the listed names of devices. 

It is not easy to debug the problem because the source code of the library is not public (I presume), and the function doesn't report any information.

Do you think it's an issue of driver (libusb1-0 and liftdi) or the adept runtime wrongly installed ? Or anyhting else ?

Thanks again ! 

 

Share this post


Link to post
Share on other sites
  • 0

@Assane,

As I recall, there's an action required by the udev subsystem when you insert a USB Xilinx into your system.  Without the udev action, it will show under lsusb (which I think is what you meant earlier, not libusb, right?), but nothing will recognize it.

Getting the udev action to take place when you plug in your device requires installing the Xilinx device drivers as root.  Basically, Xilinx and Digilent want to install two separate files into /etc/udev/rules.d/. 

Just to see if these files have been installed, can you "ls" this directory for me?  You are looking for files "52-xilinx-digilent-usb.rules" and "52-xilinx-pcusb.rules".

Thanks,

Dan

Share this post


Link to post
Share on other sites
  • 0

Hi @D@n,

yes I meant "lsusb" earlier, not "libusb" sorry.

And finally, I got it working ! It was because "ibftdi" library wasn't installed correctly. I did it manually and I didn't noticed the mistake since the compilation never mentioned anything wrong. 

The /etc/udev/rules.d directory does contain digilent rules file with the right permissions. 

Thanks a lot Dan, Colvin, Jon !

Best regards,

Assane.

 

 

Share this post


Link to post
Share on other sites
  • 0

@Assane,

You know what's really cool about this then?  I get to get the credit for being the "more experienced engineer" @jpeyron mentioned ... when I really know very little about this interface.  :P

18 hours ago, jpeyron said:

I will reach out to a more experienced engineer about this question.

Dan

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now