whz.py


1
#!/usr/bin/env python
2
# -*- coding: utf-8 -*-
3
# whz.py
4
5
#Import
6
import time
7
import sys
8
import os
9
import sqlite3
10
11
#SQL
12
connection = sqlite3.connect("database_whz.dB")
13
14
15
#Outputs and Inputs
16
import RPi.GPIO as GPIO
17
GPIO.setmode(GPIO.BCM)
18
GPIO.setwarnings(False)
19
GPIO.setup(17,GPIO.OUT)#SO 16-MUX
20
GPIO.setup(18,GPIO.OUT)#S1 16-MUX
21
GPIO.setup(19,GPIO.OUT)#S2 16-MUX
22
GPIO.setup(20,GPIO.OUT)#S3 16-MUX
23
GPIO.setup(22,GPIO.OUT)#SO 8-MUX
24
GPIO.setup(23,GPIO.OUT)#S1 8-MUX
25
GPIO.setup(24,GPIO.OUT)#S2 8-MUX
26
GPIO.setup(4,GPIO.OUT)#1-16 MUX EIN
27
GPIO.setup(5,GPIO.OUT)#1-16 MUX AUS
28
GPIO.setup(6,GPIO.IN,GPIO.PUD_DOWN)#16-1 MUX EIN
29
GPIO.setup(12,GPIO.IN,GPIO.PUD_DOWN)#16-1 MUX HEIZ
30
GPIO.setup(13,GPIO.IN,GPIO.PUD_DOWN)#16-1 MUX STOER
31
32
33
#function
34
# Adressierung: Kanalauswahl für den Multiplexer bzw Demultiplexer, im ganzen 18 Adressen
35
def Adressierung(adr):
36
    if adr == 0:
37
        GPIO.output(17,GPIO.LOW)
38
        GPIO.output(18,GPIO.LOW)
39
        GPIO.output(19,GPIO.LOW)
40
        GPIO.output(20,GPIO.LOW)
41
    elif adr == 1:
42
        GPIO.output(17,GPIO.HIGH)
43
        GPIO.output(18,GPIO.LOW)
44
        GPIO.output(19,GPIO.LOW)
45
        GPIO.output(20,GPIO.LOW)
46
    elif adr == 2:
47
        GPIO.output(17,GPIO.LOW)
48
        GPIO.output(18,GPIO.HIGH)
49
        GPIO.output(19,GPIO.LOW)
50
        GPIO.output(20,GPIO.LOW)
51
    elif adr == 3:
52
        GPIO.output(17,GPIO.HIGH)
53
        GPIO.output(18,GPIO.HIGH)
54
        GPIO.output(19,GPIO.LOW)
55
        GPIO.output(20,GPIO.LOW)
56
    elif adr == 4:
57
        GPIO.output(17,GPIO.LOW)
58
        GPIO.output(18,GPIO.LOW)
59
        GPIO.output(19,GPIO.HIGH)
60
        GPIO.output(20,GPIO.LOW)
61
    elif adr == 5:
62
        GPIO.output(17,GPIO.HIGH)
63
        GPIO.output(18,GPIO.LOW)
64
        GPIO.output(19,GPIO.HIGH)
65
        GPIO.output(20,GPIO.LOW)
66
    elif adr == 6:
67
        GPIO.output(17,GPIO.LOW)
68
        GPIO.output(18,GPIO.HIGH)
69
        GPIO.output(19,GPIO.HIGH)
70
        GPIO.output(20,GPIO.LOW)
71
    elif adr == 7:
72
        GPIO.output(17,GPIO.HIGH)
73
        GPIO.output(18,GPIO.HIGH)
74
        GPIO.output(19,GPIO.HIGH)
75
        GPIO.output(20,GPIO.LOW)
76
    elif adr == 8:
77
        GPIO.output(17,GPIO.LOW)
78
        GPIO.output(18,GPIO.LOW)
79
        GPIO.output(19,GPIO.LOW)
80
        GPIO.output(20,GPIO.HIGH)
81
    elif adr == 9:
82
        GPIO.output(17,GPIO.HIGH)
83
        GPIO.output(18,GPIO.LOW)
84
        GPIO.output(19,GPIO.LOW)
85
        GPIO.output(20,GPIO.HIGH)
86
    elif adr == 10:
87
        GPIO.output(17,GPIO.LOW)
88
        GPIO.output(18,GPIO.HIGH)
89
        GPIO.output(19,GPIO.LOW)
90
        GPIO.output(20,GPIO.HIGH)
91
    elif adr == 11:
92
        GPIO.output(17,GPIO.HIGH)
93
        GPIO.output(18,GPIO.HIGH)
94
        GPIO.output(19,GPIO.LOW)
95
        GPIO.output(20,GPIO.HIGH)
96
    elif adr == 12:
97
        GPIO.output(17,GPIO.LOW)
98
        GPIO.output(18,GPIO.LOW)
99
        GPIO.output(19,GPIO.HIGH)
100
        GPIO.output(20,GPIO.HIGH)
101
    elif adr == 13:
102
        GPIO.output(17,GPIO.HIGH)
103
        GPIO.output(18,GPIO.LOW)
104
        GPIO.output(19,GPIO.HIGH)
105
        GPIO.output(20,GPIO.HIGH)
106
    elif adr == 14:
107
        GPIO.output(17,GPIO.LOW)
108
        GPIO.output(18,GPIO.HIGH)
109
        GPIO.output(19,GPIO.HIGH)
110
        GPIO.output(20,GPIO.HIGH)
111
    elif adr == 15:
112
        GPIO.output(17,GPIO.HIGH)
113
        GPIO.output(18,GPIO.HIGH)
114
        GPIO.output(19,GPIO.HIGH)
115
        GPIO.output(20,GPIO.HIGH)
116
    elif adr == 16:
117
        GPIO.output(22,GPIO.LOW)
118
        GPIO.output(23,GPIO.LOW)
119
        GPIO.output(24,GPIO.LOW)
120
    elif adr == 17:
121
        GPIO.output(22,GPIO.HIGH)
122
        GPIO.output(23,GPIO.LOW)
123
        GPIO.output(24,GPIO.LOW)
124
    elif adr == 18:
125
        GPIO.output(22,GPIO.LOW)
126
        GPIO.output(23,GPIO.HIGH)
127
        GPIO.output(24,GPIO.LOW)
128
129
#Heating: Heizung starten
130
def heat_on(x):
131
    adr=x
132
    Adressierung(adr)
133
    GPIO.output(4,GPIO.HIGH)
134
    time.sleep(1)
135
    GPIO.output(4,GPIO.LOW)
136
    
137
#Heating: Heizung ausschalten
138
def heat_off(x):
139
    adr=x
140
    Adressierung(adr)
141
    GPIO.output(5,GPIO.HIGH)
142
    time.sleep(1)
143
    GPIO.output(5,GPIO.LOW)
144
145
#Heating: Heizung Dauerbetrieb
146
def heat_continuous(x):
147
    adr=x
148
    Adressierung(adr)
149
    GPIO.output(4,GPIO.HIGH)
150
    time.sleep(2)
151
    GPIO.output(4,GPIO.LOW)
152
153
#Heating: Heizung Dauerbetrieb
154
def test():
155
    GPIO.output(4,GPIO.HIGH)
156
    time.sleep(1)
157
    GPIO.output(4,GPIO.LOW)
158
    time.sleep(1)
159
    GPIO.output(4,GPIO.HIGH)
160
    time.sleep(1)
161
    GPIO.output(4,GPIO.LOW)
162
    time.sleep(1)
163
    GPIO.output(4,GPIO.HIGH)
164
    time.sleep(1)
165
    GPIO.output(4,GPIO.LOW)
166
    time.sleep(1)
167
    GPIO.output(4,GPIO.HIGH)
168
    time.sleep(1)
169
    GPIO.output(4,GPIO.LOW)
170
    time.sleep(1)
171
    GPIO.output(4,GPIO.HIGH)
172
    time.sleep(1)
173
    GPIO.output(4,GPIO.LOW)
174
    
175
#Image: Zustand der Anlagen
176
def image_EIN(y):
177
    adr=y
178
    Adressierung(adr)
179
    if GPIO.input(6) == True:
180
        print('''<img id="led" src="../led_on.gif" width="200" height="200">''')
181
    else:
182
        print('''<img id="led" src="../led_off.gif" width="200" height="200">''')
183
184
def image_HEIZ(y):
185
    adr=y
186
    Adressierung(adr)
187
    if GPIO.input(12) == True:
188
        print('''<img id="led" src="../led_on.gif" width="200" height="200">''')
189
    else:
190
        print('''<img id="led" src="../led_off.gif" width="200" height="200">''')
191
192
def image_error(y):
193
    adr=y
194
    Adressierung(adr)
195
    if GPIO.input(13) == True:
196
        print('''<img id="led" src="../error.gif" width="200" height="200">''')
197
    else:
198
        print('''<img id="led" src="../led_off.gif" width="200" height="200">''')
199
200
global cont0, cont1,cont2, data
201
cont0=0
202
cont1=0
203
cont2=0
204
cont3=0
205
cont4=0
206
cont5=0
207
cont6=0
208
cont7=0
209
cont8=0
210
cont9=0
211
cont10=0
212
cont11=0
213
data=0
214
215
216
               
217
                
218
#
219
#cont2 = 1
220
#data = cont2
221
#file5 = open('whz3.txt','w')
222
#file5.write(str(data))
223
#file5.close
224
225
226
try:
227
    para = sys.argv[1]
228
    state = para.split('&')
229
    if (state[0] == '0'):
230
        if (state[1] == '0'):
231
            heat_off(0)
232
            print('1/I wurde ausgeschaltet')
233
        elif (state[1] == '1'):
234
            heat_on(0)
235
            print('1/I wurde eingeschaltet')
236
        elif (state[1] == '2'):
237
238
            connection = sqlite3.connect("database_whz.dB")
239
            
240
            cursor = connection.cursor()
241
            
242
            sql = "SELECT * FROM weichenheizung WHERE name='whz1'"
243
            
244
            cursor.execute(sql)
245
            test()
246
            for dsatz in cursor:
247
                cont0 = dsatz[1]
248
                
249
            cont0 = int(cont0)
250
            connection.close()
251
252
253
            if  cont0 == 0:
254
                heat_continuous(0)
255
                print('1/I wurde in den Dauermodus gewechselt')
256
                cursor = connection.cursor()
257
                sql = "UPDATE weichenheizung SET zustand=1 "\
258
                      "WHERE name='whz1'"
259
                cursor.execute(sql)
260
                connection.commit()
261
                connection.close()
262
                
263
            elif cont0 == 1:
264
                heat_continuous(0)
265
                print('1/I wurde in den Normalrmodus gewechselt')
266
                
267
                cursor = connection.cursor()
268
                sql = "UPDATE weichenheizung SET zustand=0 "\
269
                      "WHERE name='whz1'"
270
                cursor.execute(sql)
271
                connection.commit()
272
                connection.close()
273
                
274
    elif (state[0] == '1'):
275
        if (state[1] == '0'):
276
            heat_off(1)
277
            print('1/II wurde ausgeschaltet')
278
        elif (state[1] == '1'):
279
            heat_on(1)
280
            print('1/II wurde eingeschaltet')
281
        elif (state[1] == '2'):
282
            cursor = connection.cursor()
283
            sql = "SELECT * FROM weichenheizung WHERE name='whz2'"
284
            cursor.execute(sql)
285
            for dsatz in cursor:
286
                cont1 = dsatz[1]
287
            cont1 = int(cont1)
288
            connection.close()
289
            if  cont1 == 0:
290
                heat_continuous(1)
291
                print('1/II wurde in den Dauermodus gewechselt')
292
                
293
                cursor = connection.cursor()
294
                sql = "UPDATE weichenheizung SET zustand='1' "\
295
                      "WHERE name='whz2'"
296
                cursor.execute(sql)
297
                connection.commit()
298
                connection.close()
299
                
300
            elif cont1 == 1:
301
                heat_continuous(1)
302
                print('1/II wurde in den Normalrmodus gewechselt')
303
                
304
                cursor = connection.cursor()
305
                sql = "UPDATE weichenheizung SET zustand='0' "\
306
                      "WHERE name='whz2'"
307
                cursor.execute(sql)
308
                connection.commit()
309
                connection.close()
310
311
    elif (state[0] == '2'):
312
        if (state[1] == '0'):
313
            heat_off(2)
314
            print('2/I wurde ausgeschaltet')
315
        elif (state[1] == '1'):
316
            heat_on(2)
317
            print('2/I wurde eingeschaltet')
318
        elif (state[1] == '2'):
319
            cursor = connection.cursor()
320
            sql = "SELECT * FROM weichenheizung WHERE name='whz3'"
321
            cursor.execute(sql)
322
            for dsatz in cursor:
323
                cont2 = dsatz[1]
324
            cont2 = int(cont2)
325
            connection.close()
326
            if  cont2 == 0:
327
                heat_continuous(2)
328
                print('2/I wurde in den Dauermodus gewechselt')
329
                
330
                cursor = connection.cursor()
331
                sql = "UPDATE weichenheizung SET zustand='1' "\
332
                      "WHERE name='whz3'"
333
                cursor.execute(sql)
334
                connection.commit()
335
                connection.close()
336
337
            elif cont2 == 1:
338
                heat_continuous(2)
339
                print('2/I wurde in den Normalrmodus gewechselt')
340
                
341
                cursor = connection.cursor()
342
                sql = "UPDATE weichenheizung SET zustand='0' "\
343
                      "WHERE name='whz3'"
344
                cursor.execute(sql)
345
                connection.commit()
346
                connection.close()
347
348
    
349
              
350
    else:
351
        print('Fehler')
352
except:
353
    print()
354
355
356
357
358
359
    
360
361
print('''
362
<!DOCTYPE html>
363
<html lang="en">
364
<head>
365
        <meta charset="utf-8">
366
        <meta http-equiv="refresh" content="20; URL=whz.py">
367
        <title>Weichenheizung</title>
368
        <link type="text/css" rel="stylesheet" href="../whz/whz.css">
369
  </head>
370
371
  <body>
372
         <div id="header">
373
                      <h1>Weichenheizungsteuerung</h1>
374
               </div>
375
         <div id="main">
376
    <center><h1>Lux nord</h1></center>
377
           <table>
378
      <tr>
379
        <td id="spalte1">
380
        <h2>WHz:</h2>        </td>
381
        <td id="spalte2">
382
        <h2>Steuerung:</h2>      
383
        
384
        </td>
385
        <td id="spalte3">
386
        <h2>Auswertung:</h2>
387
        <center><h3 id="nobreak" >EIN</h3><h3 id="nobreak">Heiz</h3><h3 id="nobreak">Stoerung</h3></center>
388
        </td>
389
        <td id="spalte4"><button type="button">Stoerung</button></td>
390
        <td id="spalte5">
391
        <form method="get" action="info.py">
392
           <button type="submit">Info</button>
393
        </form>
394
        </td>
395
      </tr>
396
      <tr>
397
        <td>
398
        <center><p>1/I:</p></center>
399
        </td>
400
        <td>
401
402
                
403
                <button onclick="window.location.href='http://127.0.0.1:8000/cgi-bin/whz.py?0&1'">EIN</button>
404
                <button onclick="window.location.href='http://127.0.0.1:8000/cgi-bin/whz.py?0&0'">AUS</button>
405
''')
406
407
408
try:
409
    cursor = connection.cursor()
410
    sql = "SELECT * FROM weichenheizung WHERE name='whz1'"
411
    cursor.execute(sql)
412
    for dsatz in cursor:
413
        cont0 = dsatz[1]
414
    cont0 = int(cont0)
415
    connection.close()
416
    print('TYP:',type(cont0),cont0)
417
    
418
    
419
except:
420
    print('')
421
422
if cont0 == 1:
423
    print('''                 <button style="background-color: red;" onclick="window.location.href='http://127.0.0.1:8000/cgi-bin/whz.py?0&2'">Dauerbetrieb</button>''')
424
else:
425
    print('''                 <button onclick="window.location.href='http://127.0.0.1:8000/cgi-bin/whz.py?0&2'">Dauerbetrieb</button> ''')
426
427
428
print('''         
429
        </td>
430
        <td>
431
          <center>''')
432
image_EIN(0)
433
image_HEIZ(0)
434
image_error(0)
435
436
#<img id="led" src="../led_off.gif" width="200" height="200"><img id="led" src="../led_off.gif" width="200" height="200"><img id="led" src="../led_off.gif" width="200" height="200">
437
          #<button type="button">EIN</button>
438
          #<button type="button">AUS</button>
439
          #<button type="button">Dauerbetrieb</button>
440
print('''
441
                                        </center>
442
        </td>
443
      </tr>
444
      <tr>
445
        <td>
446
          <center><p>1/II</p></center>
447
        </td>
448
        <td>
449
450
                
451
                <button onclick="window.location.href='http://127.0.0.1:8000/cgi-bin/whz.py?1&1'">EIN</button>
452
                <button onclick="window.location.href='http://127.0.0.1:8000/cgi-bin/whz.py?1&0'">AUS</button>
453
''')
454
455
456
try:
457
    cursor = connection.cursor()
458
    sql = "SELECT * FROM weichenheizung WHERE name='whz2'"
459
    cursor.execute(sql)
460
    for dsatz in cursor:
461
        cont1 = dsatz[1]
462
    cont1 = int(cont1)
463
    connection.close()
464
465
except:
466
    print('')
467
468
                
469
if cont1 == 1: print('''    <button style="background-color: red;" onclick="window.location.href='http://127.0.0.1:8000/cgi-bin/whz.py?1&2'">Dauerbetrieb</button>''')
470
if cont1 == 0: print('''    <button onclick="window.location.href='http://127.0.0.1:8000/cgi-bin/whz.py?1&2'">Dauerbetrieb</button> ''')
471
print('''          
472
        </td>
473
        <td>
474
          <center>''')
475
476
image_EIN(1)
477
image_HEIZ(1)
478
image_error(1)
479
print('''                               </center>
480
        </td>
481
      </tr>
482
                   <p></p>
483
    </table>
484
         </div>
485
486
     <div id="main">
487
    <center><h1>Lux centre</h1></center>
488
           <table>
489
      <tr>
490
        <td id="spalte1">
491
        <h2>WHz:</h2>
492
        </td>
493
        <td id="spalte2">
494
        <h2>Steuerung:</h2>      
495
        
496
        </td>
497
        <td id="spalte3">
498
        <h2>Auswertung:</h2>
499
        <center><h3 id="nobreak" >EIN</h3><h3 id="nobreak">Heiz</h3><h3 id="nobreak">Stoerung</h3></center>
500
        </td>
501
        <td id="spalte4"><button type="button">Stoerung</button></td>
502
        <td id="spalte5">
503
        <form method="get" action="info.py">
504
           <button type="submit">Info</button>
505
        </form>
506
        </td>
507
      </tr>
508
      <tr>
509
        <td>
510
        <center><p>2/I:</p></center>
511
        </td>
512
        <td>
513
514
                
515
                <button onclick="window.location.href='http://127.0.0.1:8000/cgi-bin/whz.py?2&1'">EIN</button>
516
                <button onclick="window.location.href='http://127.0.0.1:8000/cgi-bin/whz.py?2&0'">AUS</button>
517
''')
518
519
520
try:
521
    cursor = connection.cursor()
522
    sql = "SELECT * FROM weichenheizung WHERE name='whz3'"
523
    cursor.execute(sql)
524
    for dsatz in cursor:
525
        cont1 = dsatz[2]
526
    cont2 = int(cont2)
527
    connection.close()
528
529
530
except:
531
    print('')
532
533
534
                
535
if cont2 == 1: print('''    <button style="background-color: red;" onclick="window.location.href='http://127.0.0.1:8000/cgi-bin/whz.py?2&2'">Dauerbetrieb</button>''')
536
if cont2 == 0: print('''    <button onclick="window.location.href='http://127.0.0.1:8000/cgi-bin/whz.py?2&2'">Dauerbetrieb</button> ''')
537
print('''          
538
        </td>
539
        <td>
540
          <center>''')
541
542
543
image_EIN(2)
544
image_HEIZ(2)
545
image_error(2)
546
print('''                               </center>
547
        </td>
548
      </tr>
549
      <tr>
550
        <td>
551
        <center><p>2/II</p></center>
552
        </td>
553
        <td>
554
        <button type="button">EIN</button>
555
        <button type="button">AUS</button>
556
        <button type="button">Dauerbetrieb</button>
557
        </td>
558
        <td>
559
          <center>''')
560
image_EIN(3)
561
image_HEIZ(3)
562
image_error(3)
563
print('''                               </center>  
564
        </td>
565
      </tr>
566
      <tr>
567
        <td>
568
        <center><p>2/III:</p></center>
569
        </td>
570
        <td>
571
        <button type="button">EIN</button>
572
        <button type="button">AUS</button>
573
        <button type="button">Dauerbetrieb</button>
574
        </td>
575
        <td>
576
                  <center>''')
577
image_EIN(4)
578
image_HEIZ(4)
579
image_error(4)
580
print('''                               </center>
581
                                </td>
582
      </tr>
583
      <tr>
584
        <td>
585
        <center><p>2/IV</p></center>
586
        </td>
587
        <td>
588
        <button type="button">EIN</button>
589
        <button type="button">AUS</button>
590
        <button type="button">Dauerbetrieb</button>
591
        </td>
592
        <td>
593
          <center>''')
594
image_EIN(5)
595
image_HEIZ(5)
596
image_error(5)
597
print('''                               </center>
598
        </td>
599
      </tr>
600
            <tr>
601
        <td>
602
        <center><p>3/I</p></center>
603
        </td>
604
        <td>
605
        <button type="button">EIN</button>
606
        <button type="button">AUS</button>
607
        <button type="button">Dauerbetrieb</button>
608
        </td>
609
        <td>
610
          <center>''')
611
image_EIN(6)
612
image_HEIZ(6)
613
image_error(6)
614
print('''                               </center>
615
        </td>
616
      </tr>
617
      <tr>
618
        <td>
619
        <center><p>3/II:</p></center>
620
        </td>
621
        <td>
622
        <button type="button">EIN</button>
623
        <button type="button">AUS</button>
624
        <button type="button">Dauerbetrieb</button>
625
        </td>
626
        <td>
627
          <center>''')
628
image_EIN(7)
629
image_HEIZ(7)
630
image_error(7)
631
print('''                               </center>
632
        </td>
633
      </tr>
634
      <tr>
635
        <td>
636
        <center><p>4/I</p></center>
637
        </td>
638
        <td>
639
        <button type="button">EIN</button>
640
        <button type="button">AUS</button>
641
        <button type="button">Dauerbetrieb</button>
642
        </td>
643
        <td>
644
          <center>''')
645
image_EIN(8)
646
image_HEIZ(8)
647
image_error(8)
648
print('''                               </center>
649
        </td>
650
      </tr>
651
    </table>
652
         </div>
653
654
655
         <div id="main">
656
    <center><h1>Triage nord</h1></center>
657
           <table>
658
      <tr>
659
        <td id="spalte1">
660
        <h2>WHz:</h2>
661
        </td>
662
        <td id="spalte2">
663
        <h2>Steuerung:</h2>      
664
        
665
        </td>
666
        <td id="spalte3">
667
        <h2>Auswertung:</h2>
668
        <center><h3 id="nobreak" >EIN</h3><h3 id="nobreak">Heiz</h3><h3 id="nobreak">Stoerung</h3></center>
669
        </td>
670
        <td id="spalte4"><button type="button">Stoerung</button></td>
671
        <td id="spalte5">
672
        <form method="get" action="info.py">
673
           <button type="submit">Info</button>
674
        </form>
675
        </td>
676
      </tr>
677
      <tr>
678
        <td>
679
        <center><p>4/II:</p></center>
680
        </td>
681
        <td>
682
        <button type="button">EIN</button>
683
        <button type="button">AUS</button>
684
        <button type="button">Dauerbetrieb</button>
685
        </td>
686
        <td>
687
          <center>''')
688
image_EIN(9)
689
image_HEIZ(9)
690
image_error(9)
691
print('''                               </center>
692
        </td>
693
      </tr>
694
      <tr>
695
        <td>
696
        <center><p>4/III</p></center>
697
        </td>
698
        <td>
699
        <button type="button">EIN</button>
700
        <button type="button">AUS</button>
701
        <button type="button">Dauerbetrieb</button>
702
        </td>
703
        <td>
704
          <center>''')
705
image_EIN(10)
706
image_HEIZ(10)
707
image_error(10)
708
print('''                               </center>
709
        </td>
710
      </tr>
711
      <tr>
712
        <td>
713
        <center><p>4/IV:</p></center>
714
        </td>
715
        <td>
716
        <button type="button">EIN</button>
717
        <button type="button">AUS</button>
718
        <button type="button">Dauerbetrieb</button>
719
        </td>
720
        <td>
721
          <center>''')
722
image_EIN(11)
723
image_HEIZ(11)
724
image_error(11)
725
print('''                               </center>
726
        </td>    
727
      </tr>
728
      <tr>
729
        <td>
730
        <center><p>5/I</p></center>
731
        </td>
732
        <td>
733
        <button type="button">EIN</button>
734
        <button type="button">AUS</button>
735
        <button type="button">Dauerbetrieb</button>
736
        </td>
737
        <td>
738
          <center>''')
739
image_EIN(12)
740
image_HEIZ(12)
741
image_error(12)
742
print('''                               </center>
743
        </td>
744
      </tr>
745
      <tr>
746
        <td>
747
        <center><p>5/II:</p></center>
748
        </td>
749
        <td>
750
        <button type="button">EIN</button>
751
        <button type="button">AUS</button>
752
        <button type="button">Dauerbetrieb</button>
753
        </td>
754
        <td>
755
          <center>''')
756
image_EIN(13)
757
image_HEIZ(13)
758
image_error(13)
759
print('''                               </center>
760
        </td>
761
      </tr>
762
      <tr>
763
        <td>
764
        <center><p>5/III</p></center>
765
        </td>
766
        <td>
767
        <button type="button">EIN</button>
768
        <button type="button">AUS</button>
769
        <button type="button">Dauerbetrieb</button>
770
        </td>
771
        <td>
772
          <center>''')
773
image_EIN(14)
774
image_HEIZ(14)
775
image_error(14)
776
print('''                               </center>
777
        </td>
778
      </tr>
779
      <tr>
780
        <td>
781
        <center><p>5/IV</p></center>
782
        </td>
783
        <td>
784
        <button type="button">EIN</button>
785
        <button type="button">AUS</button>
786
        <button type="button">Dauerbetrieb</button>
787
        </td>
788
        <td>
789
          <center>''')
790
image_EIN(15)
791
image_HEIZ(15)
792
image_error(15)
793
print('''                               </center>
794
        </td>
795
      </tr>
796
    </table>
797
         </div>
798
799
               <div id="main">
800
    <center><h1>Triage sud</h1></center>
801
           <table>
802
      <tr>
803
        <td id="spalte1">
804
        <h2>WHz:</h2>
805
        </td>
806
        <td id="spalte2">
807
        <h2>Steuerung:</h2>      
808
        
809
        </td>
810
        <td id="spalte3">
811
        <h2>Auswertung:</h2>
812
        <center><h3 id="nobreak" >EIN</h3><h3 id="nobreak">Heiz</h3><h3 id="nobreak">Stoerung</h3></center>
813
        </td>
814
        <td id="spalte4"><button type="button">Stoerung</button></td>
815
        <td id="spalte5">
816
        <form method="get" action="info.py">
817
           <button type="submit">Info</button>
818
        </form>
819
        </td>
820
      </tr>
821
      <tr>
822
        <td>
823
        <center><p>6/I:</p></center>
824
        </td>
825
        <td>
826
        <button type="button">EIN</button>
827
        <button type="button">AUS</button>
828
        <button type="button">Dauerbetrieb</button>
829
        </td>
830
        <td>
831
          <center>''')
832
image_EIN(16)
833
image_HEIZ(16)
834
image_error(16)
835
print('''                               </center>
836
        </td>
837
      </tr>
838
    </table>
839
         </div>
840
841
         <div id="main">
842
    <center><h1>Hollerich</h1></center>
843
           <table>
844
      <tr>
845
        <td id="spalte1">
846
        <h2>WHz:</h2>
847
        </td>
848
        <td id="spalte2">
849
        <h2>Steuerung:</h2>      
850
        
851
        </td>
852
        <td id="spalte3">
853
        <h2>Auswertung:</h2>
854
        <center><h3 id="nobreak" >EIN</h3><h3 id="nobreak">Heiz</h3><h3 id="nobreak">Stoerung</h3></center>
855
        </td>
856
        <td id="spalte4"><button type="button">Stoerung</button></td>
857
        <td id="spalte5">
858
        <form method="get" action="info.py">
859
           <button type="submit">Info</button>
860
        </form>
861
        </td>
862
      </tr>
863
      <tr>
864
        <td>
865
        <center><p>7/I:</p></center>
866
        </td>
867
        <td>
868
        <button type="button">EIN</button>
869
        <button type="button">AUS</button>
870
        <button type="button">Dauerbetrieb</button>
871
        </td>
872
        <td>
873
          <center>''')
874
image_EIN(17)
875
image_HEIZ(17)
876
image_error(17)
877
print('''                               </center>
878
        </td>
879
      </tr>
880
      <tr>
881
        <td>
882
        <center><p>7/II</p></center>
883
        </td>
884
        <td>
885
        <button type="button">EIN</button>
886
        <button type="button">AUS</button>
887
        <button type="button">Dauerbetrieb</button>
888
        </td>
889
        <td>
890
          <center>''')
891
image_EIN(18)
892
image_HEIZ(18)
893
image_error(18)
894
print('''                               </center>
895
        </td>
896
      </tr>
897
    </table>
898
         </div>
899
900
901
  </body>
902
</html>
903
''')