Jump to content
IGNORED

ELSA (the assembler)


Recommended Posts

If anyone here is interested... I have published ELSA, my (to this time) private assembler I have used to compile most of my programs:

 

http://drac030.krap.pl/en-elsa-info.php

 

Those who are familiar with MAE will feel at home. There is a PDF there (and a TXT file in the archive) which explains the details.

 

I started writing it around 2006 and, as years were passing, it was taking over more and more of my projects. ELSA compiles are e.g. the Let's Emu! ZX Spectrum emulator, MultiBASIC, U-BASIC, Rapidus OS and such. The latest convert is IDE+ BIOS (which has grown so large that MAE started to run out of memory while assembling it).

 

It is written in pure 65C816 native code, so it will run on Ataris with Rapidus and Antonia.

 

Have fun :)

  • Like 12
  • Thanks 2
Link to comment
Share on other sites

  • 2 weeks later...
  • 3 weeks later...
  • 2 weeks later...
  • 5 months later...

If anyone is (still) interested, I have uploaded new version, 0.91, to my website: http://drac030.krap.pl/en-elsa-info.php

 

The list of changes is rather large, but most of this stuff are minor improvements accumulated since April. Still, seeing how long the list is, I decided to release a version before I proceed with more important changes.

 

At the occasion, I would like to ask if anyone has a good method of converting OpenOffice/LibreOffice/MS-Word documents to ASCII text with the preservation of tables and table borders. The best way I know so far is:

 

a) convert to HTML using "File->Save as..." in OpenOffice

b) use links -width 78 -dump foo.html >foo.txt

 

This is not perfect, as the resulting txt file still needs manual editing. The problem seems to be how the wordprocessors and/or links deal with lists: they love to drop indentation, but also they love to insert paragraph ends at the end of each line. This is disastrous for scraps of assembler listings, especially in the tables, where they cannot be manually reedited in the final txt file.

 

So the question is, does anyone know a better method (ideally: fully automatic) or maybe there are tips to format the original document so that the conversion yields the desired result. Thanks in advance.

 

PS. The reason is that I would like to provide the documentation to ELSA also in the text form, so that it could be read on Atari. I would love to edit the original on Atari (and later convert to a PC format like TXT, HTML or PDF), but unfortunately we seem to be lacking any wordprocessor capable of editing a single file larger than about 30 KB (and Last Word is even limited to 15k, which is sad).

 

  • Like 1
  • Thanks 1
Link to comment
Share on other sites

Hi!

9 hours ago, drac030 said:

At the occasion, I would like to ask if anyone has a good method of converting OpenOffice/LibreOffice/MS-Word documents to ASCII text with the preservation of tables and table borders.

 

So the question is, does anyone know a better method (ideally: fully automatic) or maybe there are tips to format the original document so that the conversion yields the desired result. Thanks in advance.

 

Use pandoc: https://pandoc.org/ , it converts between hundred of different text formats. In your case, you can convert to Markdown (.md) or RestructuredText (.rst), see which looks better to you:

pandoc mydocument.odt -o mydocument.md
pandoc mydocument.odt -o mydocument.rst

The beauty of pandoc is that you can convert from Markdown of RST to HTML, PDF or ODT again, and you can use a template to provide styles and formating.

 

Have Fun!

 

  • Thanks 2
Link to comment
Share on other sites

@ivop From what I read, tools to extract tables from PDF files have to use AI to do that, so this route does not look very promising :D But sure, everything is to try.

 

@dmsc Thanks, that program indeed look very promising, and it indeed can translate to plain text even preserving tables with borders, sometimes however the output looks like this:

 

pandoc.thumb.png.61451e86ebb72f2c82ea0fb872bb65a1.png

 

which to me looks like a failure. It also has the habit of removing indentation (they even sort of advertise this in the manual as a feature) and inserting spurious paragraph ends a the end of each item of a list. Damn...

 

Edited by drac030
@@
Link to comment
Share on other sites

Hi!

 

On 10/6/2020 at 6:58 AM, drac030 said:

 

@dmsc Thanks, that program indeed look very promising, and it indeed can translate to plain text even preserving tables with borders, sometimes however the output looks like this:

 

pandoc.thumb.png.61451e86ebb72f2c82ea0fb872bb65a1.png

 

Strange, must be some default option. Here this works:

 

image.thumb.png.d86b4245e7c5aa22209e15e5af3e3a5a.png

 

Perhaps some default option is set differently. I'm using pandoc version 2.9.2.1, with the command line: pandoc doctst.odt -o test.md

 

Reading the manual, you can try with: pandoc doctst.odt -t markdown+grid_tables-simple_tables-pipe_tables-raw_html  -o test.md

 

This disables "simple tables" and activates the "grid tables".

 

Have Fun!

Link to comment
Share on other sites

18 hours ago, dmsc said:

pandoc doctst.odt -o test.md

 

pandoc doctst.odt -t markdown+grid_tables-simple_tables-pipe_tables-raw_html  -o test.md

Tried both, same effect. Pandoc 2.10.1. As I said, the program converts SOME tables right, but some does as shown. Whence I guess it is simply buggy (it probably does not understand some odt subtleties). It also likes to drop rows marked as "headers" from the tables, even if it converts them well otherwise.

Link to comment
Share on other sites

Just to save people some time:

 

I've been using sphinx to render [url=http://rmac.is-slick.com/manual/rmac.html]rmac's documentation into html[/url] (originally written in restructuredtext), and this thread reminded me that it also supports text output. Sadly, I get the exact same results with tables using that tool - one super long line without wrap around. And no options in the tool to set line width. Seems like text output is not a huge priority to these people....

Link to comment
Share on other sites

Hi!

23 hours ago, drac030 said:

Tried both, same effect. Pandoc 2.10.1. As I said, the program converts SOME tables right, but some does as shown. Whence I guess it is simply buggy (it probably does not understand some odt subtleties). It also likes to drop rows marked as "headers" from the tables, even if it converts them well otherwise.

Oh, that's a nuisance.

 

I use pandoc in the reverse direction: I wrote the manual for Fastbasic in markdown but in 40 columns, so it can be rendered in the Atari screen easily - I just replace the `CODE` blocks with inverse video using an awk script. And by using a template, the PDF output is quite good, even with syntax coloring for the BASIC samples:

 

Original Version: https://raw.githubusercontent.com/dmsc/fastbasic/master/manual.md

Output PDF: https://github.com/dmsc/fastbasic/releases/download/v4.4/fastbasic-v4.4-manual.pdf

 

Perhaps you could convert it once, manually editing the bad parts and then use pandoc to go to the ODT format again - pandoc can use an existing ODT as a base, extracting the styles and replacing only the text.

 

Have Fun!

 

  • Like 1
Link to comment
Share on other sites

  • 3 weeks later...

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