Skip to content

feat(cfc): storage mode (set/reset) - #1851

Open
volsa wants to merge 1 commit into
masterfrom
claude/last-commit-query-c1083e
Open

feat(cfc): storage mode (set/reset)#1851
volsa wants to merge 1 commit into
masterfrom
claude/last-commit-query-c1083e

Conversation

@volsa

@volsa volsa commented Aug 7, 2026

Copy link
Copy Markdown
Member

Problem: The IDE exports a storage mode extension on data sinks,
<bmx:StorageMode mode="Set|Reset"/>, to latch signals that are only
present for a short time. The compiler ignored the extension and
transpiled such sinks as plain assignments, so the latch behavior was
silently lost.

Solution: Adapt the model to the exported format and lower a storage
sink to a guarded constant store: IF <input> THEN sink := TRUE; END_IF
for Set, storing FALSE for Reset. Nothing is written while the input
is FALSE, so a once-set sink keeps its value until the counterpart
fires.

Problem: The IDE exports a storage mode extension on data sinks,
`<bmx:StorageMode mode="Set|Reset"/>`, to latch signals that are only
present for a short time. The compiler ignored the extension and
transpiled such sinks as plain assignments, so the latch behavior was
silently lost.

Solution: Adapt the model to the exported format and lower a storage
sink to a guarded constant store: `IF <input> THEN sink := TRUE; END_IF`
for Set, storing `FALSE` for Reset. Nothing is written while the input
is FALSE, so a once-set sink keeps its value until the counterpart
fires.
@github-actions

github-actions Bot commented Aug 7, 2026

Copy link
Copy Markdown

Build Artifacts

🐧 Linux

Artifact Link Size
deb-x86_64 Download 38.4 MB
schema Download 0.0 MB
stdlib Download 32.4 MB
plc-x86_64 Download 43.5 MB
deb-aarch64 Download 30.8 MB
plc-aarch64 Download 43.3 MB

From workflow run

🪟 Windows

Artifact Link Size
stdlib.lib Download 4.0 MB
stdlib.dll Download 0.1 MB
plc.exe Download 38.3 MB

From workflow run

@volsa volsa changed the title feat(cfc): storage modes on data sinks (set/reset) feat(cfc): storage mode (set/reset) Aug 7, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant