Thursday, January 08, 2009     Register | Login | Search | Contact Us
     

Many of you already received communications about the move of the Cadence user community into cadence.com. And many of you have already joined, with over 4000 registrations in the first two weeks.

The new Cadence Community enhances the ability of Cadence users to connect and collaborate. In addition to moving the community into cadence.com -- enabling single sign-on for community, Sourcelink and Cadence events -- the new site is organized around nine technology segments, giving you easy access to product information, training, forums and blogs. Some of the new features include:
  • Ability to respond to posts via e-mail
  • Technology-specific blogs
  • Latest Web 2.0 social networking capabilities
  • Public profile options
  • Private messaging
  • Friends lists
Visit the new Cadence Community today at www.cadence.com/community and join the discussions!

Registration note: Due to the scope of the enhancements and the new SSO registration system, we were not able to migrate existing cdnusers.org member accounts. So new registrations are required, but this enables a broader set of functionality we think you'll enjoy.

Forum note: Under the guidance of forum moderators, we have taken the 20+ cdnusers.org forums and consolidated them into 11 forums on the new site. Posts have been brought over so you can leverage that posting history. CDNusers forums will be set to read only starting 7/30, and cdnusers.org will be redirected to the new community on 8/4.

Best regards,
Mike and Tom

Michael A. Catrambone - Steering Committee Chairman
Distinguished Engineer
PCB/Mechanical
UTStarcom, Inc.

Tom Diederich
Cadence Community Manager
Home
Forums
Subject: Access Host-ID by Skill
Posting to forums is available to community members only.
Login or Register
Rate this topic:
   
Author Messages
sghsu
Posts: 4
Online: User is Offline
8/08/2006 7:32 PM  
Hi, Gurus,

Is it possible to access user Host-ID by Skill? I have tried function getShellEnvVar. It seems useless. Thank you for your helps in advance.

BRs,

Sogo Hsu
Dave Elder
Moderator
Posts: 150
Online: User is Offline
8/15/2006 6:12 PM  
Hi Sogo

You could write the output of ipconfig /all to a text file using a system command. ie.
system("ipconfig /all > ipdata.txt")
Then get the physical address thus:
p = axlDMOpenFile("TEMP" "ipdata.txt", "r")
while(gets(ln, p)
when(index(ln, "Physical Address")
hostId = cadr(parseString(ln, ":\n"))
)
)
axlDMClose(p)
println(hostId)

Cheers, Dave

Dave Elder
Tait Electronics
sghsu
Posts: 4
Online: User is Offline
8/15/2006 8:46 PM  
Dear Dave,

I sincerely appreciated your helps very well.

BRs,

Sogo Hsu
leonlee
Posts: 81
Online: User is Offline
8/27/2006 6:47 PM  
Hi Dave,

how about the command "infile" instead of axlDMOpenFile?

Leon Lee
Schneider-Electric
Dave Elder
Moderator
Posts: 150
Online: User is Offline
8/27/2006 7:06 PM  

Hi Leon,

That would work too - but isn't quite as reliable.

Cheers, Dave


Dave Elder
Tait Electronics
rajesh
Posts: 11
Online: User is Offline
11/15/2006 11:52 PM  
Hi dave,

Can you explain step by step how to get the host id i could'nt undrstand this

"You could write the output of ipconfig /all to a text file using a system command. ie.
system("ipconfig /all > ipdata.txt")
Then get the physical address thus:
p = axlDMOpenFile("TEMP" "ipdata.txt", "r")
while(gets(ln, p)
when(index(ln, "Physical Address")
hostId = cadr(parseString(ln, ":\n"))
)
)
axlDMClose(p)
println(hostId)"


Regards
Rajesh.
Dave Elder
Moderator
Posts: 150
Online: User is Offline
11/19/2006 5:36 PM  
Hi Rajesh,

Here's how it works:

system("ipconfig /all > ipdata.txt"); Prints the result of a DOS ipconfig request to a text file (ipdata.txt) in the working folder.
;Note that this command is slightly different in the Unix world (use "ifconfig -a").
p = axlDMOpenFile("TEMP" "ipdata.txt", "r"); Open that file for reading
while(gets(ln, p); Step through each line of the file ...
when(index(ln, "Physical Address"); ...Until you reach the Physical Address line
hostId = cadr(parseString(ln, ":\n")); The hostId is the second "word" in the Physical Address line
)
)
axlDMClose(p); Close the file
println(hostId); Print the hostId to the console

Cheers, Dave

Dave Elder
Tait Electronics
rajesh
Posts: 11
Online: User is Offline
11/23/2006 8:14 PM  
thanks dave.
hunter
Posts: 3
Online: User is Offline
11/24/2006 3:49 AM  
Posted By hunter on 11/24/2006 3:44 AM

change

hostId = cadr(parseString(ln, ":\n"));

to

hostId = car(  last (parseString(ln, " :\n"));
system("ipconfig /all > ipdata.txt")
;;Then get the physical address thus:
p = axlDMOpenFile("TEMP" "ipdata.txt", "r")
while(gets(ln, p)
when(index(ln, "Physical Address")
hostId = car(last(parseString(ln, ":\n")))
);end when
);end while
axlDMClose(p)
deleteFile("./ipdata.txt");
println(hostId)
;;


Posting to forums is available to community members only.
Login or Register

Forums > Silicon-package-board > Shared code - SKILL > Access Host-ID by Skill


ActiveForums 3.6
     
Copyright 2006 Cadence Design Systems, Inc.