In the process of making the latest version of Solar89, I got fed up with having to copy and paste *.89t and *.89p files and change their extensions to *.v2t and *.9xt. I wrote a Python script to do it for me called renamr68k.

What exactly am I talking about, you ask? (If you understood exactly what I just said, skip the next two paragraphs).

GCC4TI produces executable files for all three supported 68k calculators- the 92+, the 89, and the V200. However, if an assembly program needs external files, or is coupled with useful TI-BASIC programs (both of which are true for Solar89) and you only have one 68k calculator, you'll need to manually create duplicate versions for the other calculators. So if I need the text file "test.89t", I send it to my computer from my 89, make two copies, and change them to "test.9xt" and "test.v2t".

The same problem is true if you are making BASIC programs with your calculator and would like to support the other 68ks. Yes, in both cases a user could do it themselves, but they may not know that the file formats are identical on all three 68k calculators.

Hence, this Python (2.x) script. Credit to Kerm for coming up with the core of the name- renamr (which I expanded to renamr68k).

It has been submitted to Cemetech and ticalc.org... download here on Cemetech.
Renamr? Corona, Flare, or something else sun-related (to go with Solar89)?
KermMartian wrote:
Renamr? Corona, Flare, or something else sun-related (to go with Solar89)?


I hadn't thought of that kind of name... was thinking of something more like "Renamr". Maybe Flare... but as this isn't really related to Solar89 I was leaning towards a name that says what it does (like your "BinPac8x" or "Branchmap" scripts).

Maybe renamr68k?
I like renamr68k. Smile Does what it says on the tin; I like that kind of project name.
renamr68k it is.

I've uploaded it to the Cemetech archives, and to ticalc.org- it's still pending on ticalc of course but you can get it from Cemetech here.
TC01 wrote:
renamr68k it is.

I've uploaded it to the Cemetech archives, and to ticalc.org- it's still pending on ticalc of course but you can get it from Cemetech here.
I'll have to look at your code; I hope it's no more than about 10 or 15 lines of Python. Smile
KermMartian wrote:
TC01 wrote:
renamr68k it is.

I've uploaded it to the Cemetech archives, and to ticalc.org- it's still pending on ticalc of course but you can get it from Cemetech here.
I'll have to look at your code; I hope it's no more than about 10 or 15 lines of Python. Smile


Not counting the script stuff (arguments, help text, etc.) and imports, it's a 19 line function, but that includes several print statements (3) and code to count how many files I'm working on (2)- this gets printed after running. So... 14 lines.

And, I just realized I had an unnecessary return statement at the end of the function... that technically makes it 15 lines I suppose.
Aight, I think that'll be acceptable. Wink I'm trying to think if there are ways that you could expand this to do other handy things, but nothing is coming to me yet.
  
Register to Join the Conversation
Have your own thoughts to add to this or any other topic? Want to ask a question, offer a suggestion, share your own programs and projects, upload a file to the file archives, get help with calculator and computer programming, or simply chat with like-minded coders and tech and calculator enthusiasts via the site-wide AJAX SAX widget? Registration for a free Cemetech account only takes a minute.

» Go to Registration page
Page 1 of 1
» All times are UTC - 5 Hours
 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

 

Advertisement