Crestron SIMPL+ Spezifikationen

Stöbern Sie online oder laden Sie Spezifikationen nach Software Crestron SIMPL+ herunter. Crestron SIMPL+ Specifications Benutzerhandbuch

  • Herunterladen
  • Zu meinen Handbüchern hinzufügen
  • Drucken

Inhaltsverzeichnis

Seite 1 - Programming Guide

Crestron SIMPL+ Software Programming Guide

Seite 2

Software Crestron SIMPL+ #SYMBOL_NAME - Allows the user to specify the name that SIMPL Windows uses for this module. If this directive is left out,

Seite 3 - Contents

Crestron SIMPL+ Software #DEFINE_CONSTANT VCR_INPUT 3 #DEFINE_CONSTANT DVD_INPUT 4 #DEFINE_CONSTANT VPROJ_OUTPUT 2 PUSH vcr_select { switcher_inpu

Seite 4 - Software Crestron SIMPL+

Software Crestron SIMPL+ Crestron-Libraries are provided from Crestron and are contained within the Crestron Database. Variable Declarations Variabl

Seite 5 - Introduction

Crestron SIMPL+ Software variables are also available with the INTEGER and STRING datatype. Integers are 16 bit quantities. For the 2-series contr

Seite 6 - Quick Start

Software Crestron SIMPL+ User-Defined Functions The term checksum byte is commonly used in serial communications to represent a byte (or bytes) that

Seite 7

Crestron SIMPL+ Software This example assumes that the camera unit being controlled continues to move in a given direction until a stop command is i

Seite 8 - Making it Work

Software Crestron SIMPL+ CHANGE output_value PUSH button1, button2 { <statements> } A useful feature of SIMPL+ event functions is that a sing

Seite 9 - Compiler Directives

Crestron SIMPL+ Software while (1) { <do something forever> // code in here runs // continuously } } This loop runs continuou

Seite 10 - Software Crestron SIMPL+

Software Crestron SIMPL+ Analog Inputs/Outputs Analog signals are used in SIMPL to accomplish tasks for which digital signals are inadequate. Typica

Seite 11 - Include Libraries

Crestron SIMPL+ Software SIMPL+ program. The value of any output is the value of the signal as seen by the outside SIMPL program at that instant. Th

Seite 12 - Variable Declarations

This document was prepared and written by the Technical Documentation department at: Crestron Electronics, Inc. 15 Volvo Drive Rockleigh, NJ 0764

Seite 13

Software Crestron SIMPL+ The 'if' language construct is described in detail in “Controlling Program Flow: Branching”. Evaluation of TRUE a

Seite 14 - Event Functions

Crestron SIMPL+ Software When an integer has a value of between 0 and 32767, it is identical whether it is considered signed or unsigned. However, n

Seite 15

Software Crestron SIMPL+ Examine one more example: INTEGER a, b, c, d; Function Main() { a = 100; b = -4; c = a / b; // c = 0 (100/65532)

Seite 16 - Function Main

Crestron SIMPL+ Software name, as was done when it was declared. When assigning a value to a string, that value is always assigned starting at the f

Seite 17 - Input/Output Types

Software Crestron SIMPL+ Notice how the constant parts of the string are entered directly. The interesting thing about the format specification is t

Seite 18

Crestron SIMPL+ Software The first two examples above define 1D and 2D integer arrays, respectively. The last example looks like it declares a 2D ar

Seite 19

Software Crestron SIMPL+ Operators, Expressions, and Statements This section deals with the core programming elements in SIMPL+. Operators Operator

Seite 20 - All About Variables

Crestron SIMPL+ Software Expressions As reading through the later parts of this guide, as well as the latest revision of the SIMPL+ Language Referen

Seite 21

Software Crestron SIMPL+ Branching” and “Controlling Program Flow: Loops” on pages 24 and 27, respectively. Statements Statements in SIMPL+ consist

Seite 22

Crestron SIMPL+ Software Expressions EXPRESSION EVALUATES TO a = 3 true if a=3, false otherwiseb*4 - a/3 true as long as the result is non-zero1 alw

Seite 23

Crestron SIMPL+ Software Contents SIMPL+ 1 Introduction ...

Seite 24

Software Crestron SIMPL+ today = getDayNum(); // gets the current day of the week if (today = 0) // is today Sunday? { // code to run on Sunda

Seite 25

Crestron SIMPL+ Software Examine an example using the switch-case construct. Perhaps there is a variable that should hold the number of days in the

Seite 26 - Operators

Software Crestron SIMPL+ To see an example of the for loop use the situation alluded to above. That is, a need to clear each string element in a str

Seite 27 - Expressions

Crestron SIMPL+ Software while and do-until Loops The for loop discussed in an earlier section is useful for iterating through code a specific numbe

Seite 28 - Statements

Software Crestron SIMPL+ this code, the value of this expression determines whether or not the code should be executed again. Here lies the other di

Seite 29

Crestron SIMPL+ Software programming task that has been predefined and given a name. Many of the examples in previous sections of this document have

Seite 30

Software Crestron SIMPL+ perform exactly like system functions with the only exception in that they must be defined before they are used. Function D

Seite 31

Crestron SIMPL+ Software The FUNCTION keyword is used to tell the SIMPL+ compiler that what follows is the definition of a function and not a functi

Seite 32

Software Crestron SIMPL+ This code causes a compile error, because the function MyUserFunction1 has been called before it has been defined. This can

Seite 33

Crestron SIMPL+ Software Print("i = %d, j = %d, k = %d\n", i, j, k); Call sillyFunction(); Print("i = %d, j = %d, k = %d\n"

Seite 34 - Using System Functions

Software Crestron SIMPL+ Wait Events ...

Seite 35 - User Defined Functions

Software Crestron SIMPL+ localStr = left(var3, 10); } Notice that the function shown above has three arguments, named var1, var2, and var3. var1

Seite 36 - Function Definitions

Crestron SIMPL+ Software String1 = itoa(int1); position = find(“Artist”,CD_data); int3 = max(int1, int2); For clarity, here are some example stateme

Seite 37

Software Crestron SIMPL+ Print(“5 raised to the power of 3 = %d\n”,power(5,3)); x = power(y,z); As a second example, we shall build a function which

Seite 38

Crestron SIMPL+ Software To solve this problem, SIMPL+ has introduced the concept of function libraries. Simply put, a function library is a collect

Seite 39

Software Crestron SIMPL+ flash card within the control system. The function will return an error code and the program can act accordingly. Other pr

Seite 40 - Functions That Return Values

Crestron SIMPL+ Software DIGITAL_INPUT readCompactFlashCard; DIGITAL_INPUT writeCompactFlashCard; INTEGER myInt; LONG_INTEGER myLongInt; STRING myS

Seite 41

Software Crestron SIMPL+ } myStruct struct; PUSH writeCompactFlashCard { SIGNED_INTEGER nFileHandle; INTEGER nNumBytes; StartFileOpe

Seite 42 - Function Libraries

Crestron SIMPL+ Software PUSH startMe { Print("I’m starting now..."); Delay(500); //this equals 5 seconds Print("and I’m endin

Seite 43 - Compact Flash Functions

Software Crestron SIMPL+ This syntax defines a wait event to occur at some time in the future, defined by the value of wait_time. While the wait eve

Seite 44 - Reading and Writing Data

Crestron SIMPL+ Software Pulse(PULSETIME, vproj_on); } Wait (1500, sysOnWait2) // 15 second delay pulse(PULSETIME, vproj_video); } // end of

Seite 45

Crestron SIMPL+ Software SIMPL+ Introduction What is SIMPL+? SIMPL+ is a language extension to SIMPL Windows. It does not replace SIMPL, but inste

Seite 46 - Working with Time

Software Crestron SIMPL+ The Serial Send symbol simply generates the static text defined in its parameter field onto the output serial signal whenev

Seite 47 - Wait Events

Crestron SIMPL+ Software second pass: jukebox_in = "k=My Way, Album=Very Good Yea" third pass: jukebox_in = "rs<CR>" I

Seite 48

Software Crestron SIMPL+ Notice that a do-until loop was used in the example above. Every time a change event is triggered for the data_in buffer, i

Seite 49 - Working with Strings

Crestron SIMPL+ Software tempStr = ""; } This example introduces two new system functions, which are extremely useful for string manipul

Seite 50

Software Crestron SIMPL+ There are two ways to force a task switch: with the ProcessLogic function or the Delay function. To provide an immediate ta

Seite 51 - Removing Data From Buffers

Crestron SIMPL+ Software To determine if a run-time error is occurring in your program, watch the status of the control system's computer port

Seite 52

Software Crestron SIMPL+ Software License Agreement This License Agreement (“Agreement”) is a legal contract between you (either an individual or a

Seite 53 - Forcing a Task Switch

Crestron SIMPL+ Software If You are a business or organization, You agree that upon request from Crestron or its authorized agent, You will within t

Seite 54 - Debugging

Software Crestron SIMPL+ Return and Warranty Policies Merchandise Returns / Repair Service 1. No merchandise may be returned for credit, exchange,

Seite 55 - Debugging with Print()

Crestron SIMPL+ Software This page intentionally left blank. Programming Guide – DOC. 5789A

Seite 56 - Software License Agreement

Software Crestron SIMPL+ Using SIMPL vs. SIMPL+ SIMPL+, while exciting and powerful, does present the programmer with somewhat of a dilemma, namely,

Seite 57

Crestron Electronics, Inc. Programming Guide – DOC. 5789A 15 Volvo Drive Rockleigh, NJ 07647

Seite 58 - Return and Warranty Policies

Crestron SIMPL+ Software Start creating a new SIMPL+ program while running SIMPL Windows. Select File | New | New SIMPL+ Module. The SIMPL+ program

Seite 59

Software Crestron SIMPL+ Function Main { Print( “I am born!”\n ); } This causes the text “I am born” to be sent out the computer port only upon st

Seite 60

Crestron SIMPL+ Software program by clicking on the compile toolbar button or selecting Project | Convert/Compile. The compile process automatically

Kommentare zu diesen Handbüchern

Keine Kommentare