[Dashboard\Renault\Fluence\Fluence abs 95160]

Size(280,310); 

Form 
{
    Group("Пробег",5,13,165,50)
    {
        Digit(Distance," ",5,18,60);
        Label(lbkm,"КМ",80,20);
       
    }
 //   Group("Идентификация",5,80,270,45)
 //   {
 //       Label(partmb," ",0,18);
 //   }
    Group("Информация",5,125,270,45) 
    {
        Label(Message," ",0,18);
    }    
    Group("Описание",5,175,270,90) 
    {
        Label(lb1,"Калькулятор пробега для Renault Fluence ABS.",0,20);
        Label(lb2,"EEPROM 95160.",0,35);
        Label(lb3,"Введите нужное значение в окне <Пробег>.",0,50);
        Label(lb4,"Нажмите кнопку <Применить>.",0,65);
    }
    Picture(Logo,"Renault.bmp",185,8,0,0);
}

OnShow 
{
    Message.Bold = 1;  
    Var0 = 1;
   
 if (Var0 = 0)


    {
        message.Color = 0x0000FF;
        Message = "Неверный дамп!";
        Distance = 0;
    }
    else
    {
    VAr5 = 0xffffffff - ((@0x10e << 24) | (@0x10f << 16) | (@0x110 << 8) | @0x111);

    
    message.Color = 0xFF0000;
    message.Bold = 1;
    message = "Дамп ОК. Введите новый пробег.";
    Distance = Var5/10000;
 //   partmb = "VIN: "+#c.@0x5C+#c.@0x5D+#c.@0x60+#c.@0x61+#c.@0x64+#c.@0x65+#c.@0x68+#c.@0x69+#c.@0x6C+#c.@0x6D+#c.@0x70+#c.@0x71+#c.@0x74+#c.@0x75+#c.@0x78+#c.@0x79+#c.@0x7C;
    }
}
    
OnApply
{
    Var0 = 1;
	
    if (Var0 = 0)
    {
        message.Color = 0x0000FF;
        Message = "Неверный дамп! Запись прекращена!";
        Distance = 0;
    }
    else
    {
    Var5 = 0;
    Var2 = Distance;
    if(Var2 > 999900) {Var5 = 1;}
    if(Var2 < 0)   {Var5 = 1;}
    if(Var5 != 0)
    {
        message.Color = 0x0000FF;
        message.Bold = 1;
        message = "Пробег должен быть от 0 до 999900 км";
    }
    else
    { 
       Var2 = Var2 * 10000;

       Var0 = 0x10e;

       
       @Var0 = 0xffffffff - Var2 >> 24; Var0 = Var0 +4;     
       @Var0 = 0xffffffff - Var2 >> 24; Var0 = Var0 +100;
       	@Var0 = 0xffffffff - Var2 >> 24; Var0 = Var0 +4;     
       	@Var0 = 0xffffffff - Var2 >> 24; Var0 = Var0 +19;
	@Var0 = 0xffffffff - Var2 >> 24;Var0 = Var0 +4;
	@Var0 = 0xffffffff - Var2 >> 24;Var0 = Var0 +19;
	@Var0 = 0xffffffff - Var2 >> 24;Var0 = Var0 +4;
	@Var0 = 0xffffffff - Var2 >> 24;Var0 = Var0 +19;
	@Var0 = 0xffffffff - Var2 >> 24;Var0 = Var0 +4;
	@Var0 = 0xffffffff - Var2 >> 24;Var0 = Var0 +19;
	@Var0 = 0xffffffff - Var2 >> 24;Var0 = Var0 +4;
	@Var0 = 0xffffffff - Var2 >> 24;Var0 = Var0 +19;
	@Var0 = 0xffffffff - Var2 >> 24;Var0 = Var0 +4;
	@Var0 = 0xffffffff - Var2 >> 24;Var0 = Var0 +19;
	@Var0 = 0xffffffff - Var2 >> 24;Var0 = Var0 +4;
	@Var0 = 0xffffffff - Var2 >> 24;Var0 = Var0 +19;
	@Var0 = 0xffffffff - Var2 >> 24;Var0 = Var0 +4;
	@Var0 = 0xffffffff - Var2 >> 24;Var0 = Var0 +19;

	Var0 = 0x10f;
       @Var0 = 0xffffffff - Var2 >> 16; Var0 = Var0 +4; 
       @Var0 = 0xffffffff - Var2 >> 16; Var0 = Var0 +100;   
       	@Var0 = 0xffffffff - Var2 >> 16; Var0 = Var0 +4; 
        @Var0 = 0xffffffff - Var2 >> 16; Var0 = Var0 +19;
	@Var0 = 0xffffffff - Var2 >> 16;Var0 = Var0 +4;
	@Var0 = 0xffffffff - Var2 >> 16;Var0 = Var0 +19;
	@Var0 = 0xffffffff - Var2 >> 16;Var0 = Var0 +4;
	@Var0 = 0xffffffff - Var2 >> 16;Var0 = Var0 +19;
	@Var0 = 0xffffffff - Var2 >> 16;Var0 = Var0 +4;
	@Var0 = 0xffffffff - Var2 >> 16;Var0 = Var0 +19;
	@Var0 = 0xffffffff - Var2 >> 16;Var0 = Var0 +4;
	@Var0 = 0xffffffff - Var2 >> 16;Var0 = Var0 +19;
	@Var0 = 0xffffffff - Var2 >> 16;Var0 = Var0 +4;
	@Var0 = 0xffffffff - Var2 >> 16;Var0 = Var0 +19;
	@Var0 = 0xffffffff - Var2 >> 16;Var0 = Var0 +4;
	@Var0 = 0xffffffff - Var2 >> 16;Var0 = Var0 +19;
	@Var0 = 0xffffffff - Var2 >> 16;Var0 = Var0 +4;
	@Var0 = 0xffffffff - Var2 >> 16;Var0 = Var0 +19;
       Var0 = 0x110;
       @Var0 = 0xffffffff - Var2 >> 8; Var0 = Var0 +4; 
       @Var0 = 0xffffffff - Var2 >> 8; Var0 = Var0 +100;
       	@Var0 = 0xffffffff - Var2 >> 8; Var0 = Var0 +4; 
        @Var0 = 0xffffffff - Var2 >> 8; Var0 = Var0 +19;
	@Var0 = 0xffffffff - Var2 >> 8;Var0 = Var0 +4;
	@Var0 = 0xffffffff - Var2 >> 8;Var0 = Var0 +19;
	@Var0 = 0xffffffff - Var2 >> 8;Var0 = Var0 +4;
	@Var0 = 0xffffffff - Var2 >> 8;Var0 = Var0 +19;
	@Var0 = 0xffffffff - Var2 >> 8;Var0 = Var0 +4;
	@Var0 = 0xffffffff - Var2 >> 8;Var0 = Var0 +19;
	@Var0 = 0xffffffff - Var2 >> 8;Var0 = Var0 +4;
	@Var0 = 0xffffffff - Var2 >> 8;Var0 = Var0 +19;
	@Var0 = 0xffffffff - Var2 >> 8;Var0 = Var0 +4;
	@Var0 = 0xffffffff - Var2 >> 8;Var0 = Var0 +19;
	@Var0 = 0xffffffff - Var2 >> 8;Var0 = Var0 +4;
	@Var0 = 0xffffffff - Var2 >> 8;Var0 = Var0 +19;
	@Var0 = 0xffffffff - Var2 >> 8;Var0 = Var0 +4;
	@Var0 = 0xffffffff - Var2 >> 8;Var0 = Var0 +19;

	Var0 = 0x111;
        @Var0 = 0xffffffff - Var2; Var0 = Var0 +4; 
       @Var0 = 0xffffffff - Var2; Var0 = Var0 +100;
       	@Var0 = 0xffffffff - Var2; Var0 = Var0 +4; 
        @Var0 = 0xffffffff - Var2; Var0 = Var0 +19;
	@Var0 = 0xffffffff - Var2;Var0 = Var0 +4;
	@Var0 = 0xffffffff - Var2;Var0 = Var0 +19;
	@Var0 = 0xffffffff - Var2;Var0 = Var0 +4;
	@Var0 = 0xffffffff - Var2;Var0 = Var0 +19;
	@Var0 = 0xffffffff - Var2;Var0 = Var0 +4;
	@Var0 = 0xffffffff - Var2;Var0 = Var0 +19;
	@Var0 = 0xffffffff - Var2;Var0 = Var0 +4;
	@Var0 = 0xffffffff - Var2;Var0 = Var0 +19;
	@Var0 = 0xffffffff - Var2;Var0 = Var0 +4;
	@Var0 = 0xffffffff - Var2;Var0 = Var0 +19;
	@Var0 = 0xffffffff - Var2;Var0 = Var0 +4;
	@Var0 = 0xffffffff - Var2;Var0 = Var0 +19;
	@Var0 = 0xffffffff - Var2;Var0 = Var0 +4;
	@Var0 = 0xffffffff - Var2;Var0 = Var0 +19;

 
         

 
       message.Color = 0xFF0000;
       message.Bold = 1;
       message = "Новый пробег записан.";
    }
   }
}












