[Carradio\PHILIPS\CCRT700 90566805]

Size(380,520);  

Form {

    HexDigit(Code,"Code",70,15,50,4);
    Label(message," ",180,38);
    ComboBox(CodeRequest,"Code request",32,45,50,"On","Off");
    CheckBox(ResetCounter,"Clear error counter",82,75);
    Label(lb1,"Code calculator for PHILIPS  No.: 90 566 805 GM1700X",10,100);
    Label(lb2,"Model: CCRT700MK1 ver.1 для модели DC398/75B",10,120);
    Label(lb3,"Sec. Type:  CODE 0000-9999",10,140);
    Label(lb4,"Manufacturen: Philips",10,160);
    Label(lb5,"MCU: SAF-C167CR-LM",10,180);
    Label(lb6,"EEPROM: ST M28C64",10,200);  
    Label(lb7,"Autor:  telik@ukrwest.net   2008",10,220);
    Label(lb8,"Test: SSM (telik@ukrwest.net)",10,240);
    Label(lb9,"Ввод кода удерживая клавишу (AS) включить магнитолу клавишей (OI)",10,260);
    Label(lb10,"набрать код клавишами (1)(2)(3)(4) и ввести код большой круглой ручкой.",5,280);
    Picture(Logo1,"ccrt700.bmp",20,300,0,0);
}
OnShow {
	var0=@0x0039D;
	var1=@0x0039C;
	var2=var0 ^ 0x007E;
	var3=var1 ^ 0x009C;
	var12=var2 << 8;
	var13=var3 ;
                  
    	if(@0x3 = 57) { var30 = 0; }       else { var37 = 0;}
        if(@0x4 = 48) { var31 = var30+1; } else { var37 = 0;}
        if(@0x5 = 53) { var32 = var31+1; } else { var37 = 0;}
        if(@0x6 = 54) { var33 = var32+1; } else { var37 = 0;}
	if(@0x7 = 54) { var34 = var33+1; } else { var37 = 0;}
        if(@0x8 = 56) { var35 = var34+1; } else { var37 = 0;}
        if(@0x9 = 48) { var36 = var35+1; } else { var37 = 0;}
        if(@0xA = 53) { var37 = var36+1; } else { var37 = 0;}
        if(var37 = 7)
{
  message.Color = 0xFF0000; 
 Message.Bold = 1;
 message = "Дамп ОК.";
var37=7;
 }
else
{
     message.Color = 0x0000FF;
     Message.Bold = 1;
   Message = "Неверный дамп!";
  var12=0;
  //var13=0;
  //var37=0;
  }
                  var23=0;
	CodeRequest = var23;      
        Code = var12 |var13;		
}
OnApply {
                  if(CodeRequest = 1) { @0x003AD = 00; } 
	if(CodeRequest = 1) { @0x003AE = 00; } 
	if(CodeRequest = 1) { @0x003AF = 10; }
	if(CodeRequest = 0) { @0x003AD = 02; }
                  if(CodeRequest = 0) { @0x003AE = 01; }
                  if(CodeRequest = 0) { @0x003AF = 10; }
}
