Jump to content
Paul DeRocco

Where does CAL send "message" output?

Recommended Posts

It used to be the status bar, but apparently the current Cakewalk has no status bar. I don't see messages from my CAL file appearing anywhere, but its a huge screen with lots of tiny widgets all over it, so I could be missing it.

 

Share this post


Link to post
Share on other sites

AFAIK, the CAL message function still sends to the status bar.

The status bar was removed from the Skylight UI in 2010.

Share this post


Link to post
Share on other sites

It has been years since I have done anything with CAL scripts. but I dimly recall the ability to construct messages with dynamic content, such as telling the user to enter some figure - like maybe a percentage, or a range, or whatever, so if my memory is correct, then couldn't any CAL script be modified to output things that used to go through the message function, to instead be put out like the text I refer to?  It wouldn't be too difficult to alter a script to try it.

Is there any particular CAL script you want to run?  I would be happy to try to modify it to output message content as line output.

Bob Bone

 

Share this post


Link to post
Share on other sites

There is a Pause function that outputs info to a message box, and a Format function to construct text strings from numeric data, etc..., that might work:

(from a CAL guide):

(pause <operand1> [[<operand2>]……])

This is similar to the “message” function and again you can combine strings, integers (“int”, “word”, “dword”), or functions. The difference is that “pause” halts execution of the CAL program and displays a dialog box in the middle of the screen containing the information the user provides in the function statement plus ‘OK’ and ‘Cancel’ buttons. The user must click ‘OK’ or hit the ‘Enter’ key to acknowledge the “pause” box before the program will continue. The user can also click the ‘Cancel’ button or hit the ‘Esc’ key and abort the CAL program completely.9 Besides displaying information critical to the user’s decision to continue the program or cancel, the “pause” is a great troubleshooting tool for programmers.

If a CAL program is not acting quite right or if you want to verify the operation of some part of a program, you can place “pause” statements at key locations in the code to display the contents of some important variables and see if things are running as planned.

Note this example:

(if (> something somevalue) (do (pause “Reached first test. somevalue = “ somevalue) (go on about your business.....

Here a “pause” has been placed at the ‘then’ part of an “if” function to help verify if that function is being called. If it is, the “pause” tells the programmer where the program currently is and what the current value of variable ‘somevalue’ is. After the programmer hits ‘Enter’ or clicks ‘Ok’, the program goes on as if nothing ever happened. By the way, there is a limit of 128 characters for a “pause” message, so if you have allot of information to give out, it may require more than one “pause” box to deliver it

Bob Bone

Share this post


Link to post
Share on other sites

Yes, I used pause as an alternative, but sometimes that's not appropriate because it, well, pauses. But I managed to use it to find my bug. Thanks.

Share this post


Link to post
Share on other sites
On 12/6/2019 at 2:23 AM, Paul DeRocco said:

Yes, I used pause as an alternative, but sometimes that's not appropriate because it, well, pauses. But I managed to use it to find my bug. Thanks.

I thought I was doing good just remembering about CAL - been quite a while since I have done anything with it.

Glad you are sorted out.  :)

Bob Bone

Share this post


Link to post
Share on other sites

Mike would love to get it.  I am just starting with Cakewalk/Cal and need to change one of the scripts -- Split Channel to Tracks. It is part of the install.

Specifically, assign Midi IN and Midi OUT on the Split tracks to the Midi Channel events came from. May be you can do this is in your SLEEP!! and give me the updates to the Script. It may take some time for me to get the names of the objects and functions correctly.

There is also an unwanted Shift in the Tracks -- for example post split, Tracks are playing one Mid Channel than what they should. I think this should be easy to change in the code. 

Does Message function work? Where does the Output Display - is it fleeting and fast to see or it does not display at all. What is the equivalent function for simple Print/Log?

Thanks in advance Sri.

Share this post


Link to post
Share on other sites

The following link is for my whole CAL repository. It’s stored in my OneDrive feel free to download the lot. The majority of the files are in the zip archive.  The link is good go a week. 
 

https://1drv.ms/f/s!Ahg7GEVUP0HfvFn2ew71b680OgES

. BTW - I’m no CAL programmer or expert of any kind so I can only help with the resources above. Hope it helps. It’s everything I could find on the Net about CAL.

Edited by Michael Vovel (MUDGEL)
  • Like 1

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now

×
×
  • Create New...