It is currently Mon Oct 20, 2014 4:36 pm

All times are UTC [ DST ]




Post new topic Reply to topic  [ 16 posts ] 
Author Message
 Post subject: BeebASM and swift
PostPosted: Mon Nov 15, 2010 3:50 pm 
Offline
 Profile

Joined: Sat Sep 04, 2010 5:28 pm
Posts: 92
I've having a lot of problems coaxing BeebASM to work with swift (Ophis seems to commodorey to me - I've always hated "$" being a hex signifier - & is just so much more classy)!

I've finally managed to get it assembling my code (lesson: don't have spaces in your project directory name). But the disc that is outputed only has the last file assembled on it and nothing else.


Top
 
 Post subject: Re: BeebASM and swift
PostPosted: Mon Nov 15, 2010 4:47 pm 
Offline
User avatar
 Profile

Joined: Mon Jan 07, 2008 6:46 pm
Posts: 380
Location: Málaga, Spain
I don't think Steve ever finished integrating BeebAsm with Swift, as BeebAsm works rather differently to any other 6502 assembler.

The main difference is that most assemblers take the name of the file to output on their command-line. BeebAsm, however, specifies which block of assembled code to save inside the source code itself with a SAVE command - this is just like BBC BASIC (which was the original intention). For me this is much clearer, as I have clear control over which bits of assembled code are output as which machine code files. With 'regular' assemblers, it's not obvious to me exactly what will be output if, for example, you've changed the origin address several times in the source code (will it output the biggest inclusive block, will it join all the blocks together into a contiguous block, removing any gaps, etc etc?)

Anyway, the point is that I don't think Swift is really designed to work like this - you might have to stick with a more conventional assembler if you'd like to use Swift. Unless Steve says otherwise...?


Top
 
 Post subject: Re: BeebASM and swift
PostPosted: Mon Nov 15, 2010 5:16 pm 
Offline
 Profile

Joined: Sat Sep 04, 2010 5:28 pm
Posts: 92
Hmm... that may be the kicker for me using swift then. Especially as I don't use the Adobe PDF reader (I use foxit) so I can't even get the on-line manuals...

Time to move to Notepad++ and beebasm on the command line.


Top
 
 Post subject: Re: BeebASM and swift
PostPosted: Mon Nov 15, 2010 6:13 pm 
Offline
User avatar
 Profile

Joined: Mon Jan 07, 2008 6:46 pm
Posts: 380
Location: Málaga, Spain
Here's a Notepad++ syntax highlighter if you want to go down that route - you have to add it to userDefineLang.xml in your AppData directory (mine is in C:\Users\Rich\AppData\Roaming\Notepad++):

Code:
<NotepadPlus>
    <UserLang name="6502" ext="6502">
        <Settings>
            <Global caseIgnored="yes" />
            <TreatAsSymbol comment="no" commentLine="yes" />
            <Prefix words1="no" words2="no" words3="no" words4="no" />
        </Settings>
        <KeywordLists>
            <Keywords name="Delimiters">000000</Keywords>
            <Keywords name="Folder+"></Keywords>
            <Keywords name="Folder-"></Keywords>
            <Keywords name="Operators">- % ( ) * / : ^ ~ + &lt; = &gt;</Keywords>
            <Keywords name="Comment"> 1 1 2 2 0\ 0; 0\\ 0\\\</Keywords>
            <Keywords name="Words1">and asl bit clc cld cli clv eor lda ldx ldy lsr ora pha php pla plp rol ror sec sed sei sta stx sty bcc bcs beq bmi bne bpl brk bvc bvs cmp cpx cpy jmp jsr nop rti rts adc dec dex dey inc inx iny sbc tax tay tsx txa txs tya equb equw equd equs</Keywords>
            <Keywords name="Words2">org if elif else endif align for next save cpu skip skipto include incbin mapchar guard clear print</Keywords>
            <Keywords name="Words3">and or eor div mod lo hi sqr sin cos tan asn acs atn rad deg int abs sgn rnd not log ln exp pi false true p%</Keywords>
            <Keywords name="Words4"></Keywords>
        </KeywordLists>
        <Styles>
            <WordsStyle name="DEFAULT" styleID="11" fgColor="000000" bgColor="FFFFFF" fontName="" fontStyle="0" />
            <WordsStyle name="FOLDEROPEN" styleID="12" fgColor="000000" bgColor="FFFFFF" fontName="" fontStyle="0" />
            <WordsStyle name="FOLDERCLOSE" styleID="13" fgColor="000000" bgColor="FFFFFF" fontName="" fontStyle="0" />
            <WordsStyle name="KEYWORD1" styleID="5" fgColor="0000FF" bgColor="FFFFFF" fontName="" fontStyle="0" />
            <WordsStyle name="KEYWORD2" styleID="6" fgColor="800080" bgColor="FFFFFF" fontName="" fontStyle="0" />
            <WordsStyle name="KEYWORD3" styleID="7" fgColor="800000" bgColor="FFFFFF" fontName="" fontStyle="0" />
            <WordsStyle name="KEYWORD4" styleID="8" fgColor="000000" bgColor="FFFFFF" fontName="" fontStyle="0" />
            <WordsStyle name="COMMENT" styleID="1" fgColor="000000" bgColor="FFFFFF" fontName="" fontStyle="0" />
            <WordsStyle name="COMMENT LINE" styleID="2" fgColor="008000" bgColor="FFFFFF" fontName="" fontStyle="0" />
            <WordsStyle name="NUMBER" styleID="4" fgColor="000000" bgColor="FFFFFF" fontName="" fontStyle="0" />
            <WordsStyle name="OPERATOR" styleID="10" fgColor="000000" bgColor="FFFFFF" fontName="" fontStyle="0" />
            <WordsStyle name="DELIMINER1" styleID="14" fgColor="000000" bgColor="FFFFFF" fontName="" fontStyle="0" />
            <WordsStyle name="DELIMINER2" styleID="15" fgColor="000000" bgColor="FFFFFF" fontName="" fontStyle="0" />
            <WordsStyle name="DELIMINER3" styleID="16" fgColor="000000" bgColor="FFFFFF" fontName="" fontStyle="0" />
        </Styles>
    </UserLang>
</NotepadPlus>


Top
 
 Post subject: Re: BeebASM and swift
PostPosted: Mon Nov 15, 2010 6:43 pm 
Offline
User avatar
 Profile

Joined: Mon Jan 07, 2008 6:46 pm
Posts: 380
Location: Málaga, Spain
Steve, just out of interest, how much work would it be to get BeebAsm integrated with Swift? What extra features would you require of BeebAsm, if any? I know we've been through this a few years ago, but I've forgotten what problems there are.

It'd be a shame to leave the two development options mutally exclusive.


Top
 
 Post subject: Re: BeebASM and swift
PostPosted: Mon Nov 15, 2010 8:41 pm 
Offline
User avatar
 Profile

Joined: Wed Jan 09, 2008 7:30 am
Posts: 406
Mostly it worked a while back, but I've added a lot in since my last thorough testing with BeebASM and maybe things are breaking a little. I mostly only get time to test stuff with P65 as my projects are in that so testing is easy.

I'll have to have a look see to find out what the issues are, do you have some nice BeebASM projects I could work with, perhaps a couple, something simple and something a bit more meaty to put it through it's paces.


Top
 
 Post subject: Re: BeebASM and swift
PostPosted: Mon Nov 15, 2010 8:43 pm 
Offline
User avatar
 Profile

Joined: Wed Jan 09, 2008 7:30 am
Posts: 406
tautology wrote:
But the disc that is outputed only has the last file assembled on it and nothing else.


When you say last file, what do you mean, are you trying to assemble more than one file ? or are we talking other none source files (i.e. sprite or look up tables).

If source files, are you putting more than one save in BeebASM ? If so that may be an issue for Swift.


Top
 
 Post subject: Re: BeebASM and swift
PostPosted: Mon Nov 15, 2010 11:18 pm 
Offline
 Profile

Joined: Sat Sep 04, 2010 5:28 pm
Posts: 92
SteveO wrote:
tautology wrote:
But the disc that is outputed only has the last file assembled on it and nothing else.


When you say last file, what do you mean, are you trying to assemble more than one file ? or are we talking other none source files (i.e. sprite or look up tables).

If source files, are you putting more than one save in BeebASM ? If so that may be an issue for Swift.


I was trying to assemble 2 files and add one raw data file. I had a save at the end of each file.

There is one bug that it doesn't seem to quote string properly if you've got a space in the directory name (this got me confused for a while).

I've got a working solution now, not involving swift; but I think if I was using some of the other features (e.g. the sprite editor), I'd probably spend more time trying to get it working!


Top
 
 Post subject: Re: BeebASM and swift
PostPosted: Tue Nov 16, 2010 11:33 am 
Offline
User avatar
 Profile

Joined: Wed Jan 09, 2008 7:30 am
Posts: 406
I'll look into the direcotry sace name thing, thought I used spaces in my names but mustn't have. Thanks for the feed back.


Top
 
 Post subject: Re: BeebASM and swift
PostPosted: Fri Nov 19, 2010 2:00 pm 
Offline
 Profile

Joined: Sun May 02, 2010 2:07 pm
Posts: 42
Ah the old spaces in directory names bug, microsoft created this when they patched out a security hole. From memory its in the .net library, a recompile of the program may fix it.


Top
 
 Post subject: Re: BeebASM and swift
PostPosted: Sat Nov 20, 2010 7:30 am 
Offline
User avatar
 Profile

Joined: Wed Jan 09, 2008 7:30 am
Posts: 406
From memory of the code (not looked), some of the stuff I have to use (i.e. P65) doesn't like spaces in file names so I use a routine (from the OS, not my own) to convert them to their short name equivalents. Sounds like something as you say may have gone amiss, although I don't compile against the .net framework - knowingly !


Top
 
 Post subject: Re: BeebASM and swift
PostPosted: Sun Feb 13, 2011 1:57 am 
Offline
User avatar
 Profile

Joined: Mon Jan 24, 2011 6:10 pm
Posts: 29
Just wondering if any progress has been made on Swift+BeebASM integration, or if it's even in the pipeline?

-Martin.


Top
 
 Post subject: Re: BeebASM and swift
PostPosted: Sun Feb 13, 2011 8:48 am 
Offline
User avatar
 Profile

Joined: Wed Jan 09, 2008 7:30 am
Posts: 406
Yes, it's in the pipeline and as it used to work a while back probably not too big a job. I've a version I want to release that's been virtually ready for over a year that allows source code debugguing with watch variables, breakpoints etc. all the usual stuff but real life has just got in the way for a long time now, but hoping to have a big push to get this out as beta hopefully for about end of March/ early April. It's all done, just needs debugging for a couple of niggles.

Once that's done the next version will address the BeebASM issues and bring back compatible integration.


Top
 
 Post subject: Re: BeebASM and swift
PostPosted: Sun Feb 13, 2011 12:00 pm 
Offline
User avatar
 Profile

Joined: Mon Jan 24, 2011 6:10 pm
Posts: 29
Excellent! Great to hear. Looking forward to the releases!

Thanks & regards,
Martin.


Top
 
 Post subject: Re: BeebASM and swift
PostPosted: Sun Feb 13, 2011 2:15 pm 
Offline
Site Admin
User avatar
 Profile

Joined: Wed Dec 19, 2007 10:46 pm
Posts: 779
SteveO wrote:
do you have some nice BeebASM projects I could work with, perhaps a couple, something simple and something a bit more meaty to put it through it's paces.

Steve,

Just a reminder that to date we have two projects with freely available BeebAsm source code - Kenton's Hyper Viper and the BBC Micro Z-Machine Interpreter.

Sam.


Top
 
 Post subject: Re: BeebASM and swift
PostPosted: Sun Feb 13, 2011 2:55 pm 
Offline
User avatar
 Profile

Joined: Wed Jan 09, 2008 7:30 am
Posts: 406
Excellent, thanks for that.


Top
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 16 posts ] 

All times are UTC [ DST ]


Who is online

Users browsing this forum: No registered users and 0 guests


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 post attachments in this forum

Search for:
Jump to:  
cron