Page 1 of 1

Using sll with z80asm Version 1.8

Posted: Fri Apr 26, 2019 7:58 pm
by 2late
I want to use one of the shift left logical directives. According to the headline here http://z80-heaven.wikidot.com/instructions-set:sll they can either be written SLL or SL1. However the table shows sla directives, which do work as expected. But I have no success with using SLL instead..

The program is

Code: Select all

ORG 49152
SLL A
RET
which should be easy enough. However it gives me

Code: Select all

$ z80asm -v -i sllatest.zas -o sllatest.sna
Assembling....
sllatest.zas:2: error: command or comment expected (was  A )
*** 1 error found ***
I can't help feeling like I'm comitting some probably very stupid error.

Re: Using sll with z80asm Version 1.8

Posted: Sat Apr 27, 2019 3:15 pm
by olofsen
Apparently z80asm doesn't know this undocumented instruction... For example zasm and sjasm do handle it:

https://k1.spdns.de/Develop/Projects/zasm/
http://www.xl2s.tk/

Re: Using sll with z80asm Version 1.8

Posted: Sat Apr 27, 2019 4:28 pm
by 2late
Thanks for trying it out. I wasn't aware that this is no official Zilog instruction. It seems that I have to consider another assembler then or stick to the mundane, something like

Code: Select all

SLA A
OR 1

Re: Using sll with z80asm Version 1.8

Posted: Sun Apr 28, 2019 12:12 am
by 1024MAK
There is lots of information on the Z80 and it’s instruction set on http://www.z80.info/ ;)

Mark

Re: Using sll with z80asm Version 1.8

Posted: Sun May 12, 2019 2:13 pm
by 2late
1024MAK wrote: Sun Apr 28, 2019 12:12 am There is lots of information on the Z80 and it’s instruction set on http://www.z80.info/ ;)
Thanks.
I also used http://clrhome.org/table/# but the mouse over fly out always goes to the right i.e. goes over the edge of my screen for the right most column. Also all jr and jp instructions have the same, purely abstract description.

Ah, the memorys. When I learned from the "Cheap Video Cookbook" how my 81 worked. I had struggled endlessly with 1k being put into the $2000 - $3FFF rang to put the charset there. Then it finally dawned on me that one had to connect them to the "video bus" which wasn't available on the outside, i.e. through the standard connector.

Re: Using sll with z80asm Version 1.8

Posted: Sun Jun 07, 2020 5:31 pm
by hlide
2late wrote: Sat Apr 27, 2019 4:28 pm Thanks for trying it out. I wasn't aware that this is no official Zilog instruction. It seems that I have to consider another assembler then or stick to the mundane, something like

Code: Select all

SLA A
OR 1
nah, use something like

Code: Select all

DB $CB,$37 ; SLL A
Why? OR will affect C flag in the wrong way if you want to use it through SLL.

Re: Using sll with z80asm Version 1.8

Posted: Wed Nov 18, 2020 3:42 pm
by 2late
hlide wrote: Sun Jun 07, 2020 5:31 pm nah, use something like

Code: Select all

DB $CB,$37 ; SLL A
Why? OR will affect C flag in the wrong way if you want to use it through SLL.
Good point. Thanks. Didn't seem to matter in my case though.