Dates and Events: |
OSADL Articles:
2023-11-12 12:00
Open Source License Obligations Checklists even better nowImport the checklists to other tools, create context diffs and merged lists
2022-07-11 12:00
Call for participation in phase #4 of Open Source OPC UA open62541 support projectLetter of Intent fulfills wish list from recent survey
2022-01-13 12:00
Phase #3 of OSADL project on OPC UA PubSub over TSN successfully completedAnother important milestone on the way to interoperable Open Source real-time Ethernet has been reached
2021-02-09 12:00
Open Source OPC UA PubSub over TSN project phase #3 launchedLetter of Intent with call for participation is now available |
"Immediate C" has arrays now
Version 1.124 of John E. Wulff's PLC-extension of the C language is now online
Thanks to John E. Wulff, the immediate C language knows now about arrays. An entire section of the revised documentation (V1.124) is devoted to arrays and to the difference of handling arrays between conventional instruction flow languages and data flow languages such as immediate C.
The first couple of paragraphs of the newly added section on arrays in the immediate C documentation read as follows:
3 Arrays
Arrays in conventional instruction flow languages are a named collection (often of fixed length) of similar variables, which are accessed by an index expression, eg a[5]. Each such entity is an individual object, but in instruction flow languages the index is often a variable, which is manipulated in a loop and references to the individual indexed entities occur sequentially, as in the following C example:
for (n = 0; n < 4; n+) {
a[n] = b[n] * c[n];
}
3.1 Immediate Arrays
In data flow languages like immediate C, loops at run-time are meaningless. Each immediate variable is an entity, which is controlled by one assignment statement. The variable changes, when a variable in the expression of the controlling statement changes and not when some loop runs. It is well to remember, that immediate variables and their controlling expressions are more like IC building blocks connected in a static network. In that sense immediate Arrays are like hardware registers.
Arrays may be defined in immediate C, but each entity acts individually at run-time, which means that an individual immediate object must be generated for each immediate array member.
Read on here. The software archive is available for download here.