Jump to content
ralphb

xdt99: New TI 99 cross-development tools available

Recommended Posts

21 minutes ago, retroclouds said:

I have been thinking of using xdt99 as backend assembler in my TiVi editor. Could do some cool stuff, like assemble, halt on error and jump to the corresponding source code line.

I prefer to integrate TIPI like a set of devices, not an co-processor. 

 

But, as I said.. 'Technically'...   Thankfully nobody has the interest and imagination and skill in the necessary combination to have abused it in that way yet. 

 

[email protected]

  • Like 2

Share this post


Link to post
Share on other sites
On 1/17/2020 at 6:28 AM, ralphb said:

But xdt99 and core Python is less than 5 MB combined, so creating a 1 GB image just to have xdt99 seems a little wasteful.  I get your point, however, and I'll think about easing installation.

Wrapping up xdt99 into a packaging tool should be pretty straightforward. On Debian variants like Raspbian, you'd go for the .deb format and use apt to install it. On Mac, you could use Homebrew. In both cases, you'd provide a dependency spec to pull in the version of Python needed if it isn't already present.

 

But as Matt mentioned, installing that package onto a TIPI would likely break things in a way that would make it tough to troubleshoot.

Share this post


Link to post
Share on other sites
1 hour ago, InfiniteTape said:

But as Matt mentioned, installing that package onto a TIPI would likely break things in a way that would make it tough to troubleshoot.

Separate SD cards it will be for me.

 

Beery

Share this post


Link to post
Share on other sites
3 hours ago, InfiniteTape said:

Wrapping up xdt99 into a packaging tool should be pretty straightforward. On Debian variants like Raspbian, you'd go for the .deb format and use apt to install it. On Mac, you could use Homebrew. In both cases, you'd provide a dependency spec to pull in the version of Python needed if it isn't already present.

I poked around at this and determined that pip is a probably better way to distribute, since it's just Python script. Here's the setup.py script I used as a proof of concept:

 

import setuptools
with open("README.md", "r") as fh:
    long_description = fh.read()
setuptools.setup(
     name='xdt99',  
     version='2.0.1',
     scripts=['xas99.py','xbas99.py','xda99.py','xdg99.py','xdm99.py','xga99.py','xhm99.py','xvm99.py'] ,
     author="Ralph Benzinger",
     author_email="[email protected]",
     description="TI 99 Cross-Development Tools",
     long_description=long_description,
   long_description_content_type="text/markdown",
     url="https://github.com/endlos99/xdt99",
     packages=setuptools.find_packages(),
     classifiers=[
         "Programming Language :: Python :: 2.7",
         "License :: OSI Approved :: GNU General Public License v2 (GPLv2)",
         "Operating System :: OS Independent",
     ],
 )

 

  • Like 1

Share this post


Link to post
Share on other sites

I'm in the process of adding the 9995 instructions MPYS, DIVS, LST, and LWP to xas99.  Reading the 9995 datasheet, however, I'm at a loss what the second arguments for MPYS and DIVS are -- if there are any.  The description might be interpreted that the destination is always R0 (and R1).  Is that correct?  (That would be an unusually restrictive design, but I guess they ran out of short opcodes.)

 

Once I updated the documentation, I can release xas99, xga99, and xbas99. 🎇

Share this post


Link to post
Share on other sites

Yes. The instruction format for both is op-10, Ts-2, S-4.

 

MPYS: (R0,R1) = R0 * S

DIVS: R0 = (R0,R1)/S, R1 = (R0,R1)%S.

 

Share this post


Link to post
Share on other sites
On 1/10/2020 at 11:51 PM, matthew180 said:

1. The Pixel instruction is called PIX (not PIC) and is a re-purposing of the XOP instruction (you probably know that).

Oh, but then my description of "PIX <gas>, <gad>" is not correct either.  Instead of <gad>, should it be <wa> or <imm>?

 

Also, it has just occurred to me that we finally found a use for DXOP (which is supported by xas99)!  🙂

Share this post


Link to post
Share on other sites

I'm getting this warning each time I run the assembler because I use Magellan to generate my graphics, and that produces a label for every pattern or color. Would it be possible add a flag to suppress the warning?

Warning: Unreferenced constants: COL1 COL10 COL100 COL101 COL102 COL103 COL104 COL105 COL106 COL107 COL108 COL109 COL11 COL110 COL111 COL112 COL113 COL114 COL115 COL116 COL117 COL118 COL119 COL12 COL120 COL121
COL122 COL123 COL124 COL125 COL126 COL127 COL128 COL129 COL13 COL130 COL131 COL132 COL133 COL134 COL135 COL136 COL137 COL138 COL139 COL14 COL140 COL141 COL142 COL143 COL144 COL145 COL146 COL147 COL148 COL149 CO
L15 COL150 COL151 COL152 COL153 COL154 COL155 COL156 COL157 COL158 COL159 COL16 COL160 COL161 COL162 COL163 COL164 COL165 COL166 COL167 COL168 COL169 COL17 COL170 COL18 COL19 COL2 COL20 COL21 COL22 COL23 COL24
COL25 COL26 COL27 COL28 COL29 COL3 COL30 COL31 COL32 COL33 COL34 COL35 COL36 COL37 COL38 COL39 COL4 COL40 COL41 COL42 COL43 COL44 COL45 COL46 COL47 COL48 COL49 COL5 COL50 COL51 COL52 COL53 COL54 COL55 COL56 COL
57 COL58 COL59 COL6 COL60 COL61 COL62 COL63 COL64 COL65 COL66 COL67 COL68 COL69 COL7 COL70 COL71 COL72 COL73 COL74 COL75 COL76 COL77 COL78 COL79 COL8 COL80 COL81 COL82 COL83 COL84 COL85 COL86 COL87 COL88 COL89
COL9 COL90 COL91 COL92 COL93 COL94 COL95 COL96 COL97 COL98 COL99 FCOL129 FCOL130 FCOL131 FCOL132 FCOL133 FCOL134 FCOL135 FCOL136 FCOL137 FCOL138 FCOL139 FCOL140 FCOL141 FCOL142 FCOL143 FCOL144 FCOL145 FCOL146 F
COL147 FCOL148 FCOL149 FCOL150 FCOL151 FCOL152 FCOL153 FCOL154 FCOL155 FCOL156 FCOL157 FCOL158 FCOL159 FCOL160 FCOL161 FCOL162 FCOL163 FCOL164 FCOL165 FCOL166 FCOL167 FCOL168 FCOL169 FCOL170 FCOL171 FCOL172 FCO
L173 FCOL174 FCOL175 FCOL176 FCOL177 FCOL178 FCOL179 FCOL180 FCOL181 FCOL182 FCOL183 FCOL184 FCOL185 FCOL186 FCOL187 FCOL188 FCOL189 FCOL190 FCOL191 FCOL192 FCOL193 FCOL194 FCOL195 FCOL196 FCOL197 FCOL198 FCOL1
99 FCOL200 FCOL201 FCOL202 FCOL203 FCOL204 FCOL205 FCOL206 FCOL207 FCOL208 FCOL209 FCOL210 FCOL211 FCOL212 FCOL213 FCOL214 FCOL215 FCOL216 FCOL217 FCOL218 FCOL219 FCOL220 FCOL221 FCOL222 FCOL223 FCOL224 FCOL225
 FCOL226 FCOL227 FCOL228 FCOL229 FCOL230 FCOL231 FCOL232 FCOL233 FCOL234 FCOL235 FCOL236 FCOL237 FCOL238 FCOL239 FCOL240 FCOL241 FCOL242 FCOL243 FCOL244 FCOL245 FCOL246 FPAT129 FPAT130 FPAT131 FPAT132 FPAT133 F
PAT134 FPAT135 FPAT136 FPAT137 FPAT138 FPAT139 FPAT140 FPAT141 FPAT142 FPAT143 FPAT144 FPAT145 FPAT146 FPAT147 FPAT148 FPAT149 FPAT150 FPAT151 FPAT152 FPAT153 FPAT154 FPAT155 FPAT156 FPAT157 FPAT158 FPAT159 FPA
T160 FPAT161 FPAT162 FPAT163 FPAT164 FPAT165 FPAT166 FPAT167 FPAT168 FPAT169 FPAT170 FPAT171 FPAT172 FPAT173 FPAT174 FPAT175 FPAT176 FPAT177 FPAT178 FPAT179 FPAT180 FPAT181 FPAT182 FPAT183 FPAT184 FPAT185 FPAT1
86 FPAT187 FPAT188 FPAT189 FPAT190 FPAT191 FPAT192 FPAT193 FPAT194 FPAT195 FPAT196 FPAT197 FPAT198 FPAT199 FPAT200 FPAT201 FPAT202 FPAT203 FPAT204 FPAT205 FPAT206 FPAT207 FPAT208 FPAT209 FPAT210 FPAT211 FPAT212
 FPAT213 FPAT214 FPAT215 FPAT216 FPAT217 FPAT218 FPAT219 FPAT220 FPAT221 FPAT222 FPAT223 FPAT224 FPAT225 FPAT226 FPAT227 FPAT228 FPAT229 FPAT230 FPAT231 FPAT232 FPAT233 FPAT234 FPAT235 FPAT236 FPAT237 FPAT238 F
PAT239 FPAT240 FPAT241 FPAT242 FPAT243 FPAT244 FPAT245 FPAT246 MC0 MCOUNT MS0 PAT1 PAT10 PAT100 PAT101 PAT102 PAT103 PAT104 PAT105 PAT106 PAT107 PAT108 PAT109 PAT11 PAT110 PAT111 PAT112 PAT113 PAT114 PAT115 PAT
116 PAT117 PAT118 PAT119 PAT12 PAT120 PAT121 PAT122 PAT123 PAT124 PAT125 PAT126 PAT127 PAT128 PAT129 PAT13 PAT130 PAT131 PAT132 PAT133 PAT134 PAT135 PAT136 PAT137 PAT138 PAT139 PAT14 PAT140 PAT141 PAT142 PAT143
 PAT144 PAT145 PAT146 PAT147 PAT148 PAT149 PAT15 PAT150 PAT151 PAT152 PAT153 PAT154 PAT155 PAT156 PAT157 PAT158 PAT159 PAT16 PAT160 PAT161 PAT162 PAT163 PAT164 PAT165 PAT166 PAT167 PAT168 PAT169 PAT17 PAT170 PA
T18 PAT19 PAT2 PAT20 PAT21 PAT22 PAT23 PAT24 PAT25 PAT26 PAT27 PAT28 PAT29 PAT3 PAT30 PAT31 PAT32 PAT33 PAT34 PAT35 PAT36 PAT37 PAT38 PAT39 PAT4 PAT40 PAT41 PAT42 PAT43 PAT44 PAT45 PAT46 PAT47 PAT48 PAT49 PAT5
PAT50 PAT51 PAT52 PAT53 PAT54 PAT55 PAT56 PAT57 PAT58 PAT59 PAT6 PAT60 PAT61 PAT62 PAT63 PAT64 PAT65 PAT66 PAT67 PAT68 PAT69 PAT7 PAT70 PAT71 PAT72 PAT73 PAT74 PAT75 PAT76 PAT77 PAT78 PAT79 PAT8 PAT80 PAT81 PAT
82 PAT83 PAT84 PAT85 PAT86 PAT87 PAT88 PAT89 PAT9 PAT90 PAT91 PAT92 PAT93 PAT94 PAT95 PAT96 PAT97 PAT98 PAT99 SPR1 SPR10 SPR11 SPR2 SPR3 SPR4 SPR5 SPR6 SPR7 SPR8 SPR9
  • Like 1

Share this post


Link to post
Share on other sites

From the top of my head, try adding -w.  In the new version, this will be -q for quiet.

  • Like 1

Share this post


Link to post
Share on other sites

The problem with -w/-q is that it disables all warnings.  Would it help if I limit the output for unused constants to, say, 10 symbols and then "(more)"?

Share this post


Link to post
Share on other sites
6 minutes ago, ralphb said:

The problem with -w/-q is that it disables all warnings.  Would it help if I limit the output for unused constants to, say, 10 symbols and then "(more)"?

Yes that would work for me. The problem with the long warning is that I wouldn't notice any other warnings. 🙂 

Share this post


Link to post
Share on other sites

I've released a new version of xdt99, ported to Python 3.  Please uninstall Python 2 before installing Python 3.  You require version 3.6 or higher.

 

Major new features are the linker and support for TMS9995 for xas99, label-based programs for xbas99, and syntax selection for xdg99.  Please see the release notes for some incompatible changes.

 

I also revised and extended the Tutorial and the Windows Guide.  I recommend both guides to all beginners and intermediate users as well as all developers who have shied away from the command line so far.

 

As usual, please post errors or requests here, or over at the project's bug tracker (requires GitHub user).

 

Happy developing! 😃

  • Like 5
  • Thanks 4

Share this post


Link to post
Share on other sites

I have a request. In the IntelliJ IDEA plugin, if you type, for instance

mov @

and ask for suggestions (ctrl-space), nothing comes up,  but once you add a comma after the @ (and move the cursor back before the comma) the suggestions work fine. Is there any easy fix for that?

 

I try to do this (and fail) every time I work with my source code, so it would be a real time saver if this could be fixed.

 

P.S. One of these days I should make a video that shows how easy it is to use IntelliJ IDEA for editing assembly source compared to, e.g., Notepad++ that don't have any of the features for suggesting, renaming etc.

 

  • Like 2

Share this post


Link to post
Share on other sites

To be honest, both plugins need some work.  I noticed that the Emacs mode has problems resolving symbols, possibly because I never added colon labels to it.

 

The IntelliJ plugin needs to updated for the latest version as well, and also to include recent changes.  Which IDEA version are you using?

 

Oh, and a video would be awesome!  I hate making videos. 🙂

Share this post


Link to post
Share on other sites
4 hours ago, ralphb said:

Which IDEA version are you using?

The very latest, 2020.1 early access. But your plugin has worked fine for many years, so it doesn't seems like they change that API often.

Edited by Asmusr

Share this post


Link to post
Share on other sites

Finally, Python 3! Unfortunately my first attempt to compile one of my modules failed with an unhelpful error message.

 

raise AsmError(f'Invalid symbol name {name}')

SyntaxError: invalid syntax

 

I'm using Python 3.6.5.

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.

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...