
|
INFO - FAQ - CC2-Forum - CCPro-Forum |
|
||
|
Hallo , ich nutze die C-ontrol 1 ,Applicationsboard 2.0. Ich habe die Tips mit der Bezifferung der Variablen befolgt , der Compiler meckert aber die Printbefehle weiter an. Ich komme nicht auf den Fehler. ******************************************************************** ' ' C-Control/BASIC basic_sps.bat ' ' Systemvoraussetzungen: ' ' - serielle Verbindung zum PC ' ' '******************************************************************** ' Definitonen ******************************************************* ' Ports Define P1 Port[1] Define P2 Port[2] Define P3 Port[3] Define P4 Port[4] Define P5 Port[5] Define P6 Port[6] Define K1 Port[7] Define K2 Port[8] Define F1 Port[9] Define F2 Port[10] Define F3 Port[11] Define F4 Port[12] Define Led1 Port[13] Define Led2 Port[14] Define Led3 Port[15] Define Led4 Port[16] Define A1 Ad[1] Define A2 Ad[2] Define A3 Ad[3] Define A4 Ad[4] Define T1 Ad[5] Define T2 Ad[6] 'DEFINE U1 AD[7] 'DEFINE U2 AD[8] 'Variablen Define Bit1 Bit[1] Define Bit2 Bit[2] Define Bit3 Bit[3] Define Bit4 Bit[4] Define Bit5 Bit[5] Define Bit6 Bit[6] Define Bit7 Bit[7] Define Bit8 Bit[8] Define B1 Byte[17] Define B2 Byte[17] Define B3 Byte[17] Define B4 Byte[17] Define B5 Byte[17] Define B6 Byte[17] Define B7 Byte[17] Define B8 Byte[17] Define W1 Word[1] Define W2 Word[2] Define W3 Word[3] Define W4 Word[4] Define W5 Word[5] Define W6 Word[6] Define W7 Word[7] Define W8 Word[8] ' Start des Programms ********************************************************** #start B1 = 0 If Rxd Then Get B1 If B1 = 0 Then Goto Step ' if b1 <> 0 then alles ausgeben und eventuell b1 interpretieren Print ">" Print "bit=" , Bit1 , Bit2 , Bit3 , Bit4 , Bit5 , Bit6 , Bit7 , Bit8 // hier Syntaxfehler Print "b=" , B1 , B2 , B3 , B4 , B5 , B6 , B7 , B8 // hier Syntaxfehler Print "w=" , W1 , W2 , W3 , W4 , W5 , W6 , W7 , W8// hier Syntaxfehler Print "P=" , P1 , P2 , P3 , P4 , P5 , P6// hier Syntaxfehler Print "A=" , A1 , A2 , A3 , A4// hier Syntaxfehler Print "T=" , T1 , T2// hier Syntaxfehler Print "K=" , K1 , K2// hier Syntaxfehler Print "F=" , F1 , F2 , F3 , F4// hier Syntaxfehler Print "LED=" , Led1 , Led2 , Led3 , Led4// hier Syntaxfehler '******************************************************************************* ' Hier kann man b1 interpretieren '******************************************************************************* #interpret '******************************************************************************* ' Hier kommt das SPS Programm '******************************************************************************* #step If F1 = -1 Then Led1 = 0 If F2 = -1 Then Led2 = 0 If F3 = -1 Then Led3 = 0 If F4 = -1 Then Led4 = 0 If F1 = 0 Then Led1 = 1 If F2 = 0 Then Led2 = 1 If F3 = 0 Then Led3 = 1 If F4 = 0 Then Led4 = 1 Goto Start ' Ende des Programms *********************************************************** #ende End |
| Antwort schreiben |