Jump to content

Welcome to Smart Home Forum by FIBARO

Dear Guest,

 

as you can notice parts of Smart Home Forum by FIBARO is not available for you. You have to register in order to view all content and post in our community. Don't worry! Registration is a simple free process that requires minimal information for you to sign up. Become a part of of Smart Home Forum by FIBARO by creating an account.

 

As a member you can:

  •     Start new topics and reply to others
  •     Follow topics and users to get email updates
  •     Get your own profile page and make new friends
  •     Send personal messages
  •     ... and learn a lot about our system!

 

Regards,

Smart Home Forum by FIBARO Team


  • 0

SendPush to current active iPhone/iPad


Question

Posted

Hi,

is it possible via LUA to get the DeviceID of the device which has the app open and send a push just to him?

For example, my family has 5 iPhones. We have a scence "setAlarm" which is used on the iPhone (outside the house) when we leave the house. I want to confirm JUST to the specific iPhone, that the scene has completed, NOT to the other 4 iPhones.

So I need something like "getCurrentMobileDeviceID()" to do something like this:

local recp = fibaro:getCurrentMobileDeviceID();

fibaro:call(recp, "sendPush", "Alarm set, have fun!");

any idea?

thx

7 answers to this question

Recommended Posts

  • 0
Posted

Please login or register to see this code.

how to check wich one is current? you can have few in that same time

  • 0
Posted

Not fool proof, but last sent command perhaps?

  • 0
Posted

dhanjel, it send "command" only on action so

you got 2 iphones and you dont have any info till you decide to turn ON light for example so that method is not the best

  • 0
Posted

(don't have an iphone so don't know) but if there is something like tasker on android you could to set a global variable about which iphone is active everytime the phone's screen comes on...

  • 0
  • Inquirer
  • Posted

    right now, you do not have any feedback on the iphone app when you start a scene) - no icon is changed or highlighting is coming up. so basically, the user does not know IF he has hit the button or not. if you tap on a switch you know by the icon change that it worked but not when you activate a scene - maybe this changes in the new iOS-app?.

    So the idea is to send a push message to the user who just activated the scene... thats what I am trying to achivee...

    • 0
    Posted

    totally agree with dcspock

    • 0
    Posted

    I use virtual devices to switch scenes, when i push the button on a virtual device then change the icon or the label and i have a virtuell feedback

    Please login or register to see this image.

    /emoticons/default_icon_mrgreen.gif" alt=":mrgreen:" />

    Join the conversation

    You can post now and register later. If you have an account, sign in now to post with your account.

    Guest
    Answer this question...

    ×   Pasted as rich text.   Paste as plain text instead

      Only 75 emoji are allowed.

    ×   Your link has been automatically embedded.   Display as a link instead

    ×   Your previous content has been restored.   Clear editor

    ×   You cannot paste images directly. Upload or insert images from URL.

    ×
    ×
    • Create New...