PDA

View Full Version : Buying a 8086 for my Olivetti PCS



anormal
November 10th, 2017, 02:00 AM
Hi, this computer comes with a Nec V30, some weeks ago I got from a thread here a link to pretty cheap NEC V20s /16mhz. Five of them for a pair of dollars.

I was looking now for a proper intel 8086 in ebay, found a lot of things.

Most populars I see are P8086 and P8086-2

So my question is, do you recommend something in particular? I am currently searching for "8086 microprocessor". I ask because i know there is a lot of variations, and sometimes the listings are done in original Intel part numbers. Any tips? Prices are cheap in general, but want to know more about the right ones to buy. Thanks!

Chuck(G)
November 10th, 2017, 06:15 AM
Quite a number of manufacturers made the 8086 under license from Intel--they're all basically the same chip, run off on different fabs (this was back when there were more than a few foundries in the world). Just match one that meets your clock speed requirements.

1ST1
November 11th, 2017, 12:07 AM
The NEC V30 is a better replacement for 8086 with external 16 Bit Data bus. The NEC V20 is a better replacement for 8088 with 8 Bit external data bus. As 8088 is no replacement for 8086 so V20 is no replacement for V30.

And to add the last, V40 is not replaceable at all. V40 is a faster Version of V30 with partially integrated chipset. It‘s used for example in Olivetti Prodest PC-1, ETV 2700, ETV 2900, WS 2000 and M200

I also think that the PCS86 is not overclockable. So just be happy that you have a working PlasticComputerSystem 86.

anormal
November 11th, 2017, 08:16 AM
Thanks both!

Then I could get a clone 8086 and it will behave like a real Intel one? I want to test some undocument opcodes and other stuff, and I need original Intel execution.

Well... then I have 5 Nec V20s with no use, haha, I pressumed it was 16 bit bus (and 8086 compatible)...

Regards!

Chuck(G)
November 11th, 2017, 08:53 AM
Yes, all 8086 were manufactured under license to Intel, so they're all the same.

NEC also manufactured them under the same Intel license and then bought out the V30 and avoided royalties, which resulted in a significant IP case (http://digitalcommons.law.scu.edu/cgi/viewcontent.cgi?article=1030&context=chtlj). What's notable is that NEC continued to manufacture 8086 and 8088 chips--and pay royalties--during and after the progress of the legal action.

1ST1
November 11th, 2017, 11:44 PM
Thanks both!

Then I could get a clone 8086 and it will behave like a real Intel one? I want to test some undocument opcodes and other stuff, and I need original Intel execution.

Well... then I have 5 Nec V20s with no use, haha, I pressumed it was 16 bit bus (and 8086 compatible)...

Regards!

You can try 8086 in PCS86, but maybe it fails because of BIOS because the machine was made for V30. Because V20/V30 is extended, it adds 8080/z80 compatibility mode for CP/M to 8086 CPU. So maybe PCS bios makes some special function test for V30 at startup....?

Krille
November 12th, 2017, 03:42 AM
Because V20/V30 is extended, it adds 8080/z80 compatibility mode for CP/M to 8086 CPU. So maybe PCS bios makes some special function test for V30 at startup....?

Maybe, but it's unlikely that it uses the 8080 emulation mode, simply because it's so badly done I can't imagine anyone ever using that feature. It's far more likely that it uses the 186 instructions - the real benefit of the NEC V20/V30 processors.

Chuck(G)
November 12th, 2017, 08:24 AM
8080 mode isn't badly done; it just has a few gotchas. Most CP/M 8-bit programs work just fine with it, provided that they stick to 8080 opcodes (no z80). But I'm not aware of any machine manufacturer that took advantage of that, although there were a few CP/M emulators (modesty forbids) that offered to take advantage of the capability. By the time the 286s came out, software emulation of the 8080 instruction set was about as fast as that on a V20 running in 8080 emulation mode.

Krille
November 12th, 2017, 10:57 AM
8080 mode isn't badly done; it just has a few gotchas.

I was referring to how emulation mode is invoked using a software interrupt and the 8080 code is basically an interrupt handler. It would have been far more useful IMO if it had been possible to switch in and out of emulation mode on the fly without any need for setting up interrupt vectors etc. Just a matter of switching instruction sets. A lot of the 8080 instructions are very short and I believe it would have been a great way to reduce code size if that had been possible.

Chuck(G)
November 12th, 2017, 11:27 AM
There isn't enough of a difference between 8080 and 8086 instruction length to matter, particularly on an V30, but even the V20 PFQ masks the difference. Add to that the better EAG performance (I'm using NEC terminology) and the orthogonality of the x86 instruction set and I'd venture that there's nothing to be gained at all.

Krille
November 12th, 2017, 11:36 AM
I'm talking about code size only, not performance. But yeah, perhaps it doesn't matter size wise either. I guess we'll never know.

Chuck(G)
November 12th, 2017, 12:16 PM
I've never seen timing specs for the 8080 instructions, have you? I remember asking the rep at NEC Natick about them, but he couldn't find any either.

What's surprising is that the V20 is able to do all of this with a 1Kx29 bit microcode store.

anormal
November 13th, 2017, 03:57 AM
Yes ChuckG, you are being too modest about CP/M emulation ;)

Good point about the bios using V30 opcodes, i'll check a disassembling prior doing nothing. Anyway, i ordered a pair of 8086 this last weekend, a P8086 and a P8086-2 (if I am not too worng, first is 4Mhz and 8086-2 is 8Mhz)... anyway, is not bad having spare micros, could have other use sometime.

ChuckG, very nice question about the 8080 timings, never thought about it, sometimes we assume certains things are available by default... Not in this case I pressume. This could be a nice project to research.

1ST1
November 13th, 2017, 04:01 AM
I think the PCS86 is 8 Mhz by default, so the 4 Mhz type might not work. Maybe there is a key press during BIOS post to switch it down to 4,77 Mhz. But it starts at 8 Mhz.

anormal
November 13th, 2017, 10:57 AM
Well, I arrived my cave and dumped the BIOS.

It seems is version 1.13 (PCS-86 Resident Diagnostics Rev 1.13) dated 04/04/90.

After some lurking in the code, I found this nice piece of code:


00000352: BE2310 mov si,01023 ;'PCS-86 Resident Diagnostics Rev 1.13'
00000355: E8B1EC call 0FFFFF009 ;print_string_si
00000358: BE8A10 mov si,0108A ;'CPU (i8086)'
0000035B: 32C0 xor al,al
0000035D: 0E push cs
0000035E: 32C9 xor cl,cl
00000360: 0F14C0 unpcklps xmm0,xmm0 ; ??
00000363: 02C0 add al,al
00000365: 7204 jc 00000036B --↓3
00000367: 5E pop si
00000368: BE5710 mov si,01057 ;'CPU (NEC V30)'
0000036B: E89BEC call 0FFFFF009 ;print_string_si


What are these bytes marked with ??? 0F,14,C0

In Nec Vx is a Group3 Opcode:
0F,14,C0 = Set1 b
Bit CL of reg8 - 1
Sets the bit specified by CL of the a-bit register (specifiedby the first operand) to 1. Only the lower three bits of CL
are used.

So this set, bit defined by CL (0 in this case) to 1 in reg 000, that is AL (fix me if I am wrong, don't have a Nec assembler here, could be nice to have...)


Intel iAPX 86/88, 186/188 User's manual: When the opcode 0FH is encountered, the 8086,88 will execute a POP CS,
so de previous push cs has sense.
0F = POP CS
14,C0 = ADC AL,0Ch

----

So, it seems the BIOS differentiates between Nec and Intel. This test don't set any flag, just shows in the screen the CPU
installed. I've checked the bytes = 0F,14,C0 , and only is found in this check. Possibly the BIOS doesn't use any specific Nec opcodes. Or maybe does a different in another way. Let's see...


Refs:
http://www.ceibo.com/eng/datasheets/NEC-V20-V30-Users-Manual.pdf
Look here page 8.1 for 8080 mode switching

http://www.buchty.net/casio/files/V50-manual.pdf
Opcode maps here

https://sites.google.com/site/misterzeropage/

Chuck(G)
November 13th, 2017, 12:29 PM
That should be ADC AL,0c0h

Which would work; although, as you say, it changes the message and otherwise takes no note of the difference.

Krille
November 18th, 2017, 02:20 AM
I've never seen timing specs for the 8080 instructions, have you?
No, I have not.


Well, I arrived my cave and dumped the BIOS.

It seems is version 1.13 (PCS-86 Resident Diagnostics Rev 1.13) dated 04/04/90.
You should send it to modem7 so he can put it [here (http://www.minuszerodegrees.net/rom/rom.htm)].


What are these bytes marked with ??? 0F,14,C0

In Nec Vx is a Group3 Opcode:
0F,14,C0 = Set1 b
Bit CL of reg8 - 1
Sets the bit specified by CL of the a-bit register (specifiedby the first operand) to 1. Only the lower three bits of CL
are used.

So this set, bit defined by CL (0 in this case) to 1 in reg 000, that is AL (fix me if I am wrong, don't have a Nec assembler here, could be nice to have...)

Yes, that's the 'set1 al, cl' instruction. I've added macros to XUB to support SET1, CLR1, NOT1 and TEST1 instructions but the docs are a bit unclear as to what happens when the index specified in CL / the immediate value is larger than 7 (for 8-bit destinations) or 15 (for 16-bit destinations). Are the extra bits ignored or what?

Take the above instruction for example. What happens if you do this in DEBUG?


xor al, al
mov cl, 0FFh
db 0Fh, 14h, C0h

anormal
November 18th, 2017, 05:14 AM
Ok, i'll send a PM to modem7

I runned that code, AX=0080

If you want more code to be run, just ask me!

Chuck(G)
November 18th, 2017, 08:38 AM
Yes, that's the 'set1 al, cl' instruction. I've added macros to XUB to support SET1, CLR1, NOT1 and TEST1 instructions but the docs are a bit unclear as to what happens when the index specified in CL / the immediate value is larger than 7 (for 8-bit destinations) or 15 (for 16-bit destinations). Are the extra bits ignored or what?

The V20/30 user's manual is very specific--in the case of an 8-bit register operand, only the low-order 3 bits are used; for a 16-bit register, the low-order 4 bits.

Krille
November 18th, 2017, 01:24 PM
I runned that code, AX=0080

If you want more code to be run, just ask me!

Thanks! This confirms that only the 3 least significant bits in CL are used and any extra bits are ignored.


The V20/30 user's manual is very specific--in the case of an 8-bit register operand, only the low-order 3 bits are used; for a 16-bit register, the low-order 4 bits.

The document I have doesn't say 'used', it says 'valid'. I'll give an example from the CLR1 instruction;


If the operand is reg8, CL or mem8, CL, only the low-order 3 bits (0 to 7) of
the value of CL are valid.

This (at least to me) sounds like something bad/unexpected could happen if CL > 7. BTW, this is the description for what the CLR1 instruction does;


Resets bit n (n is the contents of the source operand (src) specified by the
second operand) of the destination operand (dst) specified by the first
operand, and stores the result to the destination operand (dst).


Clear as mud. Maybe it's a language thing, or maybe I'm just dense but that sentence blows my stack. :)

Chuck(G)
November 18th, 2017, 01:34 PM
Here's verbatim from the V-series user's manual, NEC stock# 500350, page 12-95:


SET1 reg8, CL

Bit CL of reg8 <- 1;

Sets the bit specified by CL of the 8-bit register specified by the first operand to 1. Only the lower 3 bits of CL are used.

Seems pretty clear to me.

For instruction descriptions, I recommend the aforementioned manual. It's got more detail than the datasheet descriptions--it's a book that discusses the uPD 70108/uPD 70118 instructions and nothing else. About 2 instructions per page.