FPGA, SoC, And CPLD Boards And Kits
FPGA Evaluation and Development Kits
Announcements
Intel Support hours are Monday-Fridays, 8am-5pm PST, except Holidays. Thanks to our community members who provide support during our down time or before we get to your questions. We appreciate you!

Need Forum Guidance? Click here
Search our FPGA Knowledge Articles here.
5283 Discussions

system-console, close_service not working?

covfefe
New Contributor I
310 Views

Hello,

 

I am trying to close_service & claim_service (to handle disconnected devices). 

Unfortunately I am unable to make it work.

  1. How can I close_service pathA, then claim_service pathA ?
  2. Or, alternatively close all service paths, to keep the service console, but start fresh?

 

close_service master {%s}; claim_service master {%s} m

 

Response:

 

CLIENT (sock2532): close_service master {/devices/5AGT(FD3H3|MD3G3)|5AGXBB3D4|..@1#USB-1/(link)/JTAG/(110:132 v1 #0)/phy_0/master}; claim_service master {/devices/5AGT(FD3H3|MD3G3)|5AGXBB3D4|..@1#USB-1/(link)/JTAG/(110:132 v1 #0)/phy_0/master} m
SERVER (sock2532): Invalid command from the client
ErrorMsg : Could not claim service at /devices/5AGT(FD3H3|MD3G3)|5AGXBB3D4|..@1#USB-1/(link)/JTAG/(110:132 v1 #0)/phy_0/master: Channel is opened
    while executing
"claim_service {master} {/devices/5AGT(FD3H3|MD3G3)|5AGXBB3D4|..@1#USB-1/(link)/JTAG/(110:132 v1 #0)/phy_0/master} {m}"
ErrorCode: NONE
ErrorInfo:
Could not claim service at /devices/5AGT(FD3H3|MD3G3)|5AGXBB3D4|..@1#USB-1/(link)/JTAG/(110:132 v1 #0)/phy_0/master: Channel is opened
    while executing
"claim_service {master} {/devices/5AGT(FD3H3|MD3G3)|5AGXBB3D4|..@1#USB-1/(link)/JTAG/(110:132 v1 #0)/phy_0/master} {m}"
    while executing
"claim_service master {/devices/5AGT(FD3H3|MD3G3)|5AGXBB3D4|..@1#USB-1/(link)/JTAG/(110:132 v1 #0)/phy_0/master} m"
    ("eval" body line 1)

 

 

covfefe_1-1657742477065.png

 

0 Kudos
11 Replies
sstrell
Honored Contributor III
298 Views

close_service has to point to the claim path, not the service path (in your case, the master service path).

claim_service will point to the master service path.

covfefe
New Contributor I
293 Views

Isn't this what I am doing?

sstrell
Honored Contributor III
291 Views

No, it looks like you are using the master service path for both close_service and claim_service.  A claim path is usually created like this in a script after you've created the service path (mpath in this case):

set claim_path [claim_service master $mpath {} {}]

So then close_service can simply be:

close_service master $claim_path

covfefe
New Contributor I
279 Views

Thank you. Right now, if I try to 

claim_service master {/devices/5AGT(FD3H3|MD3G3)|5AGXBB3D4|..@1#USB-1/(link)/JTAG/(110:132 v1 #0)/phy_0/master} m

and the channel is open, I get an error message. How can I bypass this issue, without knowing the claim path? I assume I first need to close the channel, then do claim_service.  

An attempt at 

is_service_open master {/devices/5AGT(FD3H3|MD3G3)|5AGXBB3D4|..@1#USB-1/(link)/JTAG/(110:132 v1 #0)/phy_0/master}

does not work, and returns 0 regardless. 

An attempt at  

get_claimed_services master;

returns no values.

set claim_path [claim_service master {/devices/5AGT(FD3H3|MD3G3)|5AGXBB3D4|..@1#USB-1/(link)/JTAG/(110:132 v1 #0)/phy_0/master} {} {}]

 crashes by saying could not claim service, channel is open

sstrell
Honored Contributor III
276 Views

So you've done claim_service previously but you don't know what the claim path was?

What if you just write the whole thing out:

close_service master [claim_service master {/devices/5AGT(FD3H3|MD3G3)|5AGXBB3D4|..@1#USB-1/(link)/JTAG/(110:132 v1 #0)/phy_0/master} m]

covfefe
New Contributor I
266 Views

This does not work. 

As the previous message says, this command crashes

close_service master [claim_service master {/devices/5AGT(FD3H3|MD3G3)|5AGXBB3D4|..@1#USB-1/(link)/JTAG/(110:132 v1 #0)/phy_0/master} m]

CLIENT (sock2472): claim_service master {/devices/5AGT(FD3H3|MD3G3)|5AGXBB3D4|..@1#USB-1/(link)/JTAG/(110:132 v1 #0)/phy_0/master} m
SERVER (sock2472): Invalid command from the client
ErrorMsg : Could not claim service at /devices/5AGT(FD3H3|MD3G3)|5AGXBB3D4|..@1#USB-1/(link)/JTAG/(110:132 v1 #0)/phy_0/master: Channel is opened

so the following command as well

CLIENT (sock2472): close_service master [claim_service master {/devices/5AGT(FD3H3|MD3G3)|5AGXBB3D4|..@1#USB-1/(link)/JTAG/(110:132 v1 #0)/phy_0/master} m]

SERVER (sock2472): Invalid command from the client
ErrorMsg : Could not claim service at /devices/5AGT(FD3H3|MD3G3)|5AGXBB3D4|..@1#USB-1/(link)/JTAG/(110:132 v1 #0)/phy_0/master: Channel is opened

 

Yes, claim_path is unknown (application reboot)

ShengN_Intel
Employee
246 Views

Hi,


Or may be try to get service path first like below:

set m_path [lindex [get_service_paths master] 0 ]

set c_path [claim_service master $m_path ""]

close_service master $c_path


Best Regards,

Sheng

p/s: If any answer from community or Intel support are helpful, please feel free to mark as solution and give Kudos.


ShengN_Intel
Employee
218 Views

Any further update or concern? Does your problem resolved?


ShengN_Intel
Employee
190 Views

Since there are no further updates or concerns for this thread, I shall set this thread to close pending. If you still need further assistance, you are welcome reopen this thread within 20days or open a new thread, some one will be right with you.


covfefe
New Contributor I
167 Views

Thank you, the following successfully closes the service path:

set m_path [lindex [get_service_paths master] 0 ];
set c_path [claim_service master $m_path ""];
close_service master $c_path;

Now, to be able to re-claim an existing path, I first need to be able to check if it is closed. However, this command returns 0 regardless of the status (open or closed). 

is_service_open master {/devices/5AGT(FD3H3|MD3G3)|5AGXBB3D4|..@1#USB-1/(link)/JTAG/(110:132 v1 #0)/phy_0/master}

 Which then errors on the next command to claim it

claim_service master {/devices/5AGT(FD3H3|MD3G3)|5AGXBB3D4|..@1#USB-1/(link)/JTAG/(110:132 v1 #0)/phy_0/master} m

CLIENT (sock2256): claim_service master {/devices/5AGT(FD3H3|MD3G3)|5AGXBB3D4|..@1#USB-1/(link)/JTAG/(110:132 v1 #0)/phy_0/master} m
SERVER (sock2256): Invalid command from the client
ErrorMsg : Could not claim service at /devices/5AGT(FD3H3|MD3G3)|5AGXBB3D4|..@1#USB-1/(link)/JTAG/(110:132 v1 #0)/phy_0/master: Channel is opened

 

Is it possible "close_service master" does not really close it?

 

ShengN_Intel
Employee
112 Views

Hi,

 

After close_service, you have to get_service again in order to claim_service. claim_service can't be done straight away after closing service.


Best regards,
Sheng

p/s: If any answer from community or Intel support are helpful, please feel free to mark as solution and give Kudos.

Reply