CODESYS - the IEC 61131-3 automation software

Welcome to the official CODESYS Forum by 3S-Smart Software Solutions GmbH | A member of the CODESYS Group
Deutsche Version English version russian version 
It is currently Thu Dec 13, 2018 6:31 pm

All times are UTC+01:00




Post new topic  Reply to topic  [ 4 posts ] 
Author Message
PostPosted: Mon Nov 19, 2018 9:09 pm 
Offline

Joined: Sun Nov 18, 2018 3:08 pm
Posts: 2
Hi,

I am trying to program outdoor lights, without a sensor, just switch on when it becomes dark.
I am using the Calculate_SunriseSunset function block, based on longitudinal and latitudinal.
this gives me the correct elevation and azimuth of the sun.

How can I now use this to trigger my relays?
And beside this, I also want to be able to swith them off/on manually.
For all my other lights, I am using the FB_LatchingRelay to switch on/off the lights.

Is all this possible using function blocks? Or do I need to program this myself in ST?
(I think I cannot find the SunriseSunset calculation in ST)

The basis idea is that my lights are switched on when it is dark enough outside and that I am able to switch them on/off manually, overriding the "dark enough" option.

Can someone help me with this?


Top
   
PostPosted: Thu Nov 22, 2018 7:47 pm 
Offline
Site Admin

Joined: Mon Sep 05, 2005 9:42 am
Posts: 3017
Hi,
check the OSCAT Libs:
https://store.codesys.com/catalogsearch/result/?q=OSCAT
BR
Edwin


Top
   
PostPosted: Fri Nov 23, 2018 8:20 pm 
Offline

Joined: Sun Nov 18, 2018 3:08 pm
Posts: 2
Can this also be used with codesys 2.3? I am still using the old version for my PLC


Top
   
PostPosted: Mon Dec 10, 2018 12:09 pm 
Offline

Joined: Tue Apr 24, 2018 11:57 am
Posts: 3
jpesout wrote:
Can this also be used with codesys 2.3? I am still using the old version for my PLC


Yes it can. I used it fine.


Top
   
Display posts from previous:  Sort by  
Post new topic  Reply to topic  [ 4 posts ] 

All times are UTC+01:00


Who is online

Users browsing this forum: No registered users and 3 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Limited