From b1f0b43b646f497f13b48907acdc39bba2ec590c Mon Sep 17 00:00:00 2001 From: Peter <61538034+PTKu@users.noreply.github.com> Date: Fri, 24 Nov 2023 20:21:18 +0100 Subject: [PATCH] fix template build --- cake/Program.cs | 3 ++- .../working/templates/axsharpblazor/ax/AXSharp.config.json | 2 +- .../working/templates/axsharpblazor/ax/src/configuration.st | 3 ++- templates/working/templates/axsharpblazor/ax/src/counters.st | 2 ++ 4 files changed, 7 insertions(+), 3 deletions(-) diff --git a/cake/Program.cs b/cake/Program.cs index 460d2ba5..69d449c2 100644 --- a/cake/Program.cs +++ b/cake/Program.cs @@ -127,7 +127,8 @@ public override void Run(BuildContext context) Path.Combine(context.ScrDir, "sanbox\\integration\\ix-integration-plc\\"), Path.Combine(context.ScrDir, "AXSharp.examples\\hello.world.console\\hello.world.console.plc"), Path.Combine(context.ScrDir, "AXSharp.connectors\\tests\\ax-test-project\\"), - Path.Combine(context.ScrDir, "tests.integrations\\integrated\\src\\ax\\") + Path.Combine(context.ScrDir, "tests.integrations\\integrated\\src\\ax\\"), + Path.Combine(context.TemplatesDir, "working\\templates\\axsharpblazor\\ax\\") }; diff --git a/templates/working/templates/axsharpblazor/ax/AXSharp.config.json b/templates/working/templates/axsharpblazor/ax/AXSharp.config.json index 9fe647f3..b950f310 100644 --- a/templates/working/templates/axsharpblazor/ax/AXSharp.config.json +++ b/templates/working/templates/axsharpblazor/ax/AXSharp.config.json @@ -1 +1 @@ -{"OutputProjectFolder":"..\\axsharpblazor.twin","UseBase":false,"NoDependencyUpdate":false,"ProjectFile":"axsharpblazor.csproj"} \ No newline at end of file +{"OutputProjectFolder":"..\\axsharpblazor.twin","UseBase":false,"NoDependencyUpdate":false,"IgnoreS7Pragmas":false,"ProjectFile":"axsharpblazor.csproj"} \ No newline at end of file diff --git a/templates/working/templates/axsharpblazor/ax/src/configuration.st b/templates/working/templates/axsharpblazor/ax/src/configuration.st index 343c95c8..a15e24fc 100644 --- a/templates/working/templates/axsharpblazor/ax/src/configuration.st +++ b/templates/working/templates/axsharpblazor/ax/src/configuration.st @@ -2,7 +2,8 @@ CONFIGURATION MyConfiguration TASK Main(Interval := T#10ms, Priority := 1); PROGRAM P1 WITH Main: MyProgram; - VAR_GLOBAL + VAR_GLOBAL + {S7.extern=ReadWrite} counters : counters; END_VAR END_CONFIGURATION diff --git a/templates/working/templates/axsharpblazor/ax/src/counters.st b/templates/working/templates/axsharpblazor/ax/src/counters.st index 9f7330f1..2b05eae5 100644 --- a/templates/working/templates/axsharpblazor/ax/src/counters.st +++ b/templates/working/templates/axsharpblazor/ax/src/counters.st @@ -1,4 +1,5 @@ +{S7.extern=ReadWrite} CLASS Counters VAR PUBLIC {#ix-attr:[Container(Layout.Wrap)]} @@ -12,6 +13,7 @@ CLASS Counters END_VAR END_CLASS +{S7.extern=ReadWrite} CLASS PUBLIC Counter VAR PUBLIC {#ix-set:AttributeName = "Number of revolutions"}