SDCC Tutorial Part 3 of 4 : Using Maxam-style inlined assembly code in your C programs (http://www.norecess.net/1/post/2011/01/sdcc-tutorial-part-3-of-4-using-maxam-style-inlined-assembly-code-in-your-c-programs.html)
12 January 2011, 3:00 am
Part 3 (http://www.norecess.net/sdcc-part-3---using-maxam-style-inlined-asm.html) is now available for reading. As usual, send me comments through Contact (http://www.norecess.net/contact.html) section !
Source: NoRecess {the website} - Blog (http://www.norecess.net/index.html)
Note that Pasmo, the assembler mentioned in this article, can be obtained from http://www.speccy.org/pasmo/ (http://www.speccy.org/pasmo/)
Hi,
What would be better as URL to use ? the one from the author or the one from speccy.org ?
Thanks.
I tried the author's link, but the download wasn't working there - the website wasn't available. So I did a search for pasmo, and Wikipedia links to speccy.org for the download.
Thanks for the articles, I now have an Amstrad CPC build environment for C! It'll be a while yet before I get anywhere with it though.
I added this onto the build.bat script:
IF NOT EXIST main.dsk managedsk -C -S"main.dsk"
managedsk -L"main.dsk" -I"main.bin"/MAIN.BIN/BIN/16384/16384 -S"main.dsk"
So the build script does everything and creates the disk. I think WinAPE locks the file though, so you need to eject an existing disk before you can run the build script.
Note that you need managedsk version 0.19 - http://ldeplanque.free.fr/ManageDsk/ManageDsk_V0.19.zip
The one on http://amstrad.cpc.free.fr/download.php (http://amstrad.cpc.free.fr/download.php) is version 0.16 which doesn't have the -I command line option.
Quote from: Briggsy on 16:30, 12 January 11
Thanks for the articles, I now have an Amstrad CPC build environment for C! It'll be a while yet before I get anywhere with it though.
In the blue angel 69 source I distributed all my build files, so it is possible to use my tools to build C progs using z88dk.
A possible alternative?
EDIT: I think in the end the choice of build tools is up to you. Norecess has made coding C for the CPC "sexy". No more is it "don't code in C". He has shown demos are possible and mojontwins show games are possible.
The aim of these tutorials was to show the basics - let you started with a C project on CPC. Of course you have to make your own experience on top of it, meaning adapting your toolchain etc. for it.
Thank, I will update the Pasmo URL in the day.
@Kevin: what would be interesting for you is to try compiling Blue Angel 69 with SDCC. I'm quite interested in knowing the new size after the switch :) (cf. how much space you gained!).
And yes, C coding for the CPC is sexy. Next step not presented in tutorials is Visual Studio integration..
Ps. I just updated the links on my website. Thank you.
Briggsy : I added your tip (IF NOT EXIST) in the Part 4 Article.