Newbie: Where to start to learn QL assembly language?

Anything QL Software or Programming Related.
User avatar
drdtyc
ROM Dongle
Posts: 22
Joined: Mon Oct 01, 2018 10:09 pm

Newbie: Where to start to learn QL assembly language?

Postby drdtyc » Mon Jul 27, 2020 4:53 pm

With so much free time at home during this covid pandemic, I am thinking of learning something new to keep my brain busy.

I have previous background in high level programming languages e.g. Fortran 77 and Coral 66 during early stage of my career as a programmer/engineer in England. I also have basic knowledge of how an Intel 8080 microprocessor works from my university training. But all the these are now hazy to me after more than three decades of unuse.

I am now inclined to take up QL assemby language programming as a self challenge. Where shall I get online help?

I need some reading material on
(1) Motorola 68000 microprocessor
(2) QL assembly language
(3) Simple examples of assemby programs
(4) Beginner's projects on QL assemby langauge (hopefully with hints).
Last edited by drdtyc on Mon Jul 27, 2020 9:31 pm, edited 1 time in total.


User avatar
tofro
Font of All Knowledge
Posts: 2014
Joined: Sun Feb 13, 2011 10:53 pm
Location: SW Germany

Re: Newbie: Where to start to learn QL assembly language?

Postby tofro » Mon Jul 27, 2020 5:29 pm

You will definitely want to start here.
And then continue there

And you definitely want to look in Norm's excellent write-ups on QL Assembler.
Next you want a book on QDOS System calls - The official one is the "QL Technical Guide"
And next you definitely want an editor/assembler/linker setup - Norman will recommend GWASL/GWASS (Which is excellent), I'd recommend the "real thing", the GST/Quanta Macro Assembler (can all be had from the above site)


ʎɐqǝ ɯoɹɟ ǝq oʇ ƃuᴉoƃ ʇou sᴉ pɹɐoqʎǝʞ ʇxǝu ʎɯ 'ɹɐǝp ɥO
User avatar
NormanDunbar
Forum Moderator
Posts: 1122
Joined: Tue Dec 14, 2010 9:04 am
Location: Leeds, West Yorkshire, UK
Contact:

Re: Newbie: Where to start to learn QL assembly language?

Postby NormanDunbar » Mon Jul 27, 2020 6:00 pm

tofro wrote:And then continue there


To be sure to get the latest version, at any time, use this URL instead, then download the pdf file.

latest


Cheers,
Norm.


Why do they put lightning conductors on churches?
Author of Arduino Software Internals - https://www.amazon.co.uk/Arduino-Softwa ... 1484257898, https://www.apress.com/gb/book/9781484257890
User avatar
Sparrowhawk
Gold Card
Posts: 302
Joined: Wed Dec 15, 2010 12:33 pm
Location: @131072
Contact:

Re: Newbie: Where to start to learn QL assembly language?

Postby Sparrowhawk » Tue Jul 28, 2020 10:54 am

Assembly language is very, very simple.

- Chapter 1, Section 1.


I loved this line when I started going through this book. It's the calming equivalent of Don't Panic! on the HHGTTG :)


a.k.a. Jean-Yves !
User avatar
NormanDunbar
Forum Moderator
Posts: 1122
Joined: Tue Dec 14, 2010 9:04 am
Location: Leeds, West Yorkshire, UK
Contact:

Re: Newbie: Where to start to learn QL assembly language?

Postby NormanDunbar » Tue Jul 28, 2020 11:50 am

Sparrowhawk wrote:
Assembly language is very, very simple.

- Chapter 1, Section 1.
I loved this line when I started going through this book. It's the calming equivalent of Don't Panic! on the HHGTTG :)


:D

When I wrote the original article in QL Today, I figured I better [mis]lead the reader in gently! ;)

Seriously, it is simple. Each instructions does one simple thing. The hard part is figuring out which combination of simple things go together to make a complicated thing!


Cheers,
Norm.


Why do they put lightning conductors on churches?
Author of Arduino Software Internals - https://www.amazon.co.uk/Arduino-Softwa ... 1484257898, https://www.apress.com/gb/book/9781484257890
User avatar
Ruptor
Trump Card
Posts: 177
Joined: Fri Dec 20, 2019 2:23 pm

Re: Newbie: Where to start to learn QL assembly language?

Postby Ruptor » Tue Jul 28, 2020 12:24 pm

NormanDunbar wrote:Seriously, it is simple. Each instructions does one simple thing. The hard part is figuring out which combination of simple things go together to make a complicated thing!
Yes it is just a matter of moving '1' and '0' about in the right sequence and yet people don't seem to be able to write bug free software. :lol: Then the excuses come out "it was the compiler that inherited a bug from the assembler that inherited it from the microcode etc"
I wouldn't waste time on old hat architectures that you have trouble buying you would be better off learning the RPi that leads to other ARM based systems like phones or simple architectures like the 8 or 16 bit PICs, all very useful.


User avatar
NormanDunbar
Forum Moderator
Posts: 1122
Joined: Tue Dec 14, 2010 9:04 am
Location: Leeds, West Yorkshire, UK
Contact:

Re: Newbie: Where to start to learn QL assembly language?

Postby NormanDunbar » Tue Jul 28, 2020 1:09 pm

Hi Ruptor,

Ruptor wrote:I wouldn't waste time on old hat architectures that you have trouble buying you would be better off learning the RPi that leads to other ARM based systems like phones or simple architectures like the 8 or 16 bit PICs, all very useful.


Have you seen ARM assembly code? It's all "frack to bont" (back to front). You move something from the source to the destination and that's how (I think) it should be written, not ARM! Or indeed, not AVR 8 bit microcontrollers either, they are the wrong way around too. Most confusig after years of messing about with 68000 stuff. It seriously does my head in. :(

I'm working/playing with 32 bit ARM microcontrollers at the moment..........


Cheers,
Norm.


Why do they put lightning conductors on churches?
Author of Arduino Software Internals - https://www.amazon.co.uk/Arduino-Softwa ... 1484257898, https://www.apress.com/gb/book/9781484257890
User avatar
tofro
Font of All Knowledge
Posts: 2014
Joined: Sun Feb 13, 2011 10:53 pm
Location: SW Germany

Re: Newbie: Where to start to learn QL assembly language?

Postby tofro » Tue Jul 28, 2020 1:28 pm

Ruptor wrote:I wouldn't waste time on old hat architectures that you have trouble buying you would be better off learning the RPi ...


That sentence probably entitles you to a lifetime ban from this forum ;)

Seriously: ARM assembly is definitely not something you want to learn. Even if difficult, 68k assembly is much easier to learn than ARM.
Last edited by tofro on Tue Jul 28, 2020 1:49 pm, edited 1 time in total.


ʎɐqǝ ɯoɹɟ ǝq oʇ ƃuᴉoƃ ʇou sᴉ pɹɐoqʎǝʞ ʇxǝu ʎɯ 'ɹɐǝp ɥO
User avatar
Pr0f
Super Gold Card
Posts: 655
Joined: Thu Oct 12, 2017 9:54 am

Re: Newbie: Where to start to learn QL assembly language?

Postby Pr0f » Tue Jul 28, 2020 1:31 pm

Also - if you think pic assembly is easy - it is until you want to do subtraction - then it's far from intuitive :-)


User avatar
Ruptor
Trump Card
Posts: 177
Joined: Fri Dec 20, 2019 2:23 pm

Re: Newbie: Where to start to learn QL assembly language?

Postby Ruptor » Tue Jul 28, 2020 3:26 pm

Hi Guys
Yes as you say there is not much point in learning assembler on modern chips because the compilers are so good at optimising and they are so fast. All the assembly code I have done is on 8 or 16 bit chips starting on Z80 then 6800 then 8051 that as you say Norm swapped everything around. The last 8051 program was 48K that was all code no tables or data blocks. The PIC Hitech compiler that we moved on to was magic in terms of optimisation that you could use as an encryption machine because on disassembly you couldn't tell what the code was doing. It seemed to find bits of code that were the same and use them all over the place blowing structured code out the window. :shock: These days they write code for weight don't they? Assembler is two compact and fast for people to handle. :lol:



Who is online

Users browsing this forum: No registered users and 3 guests