Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » 4DIAC - Framework for Distributed Industrial Automation and Control » Compute now F_MOD value by triggered event
Compute now F_MOD value by triggered event [message #1840222] Fri, 09 April 2021 06:31 Go to next message
Thomas Wagner is currently offline Thomas WagnerFriend
Messages: 10
Registered: April 2021
Junior Member
Hi at all.

First I am new to PLC. I just have skills in "normal" programming.
I try to implement a "is multiple of" PLC. See "4DIAC.png".

A F_MOD gets its dividend by an upcounter and has a fixed divisor.
How ever the F_MOD does no action even if the upcounter has values as you can see in the watches.

So whats wrong?
  • Attachment: 4DIAC.png
    (Size: 32.95KB, Downloaded 66 times)
Re: Compute now F_MOD value by triggered event [message #1840240 is a reply to message #1840222] Fri, 09 April 2021 12:42 Go to previous messageGo to next message
Alois Zoitl is currently offline Alois ZoitlFriend
Messages: 1583
Registered: January 2014
Senior Member

The NA in the monitoring indicates that the block could not deployed to your runtime. Do you get any error in the Deployment Console (you can get it via: Window -> show view -> other and search for it)
Do you have the IEC 61131-3 lib compiled into your 4diac FORTE?
Re: Compute now F_MOD value by triggered event [message #1840243 is a reply to message #1840240] Fri, 09 April 2021 14:31 Go to previous messageGo to next message
Thomas Wagner is currently offline Thomas WagnerFriend
Messages: 10
Registered: April 2021
Junior Member
Ok, thanks.

It says:
<!-- 127.0.0.1:61499: EMB_RES -->
<Request Action="CREATE" ID="11">
  <Connection Destination="F_MOD.REQ" Source="E_CTU.CUO"/>
</Request>

<Response ID="11" Reason="NO_SUCH_OBJECT"/>


<!-- 127.0.0.1:61499: EMB_RES -->
<Request Action="CREATE" ID="12">
  <Connection Destination="F_MOD.IN1" Source="E_CTU.CV"/>
</Request>

<Response ID="12" Reason="NO_SUCH_OBJECT"/>


I 'll try to debug this.
Re: Compute now F_MOD value by triggered event [message #1840245 is a reply to message #1840243] Fri, 09 April 2021 14:52 Go to previous messageGo to next message
Alois Zoitl is currently offline Alois ZoitlFriend
Messages: 1583
Registered: January 2014
Senior Member

could it be that above is a NO_SUCH_TYPE error?
Re: Compute now F_MOD value by triggered event [message #1840250 is a reply to message #1840245] Fri, 09 April 2021 16:18 Go to previous messageGo to next message
Thomas Wagner is currently offline Thomas WagnerFriend
Messages: 10
Registered: April 2021
Junior Member
No.
I use forte binary downloaded from the homepage running on Ubuntu 20.04 LTS.
Alternative I build the variant with CMake for PikeOS and run it on a QEMU-Arm-v7 emulated target with usermode network. Port 61499 was to the targets forte port.
So both, Ubuntu and PikeOS, where reachable via 127.0.0.1:61499.
The complet log of the deployment console is attached.

"Problems and Warnings" View is empty.

This is the STDOUT print of PikeOS which was similar to Ubuntu:
INFO: T#51123721770: FORTE starting
INFO: T#51263721770: FORTE is up and running
INFO: T#51283721770: Using provided bootfile location set in CMake: forte.fboot
INFO: T#51303721770: Boot file forte.fboot could not be opened. Skipping...
INFO: T#77063721770: Connection established by client
INFO: T#77283721770: Connection closed by peer
Re: Compute now F_MOD value by triggered event [message #1840267 is a reply to message #1840250] Sat, 10 April 2021 19:01 Go to previous messageGo to next message
Alois Zoitl is currently offline Alois ZoitlFriend
Messages: 1583
Registered: January 2014
Senior Member

As expected in both cases you get an unsupported type error. this means that the FB type of F_MOD is not available in your runtime. You need to enable the IEC 61131-3 module where this FB is contained in.
Re: Compute now F_MOD value by triggered event [message #1840319 is a reply to message #1840222] Mon, 12 April 2021 11:25 Go to previous messageGo to next message
Thomas Wagner is currently offline Thomas WagnerFriend
Messages: 10
Registered: April 2021
Junior Member
Hi,

thanks to the hint. I rebuild it with enable "FORTE_MODULE_IEC61131" within CMake GUI.

On Ubuntu it does run fine.
On PikeOS the runtime reports:
ERROR: T#51289337000: Error could not create the thread! Unknown error: 0
ERROR: T#51309337000: Error could not create the thread!

on deploying. But that's a PikeOS problem I guess.
Re: Compute now F_MOD value by triggered event [message #1840323 is a reply to message #1840319] Mon, 12 April 2021 12:47 Go to previous messageGo to next message
Alois Zoitl is currently offline Alois ZoitlFriend
Messages: 1583
Registered: January 2014
Senior Member

I fear yes this is a PikeOS problem. The PikeOS support was implemented by the PikeOS people so I have no knowledge what the problem could be here.
Re: Compute now F_MOD value by triggered event [message #1840326 is a reply to message #1840323] Mon, 12 April 2021 15:25 Go to previous messageGo to next message
Thomas Wagner is currently offline Thomas WagnerFriend
Messages: 10
Registered: April 2021
Junior Member
I refactored "arch/pikeos_posix/forte_thread.cpp". Now the error is
ERROR: T#132893716700: Error could not create the thread! Operation not permitted


I'll give feedback if I have it running on PikeOS.
Re: Compute now F_MOD value by triggered event [message #1840340 is a reply to message #1840326] Mon, 12 April 2021 20:13 Go to previous messageGo to next message
Alois Zoitl is currently offline Alois ZoitlFriend
Messages: 1583
Registered: January 2014
Senior Member

Thanks for your effort.
Re: Compute now F_MOD value by triggered event [message #1840428 is a reply to message #1840340] Thu, 15 April 2021 05:50 Go to previous messageGo to next message
Thomas Wagner is currently offline Thomas WagnerFriend
Messages: 10
Registered: April 2021
Junior Member
PikeOS have strict RAM configurations for each process.
On deploying it runs out of RAM. Just increase RAM Size in the PikeOS Integration Project for each forte process, if you have compiled forte with more than just the base modules:

index.php/fa/40337/0/
Re: Compute now F_MOD value by triggered event [message #1840450 is a reply to message #1840428] Thu, 15 April 2021 14:38 Go to previous message
Alois Zoitl is currently offline Alois ZoitlFriend
Messages: 1583
Registered: January 2014
Senior Member

Thanks for letting us know.
Previous Topic:What's the difference between subapp and compsite fb?
Next Topic:Cross-compiling from Ubuntu to arm32 for Raspberry Pi
Goto Forum:
  


Current Time: Sat Apr 20 00:41:23 GMT 2024

Powered by FUDForum. Page generated in 0.04077 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top