开云体育

ctrl + shift + ? for shortcuts
© 2025 开云体育

Macro Line Comments #macros


 

Anyone know of a way to temporarily comment out a line in a macro? Would like to easily change a macro definition by temporarily commenting out a line and then restoring the definition later by uncommenting it. Didn’t notice it defined anywhere in the manual.


 

I write a macro that says:?

?TRX? Call Call de MyCall Mycall?


BTU CALL CALL de MyCall. RX

The gap allows you to quickly click on the open next?box and free form (type ahead) while FLDIGI is transmitting the top line. .? ?When I stop typing, the program jumps down to the closing line.? ? ?So, I have a start and end with a blank spot where I can type a message.? ?As long as I'm typing, the closing line stays below my text.? When I stop typing, FLDIGI runs out of text, then jumps down to the closing line.? ? Craig de N6SBN


On Sat, Jan 18, 2025 at 6:46?PM Leland Ford via <lelandford=[email protected]> wrote:
Anyone know of a way to temporarily comment out a line in a macro? Would like to easily change a macro definition by temporarily commenting out a line and then restoring the definition later by uncommenting it. Didn’t notice it defined anywhere in the manual.



--
Craig


 

I think that a hashtag at the beginning of the line is what you are looking for.
<# used for acknowledgement of multilple checkins>
This is a comment line in one of my macros


 

开云体育

From the on-line fldigi manual

Macro Description
<QRG:text> Insert current operating info with "text" into Rx stream, ie:
info text <<2013-01-12T21:18Z RTTY @ 14005000+0760>> which can be used to
return to a mode, rf, audio frequency.
<PAUSE> Cause transmission to pause at place of occurance in macro
text. "Pause/Break" key on keyboard resumes transmission
<TXATTEN:nn.n> set fldigi tx attenuator to value -30 dB <= val <= 0
<COMMENT:text> allow macro to contain a comment field; everything
between < and > is ignored by macro parser
<SAVE> save the current macro definitions to the current file

Undocumented, but also valid is the <#...> macro tag pair.? From the open source C++ code:

??? {"<COMMENT:",??? pCOMMENT},
?? ?{"<#",??? ??? ??? pCOMMENT},

73, David, W1HKJ

On 1/19/25 07:19, KD2QLH Bob via groups.io wrote:

I think that a hashtag at the beginning of the line is what you are looking for.
<# used for acknowledgement of multilple checkins>
This is a comment line in one of my macros


 


Hello Leland,

I had prepared this reply while Dave has already answered. I send it anyway because of the examples I just tried out...

There's a simple way to exclude Macro Definition text from being included when running the Macro.

Anything between (and including) the pointed brackets in this 'comment:' definition will be ignored: <comment: any text here within is ignored>


Let's assume you have a Macro Definition as follows (the added dashes indicate, only here in the e-mail, where the Macro Definition and Text Output begins/ends):

- - - - - -
ZCZC
THIS IS A TEST
and yet another line
NNNN
<comment: 1. BlaBlaBla>

ZCZC
THIS IS A TEST
and yet another line
NNNN
<comment: 2. More of the same...>

ZCZC
THIS IS A TEST
and yet another line
NNNN

<comment: 3. final comment: multi-line

Thus these Lines are considered Comments, until the closing pointed bracket (below) is reached:
>

NOW THIS WILL BE PRINTED / USED AGAIN WHEN CALLING THE MACRO...
- - - - - -


=> When you call this Macro, you'll get this:

- - - - - -
ZCZC
THIS IS A TEST
and yet another line
NNNN

ZCZC
THIS IS A TEST
and yet another line
NNNN

ZCZC
THIS IS A TEST
and yet another line
NNNN


NOW THIS WILL BE PRINTED / USED AGAIN WHEN CALLING THE MACRO...
- - - - - -

Note that even multi-line comments are possible, as long as there is no closing pointed bracket '>' within. And any leading/trailing linefeeds around any <comment:..> will also be output by the Macro exactly as specified.


- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -


On a related note, you may not be aware, but you can also invoke several actions 'on the fly', in other words, while the Macro is running:

In the 'Fldigi Users Manual 4.2.00', they are listed in a separate chapter 'Inline Macros'. These include, among others:

<!MODEM: ,...> Change to specified modem (with parameters)
<!GOFREQ:NNNN> Move audio carrier to a specific audio frequency
<!QSY:FFF.F[:NNNN]> Move to specific RF and Audio frequency
<!WAIT:NN> Wait (no audio) for specified number of seconds


Example: similar to the commented definition above, but run a sequence of 3 DigiModes, one per 'message':

- - - - - -
<!MODEM:MFSK16>
ZCZC
THIS IS A TEST
and yet another line
NNNN
<comment: 1. BlaBlabla>

<!MODEM:MFSK32>
ZCZC
THIS IS A TEST
and yet another line
NNNN
<comment: 2. AlbAlbAlb>

<!MODEM:MFSK64>
ZCZC
THIS IS A TEST
and yet another line
NNNN

<comment: 3. final comment: multi-line

Thus these Lines are considered Comments, until the closing pointed bracket (below) is reached:
>

NOW THIS WILL BE PRINTED AGAIN...
- - - - - -


=> When you call this Macro, you'll get this (while the DigiModes are auto-switched as indicated):

- - - - - -
<!MODEM:MFSK16>

ZCZC
THIS IS A TEST
and yet another line
NNNN<!MODEM:MFSK32>

ZCZC
THIS IS A TEST
and yet another line
NNNN<!MODEM:MFSK64>

ZCZC
THIS IS A TEST
and yet another line
NNNN


NOW THIS WILL BE PRINTED AGAIN...
- - - - - -


- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -


Finally, and perfectly in line with the above, if you have a (non-text) actual FLdigi Macro Command you wish to temporarily comment out, precede the Macro Tag within the Macro Definition with 'comment:' as shown here below. This is necessary PER COMMAND LINE, because the Macro Commands include a '>' at the end, which is also interpreted as 'end of comment':

Original (active): <MODEM:RTTY:170:45.45:5>
Comment (inactive): <comment:MODEM:RTTY:170:45.45:5>


Hope this helps.


Best regards

SWL Tobias
.-.-.
Am Sonntag, 19. Januar 2025 um 03:46:47 MEZ hat Leland Ford via groups.io <lelandford@...> Folgendes geschrieben:


Anyone know of a way to temporarily comment out a line in a macro? Would like to easily change a macro definition by temporarily commenting out a line and then restoring the definition later by uncommenting it. Didn’t notice it defined anywhere in the manual.


 

Leland,
Two macros, one with and one without would be my approach thus avoiding a macro edit each time a change is needed.? ?Cheers, Phil?


 

Need multiple macro set up's. File->Config Script menu item might be the answer. Edit once, use multiple times by changing the macro setup via loading a script file.

Robert


 

开云体育

Not sure I know how to do that.


From: [email protected] <[email protected]> on behalf of Robert, KK5VD via groups.io <kk5vd@...>
Sent: Monday, January 20, 2025 2:58 PM
To: [email protected] <[email protected]>
Subject: Re: [winfldigi] Macro Line Comments #macros
?

Need multiple macro set up's. File->Config Script menu item might be the answer. Edit once, use multiple times by changing the macro setup via loading a script file.

Robert






 

Thanks for all your responses. I appreciate it.
?
The undocumented “<#” is kinda what I had in mind.
?
Leland