Help
  • Explore Community
  • Get Started
  • Ask the Community
  • How-To & Best Practices
  • Contact Support
Notifications
Login / Register
Community
Community
Notifications
close
  • Forums
  • Knowledge Center
  • Events & Webinars
  • Ideas
  • Blogs
Help
Help
  • Explore Community
  • Get Started
  • Ask the Community
  • How-To & Best Practices
  • Contact Support
Login / Register
Sustainability
Sustainability

Join our "Ask Me About" community webinar on May 20th at 9 AM CET and 5 PM CET to explore cybersecurity and monitoring for Data Center and edge IT. Learn about market trends, cutting-edge technologies, and best practices from industry experts.
Register and secure your Critical IT infrastructure

homelYnk sample remanent counter

SpaceLogic KNX Forum

Schneider Electric SpaceLogic KNX forum to get support and share knowledge including selection, installation and troubleshooting for spaceLYnk, Wiser for KNX, eConfigure KNX, SpaceLogic KNX Hybrid module and other topics.

cancel
Turn on suggestions
Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.
Showing results for 
Show  only  | Search instead for 
Did you mean: 
  • Home
  • Schneider Electric Community
  • EcoStruxure Building
  • Light and Room Control
  • SpaceLogic KNX Forum
  • homelYnk sample remanent counter
Options
  • Mark Topic as New
  • Mark Topic as Read
  • Float this Topic for Current User
  • Bookmark
  • Subscribe
  • Mute
  • Printer Friendly Page
Invite a Co-worker
Send a co-worker an invite to the portal.Just enter their email address and we'll connect them to register. After joining, they will belong to the same company.
You have entered an invalid email address. Please re-enter the email address.
This co-worker has already been invited to the Exchange portal. Please invite another co-worker.
Please enter email address
Send Invite Cancel
Invitation Sent
Your invitation was sent.Thanks for sharing Exchange with your co-worker.
Send New Invite Close
Top Experts
User Count
Thomas_Rohde
Sisko Thomas_Rohde Sisko
121
Erwin-vd-Zwart
Sisko Erwin-vd-Zwart Sisko
54
Heribert_Dölger
Lt. Commander Heribert_Dölger Lt. Commander
30
FZetina
Lt. Commander FZetina Lt. Commander
27
View All
Related Products
product field
SpaceLogic KNX - 4ʺ Touch Unit
product field
KNX Push Button Dynamic Labeling, universal
product field
Wiser for KNX : logic controller

Invite a Colleague

Found this content useful? Share it with a Colleague!

Invite a Colleague Invite
Back to SpaceLogic KNX Forum
esteve_budia
Lieutenant esteve_budia Lieutenant
Lieutenant

Posted: ‎2014-08-07 03:46 AM . Last Modified: ‎2024-07-15 12:06 AM

0 Likes
0
256
  • Mark as New
  • Bookmark
  • Subscribe
  • Mute
  • Permalink
  • Print
  • Email to a Friend
  • Report Inappropriate Content

Link copied. Please paste this link to share this article on your social media post.

‎2014-08-07 03:46 AM

homelYnk sample remanent counter

-- script updated every 28 seconds

count={}
count=storage.get('sto01',0)

--initialize variables
if not count.minutos then count.minutos=0 end
if not count.horas then count.horas=0 end
if not count.horasEIS5 then count.horas=0 end
if not count.h_m then count.h_m=0 end
if not count.dias then count.dias=0 end
if not count.meses then count.meses=0 end
if not count.anys then count.anys=0 end

--enable this to watch values
--log (count)

--system date
  hora = tonumber (os.date('%H'))
  minut = tonumber (os.date('%M'))
  hora_minuto_1=(hora*100)+minut

if (hora_minuto_1 == count.h_m) then
else
count.h_m=(hora*100)+minut
count.minutos=count.minutos +1
  --GOING bus / minute
  --counted minutes  1 byte EIS6
  grp.write('10/0/5', count.minutos, dt.uint8)
  --counted hours 1 byte EIS6
--  grp.write('10/0/3',math.min(255,count.horas), dt.uint8)
  --counted hours 2 byte EIS5 no reset
--  grp.write('10/0/4',count.horasEIS5, dt.float16)
  --counted days 1 byte EIS6
--  grp.write('10/0/6',math.min(69,count.dias), dt.uint8)
  --counted month 1 byte EIS6
--  grp.write('10/0/7',math.min(69,count.meses), dt.uint8)
  --counted years 1 byte EIS6
--  grp.write('10/0/8',math.min(69,count.anys), dt.uint8)
 
end

if ( count.minutos > 59 ) then
  count.horas=count.horas + 1
  count.horasEIS5=count.horasEIS5 + 1
count.minutos=0 
 
    if ( count.horas > 23 ) then
    count.dias=count.dias + 1
    count.horas=0 
    end
    if ( count.dias > 30 ) then
    count.meses=count.meses + 1
    count.dias=0 
    end
    if ( count.meses > 12 ) then
    count.anys=count.anys + 1
    count.meses=0 
    end
 
    --going bus / hour
  grp.write('10/0/5', count.minutos, dt.uint8)
  grp.write('10/0/3',math.min(255,count.horas), dt.uint8)
  grp.write('10/0/4',count.horasEIS5, dt.float16)
  grp.write('10/0/6',math.min(69,count.dias), dt.uint8)
  grp.write('10/0/7',math.min(69,count.meses), dt.uint8)
  grp.write('10/0/8',math.min(69,count.anys), dt.uint8)
 
end


-- set storage variable myobjectdata to a specified value (e.g. 127)

storage.set('sto01',count)

4309

4311

  • Thumbnail of SpaceLogic KNX - 4ʺ Touch Unit
    SpaceLogic KNX - 4ʺ Touch Unit
  • Thumbnail of KNX Push Button Dynamic Labeling, universal
    KNX Push Button Dynamic Labeling, universal
  • Thumbnail of Wiser for KNX : logic controller
    Wiser for KNX : logic controller
View products (3)
Tags (4)
  • Tags:
  • counter
  • holding
  • homelynk
  • sample
Reply
  • All forum topics
  • Previous Topic
  • Next Topic
Replies 0
To The Top!

Forums

  • APC UPS Data Center Backup Solutions
  • EcoStruxure IT
  • EcoStruxure Geo SCADA Expert
  • Metering & Power Quality
  • Schneider Electric Wiser

Knowledge Center

Events & webinars

Ideas

Blogs

Get Started

  • Ask the Community
  • Community Guidelines
  • Community User Guide
  • How-To & Best Practice
  • Experts Leaderboard
  • Contact Support
Brand-Logo
Subscribing is a smart move!
You can subscribe to this board after you log in or create your free account.
Forum-Icon

Create your free account or log in to subscribe to the board - and gain access to more than 10,000+ support articles along with insights from experts and peers.

Register today for FREE

Register Now

Already have an account? Login

Terms & Conditions Privacy Notice Change your Cookie Settings © 2025 Schneider Electric

This is a heading

With achievable small steps, users progress and continually feel satisfaction in task accomplishment.

Usetiful Onboarding Checklist remembers the progress of every user, allowing them to take bite-sized journeys and continue where they left.

of