开云体育

.MEAS scripting


 

开云体育

I have a fairly large model that I need to probe many of its components for Voltage, Current, and/or Power over a run period.

Not difficult once I get the syntax correct, for individual parts withy clear net names, but it gets hairy, or at least tedious, to build up the .meas statements for many parts.

?

In the plot pane, in Add Traces, I see a syntax like “Id(M1), Ie(Q1), I(u1:E1), etc.”

Is there a form of that for Voltages, referring to other component pin numbers, “V(R1:1)” or the like?

?

Dave

?


 
Edited

Voltages are net (wire) properties.? You can refer to them only by netname.
?
Choose good (useful) netnames.
?
Andy
?


 

And by the way, "Add Traces" is the full list of names of things you can plot.? You can mix and match in algebraic formulas, but that is the full list.
?
Andy


 

开云体育

<expletive>!

Well, currents are important to the analysis, so that’s something, but Power is, as well, and that needs differential voltages.

Nets that are significant such as I/O pins are properly labelled, and there are three logically separate sections, with named nets. I can go through the “internal” nodes and assign names I guess.

10 < #nodes < 100 so it’s not too onerous…

?

Thanks!

Dave

?

?

From: [email protected] <[email protected]> On Behalf Of Andy I via groups.io


Sent: Friday, April 04, 2025 10:05 AM
To: [email protected]
Subject: EXTERNAL: Re: [LTspice] .MEAS scripting

?

Voltages are net (wire) properties.? You can refer to them only by netname.

?

Choose good (useful) netname.

?

Andy

?


 

On 4/4/25 1:09 PM, Bell, Dave via groups.io wrote:
<*expletive*>!
Well, currents are important to the analysis, so that’s something, but Power is, as well, and that needs differential voltages.
V(N0001,N0002)



--

David Schultz
"The cheeper the crook, the gaudier the patter." - Sam Spade


 

开云体育

That is not very wise, because those nodes can get re-allocated whenever a change is made to the .ASC. It's much safer to name all the nodes, even just A, B, C ...

On 2025-04-04 19:29, David Schultz via groups.io wrote:
On 4/4/25 1:09 PM, Bell, Dave via groups.io wrote:
<*expletive*>!

Well, currents are important to the analysis, so that’s something, but Power is, as well, and that needs differential voltages.

V(N0001,N0002)



--
OOO - Own Opinions only If something is true: * as far as we know - it's science *for certain - it's mathematics *unquestionably - it's religion

Virus-free.


 

开云体育

Related, there apparently used to be a Ctrl-F search for net nets by name.

I am running XVII, and that does nothing.

Also, found a hint that maybe the search function was hiding under Tools, but can’t find it there.

AND, is there (still?) a Highlight Nets function?

?

Dave

?

From: [email protected] <[email protected]> On Behalf Of John Woodgate
Sent: Friday, April 04, 2025 12:15 PM
To: [email protected]
Subject: EXTERNAL: Re: [LTspice] .MEAS scripting

?

That is not very wise, because those nodes can get re-allocated whenever a change is made to the .ASC. It's much safer to name all the nodes, even just A, B, C ...

On 2025-04-04 19:29, David Schultz via groups.io wrote:

On 4/4/25 1:09 PM, Bell, Dave via groups.io wrote:

<*expletive*>!

Well, currents are important to the analysis, so that’s something, but Power is, as well, and that needs differential voltages.

V(N0001,N0002)


--
OOO - Own Opinions only If something is true: * as far as we know - it's science *for certain - it's mathematics *unquestionably - it's religion

?

Virus-free.


 

On 4/4/25 2:14 PM, John Woodgate wrote:
That is not very wise, because those nodes can get re-allocated whenever a change is made to the .ASC. It's much safer to name all the nodes, even just A, B, C ...
It was just an example of how to get a voltage difference. Not a recommendation to use internally generated node names.


--

David Schultz
"The cheeper the crook, the gaudier the patter." - Sam Spade


 

开云体育

Place cursor on the net, then CTRL-right click and select Highlight from the drop-down pane. Use ESC to cancel.

On 2025-04-04 20:34, Bell, Dave via groups.io wrote:

Related, there apparently used to be a Ctrl-F search for net nets by name.

I am running XVII, and that does nothing.

Also, found a hint that maybe the search function was hiding under Tools, but can’t find it there.

AND, is there (still?) a Highlight Nets function?

?

Dave

?

From: [email protected] <[email protected]> On Behalf Of John Woodgate
Sent: Friday, April 04, 2025 12:15 PM
To: [email protected]
Subject: EXTERNAL: Re: [LTspice] .MEAS scripting

?

That is not very wise, because those nodes can get re-allocated whenever a change is made to the .ASC. It's much safer to name all the nodes, even just A, B, C ...

On 2025-04-04 19:29, David Schultz via groups.io wrote:

On 4/4/25 1:09 PM, Bell, Dave via groups.io wrote:

<*expletive*>!

Well, currents are important to the analysis, so that’s something, but Power is, as well, and that needs differential voltages.

V(N0001,N0002)


--
OOO - Own Opinions only If something is true: * as far as we know - it's science *for certain - it's mathematics *unquestionably - it's religion

?

Virus-free.

--
OOO - Own Opinions only If something is true: * as far as we know - it's science *for certain - it's mathematics *unquestionably - it's religion


 

开云体育

A beginner cannot know your intention, though.

On 2025-04-04 20:36, David Schultz via groups.io wrote:
On 4/4/25 2:14 PM, John Woodgate wrote:
That is not very wise, because those nodes can get re-allocated whenever a change is made to the .ASC. It's much safer to name all the nodes, even just A, B, C ...

It was just an example of how to get a voltage difference. Not a recommendation to use internally generated node names.


--
OOO - Own Opinions only If something is true: * as far as we know - it's science *for certain - it's mathematics *unquestionably - it's religion

Virus-free.


 

开云体育

On 04/04/2025 21:34, Bell, Dave via groups.io wrote:

Related, there apparently used to be a Ctrl-F search for net nets by name.

I am running XVII, and that does nothing.

Also, found a hint that maybe the search function was hiding under Tools, but can’t find it there.

AND, is there (still?) a Highlight Nets function?

Find <NETNAME> does work in XVII. Ctrl-F brings up a search box at the top right in the icon bar. Enter any text and it will be highlighted if it exists, and if it includes a net name, the net connections will be highlighted too. But the search is strictly text. So make sure to name your nets with that in mind.

--
Regards,
Tony


 

On Sat, Apr 5, 2025 at 05:18 AM, Tony Casey wrote:
... But the search is strictly text. So make sure to name your nets with that in mind.
Can a net name (or any other schematic text) be anything other than text?
?
Andy
?


 

开云体育

'text' in this context may mean a specific character set, such as 'Extended ASCII'. I've not found a way to put Greek letters in any LTspice text, but some people seem to be able to. Apart form '?', that is.

On 2025-04-05 14:01, Andy I via groups.io wrote:
On Sat, Apr 5, 2025 at 05:18 AM, Tony Casey wrote:
... But the search is strictly text. So make sure to name your nets with that in mind.
Can a net name (or any other schematic text) be anything other than text?
?
Andy
?
--
OOO - Own Opinions only If something is true: * as far as we know - it's science *for certain - it's mathematics *unquestionably - it's religion

Virus-free.


 

What I meant is that the search context is just text. You can't specify what type of object you're searching for.

--
Regards,
Tony

On 5 April 2025 15:01:18 CEST, "Andy I via groups.io" <AI.egrps+io@...> wrote:
On Sat, Apr 5, 2025 at 05:18 AM, Tony Casey wrote:


... But the search is strictly text. So make sure to name your nets with
that in mind.
Can a net name (or any other schematic text) be anything other than text?

Andy




--<br>Regards,<br>Tony<br>


 

开云体育

I felt very stupid a while after that email:

The search box seems always to be there, but only becomes active after Ctrl-F.

I just never saw anything pop up or change, so ASSumed it didn’t work!

The box is not labelled, just a blank area on the toolbar, and after Ctrl-F, a slightly smaller input box outline appears in the larger? blank area. Unless one is expecting it or looking directly at the normally inactive area, . . .

?

Dave

?

From: [email protected] <[email protected]> On Behalf Of Tony Casey
Sent: Saturday, April 05, 2025 2:19 AM
To: [email protected]
Subject: EXTERNAL: Re: [LTspice] .MEAS scripting

?

On 04/04/2025 21:34, Bell, Dave via groups.io wrote:

Related, there apparently used to be a Ctrl-F search for net nets by name.

I am running XVII, and that does nothing.

Also, found a hint that maybe the search function was hiding under Tools, but can’t find it there.

AND, is there (still?) a Highlight Nets function?

Find <NETNAME> does work in XVII. Ctrl-F brings up a search box at the top right in the icon bar. Enter any text and it will be highlighted if it exists, and if it includes a net name, the net connections will be highlighted too. But the search is strictly text. So make sure to name your nets with that in mind.

--
Regards,
Tony

?


 

开云体育

All part of the fascinating rural charm of LTspice.?

On 2025-04-05 17:28, Bell, Dave via groups.io wrote:

I felt very stupid a while after that email:

The search box seems always to be there, but only becomes active after Ctrl-F.

I just never saw anything pop up or change, so ASSumed it didn’t work!

The box is not labelled, just a blank area on the toolbar, and after Ctrl-F, a slightly smaller input box outline appears in the larger? blank area. Unless one is expecting it or looking directly at the normally inactive area, . . .

?

Dave

?

From: [email protected] <[email protected]> On Behalf Of Tony Casey
Sent: Saturday, April 05, 2025 2:19 AM
To: [email protected]
Subject: EXTERNAL: Re: [LTspice] .MEAS scripting

?

On 04/04/2025 21:34, Bell, Dave via groups.io wrote:

Related, there apparently used to be a Ctrl-F search for net nets by name.

I am running XVII, and that does nothing.

Also, found a hint that maybe the search function was hiding under Tools, but can’t find it there.

AND, is there (still?) a Highlight Nets function?

Find <NETNAME> does work in XVII. Ctrl-F brings up a search box at the top right in the icon bar. Enter any text and it will be highlighted if it exists, and if it includes a net name, the net connections will be highlighted too. But the search is strictly text. So make sure to name your nets with that in mind.

--
Regards,
Tony

?

--
OOO - Own Opinions only If something is true: * as far as we know - it's science *for certain - it's mathematics *unquestionably - it's religion

Virus-free.


 

开云体育

I love “rural charm of LTspice”!

Wild critters and cow pies…

?

From: [email protected] <[email protected]> On Behalf Of John Woodgate
Sent: Saturday, April 05, 2025 9:32 AM
To: [email protected]
Subject: EXTERNAL: Re: [LTspice] .MEAS scripting

?

All part of the fascinating rural charm of LTspice.?

On 2025-04-05 17:28, Bell, Dave via groups.io wrote:

I felt very stupid a while after that email:

The search box seems always to be there, but only becomes active after Ctrl-F.

I just never saw anything pop up or change, so ASSumed it didn’t work!

The box is not labelled, just a blank area on the toolbar, and after Ctrl-F, a slightly smaller input box outline appears in the larger? blank area. Unless one is expecting it or looking directly at the normally inactive area, . . .

?

Dave

?

From: [email protected] <[email protected]> On Behalf Of Tony Casey
Sent: Saturday, April 05, 2025 2:19 AM
To: [email protected]
Subject: EXTERNAL: Re: [LTspice] .MEAS scripting

?

On 04/04/2025 21:34, Bell, Dave via groups.io wrote:

Related, there apparently used to be a Ctrl-F search for net nets by name.

I am running XVII, and that does nothing.

Also, found a hint that maybe the search function was hiding under Tools, but can’t find it there.

AND, is there (still?) a Highlight Nets function?

Find <NETNAME> does work in XVII. Ctrl-F brings up a search box at the top right in the icon bar. Enter any text and it will be highlighted if it exists, and if it includes a net name, the net connections will be highlighted too. But the search is strictly text. So make sure to name your nets with that in mind.

--
Regards,
Tony

?

--
OOO - Own Opinions only If something is true: * as far as we know - it's science *for certain - it's mathematics *unquestionably - it's religion

?

Virus-free.


 

开云体育

Thank you.

On 2025-04-05 17:36, Bell, Dave via groups.io wrote:

I love “rural charm of LTspice”!

Wild critters and cow pies…

?

From: [email protected] <[email protected]> On Behalf Of John Woodgate
Sent: Saturday, April 05, 2025 9:32 AM
To: [email protected]
Subject: EXTERNAL: Re: [LTspice] .MEAS scripting

?

All part of the fascinating rural charm of LTspice.?

On 2025-04-05 17:28, Bell, Dave via groups.io wrote:

I felt very stupid a while after that email:

The search box seems always to be there, but only becomes active after Ctrl-F.

I just never saw anything pop up or change, so ASSumed it didn’t work!

The box is not labelled, just a blank area on the toolbar, and after Ctrl-F, a slightly smaller input box outline appears in the larger? blank area. Unless one is expecting it or looking directly at the normally inactive area, . . .

?

Dave

?

From: [email protected] <[email protected]> On Behalf Of Tony Casey
Sent: Saturday, April 05, 2025 2:19 AM
To: [email protected]
Subject: EXTERNAL: Re: [LTspice] .MEAS scripting

?

On 04/04/2025 21:34, Bell, Dave via groups.io wrote:

Related, there apparently used to be a Ctrl-F search for net nets by name.

I am running XVII, and that does nothing.

Also, found a hint that maybe the search function was hiding under Tools, but can’t find it there.

AND, is there (still?) a Highlight Nets function?

Find <NETNAME> does work in XVII. Ctrl-F brings up a search box at the top right in the icon bar. Enter any text and it will be highlighted if it exists, and if it includes a net name, the net connections will be highlighted too. But the search is strictly text. So make sure to name your nets with that in mind.

--
Regards,
Tony

?

--
OOO - Own Opinions only If something is true: * as far as we know - it's science *for certain - it's mathematics *unquestionably - it's religion

?

Virus-free.

--
OOO - Own Opinions only If something is true: * as far as we know - it's science *for certain - it's mathematics *unquestionably - it's religion


 

I usually ignore that box in the top right.
?
Ctrl-F > Type text > Text becomes highlighted if it is found.
?
That's all I needed to see.
?
LTspice always was a bit picky about what it found.? e.g., it only finds text that starts with what you type for it to find.? No wildcards, and no finding strings embedded within longer strings, except when it starts the longer string.
?
Andy


 

开云体育

Certainly room for improvement, but FAR better than squinting at the screen to read the net names, or worse, hovering the probe, because I haven’t assigned all of them yet!

?

From: [email protected] <[email protected]> On Behalf Of Andy I via groups.io
Sent: Saturday, April 05, 2025 9:57 AM
To: [email protected]
Subject: EXTERNAL: Re: [LTspice] .MEAS scripting

?

I usually ignore that box in the top right.

?

Ctrl-F > Type text > Text becomes highlighted if it is found.

?

That's all I needed to see.

?

LTspice always was a bit picky about what it found.? e.g., it only finds text that starts with what you type for it to find.? No wildcards, and no finding strings embedded within longer strings, except when it starts the longer string.

?

Andy