Differenze
Queste sono le differenze tra la revisione selezionata e la versione attuale della pagina.
| software:qview:qview_6:qcl_library:bc10arrfifo [2019/08/29 17:01] – creata - modifica esterna 127.0.0.1 | software:qview:qview_6:qcl_library:bc10arrfifo [2024/09/02 14:29] (versione attuale) – [IMPLEMENTAZIONE] qem214 | ||
|---|---|---|---|
| Linea 1: | Linea 1: | ||
| + | ====== BC10ArrFifo ====== | ||
| + | |||
| + | **B = **// | ||
| + | |||
| + | **C = **// | ||
| + | |||
| + | La funzione BC10ArrFifo __gestisce un buffer di tipo first input - first output__. La funzione richiede un valore in ingresso nella variabile ' | ||
| + | |||
| + | ===== IMPLEMENTAZIONE ===== | ||
| + | |||
| + | **BC10ArrFifo (Buffer, elementIn, elementOut, PuntatIn, PuntatOut)** | ||
| + | |||
| + | Parametri: | ||
| + | |||
| + | ^IN/ | ||
| + | | IN | ARRSYS | ||
| + | | IN | SYSTEM | ||
| + | | IN | SYSTEM | ||
| + | | IN | SYSTEM | ||
| + | | OUT | SYSTEM | ||
| + | |||
| + | === Esempio === | ||
| + | |||
| + | Inserisce ogni secondo il valore di conteggio di un device nel buffer (eliminando il primo introdotto) | ||
| + | |||
| + | <code QCL> | ||
| + | ;... | ||
| + | MAIN: | ||
| + | IF tmTimer | ||
| + | tmTimer = 1000 | ||
| + | elementIn = count:posit | ||
| + | BC10ArrFifo (BufferS, elementIn, elementOut, PuntatIn, | ||
| + | ENDIF | ||
| + | ;... | ||
| + | </ | ||
| + | |||
| + | === Note === | ||
| + | |||
| + | *Se il parametro **PuntatIn** o **PuntatOut** vale 0, la funzione assume come valore, rispettivamente, | ||
| + | *La funzione esegue un WAIT ogni 150ms. | ||