public void fetch_effective_address()
    {
       int postbyte = ROP_ARG(m6809.pc) & 0xFF;
       m6809.pc = m6809.pc +1 & 0xFFFF;
    
    	switch(postbyte)
    	{
    	case 0x00: ea=m6809.x;												m6809_ICount[0]-=1;   break;
    	case 0x01: ea=m6809.x+1 &0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x02: ea=m6809.x+2 &0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x03: ea=m6809.x+3 &0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x04: ea=m6809.x+4 &0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x05: ea=m6809.x+5 &0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x06: ea=m6809.x+6 &0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x07: ea=m6809.x+7 &0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x08: ea=m6809.x+8 &0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x09: ea=m6809.x+9 &0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x0a: ea=m6809.x+10 &0xFFFF; 											m6809_ICount[0]-=1;   break;
    	case 0x0b: ea=m6809.x+11 &0xFFFF; 											m6809_ICount[0]-=1;   break;
    	case 0x0c: ea=m6809.x+12 &0xFFFF; 											m6809_ICount[0]-=1;   break;
    	case 0x0d: ea=m6809.x+13 &0xFFFF; 											m6809_ICount[0]-=1;   break;
    	case 0x0e: ea=m6809.x+14 &0xFFFF; 											m6809_ICount[0]-=1;   break;
    	case 0x0f: ea=m6809.x+15 &0xFFFF; 											m6809_ICount[0]-=1;   break;
 
    	case 0x10: ea=m6809.x-16 &0xFFFF;											m6809_ICount[0]-=1;   break;
    	case 0x11: ea=m6809.x-15 &0xFFFF; 											m6809_ICount[0]-=1;   break;
    	case 0x12: ea=m6809.x-14 &0xFFFF; 											m6809_ICount[0]-=1;   break;
    	case 0x13: ea=m6809.x-13 &0xFFFF; 											m6809_ICount[0]-=1;   break;
    	case 0x14: ea=m6809.x-12 &0xFFFF;											m6809_ICount[0]-=1;   break;
    	case 0x15: ea=m6809.x-11 &0xFFFF; 											m6809_ICount[0]-=1;   break;
    	case 0x16: ea=m6809.x-10 &0xFFFF; 											m6809_ICount[0]-=1;   break;
    	case 0x17: ea=m6809.x-9 &0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x18: ea=m6809.x-8 &0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x19: ea=m6809.x-7 &0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x1a: ea=m6809.x-6 &0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x1b: ea=m6809.x-5 &0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x1c: ea=m6809.x-4 &0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x1d: ea=m6809.x-3 &0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x1e: ea=m6809.x-2 & 0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x1f: ea=m6809.x-1 & 0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x20: ea=m6809.y;												m6809_ICount[0]-=1;   break;
    	case 0x21: ea=m6809.y+1 & 0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x22: ea=m6809.y+2 & 0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x23: ea=m6809.y+3 & 0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x24: ea=m6809.y+4 & 0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x25: ea=m6809.y+5 & 0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x26: ea=m6809.y+6 & 0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x27: ea=m6809.y+7 & 0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x28: ea=m6809.y+8 & 0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x29: ea=m6809.y+9 & 0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x2a: ea=m6809.y+10 & 0xFFFF; 											m6809_ICount[0]-=1;   break;
    	case 0x2b: ea=m6809.y+11 & 0xFFFF; 											m6809_ICount[0]-=1;   break;
    	case 0x2c: ea=m6809.y+12 & 0xFFFF; 											m6809_ICount[0]-=1;   break;
        case 0x2d: ea=m6809.y+13 & 0xFFFF;											m6809_ICount[0]-=1;   break;
    	case 0x2e: ea=m6809.y+14 & 0xFFFF; 											m6809_ICount[0]-=1;   break;
    	case 0x2f: ea=m6809.y+15 & 0xFFFF; 											m6809_ICount[0]-=1;   break;
    
    	case 0x30: ea=m6809.y-16 & 0xFFFF; 											m6809_ICount[0]-=1;   break;
    	case 0x31: ea=m6809.y-15 & 0xFFFF;											m6809_ICount[0]-=1;   break;
    	case 0x32: ea=m6809.y-14 & 0xFFFF; 											m6809_ICount[0]-=1;   break;
   	case 0x33: ea=m6809.y-13 & 0xFFFF; 											m6809_ICount[0]-=1;   break;
    	case 0x34: ea=m6809.y-12 & 0xFFFF; 											m6809_ICount[0]-=1;   break;
    	case 0x35: ea=m6809.y-11 & 0xFFFF; 											m6809_ICount[0]-=1;   break;
    	case 0x36: ea=m6809.y-10 & 0xFFFF; 											m6809_ICount[0]-=1;   break;
    	case 0x37: ea=m6809.y-9 & 0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x38: ea=m6809.y-8 & 0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x39: ea=m6809.y-7 & 0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x3a: ea=m6809.y-6 & 0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x3b: ea=m6809.y-5 & 0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x3c: ea=m6809.y-4 & 0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x3d: ea=m6809.y-3 & 0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x3e: ea=m6809.y-2&0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x3f: ea=m6809.y-1&0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x40: ea=m6809.u;												m6809_ICount[0]-=1;   break;
    	case 0x41: ea=m6809.u+1 & 0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x42: ea=m6809.u+2 & 0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x43: ea=m6809.u+3 & 0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x44: ea=m6809.u+4 & 0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x45: ea=m6809.u+5 & 0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x46: ea=m6809.u+6 & 0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x47: ea=m6809.u+7 & 0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x48: ea=m6809.u+8 & 0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x49: ea=m6809.u+9 & 0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x4a: ea=m6809.u+10 & 0xFFFF; 											m6809_ICount[0]-=1;   break;
    	case 0x4b: ea=m6809.u+11 & 0xFFFF; 											m6809_ICount[0]-=1;   break;
    	case 0x4c: ea=m6809.u+12 & 0xFFFF; 											m6809_ICount[0]-=1;   break;
    	case 0x4d: ea=m6809.u+13 & 0xFFFF; 											m6809_ICount[0]-=1;   break;
    	case 0x4e: ea=m6809.u+14 & 0xFFFF; 											m6809_ICount[0]-=1;   break;
    	case 0x4f: ea=m6809.u+15 & 0xFFFF; 											m6809_ICount[0]-=1;   break;
    
    	case 0x50: ea=m6809.u-16 & 0xFFFF; 											m6809_ICount[0]-=1;   break;
    	case 0x51: ea=m6809.u-15 & 0xFFFF; 											m6809_ICount[0]-=1;   break;
    	case 0x52: ea=m6809.u-14 & 0xFFFF; 											m6809_ICount[0]-=1;   break;
    	case 0x53: ea=m6809.u-13 & 0xFFFF; 											m6809_ICount[0]-=1;   break;
    	case 0x54: ea=m6809.u-12 & 0xFFFF; 											m6809_ICount[0]-=1;   break;
    	case 0x55: ea=m6809.u-11 & 0xFFFF; 											m6809_ICount[0]-=1;   break;
    	case 0x56: ea=m6809.u-10 & 0xFFFF; 											m6809_ICount[0]-=1;   break;
    	case 0x57: ea=m6809.u-9 & 0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x58: ea=m6809.u-8 & 0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x59: ea=m6809.u-7 & 0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x5a: ea=m6809.u-6 & 0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x5b: ea=m6809.u-5 & 0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x5c: ea=m6809.u-4 &0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x5d: ea=m6809.u-3 &0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x5e: ea=m6809.u-2 &0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x5f: ea=m6809.u-1 &0xFFFF;												m6809_ICount[0]-=1;   break;

    	case 0x60: ea=m6809.s;												m6809_ICount[0]-=1;   break;
    	case 0x61: ea=m6809.s+1&0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x62: ea=m6809.s+2&0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x63: ea=m6809.s+3&0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x64: ea=m6809.s+4&0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x65: ea=m6809.s+5&0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x66: ea=m6809.s+6&0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x67: ea=m6809.s+7&0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x68: ea=m6809.s+8&0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x69: ea=m6809.s+9&0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x6a: ea=m6809.s+10&0xFFFF; 											m6809_ICount[0]-=1;   break;
    	case 0x6b: ea=m6809.s+11&0xFFFF; 											m6809_ICount[0]-=1;   break;
    	case 0x6c: ea=m6809.s+12&0xFFFF; 											m6809_ICount[0]-=1;   break;
    	case 0x6d: ea=m6809.s+13&0xFFFF; 											m6809_ICount[0]-=1;   break;
    	case 0x6e: ea=m6809.s+14&0xFFFF; 											m6809_ICount[0]-=1;   break;
    	case 0x6f: ea=m6809.s+15&0xFFFF;												m6809_ICount[0]-=1;   break;

    	case 0x70: ea=m6809.s-16 &0xFFFF; 											m6809_ICount[0]-=1;   break;
    	case 0x71: ea=m6809.s-15 &0xFFFF; 											m6809_ICount[0]-=1;   break;
    	case 0x72: ea=m6809.s-14 &0xFFFF; 											m6809_ICount[0]-=1;   break;
    	case 0x73: ea=m6809.s-13 &0xFFFF;											m6809_ICount[0]-=1;   break;
   	case 0x74: ea=m6809.s-12 &0xFFFF; 											m6809_ICount[0]-=1;   break;
    	case 0x75: ea=m6809.s-11 &0xFFFF; 											m6809_ICount[0]-=1;   break;
    	case 0x76: ea=m6809.s-10 &0xFFFF;											m6809_ICount[0]-=1;   break;
    	case 0x77: ea=m6809.s-9 &0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x78: ea=m6809.s-8 &0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x79: ea=m6809.s-7 &0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x7a: ea=m6809.s-6 &0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x7b: ea=m6809.s-5 &0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x7c: ea=m6809.s-4 &0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x7d: ea=m6809.s-3 &0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x7e: ea=m6809.s-2 &0xFFFF;												m6809_ICount[0]-=1;   break;
    	case 0x7f: ea=m6809.s-1 &0xFFFF;												m6809_ICount[0]-=1;   break;
    
    	case 0x80: ea=m6809.x;	m6809.x=m6809.x+1&0xFFFF;										m6809_ICount[0]-=2;   break;
    	case 0x81: ea=m6809.x;	m6809.x=m6809.x+2&0xFFFF;										m6809_ICount[0]-=3;   break;
    	case 0x82: m6809.x=m6809.x-1&0xFFFF; 	ea=m6809.x;										m6809_ICount[0]-=2;   break;
    	case 0x83: m6809.x=m6809.x-2&0xFFFF; 	ea=m6809.x;										m6809_ICount[0]-=3;   break;
    	case 0x84: ea=m6809.x;																   break;
    	case 0x85: ea = m6809.x + (byte)m6809.b & 0xFFFF;/*EA=X+SIGNED(B);*/										m6809_ICount[0]-=1;   break;
    	case 0x86: ea = m6809.x + (byte)m6809.a & 0xFFFF;/*EA=X+SIGNED(A);*/										m6809_ICount[0]-=1;   break;
    /*TODO*///	case 0x87: EA=0;																   break; /*   ILLEGAL*/
    	case 0x88: ea=IMMBYTE(); 	ea=m6809.x+(byte)ea& 0xFFFF;					m6809_ICount[0]-=1;   break; /* this is a hack to make Vectrex work. It should be m6809_ICount[0]-=1. Dunno where the cycle was lost :( */
    	case 0x89: ea=IMMWORD(); 	ea = ea + m6809.x & 0xFFFF;								m6809_ICount[0]-=4;   break;
    /*TODO*///	case 0x8a: EA=0;																   break; /*   ILLEGAL*/
    	case 0x8b: ea=m6809.x+getDreg() &0xFFFF;												m6809_ICount[0]-=4;   break;
    /*TODO*///	case 0x8c: IMMBYTE(EA); 	EA=PC+SIGNED(EA);					m6809_ICount[0]-=1;   break;
    	case 0x8d: ea=IMMWORD(); 	ea = ea + m6809.pc & 0xFFFF;				m6809_ICount[0]-=5;   break;
    /*TODO*///	case 0x8e: EA=0;																   break; /*   ILLEGAL*/
    /*TODO*///	case 0x8f: IMMWORD(ea); 										m6809_ICount[0]-=5;   break;
    /*TODO*///
    	case 0x90: ea=m6809.x;	m6809.x=m6809.x+1 &0xFFFF;						ea=RM16(ea);	m6809_ICount[0]-=5;   break; /* Indirect ,R+ not in my specs */
    	case 0x91: ea=m6809.x;	m6809.x=m6809.x+2 &0xFFFF;						ea=RM16(ea);	m6809_ICount[0]-=6;   break;
    	case 0x92: m6809.x=m6809.x-1 &0xFFFF; 	ea=m6809.x;						ea=RM16(ea);	m6809_ICount[0]-=5;   break;
    	case 0x93: m6809.x=m6809.x-2 &0xFFFF;	ea=m6809.x;						ea=RM16(ea);	m6809_ICount[0]-=6;   break;
    	case 0x94: ea=m6809.x;								ea=RM16(ea);	m6809_ICount[0]-=3;   break;
    	case 0x95: ea = m6809.x + (byte)m6809.b & 0xFFFF;						ea=RM16(ea);	m6809_ICount[0]-=4;   break;
    	case 0x96: ea = m6809.x + (byte)m6809.a & 0xFFFF;						ea=RM16(ea);	m6809_ICount[0]-=4;   break;
    /*TODO*///	case 0x97: EA=0;																   break; /*   ILLEGAL*/
    	case 0x98: ea=IMMBYTE(); 	ea=m6809.x+(byte)ea & 0xFFFF;	ea=RM16(ea);	m6809_ICount[0]-=4;   break;
    /*TODO*///	case 0x99: IMMWORD(ea); 	EA+=X;				EAD=RM16(EAD);	m6809_ICount[0]-=7;   break;
    /*TODO*///	case 0x9a: EA=0;																   break; /*   ILLEGAL*/
    	case 0x9b: ea=m6809.x+getDreg();								ea=RM16(ea);	m6809_ICount[0]-=7;   break;
    /*TODO*///	case 0x9c: IMMBYTE(EA); 	EA=PC+SIGNED(EA);	EAD=RM16(EAD);	m6809_ICount[0]-=4;   break;
    /*TODO*///	case 0x9d: IMMWORD(ea); 	EA+=PC; 			EAD=RM16(EAD);	m6809_ICount[0]-=8;   break;
    /*TODO*///	case 0x9e: EA=0;																   break; /*   ILLEGAL*/
    	case 0x9f: ea=IMMWORD(); 						ea=RM16(ea);	m6809_ICount[0]-=8;   break;
    
    	case 0xa0: ea=m6809.y;	m6809.y=m6809.y+1 &0xFFFF;										m6809_ICount[0]-=2;   break;
    	case 0xa1: ea=m6809.y;	m6809.y=m6809.y+2 &0xFFFF;										m6809_ICount[0]-=3;   break;
    	case 0xa2: m6809.y=m6809.y-1&0xFFFF; 	ea=m6809.y;										m6809_ICount[0]-=2;   break;
    	case 0xa3: m6809.y=m6809.y-2&0xFFFF; 	ea=m6809.y;										m6809_ICount[0]-=3;   break;
    	case 0xa4: ea=m6809.y;																   break;
    	case 0xa5: ea=m6809.y + (byte)m6809.b & 0xFFFF;										m6809_ICount[0]-=1;   break;
    	case 0xa6: ea=m6809.y + (byte)m6809.a & 0xFFFF;/*EA=Y+SIGNED(A);*/									m6809_ICount[0]-=1;   break;
    /*TODO*///	case 0xa7: EA=0;																   break; /*   ILLEGAL*/
    	case 0xa8: ea=IMMBYTE(); 	ea=m6809.y + (byte)ea & 0xFFFF;					m6809_ICount[0]-=1;   break;
    	case 0xa9: ea=IMMWORD(); 	ea=ea+m6809.y & 0xFFFF;								m6809_ICount[0]-=4;   break;
    /*TODO*///	case 0xaa: EA=0;																   break; /*   ILLEGAL*/
    	case 0xab: ea=m6809.y+getDreg() & 0xFFFF;												m6809_ICount[0]-=4;   break;
    /*TODO*///	case 0xac: IMMBYTE(EA); 	EA=PC+SIGNED(EA);					m6809_ICount[0]-=1;   break;
    /*TODO*///	case 0xad: IMMWORD(ea); 	EA+=PC; 							m6809_ICount[0]-=5;   break;
    /*TODO*///	case 0xae: EA=0;																   break; /*   ILLEGAL*/
    	case 0xaf: ea=IMMWORD(); 										m6809_ICount[0]-=5;   break;
    /*TODO*///
    /*TODO*///	case 0xb0: EA=Y;	Y++;						EAD=RM16(EAD);	m6809_ICount[0]-=5;   break;
    	case 0xb1: ea=m6809.y;	m6809.y=m6809.y+2 &0xFFFF;						ea=RM16(ea);	m6809_ICount[0]-=6;   break;
    /*TODO*///	case 0xb2: Y--; 	EA=Y;						EAD=RM16(EAD);	m6809_ICount[0]-=5;   break;
    /*TODO*///	case 0xb3: Y-=2;	EA=Y;						EAD=RM16(EAD);	m6809_ICount[0]-=6;   break;
    	case 0xb4: ea=m6809.y;								ea=RM16(ea);	m6809_ICount[0]-=3;   break;
    	case 0xb5: ea=m6809.y + (byte)m6809.b & 0xFFFF;						ea=RM16(ea);	m6809_ICount[0]-=4;   break;
    	case 0xb6: ea=m6809.y + (byte)m6809.a & 0xFFFF; 						ea=RM16(ea);	m6809_ICount[0]-=4;   break;
    /*TODO*///	case 0xb7: EA=0;																   break; /*   ILLEGAL*/
    	case 0xb8: ea=IMMBYTE(); 	ea=m6809.y + (byte)ea & 0xFFFF;	ea=RM16(ea);	m6809_ICount[0]-=4;   break;
    /*TODO*///	case 0xb9: IMMWORD(ea); 	EA+=Y;				EAD=RM16(EAD);	m6809_ICount[0]-=7;   break;
    /*TODO*///	case 0xba: EA=0;																   break; /*   ILLEGAL*/
    	case 0xbb: ea=m6809.y+getDreg() & 0xFFFF;								ea=RM16(ea);	m6809_ICount[0]-=7;   break;
    /*TODO*///	case 0xbc: IMMBYTE(EA); 	EA=PC+SIGNED(EA);	EAD=RM16(EAD);	m6809_ICount[0]-=4;   break;
    /*TODO*///	case 0xbd: IMMWORD(ea); 	EA+=PC; 			EAD=RM16(EAD);	m6809_ICount[0]-=8;   break;
    /*TODO*///	case 0xbe: EA=0;																   break; /*   ILLEGAL*/
    /*TODO*///	case 0xbf: IMMWORD(ea); 						EAD=RM16(EAD);	m6809_ICount[0]-=8;   break;
    /*TODO*///
    	case 0xc0: ea=m6809.u;			m6809.u=m6809.u+1&0xFFFF;								m6809_ICount[0]-=2;   break;
    	case 0xc1: ea=m6809.u;			m6809.u=m6809.u+2&0xFFFF;								m6809_ICount[0]-=3;   break;
    	case 0xc2: m6809.u=m6809.u-1 &0xFFFF; 			ea=m6809.u;								m6809_ICount[0]-=2;   break;
    	case 0xc3: m6809.u=m6809.u-2 &0xFFFF; 			ea=m6809.u;								m6809_ICount[0]-=3;   break;
    	case 0xc4: ea=m6809.u;																   break;
    	case 0xc5: ea=m6809.u+(byte)m6809.b & 0xFFFF;										m6809_ICount[0]-=1;   break;
    	case 0xc6: ea=m6809.u+(byte)m6809.a & 0xFFFF;										m6809_ICount[0]-=1;   break;
    /*TODO*///	case 0xc7: EA=0;																   break; /*ILLEGAL*/
    	case 0xc8: ea=IMMBYTE(); 	ea=m6809.u+(byte)ea & 0xFFFF;					m6809_ICount[0]-=1;   break;
    	case 0xc9: ea=IMMWORD(); 	ea=ea+m6809.u &0xFFFF;					m6809_ICount[0]-=4;   break;
    /*TODO*///	case 0xca: EA=0;																   break; /*ILLEGAL*/
    	case 0xcb: ea=m6809.u+getDreg() &0xFFFF;												m6809_ICount[0]-=4;   break;
    /*TODO*///	case 0xcc: IMMBYTE(EA); 	EA=PC+SIGNED(EA);					m6809_ICount[0]-=1;   break;
    /*TODO*///	case 0xcd: IMMWORD(ea); 	EA+=PC; 							m6809_ICount[0]-=5;   break;
    /*TODO*///	case 0xce: EA=0;																   break; /*ILLEGAL*/
    /*TODO*///	case 0xcf: IMMWORD(ea); 										m6809_ICount[0]-=5;   break;
    /*TODO*///
    /*TODO*///	case 0xd0: EA=U;	U++;						EAD=RM16(EAD);	m6809_ICount[0]-=5;   break;
        case 0xd1: ea=m6809.u;	m6809.u=m6809.u+2&0xFFFF;						ea=RM16(ea);	m6809_ICount[0]-=6;   break;
    /*TODO*///	case 0xd2: U--; 	EA=U;						EAD=RM16(EAD);	m6809_ICount[0]-=5;   break;
    /*TODO*///	case 0xd3: U-=2;	EA=U;						EAD=RM16(EAD);	m6809_ICount[0]-=6;   break;
    	case 0xd4: ea=m6809.u;								ea=RM16(ea);	m6809_ICount[0]-=3;   break;
    	case 0xd5: ea=m6809.u+(byte)m6809.b & 0xFFFF;						ea=RM16(ea);	m6809_ICount[0]-=4;   break;
    	case 0xd6: ea=m6809.u+(byte)m6809.a & 0xFFFF;						ea=RM16(ea);	m6809_ICount[0]-=4;   break;
    /*TODO*///	case 0xd7: EA=0;																   break; /*ILLEGAL*/
    	case 0xd8: ea=IMMBYTE(); 	ea=m6809.u+(byte)ea&0xFFFF;	ea=RM16(ea);	m6809_ICount[0]-=4;   break;
    /*TODO*///	case 0xd9: IMMWORD(ea); 	EA+=U;				EAD=RM16(EAD);	m6809_ICount[0]-=7;   break;
    /*TODO*///	case 0xda: EA=0;																   break; /*ILLEGAL*/
    	case 0xdb: ea=m6809.u+getDreg() & 0xFFFF;								ea=RM16(ea);	m6809_ICount[0]-=7;   break;
    /*TODO*///	case 0xdc: IMMBYTE(EA); 	EA=PC+SIGNED(EA);	EAD=RM16(EAD);	m6809_ICount[0]-=4;   break;
    /*TODO*///	case 0xdd: IMMWORD(ea); 	EA+=PC; 			EAD=RM16(EAD);	m6809_ICount[0]-=8;   break;
    /*TODO*///	case 0xde: EA=0;																   break; /*ILLEGAL*/
    /*TODO*///	case 0xdf: IMMWORD(ea); 						EAD=RM16(EAD);	m6809_ICount[0]-=8;   break;
    /*TODO*///
    	case 0xe0: ea=m6809.s;	m6809.s=m6809.s+1&0xFFFF;										m6809_ICount[0]-=2;   break;
    	case 0xe1: ea=m6809.s;	m6809.s=m6809.s+2&0xFFFF;										m6809_ICount[0]-=3;   break;
    	case 0xe2: m6809.s=m6809.s-1&0xFFFF; 	ea=m6809.s;										m6809_ICount[0]-=2;   break;
    	case 0xe3: m6809.s=m6809.s-2&0xFFFF; 	ea=m6809.s;										m6809_ICount[0]-=3;   break;
    	case 0xe4: ea=m6809.s;																   break;
    	case 0xe5: ea=m6809.s+(byte)m6809.b&0xFFFF;										m6809_ICount[0]-=1;   break;
    	case 0xe6: ea=m6809.s+(byte)m6809.a&0xFFFF;										m6809_ICount[0]-=1;   break;
    /*TODO*///	case 0xe7: EA=0;																   break; /*ILLEGAL*/
    	case 0xe8: ea=IMMBYTE(); 	ea=m6809.s+(byte)ea & 0xFFFF;					m6809_ICount[0]-=1;   break;
    /*TODO*///	case 0xe9: IMMWORD(ea); 	EA+=S;								m6809_ICount[0]-=4;   break;
    /*TODO*///	case 0xea: EA=0;																   break; /*ILLEGAL*/
    /*TODO*///	case 0xeb: EA=S+D;												m6809_ICount[0]-=4;   break;
    /*TODO*///	case 0xec: IMMBYTE(EA); 	EA=PC+SIGNED(EA);					m6809_ICount[0]-=1;   break;
    /*TODO*///	case 0xed: IMMWORD(ea); 	EA+=PC; 							m6809_ICount[0]-=5;   break;
    /*TODO*///	case 0xee: EA=0;																   break;  /*ILLEGAL*/
    /*TODO*///	case 0xef: IMMWORD(ea); 										m6809_ICount[0]-=5;   break;
    /*TODO*///
    /*TODO*///	case 0xf0: EA=S;	S++;						EAD=RM16(EAD);	m6809_ICount[0]-=5;   break;
    	case 0xf1: ea=m6809.s;	m6809.s = m6809.s+2 & 0xFFFF;						ea=RM16(ea);	m6809_ICount[0]-=6;   break;
    /*TODO*///	case 0xf2: S--; 	EA=S;						EAD=RM16(EAD);	m6809_ICount[0]-=5;   break;
    /*TODO*///	case 0xf3: S-=2;	EA=S;						EAD=RM16(EAD);	m6809_ICount[0]-=6;   break;
    /*TODO*///	case 0xf4: EA=S;								EAD=RM16(EAD);	m6809_ICount[0]-=3;   break;
    /*TODO*///	case 0xf5: EA=S+SIGNED(B);						EAD=RM16(EAD);	m6809_ICount[0]-=4;   break;
    /*TODO*///	case 0xf6: EA=S+SIGNED(A);						EAD=RM16(EAD);	m6809_ICount[0]-=4;   break;
    /*TODO*///	case 0xf7: EA=0;																   break; /*ILLEGAL*/
    	case 0xf8: ea=IMMBYTE(); 	ea=m6809.s+(byte)ea & 0xFFFF;	ea=RM16(ea);	m6809_ICount[0]-=4;   break;
    /*TODO*///	case 0xf9: IMMWORD(ea); 	EA+=S;				EAD=RM16(EAD);	m6809_ICount[0]-=7;   break;
    /*TODO*///	case 0xfa: EA=0;																   break; /*ILLEGAL*/
    /*TODO*///	case 0xfb: EA=S+D;								EAD=RM16(EAD);	m6809_ICount[0]-=7;   break;
    	case 0xfc: ea=IMMBYTE(); 	ea=m6809.pc+(byte)ea & 0xFFFF;	ea=RM16(ea);	m6809_ICount[0]-=4;   break;
    /*TODO*///	case 0xfd: IMMWORD(ea); 	EA+=PC; 			EAD=RM16(EAD);	m6809_ICount[0]-=8;   break;
    /*TODO*///	case 0xfe: EA=0;																   break; /*ILLEGAL*/
    /*TODO*///	case 0xff: IMMWORD(ea); 						EAD=RM16(EAD);	m6809_ICount[0]-=8;   break;
                default:
                System.out.println("6809 effective address : 0x"+Integer.toHexString(postbyte));
        }
    }
    /*TODO*////****************************************************************************
    /*TODO*/// * M6309 section
    /*TODO*/// ****************************************************************************/
    /*TODO*///#if HAS_HD6309
    /*TODO*///static UINT8 hd6309_reg_layout[] = {
    /*TODO*///	M6309_PC, M6309_S, M6309_CC, M6309_A, M6309_B, M6309_X, -1,
    /*TODO*///	M6309_Y, M6309_U, M6309_DP, M6309_NMI_STATE, M6309_IRQ_STATE, M6309_FIRQ_STATE, 0
    /*TODO*///};
    /*TODO*///
    /*TODO*////* Layout of the debugger windows x,y,w,h */
    /*TODO*///static UINT8 hd6309_win_layout[] = {
    /*TODO*///	27, 0,53, 4,	/* register window (top, right rows) */
    /*TODO*///	 0, 0,26,22,	/* disassembler window (left colums) */
    /*TODO*///	27, 5,53, 8,	/* memory #1 window (right, upper middle) */
    /*TODO*///	27,14,53, 8,	/* memory #2 window (right, lower middle) */
    /*TODO*///     0,23,80, 1,    /* command line window (bottom rows) */
    /*TODO*///};
    /*TODO*///
    /*TODO*///void hd6309_reset(void *param) { m6809_reset(param); }
    /*TODO*///void hd6309_exit(void) { m6809_exit(); }
    /*TODO*///int hd6309_execute(int cycles) { return m6809_execute(cycles); }
    /*TODO*///unsigned hd6309_get_context(void *dst) { return m6809_get_context(dst); }
    /*TODO*///void hd6309_set_context(void *src) { m6809_set_context(src); }
    /*TODO*///unsigned hd6309_get_pc(void) { return m6809_get_pc(); }
    /*TODO*///void hd6309_set_pc(unsigned val) { m6809_set_pc(val); }
    /*TODO*///unsigned hd6309_get_sp(void) { return m6809_get_sp(); }
    /*TODO*///void hd6309_set_sp(unsigned val) { m6809_set_sp(val); }
    /*TODO*///unsigned hd6309_get_reg(int regnum) { return m6809_get_reg(regnum); }
    /*TODO*///void hd6309_set_reg(int regnum, unsigned val) { m6809_set_reg(regnum,val); }
    /*TODO*///void hd6309_set_nmi_line(int state) { m6809_set_nmi_line(state); }
    /*TODO*///void hd6309_set_irq_line(int irqline, int state) { m6809_set_irq_line(irqline,state); }
    /*TODO*///void hd6309_set_irq_callback(int (*callback)(int irqline)) { m6809_set_irq_callback(callback); }
    /*TODO*///void hd6309_state_save(void *file) { state_save(file, "hd6309"); }
    /*TODO*///void hd6309_state_load(void *file) { state_load(file, "hd6309"); }