Jump to content
jedimatt42

Force Command ver 1.26 : kinda like command.com from 1985 (no TIPI required!)

Recommended Posts

Updated Force Command 1.25. 

 

This adds routines to read the TIPI mouse, and support a mouse pointer in 80x30 F18A text mode. For the purpose of allowing FCMENU to use these routines and support click to launch. 

 

Mouse pointer only works in F18A mode.

 

It felt pretty slick to boot into ForceCommand, where my AUTOCMD launches FCMENU. I click on a script entry that maps DSK1 to TI-Artist, and then XB DSK1.LOAD, and then in TI-Artist the mouse also works (due to prior work) 

 

Improvements... I should probably hide the mouse pointer until it moves... and provide next and back screen elements to click on if your menu has multiple pages.... next weekend.

  • Like 6
  • Thanks 1

Share this post


Link to post
Share on other sites

Hi @jedimatt42,

 

today I made the update from ForceCommand 1.17 to 1.25 but my autocmd file does not work properly.

 

It starts good and I can select the EDIT80 program, but if I select the menu item "TI System Info" or simply select "X for Quit" 
ForceCommand shows the message "Error, label already defined at line: 8553". And the system blocks with the tipi LED is on.

After a reset all is good again.

So I tried some other versions. My problem occures in version 1.24.

IMG_4222.thumb.JPG.b5853fa5c7a61bfde26f354fbb1da511.JPG

The line number 8553 is always the same.

 

In version 1.22 my autocmd works without a problem, the same as in version 1.17.

 

Do I have to change something in my autocmd file?

 

Maybe I will make a shorter autocmd file and using the new fcmenu function for my menu items.

 

p.s. I have a F18A and a SAMS card in my system.

My autocmd file is still under construction: AUTOCMD

 

Thank you for your help!

  • Like 2
  • Thanks 1

Share this post


Link to post
Share on other sites

@wolhess - just a couple tips reviewing the AUTOCMD code...

 

A80:
... 
load TIPI.AUTOCMD

"load" is the command for EA5 binaries... this may appear to work if the file type checking isn't there... as once I start far enough down the load code path, if it fails, the console is reset, which triggers re-entering FC and it runs your new AUTOCMD script. 

A better choice of command for this would be 'exit', as it resets the console on purpose, and if the GROM for force command was loaded, then FC is re-entered, and the script is picked up again.   (you do this in A40: ) as well. 

 

INFO:
...
AUTOCMD

GOTO BEGIN would be a better choice here. While you can run scripts from the script, the calling script details (line number, file name, PAB) are on the stack so when a script completes, it can return to where it left off in the calling script. Doing this repeatedly will eventually run out of stack and corrupt environment variables, and then label data, etc... GOTO BEGIN will instead, will just reset the existing PAB to the record number that the BEGIN label is on, and resume execution. 

 

I am still looking for the root cause, more later...

 

Some simple GOTO behavior seems to be broken as well... 

 

 

  • Like 2
  • Thanks 1

Share this post


Link to post
Share on other sites

Update 1.26 - goto fixed, along with a couple other things.

 

@wolhess your AUTOCMD seems to work for me as expected with these fixes.

  • Like 3
  • Thanks 1

Share this post


Link to post
Share on other sites
11 hours ago, jedimatt42 said:

@wolhess - just a couple tips reviewing the AUTOCMD code...

 

A80:
... 
load TIPI.AUTOCMD

"load" is the command for EA5 binaries... this may appear to work if the file type checking isn't there... as once I start far enough down the load code path, if it fails, the console is reset, which triggers re-entering FC and it runs your new AUTOCMD script. 

A better choice of command for this would be 'exit', as it resets the console on purpose, and if the GROM for force command was loaded, then FC is re-entered, and the script is picked up again.   (you do this in A40: ) as well. 

 

INFO:
...
AUTOCMD

GOTO BEGIN would be a better choice here. While you can run scripts from the script, the calling script details (line number, file name, PAB) are on the stack so when a script completes, it can return to where it left off in the calling script. Doing this repeatedly will eventually run out of stack and corrupt environment variables, and then label data, etc... GOTO BEGIN will instead, will just reset the existing PAB to the record number that the BEGIN label is on, and resume execution. 

 

I am still looking for the root cause, more later...

 

Some simple GOTO behavior seems to be broken as well... 

 

 

Thank You for your tips, I will change my autocmd as you recommended.

Share this post


Link to post
Share on other sites
On 8/7/2021 at 7:50 AM, jedimatt42 said:

Update 1.26 - goto fixed, along with a couple other things.

 

@wolhess your AUTOCMD seems to work for me as expected with these fixes.

@jedimatt42, Yes my autocmd is workis again as before. 

 

Once again, that was a super quick fix! Many Thanks

  • Like 3

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...

  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...