CPCWiki forum

General Category => Programming => Topic started by: zhulien on 12:43, 05 August 17

Title: CPC Assembly Time
Post by: zhulien on 12:43, 05 August 17
Hi All,

I am wondering from your largish projects, how long on a CPC does it take you to assemble?

Do you use a cross assembler or develop on the actual CPC, or perhaps a cross assembler injecting directly into an emulator?
Title: Re: CPC Assembly Time
Post by: ervin on 12:53, 05 August 17
Quote from: zhulien on 12:43, 05 August 17
Hi All,

I am wondering from your largish projects, how long on a CPC does it take you to assemble?

Do you use a cross assembler or develop on the actual CPC, or perhaps a cross assembler injecting directly into an emulator?

Hi zhulien.

I cross-develop in cpctelera.
Compilation takes anywhere from a few seconds up to... I don't know... maybe 30 seconds?
And higher compilation times only happen when the project has become large.
Title: Re: CPC Assembly Time
Post by: keith56 on 14:36, 05 August 17
I use winape's assembler - and it compiles straight into a floppy disk image.
it only takes a few seconds to compile, but once it's done, I start the game via Load"Disk from basic... so it's the loading time not the compiling time that is the big hold-up for me
I often run the emulator at 200% speed to cut down the load times - and let me test the game more quickly.

I've actually used winape to compile a file for the ZX spectrum! I was able to create a spectrum compatible header in winape's assembler, and copy the code file onto a +3 formatted disk - then load it in my speccy emulator.

I've not found a solution as good as Winape for the MSX or Spectrum, it's debugger and built in compiler make CPC development as easy as I could ask.
Title: Re: CPC Assembly Time
Post by: ronaldo on 15:43, 05 August 17
Well, we cannot compare compilation times of C source files with assembly times: it is simply unfair. C compilation times will always be slower, even if it sometimes is not noticeable. If you program in assembly, there will be almost no difference assembling your sources with CPCtelera or WinAPE, because assembling is an almost direct operation. Loading times will also be pretty similar, as CPCtelera launches WinAPE with autoload from the command line.

Then, it depends on your preference which tool is best for your work. Each tool has advantages and disadvantages. Best advice is to test tools on your own and then pick up whichever suits your needs.
Title: Re: CPC Assembly Time
Post by: roudoudou on 17:29, 05 August 17
I use rasm to assemble. A full cartridge with thousand of lines, macro,compression take 1/10s to make.

Title: Re: CPC Assembly Time
Post by: Ast on 22:48, 05 August 17
I only work on real hardware, Cpc old & Cpc plus with orgams (http://orgams.wikidot.com/userguide) z80 assembler rom.
It takes approximatively up to 5 seconds to assemble 6000 lines of code.
Title: Re: CPC Assembly Time
Post by: zhulien on 02:56, 08 August 17
I have put a POC of an HTML/8BML coding interface online here:  http://8bitology.com/z80ce.php


To be fair, it doesn't assemble itself, but uses The ORG Assembler's API but exposes it in a way that will work on CPC and Windows too.  This is a POC really but what are your thoughts on such a DEV tool that uses a fast online server to assemble code in a way that can download directly to CPC?  Is it worthwhile expanding on with project management, file management, both ability to assemble code submitted from CPC to a binary downloadable by CPC?
Title: Re: CPC Assembly Time
Post by: Targhan on 08:01, 08 August 17
Why don't you simply assemble your code on PC and transfer it on CPC? I do that using the M4 (Wifi) board, and it's an absolute blast. I generate SNApshot of the memory and transfer them directly in the memory of the CPC (it even resets automatically). All this via command line of the M4 board. The best of the two worlds (CPC + cross dev)!
Title: Re: CPC Assembly Time
Post by: zhulien on 09:00, 08 August 17
Quote from: Targhan on 08:01, 08 August 17
Why don't you simply assemble your code on PC and transfer it on CPC? I do that using the M4 (Wifi) board, and it's an absolute blast. I generate SNApshot of the memory and transfer them directly in the memory of the CPC (it even resets automatically). All this via command line of the M4 board. The best of the two worlds (CPC + cross dev)!


That sounds like a good option too.  I am looking at a solution to dev nicely on CPC though.  I used to use Pyradev (as it supports 512kb RAM) and has quite a good debugger.  How lots of cool tools are available, some are harder to use than they should be - especially some of the cross dev tools.  I have also developed using Marco Veith's CPC Emulator for DOS which was awesome.  These days though emulators seem lacking... in that they aren't supporting the cool hardware that is coming out on CPC. 


Which dev tools do you use on PC for CPC?


Don't you think CPC user/developers would find online dev tools useful for their CPCs? 



Title: Re: CPC Assembly Time
Post by: Targhan on 09:08, 08 August 17
I'm not sure about online dev tools, because I work many times off-line, and it would surely hinder my productivity. Personnally, it wouldn't fit my needs.


I am using Winape for emulating, plus some scripts on my own to inject SNA (thanks to the automatization software called AutoHotKey to simulate the clicks on the interface, since Winape is "closed"). I wrote an article about that on the late Push'n'Pop, I will try to upload it to Quasar Net to make it available again.
I use SJAsmPlus for assembling, it works great.
If you want to generate SNApshots, you will need Ramlaid's tool (http://www.julien-nevo.com/arkos/cpc-tools/) (windows only).
Then, injecting the SNA directly into the CPC is a piece of cake thanks to the awesome hardware M4 Board (via Wifi), check its command-line.
Title: Re: CPC Assembly Time
Post by: arnoldemu on 09:25, 08 August 17
Quote from: zhulien on 09:00, 08 August 17
These days though emulators seem lacking... in that they aren't supporting the cool hardware that is coming out on CPC. 
Arnold supports lots of hardware...

Some of the devices are more advanced in emulation than others because it does depend on which ones I can test - I need to test i/o port decoding and things like that to make it more accurate.

It doesn't emulate the m4, or the msx gfx card, but it emulates x-mass, symbiface 2, multiface 2, 4mb ram expansion and many more.

They can be activated through the devices dialog (expansion, printer and joystick).

Title: Re: CPC Assembly Time
Post by: Grim on 04:58, 09 August 17
Quote from: zhulien on 09:00, 08 August 17
Don't you think CPC user/developers would find online dev tools useful for their CPCs?
It works for me. Most of my tools nowadays are written in Javascript just so that can use them on anything with a web-browser (even offline) and can quickly modify/fix them without having to re-compile the thing manually. However, the complete lack of production-ready devtools available in JS and getting them working together like you would usually do with make/batch files or with regular applications (emulators) make things a lot more ... challenging, to say the least. And also that not too many devs seem ready to give up on their antic *nix habits of doing things, will take decade of active brainwashing to change that =)
Title: Re: CPC Assembly Time
Post by: keith56 on 09:07, 09 August 17
Quote from: zhulien on 09:00, 08 August 17
Don't you think CPC user/developers would find online dev tools useful for their CPCs?

I avoid online tools - they can disappear at any time if the developer removes them or changes them in a way you don't like... if you can't do what you need without an online tool, then you'll be stuck if it goes offline.

I download all the online docs I rely on, and only use software that works offline... in an ideal world I'd only use open source, but the software I need works on an offline XP virtual machine, then I can be pretty sure I'm going to be able to keep using it in years to come.

Quote from: arnoldemu on 09:25, 08 August 17
Arnold supports lots of hardware...
Agreed! Arnold has great support for strange things! The list of possible addons is huge!... I did all my multiplay testing with Arnold, and it worked fine when the real hardware turned up!
Title: Re: CPC Assembly Time
Post by: zhulien on 18:53, 10 August 17
One feature i would like to see is a memory exception feature. So at runtime the program can be halted if not reading or writing to allowed memory.
Title: Re: CPC Assembly Time
Post by: arnoldemu on 19:26, 10 August 17
Quote from: zhulien on 18:53, 10 August 17
One feature i would like to see is a memory exception feature. So at runtime the program can be halted if not reading or writing to allowed memory.
From a memory range you define?

A limited version is available in Arnold. You can set a memory read/write breakpoint. You can then define an address range using a mask. e.g. the computation is like this (addr AND c000)==0x04000, so this means any write to a 16KB block.

Title: Re: CPC Assembly Time
Post by: AMSDOS on 06:00, 20 August 17
Quote from: zhulien on 09:00, 08 August 17

Which dev tools do you use on PC for CPC?


Don't you think CPC user/developers would find online dev tools useful for their CPCs?


Sorry I would of replied earlier only I had trouble trying to find the Online Development Tools I wanted to refer to.


Personally I think it would be great if Locomotive BASIC came as an online tool, the examples I've seen are Quite BASIC (http://www.quitebasic.com) and AppleSoft BASIC in JavaScript (http://www.calormen.com/jsbasic/).
Quite BASIC doesn't try and copy any specific BASIC from any particular machine, earlier on though (a few years ago), I was able to take some of my Locomotive BASIC and write it for Quite BASIC, though it was quite generic and porting wasn't a hassle. My only concern with Quite BASIC is it doesn't appear the site is being maintained and I wasn't able to contact the Author.
AppleSoft BASIC in JavaScript on the other hand allows you to take an Apple BASIC program and do the same thing. I was able to easily type-in a Graphical Snowflake demo and execute it. Unsure if the Snowflakes are meant to be in Pink, though in that App I could Save the program I typed in (saves to the computer) as well as Load and unlike Quite BASIC, I could contact the author in case they were interested in that routine.


Though I just think if there was something like a Locomotive BASIC, anyone with a Web-browser could run a BASIC program without the necessary knowledge of using or setting up an emulator.
Powered by SMFPacks Menu Editor Mod