V3.81
This commit is contained in:
Binary file not shown.
+5
-4
@@ -1,6 +1,6 @@
|
||||
object FormConfig: TFormConfig
|
||||
Left = 230
|
||||
Top = 226
|
||||
Left = 384
|
||||
Top = 136
|
||||
Hint =
|
||||
'Modifie les fichiers de configuration selon les s'#233'lections chois' +
|
||||
'ies'
|
||||
@@ -1578,7 +1578,7 @@ object FormConfig: TFormConfig
|
||||
Top = 8
|
||||
Width = 633
|
||||
Height = 497
|
||||
ActivePage = TabSheetBranches
|
||||
ActivePage = TabSheetSig
|
||||
Font.Charset = DEFAULT_CHARSET
|
||||
Font.Color = clBlack
|
||||
Font.Height = -11
|
||||
@@ -1858,7 +1858,7 @@ object FormConfig: TFormConfig
|
||||
Top = 18
|
||||
Width = 215
|
||||
Height = 13
|
||||
Caption = 'Liste des '#233'v'#232'nements envoy'#233's par CDM Rail:'
|
||||
Caption = 'Liste des '#233'v'#232'nements demand'#233's '#224' CDM Rail:'
|
||||
end
|
||||
object CheckBoxServAig: TCheckBox
|
||||
Left = 8
|
||||
@@ -2732,6 +2732,7 @@ object FormConfig: TFormConfig
|
||||
ScrollBars = ssBoth
|
||||
TabOrder = 1
|
||||
WordWrap = False
|
||||
OnKeyDown = RichBrancheKeyDown
|
||||
OnMouseDown = RichBrancheMouseDown
|
||||
end
|
||||
end
|
||||
|
||||
+360
-158
File diff suppressed because it is too large
Load Diff
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
+1
-1
@@ -1374,7 +1374,7 @@ object FormPrinc: TFormPrinc
|
||||
object ButtonLocCV: TButton
|
||||
Left = 192
|
||||
Top = 88
|
||||
Width = 81
|
||||
Width = 83
|
||||
Height = 33
|
||||
Caption = 'Trains / CVs'
|
||||
TabOrder = 8
|
||||
|
||||
+59
-27
@@ -3,7 +3,7 @@ Unit UnitPrinc;
|
||||
programme signaux complexes Graphique Lenz
|
||||
delphi 7 + activeX Tmscomm + clientSocket
|
||||
********************************************
|
||||
27/2/2022 10h
|
||||
6/3/2022 16h
|
||||
note sur le pilotage des accessoires:
|
||||
raquette octet sortie
|
||||
+ 2 = aiguillage droit = sortie 2 de l'adresse d'accessoire
|
||||
@@ -198,6 +198,8 @@ NbMaxDet=100; // nombre maximal de d
|
||||
NbMemZone=2048; // adresse maximale des détecteurs
|
||||
Max_Trains=100;
|
||||
Max_event_det=400;
|
||||
MaxBranches=100;
|
||||
MaxElBranches=200;
|
||||
LargImg=50;HtImg=91; // Dimensions image des feux
|
||||
const_droit=2; // positions aiguillages transmises par la centrale LENZ
|
||||
const_devie=1; // positions aiguillages transmises par la centrale LENZ
|
||||
@@ -286,7 +288,7 @@ TFeu = record
|
||||
Adr_el_suiv4 : integer; // adresse de l'élément4 suivant (si un signal est pour plusieurs voies)
|
||||
Btype_suiv1 : TEquipement ; // type de l'élément suivant ne prend que les valeurs rien, det ou aig
|
||||
Btype_suiv2 : TEquipement ; //
|
||||
Btype_suiv3 : TEquipement ; //
|
||||
Btype_suiv3 : TEquipement ; //
|
||||
Btype_suiv4 : TEquipement ; //
|
||||
VerrouCarre : boolean ; // si vrai, le feu se verrouille au carré si pas de train avant le signal
|
||||
modifie : boolean; // feu modifié
|
||||
@@ -397,7 +399,8 @@ var
|
||||
Aig_supprime,Aig_sauve : TAiguillage;
|
||||
|
||||
Fimage : Timage;
|
||||
BrancheN : array[1..100,1..200] of TBranche;
|
||||
|
||||
BrancheN : array[1..MaxBranches,1..MaxElBranches] of TBranche;
|
||||
|
||||
{$R *.dfm}
|
||||
|
||||
@@ -440,6 +443,7 @@ procedure cree_image(rang : integer);
|
||||
procedure trouve_aiguillage(adresse : integer);
|
||||
procedure trouve_detecteur(detecteur : integer);
|
||||
function BTypeToNum(BT : TEquipement) : integer;
|
||||
function ProcessRunning(sExeName: String) : Boolean;
|
||||
|
||||
implementation
|
||||
|
||||
@@ -494,8 +498,7 @@ begin
|
||||
until (i=16) or trouve;
|
||||
PremBitNum:=i;
|
||||
end;
|
||||
|
||||
|
||||
|
||||
// conversion du motif de bits (codebin) de la configuration du signal complexe en deux mots:
|
||||
// en sortie :
|
||||
// premierBit : code de la signalisation
|
||||
@@ -548,7 +551,6 @@ begin
|
||||
16 17 18 19 }
|
||||
end;
|
||||
|
||||
|
||||
// dessine un cercle plein dans le feu
|
||||
procedure cercle(ACanvas : Tcanvas;x,y,rayon : integer;couleur : Tcolor);
|
||||
begin
|
||||
@@ -3062,22 +3064,32 @@ end;
|
||||
// si 0 = OK
|
||||
// si 1 = erreur code Unisemaf
|
||||
// si 2 = erreur cohérence entre code et aspect
|
||||
// si 3 = signal inconnu
|
||||
function verif_UniSemaf(adresse,UniSem : integer) : integer;
|
||||
var aspect : integer;
|
||||
var aspect,i : integer;
|
||||
begin
|
||||
if UniSem=0 then begin verif_unisemaf:=1;exit;end;
|
||||
if (UniSem<>2) and (UniSem<>3) and (UniSem<>4) and (UniSem<>51) and (UniSem<>52) and (UniSem<>71) and (UniSem<>72) and (UniSem<>73) and
|
||||
((UniSem<90) or (UniSem>99)) then begin verif_UniSemaf:=1;exit;end;
|
||||
|
||||
aspect:=feux[index_feu(adresse)].aspect;
|
||||
if ((aspect=2) and (UniSem=2)) or
|
||||
((aspect=3) and (UniSem=3)) or
|
||||
((aspect=4) and (UniSem=4)) or
|
||||
((aspect=5) and ((UniSem=51) or (UniSem=52))) or
|
||||
((aspect=7) and ((UniSem=71) or (UniSem=72) or (UniSem=73))) or
|
||||
((aspect=9) and ((UniSem>=90) or (UniSem<=99)))
|
||||
then Verif_unisemaf:=0
|
||||
else Verif_Unisemaf:=2;
|
||||
i:=index_feu(adresse);
|
||||
if i<>0 then
|
||||
begin
|
||||
aspect:=feux[i].aspect;
|
||||
if ((aspect=2) and (UniSem=2)) or
|
||||
((aspect=3) and (UniSem=3)) or
|
||||
((aspect=4) and (UniSem=4)) or
|
||||
((aspect=5) and ((UniSem=51) or (UniSem=52))) or
|
||||
((aspect=7) and ((UniSem=71) or (UniSem=72) or (UniSem=73))) or
|
||||
((aspect=9) and ((UniSem>=90) or (UniSem<=99)))
|
||||
then Verif_unisemaf:=0
|
||||
else Verif_Unisemaf:=2;
|
||||
end
|
||||
else
|
||||
begin
|
||||
Affiche('Erreur Signal '+intToSTR(adresse)+' inconnu',clred);
|
||||
Verif_Unisemaf:=3;
|
||||
end;
|
||||
end;
|
||||
|
||||
|
||||
@@ -6386,13 +6398,13 @@ begin
|
||||
begin
|
||||
processID:=ProcessEntry32.th32ProcessID;
|
||||
CDMhd:=GetWindowFromID(processID);
|
||||
Affiche('CDM rail processID='+IntToSTR(ProcessID)+' handle='+IntToSTR(CDMhd),clOrange);
|
||||
//Affiche('CDM rail processID='+IntToSTR(ProcessID)+' handle='+IntToSTR(CDMhd),clOrange);
|
||||
Result:=true;
|
||||
Break;
|
||||
end;
|
||||
end;
|
||||
until (Process32Next(hSnapShot,ProcessEntry32)=false);
|
||||
CloseHandle(hSnapShot);
|
||||
end;
|
||||
end;
|
||||
|
||||
// préparation du tampon pour SendInput
|
||||
procedure KeybdInput(VKey: Byte; Flags: DWORD);
|
||||
@@ -6492,7 +6504,6 @@ begin
|
||||
exit;
|
||||
end;
|
||||
|
||||
|
||||
cdm_lanceLoc:=false;
|
||||
// lancement depuis le répertoire 32 bits d'un OS64
|
||||
if ShellExecute(Formprinc.Handle,'open',PChar('C:\Program Files (x86)\CDM-Rail\cdr.exe'),
|
||||
@@ -6833,7 +6844,7 @@ begin
|
||||
begin
|
||||
pos:=aiguillage[index].posInit;
|
||||
s:='Init aiguillage '+intToSTR(i)+'='+intToSTR(pos);
|
||||
if pos=1 then s:=s+' (dévié)' else s:=s+' (droit)';
|
||||
if pos=const_devie then s:=s+' (dévié)' else s:=s+' (droit)';
|
||||
Affiche(s,cyan);
|
||||
pilote_acc(i,pos,aigP);
|
||||
sleep(Tempo_Aig);
|
||||
@@ -7349,7 +7360,7 @@ end;
|
||||
// décodage d'une trame CDM au protocole IPC
|
||||
// la trame_CDM peut contenir 2000 caractères à l'initialisation du RUN.
|
||||
procedure Interprete_trameCDM(trame_CDM:string);
|
||||
var i,j,objet,posST,posAC,posDT,posSG,posXY,k,l,erreur, adr,adr2,etat,etataig,
|
||||
var i,j,objet,posST,posAC,posDT,posSG,posXY,k,l,erreur,posErr, adr,adr2,etat,etataig,
|
||||
vitesse,etatAig2,name,prv,nbre,nbreVir,long,index,posDes,AncNumTrameCDM : integer ;
|
||||
x,y,x2,y2 : longint ;
|
||||
s,ss,train,commandeCDM : string;
|
||||
@@ -7372,13 +7383,16 @@ begin
|
||||
trame_cdm:=trame_cdm+'S-C-07-1373-DSCTRN-SPEED|029|03|NAME=CAMERA;AD=6;TMAX=120;' ;
|
||||
trame_cdm:=trame_cdm+'S-C-07-1374-DSCTRN-__END|000|' ;
|
||||
}
|
||||
//affiche(trame_cdm,clLime);
|
||||
residuCDM:='';
|
||||
AckCDM:=trame_CDM<>'';
|
||||
if pos('ACK',trame_CDM)=0 then
|
||||
|
||||
{if pos('ACK',trame_CDM)=0 then
|
||||
begin
|
||||
if pos('ERR=200',trame_CDM)<>0 then Affiche('Erreur CDM : réseau non chargé',clred);
|
||||
if pos('ERR=500',trame_CDM)<>0 then Affiche('Erreur CDM : serveur DCC non lancé',clred);
|
||||
end;
|
||||
|
||||
}
|
||||
k:=0;
|
||||
repeat
|
||||
{// inutile de vérifier les numéros de trames, elles peuvent ne pas être envoyées dans l'ordre!!
|
||||
@@ -7401,18 +7415,18 @@ begin
|
||||
val(copy(trame_CDM,i+1,j-1),NumTrameCDM,erreur);
|
||||
if AncNumTrameCDM=0 then AncNumTrameCDM:=NumTrameCDM-1;
|
||||
affiche(IntToSTR(NumTrameCDM),clLime);
|
||||
if AncNumTrameCDM+1<>NumTrameCDM then
|
||||
if AncNumTrameCDM+1<>NumTrameCDM then
|
||||
begin
|
||||
s:='Erreur trames CDM perdues: #dernière='+intToSTR(AncNumTrameCDM)+' #Nouvelle='+intToSTR(NumTrameCDM);
|
||||
Affiche(s,clred);
|
||||
AfficheDebug(s,clred);
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
end;}
|
||||
|
||||
|
||||
// trouver la longueur de la chaîne de paramètres entre les 2 premiers |xxx|
|
||||
i:=pos('|',trame_CDM);
|
||||
if i=0 then
|
||||
@@ -7443,6 +7457,7 @@ begin
|
||||
goto reprise;
|
||||
end;
|
||||
|
||||
|
||||
if long>l then
|
||||
begin
|
||||
if debugTrames then AfficheDebug('tronqué3 : '+trame_CDM,clyellow);
|
||||
@@ -7475,6 +7490,23 @@ begin
|
||||
//if debugTrames then AfficheDebug(commandeCDM,clorange);
|
||||
Delete(trame_CDM,1,i);
|
||||
|
||||
//Affiche('long chaine param='+intToSTR(long),clyellow);
|
||||
if long=0 then
|
||||
begin
|
||||
//if debugTrames then Affiche('Longueur nulle',clYellow);
|
||||
if pos('ACK',trame_cdm)<>0 then Ack_cdm:=true;
|
||||
delete(trame_cdm,1,j);
|
||||
goto reprise;
|
||||
end;
|
||||
|
||||
posERR:=pos('_ERR',commandeCDM);
|
||||
if posErr<>0 then
|
||||
begin
|
||||
if pos('ERR=200',commandeCDM)<>0 then Affiche('Erreur CDM : réseau non chargé',clred);
|
||||
//if pos('ERR=500',commandeCDM)<>0 then Affiche('Erreur CDM : serveur DCC non lancé',clred);
|
||||
delete(commandeCDM,1,i);
|
||||
end;
|
||||
|
||||
// description des trains 03|NAME=BB16024;AD=3;TMAX=120;'
|
||||
posDES:=pos('DSCTRN-SPEED',commandeCDM);
|
||||
if posDES<>0 then
|
||||
|
||||
BIN
Binary file not shown.
Binary file not shown.
BIN
Binary file not shown.
+88
-45
@@ -1,6 +1,6 @@
|
||||
object FormTCO: TFormTCO
|
||||
Left = 20
|
||||
Top = 203
|
||||
Left = 139
|
||||
Top = 146
|
||||
Width = 1139
|
||||
Height = 694
|
||||
VertScrollBar.Visible = False
|
||||
@@ -110,6 +110,8 @@ object FormTCO: TFormTCO
|
||||
VertScrollBar.Tracking = True
|
||||
Anchors = [akLeft, akTop, akRight]
|
||||
BevelEdges = [beLeft, beTop, beRight]
|
||||
Color = clBtnFace
|
||||
ParentColor = False
|
||||
TabOrder = 0
|
||||
DesignSize = (
|
||||
1032
|
||||
@@ -117,8 +119,8 @@ object FormTCO: TFormTCO
|
||||
object ImageTCO: TImage
|
||||
Left = 0
|
||||
Top = 0
|
||||
Width = 1012
|
||||
Height = 303
|
||||
Width = 1009
|
||||
Height = 353
|
||||
Anchors = [akLeft, akTop, akRight, akBottom]
|
||||
PopupMenu = PopupMenu1
|
||||
OnClick = ImageTCOClick
|
||||
@@ -157,44 +159,45 @@ object FormTCO: TFormTCO
|
||||
Font.Style = []
|
||||
ParentFont = False
|
||||
TabOrder = 2
|
||||
OnDragOver = Panel1DragOver
|
||||
DesignSize = (
|
||||
1100
|
||||
166)
|
||||
object Label4: TLabel
|
||||
Left = 8
|
||||
Top = 8
|
||||
Width = 137
|
||||
Height = 20
|
||||
Top = 16
|
||||
Width = 103
|
||||
Height = 16
|
||||
Caption = 'Adresse de l'#39#233'l'#233'ment: '
|
||||
Font.Charset = ANSI_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -16
|
||||
Font.Height = -13
|
||||
Font.Name = 'Arial Narrow'
|
||||
Font.Style = []
|
||||
ParentFont = False
|
||||
end
|
||||
object Label5: TLabel
|
||||
Left = 8
|
||||
Top = 32
|
||||
Width = 116
|
||||
Height = 20
|
||||
Top = 40
|
||||
Width = 89
|
||||
Height = 16
|
||||
Caption = 'Type de l'#39#233'l'#233'ment: '
|
||||
Font.Charset = ANSI_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -16
|
||||
Font.Height = -13
|
||||
Font.Name = 'Arial Narrow'
|
||||
Font.Style = []
|
||||
ParentFont = False
|
||||
end
|
||||
object Label15: TLabel
|
||||
Left = 8
|
||||
Top = 56
|
||||
Width = 123
|
||||
Height = 20
|
||||
Top = 64
|
||||
Width = 93
|
||||
Height = 16
|
||||
Caption = 'Image de l'#39#233'l'#233'ment: '
|
||||
Font.Charset = ANSI_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -16
|
||||
Font.Height = -13
|
||||
Font.Name = 'Arial Narrow'
|
||||
Font.Style = []
|
||||
ParentFont = False
|
||||
@@ -205,6 +208,7 @@ object FormTCO: TFormTCO
|
||||
Width = 41
|
||||
Height = 41
|
||||
DragMode = dmAutomatic
|
||||
OnDragOver = ImagePalette5DragOver
|
||||
OnEndDrag = ImagePalette5EndDrag
|
||||
OnMouseDown = ImagePalette5MouseDown
|
||||
end
|
||||
@@ -227,6 +231,7 @@ object FormTCO: TFormTCO
|
||||
Width = 41
|
||||
Height = 41
|
||||
DragMode = dmAutomatic
|
||||
OnDragOver = ImagePalette2DragOver
|
||||
OnEndDrag = ImagePalette2EndDrag
|
||||
OnMouseDown = ImagePalette2MouseDown
|
||||
end
|
||||
@@ -262,6 +267,7 @@ object FormTCO: TFormTCO
|
||||
Width = 41
|
||||
Height = 41
|
||||
DragMode = dmAutomatic
|
||||
OnDragOver = ImagePalette1DragOver
|
||||
OnEndDrag = ImagePalette1EndDrag
|
||||
OnMouseDown = ImagePalette1MouseDown
|
||||
end
|
||||
@@ -271,6 +277,7 @@ object FormTCO: TFormTCO
|
||||
Width = 41
|
||||
Height = 41
|
||||
DragMode = dmAutomatic
|
||||
OnDragOver = ImagePalette6DragOver
|
||||
OnEndDrag = ImagePalette6EndDrag
|
||||
OnMouseDown = ImagePalette6MouseDown
|
||||
end
|
||||
@@ -280,6 +287,7 @@ object FormTCO: TFormTCO
|
||||
Width = 41
|
||||
Height = 41
|
||||
DragMode = dmAutomatic
|
||||
OnDragOver = ImagePalette7DragOver
|
||||
OnEndDrag = ImagePalette7EndDrag
|
||||
OnMouseDown = ImagePalette7MouseDown
|
||||
end
|
||||
@@ -289,6 +297,7 @@ object FormTCO: TFormTCO
|
||||
Width = 41
|
||||
Height = 41
|
||||
DragMode = dmAutomatic
|
||||
OnDragOver = ImagePalette8DragOver
|
||||
OnEndDrag = ImagePalette8EndDrag
|
||||
OnMouseDown = ImagePalette8MouseDown
|
||||
end
|
||||
@@ -298,6 +307,7 @@ object FormTCO: TFormTCO
|
||||
Width = 41
|
||||
Height = 41
|
||||
DragMode = dmAutomatic
|
||||
OnDragOver = ImagePalette9DragOver
|
||||
OnEndDrag = ImagePalette9EndDrag
|
||||
OnMouseDown = ImagePalette9MouseDown
|
||||
end
|
||||
@@ -359,6 +369,7 @@ object FormTCO: TFormTCO
|
||||
Width = 41
|
||||
Height = 41
|
||||
DragMode = dmAutomatic
|
||||
OnDragOver = ImagePalette3DragOver
|
||||
OnEndDrag = ImagePalette3EndDrag
|
||||
OnMouseDown = ImagePalette3MouseDown
|
||||
end
|
||||
@@ -403,6 +414,7 @@ object FormTCO: TFormTCO
|
||||
Width = 41
|
||||
Height = 41
|
||||
DragMode = dmAutomatic
|
||||
OnDragOver = ImagePalette10DragOver
|
||||
OnEndDrag = ImageDiag10EndDrag
|
||||
OnMouseDown = ImagePalette10MouseDown
|
||||
end
|
||||
@@ -425,6 +437,7 @@ object FormTCO: TFormTCO
|
||||
Width = 41
|
||||
Height = 41
|
||||
DragMode = dmAutomatic
|
||||
OnDragOver = ImagePalette11DragOver
|
||||
OnEndDrag = ImageDiag11EndDrag
|
||||
OnMouseDown = ImagePalette11MouseDown
|
||||
end
|
||||
@@ -448,6 +461,7 @@ object FormTCO: TFormTCO
|
||||
Height = 41
|
||||
DragMode = dmAutomatic
|
||||
Stretch = True
|
||||
OnDragOver = ImagePalette30DragOver
|
||||
OnEndDrag = ImagePalette30EndDrag
|
||||
OnMouseDown = ImagePalette30MouseDown
|
||||
end
|
||||
@@ -470,6 +484,7 @@ object FormTCO: TFormTCO
|
||||
Width = 41
|
||||
Height = 41
|
||||
DragMode = dmAutomatic
|
||||
OnDragOver = ImagePalette12DragOver
|
||||
OnEndDrag = ImagePalette12EndDrag
|
||||
OnMouseDown = ImagePalette12MouseDown
|
||||
end
|
||||
@@ -505,6 +520,7 @@ object FormTCO: TFormTCO
|
||||
Width = 41
|
||||
Height = 41
|
||||
DragMode = dmAutomatic
|
||||
OnDragOver = ImagePalette13DragOver
|
||||
OnEndDrag = ImagePalette13EndDrag
|
||||
OnMouseDown = ImagePalette13MouseDown
|
||||
end
|
||||
@@ -527,6 +543,7 @@ object FormTCO: TFormTCO
|
||||
Width = 41
|
||||
Height = 41
|
||||
DragMode = dmAutomatic
|
||||
OnDragOver = ImagePalette14DragOver
|
||||
OnEndDrag = ImagePalette14EndDrag
|
||||
OnMouseDown = ImagePalette14MouseDown
|
||||
end
|
||||
@@ -549,18 +566,19 @@ object FormTCO: TFormTCO
|
||||
Width = 41
|
||||
Height = 41
|
||||
DragMode = dmAutomatic
|
||||
OnDragOver = ImagePalette15DragOver
|
||||
OnEndDrag = ImagePalette15EndDrag
|
||||
OnMouseDown = ImagePalette15MouseDown
|
||||
end
|
||||
object Label23: TLabel
|
||||
Left = 8
|
||||
Top = 85
|
||||
Width = 33
|
||||
Height = 20
|
||||
Left = 56
|
||||
Top = 88
|
||||
Width = 27
|
||||
Height = 16
|
||||
Caption = 'Texte'
|
||||
Font.Charset = ANSI_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -16
|
||||
Font.Height = -13
|
||||
Font.Name = 'Arial Narrow'
|
||||
Font.Style = []
|
||||
ParentFont = False
|
||||
@@ -571,6 +589,7 @@ object FormTCO: TFormTCO
|
||||
Width = 41
|
||||
Height = 41
|
||||
DragMode = dmAutomatic
|
||||
OnDragOver = ImagePalette16DragOver
|
||||
OnEndDrag = ImagePalette16EndDrag
|
||||
OnMouseDown = ImagePalette16MouseDown
|
||||
end
|
||||
@@ -593,6 +612,7 @@ object FormTCO: TFormTCO
|
||||
Width = 41
|
||||
Height = 41
|
||||
DragMode = dmAutomatic
|
||||
OnDragOver = ImagePalette17DragOver
|
||||
OnEndDrag = ImagePalette17EndDrag
|
||||
OnMouseDown = ImagePalette17MouseDown
|
||||
end
|
||||
@@ -615,6 +635,7 @@ object FormTCO: TFormTCO
|
||||
Width = 41
|
||||
Height = 41
|
||||
DragMode = dmAutomatic
|
||||
OnDragOver = ImagePalette18DragOver
|
||||
OnEndDrag = ImagePalette18EndDrag
|
||||
OnMouseDown = ImagePalette18MouseDown
|
||||
end
|
||||
@@ -637,6 +658,7 @@ object FormTCO: TFormTCO
|
||||
Width = 41
|
||||
Height = 41
|
||||
DragMode = dmAutomatic
|
||||
OnDragOver = ImagePalette19DragOver
|
||||
OnEndDrag = ImagePalette19EndDrag
|
||||
OnMouseDown = ImagePalette19MouseDown
|
||||
end
|
||||
@@ -659,6 +681,7 @@ object FormTCO: TFormTCO
|
||||
Width = 41
|
||||
Height = 41
|
||||
DragMode = dmAutomatic
|
||||
OnDragOver = ImagePalette20DragOver
|
||||
OnEndDrag = ImagePalette20EndDrag
|
||||
OnMouseDown = ImagePalette20MouseDown
|
||||
end
|
||||
@@ -681,6 +704,7 @@ object FormTCO: TFormTCO
|
||||
Width = 41
|
||||
Height = 41
|
||||
DragMode = dmAutomatic
|
||||
OnDragOver = ImagePalette21DragOver
|
||||
OnEndDrag = ImagePalette21EndDrag
|
||||
OnMouseDown = ImagePalette21MouseDown
|
||||
end
|
||||
@@ -703,6 +727,7 @@ object FormTCO: TFormTCO
|
||||
Width = 41
|
||||
Height = 41
|
||||
DragMode = dmAutomatic
|
||||
OnDragOver = ImagePalette22DragOver
|
||||
OnEndDrag = ImagePalette22EndDrag
|
||||
OnMouseDown = ImagePalette22MouseDown
|
||||
end
|
||||
@@ -719,14 +744,27 @@ object FormTCO: TFormTCO
|
||||
Font.Style = [fsBold]
|
||||
ParentFont = False
|
||||
end
|
||||
object Label1: TLabel
|
||||
Left = 8
|
||||
Top = 112
|
||||
Width = 75
|
||||
Height = 16
|
||||
Caption = 'position du texte'
|
||||
Font.Charset = ANSI_CHARSET
|
||||
Font.Color = clBlack
|
||||
Font.Height = -13
|
||||
Font.Name = 'Arial Narrow'
|
||||
Font.Style = []
|
||||
ParentFont = False
|
||||
end
|
||||
object EditAdrElement: TEdit
|
||||
Left = 152
|
||||
Top = 8
|
||||
Left = 144
|
||||
Top = 16
|
||||
Width = 33
|
||||
Height = 28
|
||||
Height = 24
|
||||
Font.Charset = ANSI_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -16
|
||||
Font.Height = -13
|
||||
Font.Name = 'Arial Narrow'
|
||||
Font.Style = []
|
||||
ParentFont = False
|
||||
@@ -735,13 +773,13 @@ object FormTCO: TFormTCO
|
||||
OnKeyDown = EditAdrElementKeyDown
|
||||
end
|
||||
object EditTypeElement: TEdit
|
||||
Left = 152
|
||||
Top = 32
|
||||
Left = 144
|
||||
Top = 40
|
||||
Width = 33
|
||||
Height = 28
|
||||
Height = 24
|
||||
Font.Charset = ANSI_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -16
|
||||
Font.Height = -13
|
||||
Font.Name = 'Arial Narrow'
|
||||
Font.Style = []
|
||||
ParentFont = False
|
||||
@@ -749,13 +787,13 @@ object FormTCO: TFormTCO
|
||||
TabOrder = 1
|
||||
end
|
||||
object EditTypeImage: TEdit
|
||||
Left = 152
|
||||
Top = 56
|
||||
Left = 144
|
||||
Top = 64
|
||||
Width = 33
|
||||
Height = 28
|
||||
Height = 24
|
||||
Font.Charset = ANSI_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -16
|
||||
Font.Height = -13
|
||||
Font.Name = 'Arial Narrow'
|
||||
Font.Style = []
|
||||
ParentFont = False
|
||||
@@ -812,7 +850,7 @@ object FormTCO: TFormTCO
|
||||
OnClick = ButtonConfigTCOClick
|
||||
end
|
||||
object EditTexte: TEdit
|
||||
Left = 96
|
||||
Left = 88
|
||||
Top = 88
|
||||
Width = 89
|
||||
Height = 21
|
||||
@@ -830,7 +868,7 @@ object FormTCO: TFormTCO
|
||||
end
|
||||
object CheckPinv: TCheckBox
|
||||
Left = 16
|
||||
Top = 120
|
||||
Top = 144
|
||||
Width = 161
|
||||
Height = 17
|
||||
Caption = 'aiguillage invers'#233
|
||||
@@ -848,14 +886,19 @@ object FormTCO: TFormTCO
|
||||
WordWrap = True
|
||||
OnClick = ButtonMasquerClick
|
||||
end
|
||||
object ButtonConstruit: TButton
|
||||
Left = 880
|
||||
Top = 88
|
||||
object ComboRepr: TComboBox
|
||||
Left = 88
|
||||
Top = 112
|
||||
Width = 89
|
||||
Height = 33
|
||||
Caption = 'Construit TCO'
|
||||
Height = 21
|
||||
ItemHeight = 13
|
||||
TabOrder = 12
|
||||
OnClick = ButtonConstruitClick
|
||||
OnChange = ComboReprChange
|
||||
Items.Strings = (
|
||||
'Sans'
|
||||
'Centrale'
|
||||
'Haut'
|
||||
'Bas')
|
||||
end
|
||||
end
|
||||
object ButtonAfficheBandeau: TButton
|
||||
@@ -872,7 +915,7 @@ object FormTCO: TFormTCO
|
||||
object PopupMenu1: TPopupMenu
|
||||
Left = 360
|
||||
object MenuCouper: TMenuItem
|
||||
Caption = 'Couper'
|
||||
Caption = '-'
|
||||
OnClick = MenuCouperClick
|
||||
end
|
||||
object MenuCopier: TMenuItem
|
||||
@@ -894,15 +937,15 @@ object FormTCO: TFormTCO
|
||||
Caption = '-'
|
||||
end
|
||||
object Tourner90G: TMenuItem
|
||||
Caption = 'Positionner 90'#176' '#224' gauche'
|
||||
Caption = 'Positionner feu 90'#176' '#224' gauche'
|
||||
OnClick = Tourner90GClick
|
||||
end
|
||||
object Tourner90D: TMenuItem
|
||||
Caption = 'Positionner 90'#176' '#224' droite'
|
||||
Caption = 'Positionner feu 90'#176' '#224' droite'
|
||||
OnClick = Tourner90DClick
|
||||
end
|
||||
object Pos_vert: TMenuItem
|
||||
Caption = 'Positionner verticalement'
|
||||
Caption = 'Positionner feu verticalement'
|
||||
OnClick = Pos_vertClick
|
||||
end
|
||||
end
|
||||
|
||||
+496
-295
File diff suppressed because it is too large
Load Diff
Binary file not shown.
@@ -0,0 +1,101 @@
|
||||
object FormAig: TFormAig
|
||||
Left = 400
|
||||
Top = 204
|
||||
Width = 363
|
||||
Height = 204
|
||||
Caption = 'Pilotage de l'#39'aiguillage'
|
||||
Color = clMaroon
|
||||
Font.Charset = DEFAULT_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -11
|
||||
Font.Name = 'MS Sans Serif'
|
||||
Font.Style = []
|
||||
OldCreateOrder = False
|
||||
OnActivate = FormActivate
|
||||
PixelsPerInch = 96
|
||||
TextHeight = 13
|
||||
object Label1: TLabel
|
||||
Left = 80
|
||||
Top = 8
|
||||
Width = 173
|
||||
Height = 23
|
||||
Caption = 'Pilotage de l'#39'aiguillage'
|
||||
Font.Charset = ANSI_CHARSET
|
||||
Font.Color = clWindow
|
||||
Font.Height = -19
|
||||
Font.Name = 'Arial Narrow'
|
||||
Font.Style = [fsBold, fsItalic]
|
||||
ParentFont = False
|
||||
end
|
||||
object LabelAdr1: TLabel
|
||||
Left = 56
|
||||
Top = 56
|
||||
Width = 65
|
||||
Height = 16
|
||||
Caption = 'LabelAdr1'
|
||||
Font.Charset = ANSI_CHARSET
|
||||
Font.Color = clWindow
|
||||
Font.Height = -13
|
||||
Font.Name = 'Arial'
|
||||
Font.Style = [fsBold]
|
||||
ParentFont = False
|
||||
end
|
||||
object LabelAdr2: TLabel
|
||||
Left = 224
|
||||
Top = 56
|
||||
Width = 65
|
||||
Height = 16
|
||||
Caption = 'LabelAdr2'
|
||||
Font.Charset = ANSI_CHARSET
|
||||
Font.Color = clWindow
|
||||
Font.Height = -13
|
||||
Font.Name = 'Arial'
|
||||
Font.Style = [fsBold]
|
||||
ParentFont = False
|
||||
end
|
||||
object ButtonOK: TButton
|
||||
Left = 136
|
||||
Top = 128
|
||||
Width = 75
|
||||
Height = 25
|
||||
Caption = 'Ok'
|
||||
ModalResult = 1
|
||||
TabOrder = 0
|
||||
end
|
||||
object ButtonDev: TButton
|
||||
Left = 8
|
||||
Top = 88
|
||||
Width = 75
|
||||
Height = 25
|
||||
Caption = 'D'#233'vi'#233
|
||||
TabOrder = 1
|
||||
OnClick = ButtonDevClick
|
||||
end
|
||||
object ButtonDroit: TButton
|
||||
Left = 88
|
||||
Top = 88
|
||||
Width = 75
|
||||
Height = 25
|
||||
Caption = 'Droit'
|
||||
TabOrder = 2
|
||||
OnClick = ButtonDroitClick
|
||||
end
|
||||
object ButtonDev2: TButton
|
||||
Left = 184
|
||||
Top = 88
|
||||
Width = 75
|
||||
Height = 25
|
||||
Caption = 'D'#233'vi'#233
|
||||
TabOrder = 3
|
||||
OnClick = ButtonDev2Click
|
||||
end
|
||||
object ButtonDroit2: TButton
|
||||
Left = 264
|
||||
Top = 88
|
||||
Width = 75
|
||||
Height = 25
|
||||
Caption = 'Droit'
|
||||
TabOrder = 4
|
||||
OnClick = ButtonDroit2Click
|
||||
end
|
||||
end
|
||||
@@ -0,0 +1,130 @@
|
||||
unit Unit_Pilote_aig;
|
||||
|
||||
interface
|
||||
|
||||
uses
|
||||
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
|
||||
Dialogs, StdCtrls, UnitPrinc, UnitTCO;
|
||||
|
||||
type
|
||||
TFormAig = class(TForm)
|
||||
ButtonOK: TButton;
|
||||
Label1: TLabel;
|
||||
ButtonDev: TButton;
|
||||
ButtonDroit: TButton;
|
||||
ButtonDev2: TButton;
|
||||
ButtonDroit2: TButton;
|
||||
LabelAdr1: TLabel;
|
||||
LabelAdr2: TLabel;
|
||||
procedure FormActivate(Sender: TObject);
|
||||
procedure ButtonDevClick(Sender: TObject);
|
||||
procedure ButtonDroitClick(Sender: TObject);
|
||||
procedure ButtonDev2Click(Sender: TObject);
|
||||
procedure ButtonDroit2Click(Sender: TObject);
|
||||
private
|
||||
{ Déclarations privées }
|
||||
public
|
||||
{ Déclarations publiques }
|
||||
end;
|
||||
|
||||
var
|
||||
FormAig: TFormAig;
|
||||
aiguille,aiguille2 : integer;
|
||||
tjdC,aigC : boolean;
|
||||
implementation
|
||||
|
||||
{$R *.dfm}
|
||||
|
||||
procedure commande_simple;
|
||||
begin
|
||||
with formAig do
|
||||
begin
|
||||
LabelAdr2.Visible:=false;
|
||||
LabelAdr1.Visible:=false;
|
||||
ButtonDev2.Visible:=false;
|
||||
ButtonDroit2.Visible:=false;
|
||||
ButtonOk.Visible:=false;
|
||||
ButtonDev.Left:=48;
|
||||
ButtonDroit.Left:=216;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TFormAig.FormActivate(Sender: TObject);
|
||||
var i : integer;
|
||||
s : string;
|
||||
begin
|
||||
i:=Index_aig(Aiguille);
|
||||
aigC:=(aiguillage[i].modele=aig);
|
||||
tjdC:=(aiguillage[i].modele=tjd) or (aiguillage[i].modele=tjs);
|
||||
if aigC then
|
||||
begin
|
||||
s:='Pilotage de l''aiguillage '+intToSTR(aiguille);
|
||||
commande_simple;
|
||||
end;
|
||||
if tjdC then
|
||||
begin
|
||||
s:='Pilotage de la TJD '+intToSTR(aiguille);
|
||||
|
||||
if aiguillage[i].EtatTJD=4 then
|
||||
begin
|
||||
LabelAdr1.Caption:='Adresse1: '+intToSTR(aiguille);
|
||||
aiguille2:=aiguillage[i].DDevie;
|
||||
LabelAdr2.Caption:='Adresse2: '+intToSTR(aiguille2);
|
||||
LabelAdr2.Visible:=true;
|
||||
LabelAdr1.Visible:=true;
|
||||
ButtonDev2.Visible:=true;
|
||||
ButtonOk.Visible:=true;
|
||||
ButtonDroit2.Visible:=true;
|
||||
ButtonDev.Left:=8;
|
||||
ButtonDroit.Left:=88;
|
||||
end;
|
||||
end;
|
||||
if aiguillage[i].EtatTJD=2 then
|
||||
begin
|
||||
commande_simple;
|
||||
end;
|
||||
|
||||
Label1.Caption:=s;
|
||||
end;
|
||||
|
||||
procedure TFormAig.ButtonDevClick(Sender: TObject);
|
||||
var s : string;
|
||||
begin
|
||||
efface_entoure;SelectionAffichee:=false;
|
||||
pilote_acc(aiguille,const_devie,aigP);
|
||||
s:='accessoire '+IntToSTR(aiguille)+' dévié';
|
||||
Affiche(s,clyellow);
|
||||
if AigC then close;
|
||||
end;
|
||||
|
||||
procedure TFormAig.ButtonDroitClick(Sender: TObject);
|
||||
var s : string;
|
||||
begin
|
||||
efface_entoure;SelectionAffichee:=false;
|
||||
pilote_acc(aiguille,const_droit,aigP);
|
||||
s:='accessoire '+IntToSTR(aiguille)+' droit';
|
||||
Affiche(s,clyellow);
|
||||
if AigC then close;
|
||||
end;
|
||||
|
||||
procedure TFormAig.ButtonDev2Click(Sender: TObject);
|
||||
var s : string;
|
||||
begin
|
||||
efface_entoure;SelectionAffichee:=false;
|
||||
pilote_acc(aiguille2,const_devie,aigP);
|
||||
s:='accessoire '+IntToSTR(aiguille2)+' dévié';
|
||||
Affiche(s,clyellow);
|
||||
if AigC then close;
|
||||
end;
|
||||
|
||||
procedure TFormAig.ButtonDroit2Click(Sender: TObject);
|
||||
var s : string;
|
||||
begin
|
||||
efface_entoure;SelectionAffichee:=false;
|
||||
pilote_acc(aiguille2,const_droit,aigP);
|
||||
s:='accessoire '+IntToSTR(aiguille2)+' droit';
|
||||
Affiche(s,clyellow);
|
||||
if AigC then close;
|
||||
end;
|
||||
|
||||
end.
|
||||
Binary file not shown.
+1
-1
@@ -23,7 +23,7 @@ var
|
||||
Lance_verif : integer;
|
||||
verifVersion,notificationVersion : boolean;
|
||||
|
||||
Const Version='3.8'; // sert à la comparaison de la version publiée
|
||||
Const Version='3.81'; // sert à la comparaison de la version publiée
|
||||
SousVersion=' '; // en cas d'absence de sous version mettre un espace
|
||||
|
||||
implementation
|
||||
|
||||
+2
-1
@@ -87,8 +87,9 @@ version 3.71 : Suppression vitesse train
|
||||
Ajout d'un bouton de test des actionneurs dans la page de configuration des actionneurs.
|
||||
version 3.8 : Possibilité de déclencher les actions depuis une zone deux détecteurs contigus.
|
||||
Gestion des fonctions F de train de F0 à F28 en mode autonome.
|
||||
version 3.81 : Pilotage des TJD depuis le TCO.
|
||||
Améliorations diverses dans le TCO.
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user