Tag Archives: pc xt clone

Connecting my PC XT clone to the network: Part 1 – Ethernet adapter

I currently work on connecting my PC XT clone to my home network. But why? What are the benefits of connecting a 30 years old machine to the network?

It gives me one more reason to fire up my Pravetz 16 ๐Ÿ™‚ It would be cool chatting on IRC on that monochrome (green and black) monitor, running an FTP server for file transfers between the PC XT and other PC’s on the network or an HTTP server, etc…

The PC XT will be connected to the network using the so called ‘Thin Ethernet‘ (10Base2) using a coaxial cable and BNC connectors. Why? Because finding 8-bit ISA compatible Ethernet card is extremely rare nowadays, and chances to find one with RJ45 connector are close to zero.

My long search for 8-bit ISA network adapter finally gave results and for 10$ I’m an owner of PLUS & PLUS PCN-001.

Plus & Plus PNC-001 Ethernet adpater

Plus & Plus PNC-001 Ethernet adpater

It’s 10Mbps Ethernet card with support for coaxial and DIX transceiver wiring. It has an option for a boot ROM but mine don’t have a chip. This card is a clone of AMERICAN RESEARCH CORPORATION PNC-001, it’s NE1000 compatible and supported by the NE1000 driver for DOS available in the many-other-drivers.zip along with many other packet drives, thanks to Crynwr Software!

After a bit of googling I found the required information on how to configure the adapter here. That exact same information is copy / pasted at the end of this post for future references.

Setting the IRQ to 2, the I/O base address to 200h, and disabling the boot ROM and DMA settings, changing the cable type jumpers from ‘DIX transceiver via DB-15 port’ to ‘RG-58A/U 50ohm coaxial’ I booted the PC, loaded the NE1000 driver

C:\>ne1000 0x7E 2 0x200

UPDATE 16/02/2016: I was having problems receiving network packets, changing the IRQ to 5 and I/O base address to 0x280h resolved the problem.

NE1000 packet driver loaded

NE1000 packet driver loaded

and success! The card is working! 10$ well spend ๐Ÿ™‚

NOTE: Installation instructions for packet drivers are in INSTALL.DOC (many-other-drivers.zip)

The Ethernet adapter is now configured and working properly. This concludes Part 1 of the series of articles about connecting my PC XT to the network. Later I will review other vital network component. The Surecom Ether Perfect 517T hub with BNC connector.

PLUS & PLUS (AMERICAN RESEARCH CORPORATION) PNC-001 Jumper settings (Information taken from Total Hardware 1999 page on the topic available here.)

40191-1

I/O BASE ADDRESS

Address SW1/1 SW1/2 SW1/3 SW1/4 SW1/5
200h Off On On On On
220h Off On On On Off
240h Off On On Off On
260h Off On On Off Off
280h Off On Off On On
2A0h Off On Off On Off
2C0h Off On Off Off On
2E0h Off On Off Off Off
300h (default) Off Off On On On
320h Off Off On On Off
340h Off Off On Off On
360h Off Off On Off Off
380h Off Off Off On On
3A0h Off Off Off On Off
3C0h Off Off Off Off On
3E0h Off Off Off Off Off

BOOT ROM

Setting SW1/6
Disabled (default) Off
Enabled On

BOOT ROM ADDRESS

Address SW1/7 SW1/8 SW1/9 SW1/10
C0000h On On On On
C4000h On On On Off
C8000h On On Off On
CC000h On On Off Off
D0000h On Off On On
D4000h On Off On Off
D8000h On Off Off On
DC000h (default) On Off Off Off
E0000h Off On On On
E4000h Off On On Off
E8000h Off On Off On
EC000h Off On Off Off
F0000h Off Off On On
F4000h Off Off On Off
F8000h Off Off Off On
FC000h Off Off Off Off

INTERRUPT REQUEST

IRQ JP1A JP1B JP1C JP1D
2 Closed Open Open Open
3 (default) Open Closed Open Open
4 Open Open Closed Open
5 Open Open Open Closed

DMA CHANNEL

Channel JP1F JP1G JP1H JP1I
DMA1 (default) Closed Open Closed Open
DMA3 Open Closed Open Closed

CABLE TYPE

Type JP2A – JP2F
RG-58A/U 50ohm coaxial (default) Pins 1 & 2 closed
DIX transceiver via DB-15 port Pins 2 & 3 closed

FACTORY CONFIGURED SETTINGS

Jumper Setting
JP1E Open

SINFO.EXE or playing with bios interrupts on my PC XT clone

I am stuck with a problem in the game I work on for several days now. When I’m stuck I usually do something else for a couple of hours. For example playing with bios interrupts on my PC XT clone (which by the way is completely restored, but more on this in the upcoming posts).

Pravetz 16 (IBM PC XT clone)

Pravetz 16 (IBM PC XT clone) and yes that’s Windows 3.0.

NOTE: Writing code on monochrome monitor is something that every software developer should do at least ones in his career ๐Ÿ™‚

What’s interrupt? (From Wikipedia articles on interrupts)

In system programming, an interrupt is a signal to the processor emitted by hardware or software indicating an event that needs immediate attention. An interrupt alerts the processor to a high-priority condition requiring the interruption of the current code the processor is executing. The processor responds by suspending its current activities, saving its state, and executing a function called an interrupt handler (or an interrupt service routine, ISR) to deal with the event. This interruption is temporary, and, after the interrupt handler finishes, the processor resumes normal activities.[1] There are two types of interrupts: hardware interrupts and software interrupts.

The code below calls software interrupts 11h (Equipment Installed) and 12h (Memory Available) using inline assembly. To compile the source you will need Turbo C and TASM. They both run perfectly fine under DOSBox.

The executable is available for download here.

#include 
 
int main(void)
{
  int systemInfo;
  int floppyCount;
  int mem, memSize, memSizePost;
  int videoMode;
  int serialPorts;
  int paralelPorts;
 
  /* Call INT 11h ( Equipment Installed ) */
  asm int 11h;
  asm mov systemInfo, ax;
 
  /* Call INT 12h ( Memory Available ) */
  asm int 12h;
  asm mov memSizePost, ax;
 
  printf("********** SYSTEM INFO ***********\n");
  printf("Floppy drive(s): %s ", (systemInfo & 0x0001) ? "yes" : "no");
 
  if((systemInfo & 0x0001))
  {
    switch((systemInfo & 0x00C0))
    {
      case 0:
      {
		floppyCount = 1;
		break;
      }
      case 64:
      {
		floppyCount = 2;
		break;
      }
      case 128:
      {
		floppyCount = 3;
		break;
      }
      case 192:
      {
		floppyCount = 4;
		break;
      }
    }
 
    printf("(%d)\n", floppyCount);
  }
  else
  {
    printf("\n");
  }
 
 
  printf("Math co-processor: %s\n", (systemInfo & 0x0002) ? "yes" : "no");
 
  mem = (systemInfo & 0x000C);
 
  switch(mem)
  {
    case 0:
    {
      memSize = 16;
      break;
    }    
    case 4:
    {
      memSize = 32;
      break;
    }
    case 8:
    {
      memSize = 48;
      break;
    }
    case 12:
    {
      memSize = 256;
      break;
    }
  }
  printf("On-board memory: %d K%s\n", memSize, (memSize >= 256) ? "+" : " ");
  printf("Memory reported by BIOS POST: %dK\n", memSizePost);
 
  videoMode = (systemInfo & 0x0030);
  switch(videoMode)
  {
    case 0:
    {
      printf("Video mode: EGA, VGA or PGA\n");
      break;
    }
    case 16:
    {
      printf("Video mode: CGA, 40 x 25\n");
      break;
    }
    case 32:
    {
      printf("Video mode: CGA, 80 x 25\n");
      break;
    }
    case 48:
    {
      printf("Video mode: monochrome, 80 x 25\n");
      break;
    }
  }
 
  printf("DMA support: %s\n", (systemInfo & 0x0100) == 0 ? "yes" : "no");
  printf("Game adapter: %s\n", (systemInfo & 0x1000) == 0 ? "no" : "yes");
 
  switch((systemInfo & 0x0E00))
  {
    case 0:
    {
      serialPorts = 0;
      break;
    }
    case 512:
    {
      serialPorts = 1;
      break;
    }
    case 1024:
    {
      serialPorts = 2;
      break;
    }
    case 1536:
    {
      serialPorts = 3;
      break;
    }
    case 2048:
    {
      serialPorts = 4;
      break;
    }
  }
  printf("Serial ports: %d\n", serialPorts);
 
  switch((systemInfo & 0xC000))
  {
    case 0:
    {
      paralelPorts = 0;
      break;
    }
    case 16384:
    {
      paralelPorts = 1;
      break;
    }
    case 32768:
    {
      paralelPorts = 2;
      break;
    }
    case 49152:
    {
      paralelPorts = 3;
      break;
    }
  }
  printf("Paralel ports: %d\n", paralelPorts);
 
  return 0;
}