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

GPS Tracking HC2 and iOS App question to Fibaro developers.


Alex Rob

Question

Hello,

 

i red about this function in many places in this forum. I also used google. 

It looks like there is a lot of issues in HC2 for gps tracking 

 

i got 2 users and one super user. Even I make block scenes as explained I can’t trigger scene by tracking of gps location.

family panel did not show up even I activated tracking on all devices within 1 min.

if I trigger scene manually it works. 

I see on android Fibaro app u can do adjustment of tracking range by gps location. This function is not on the iPhone app. Can Fibaro fix this? Do improvements on HC2 for get a better gos tracking function?

 

 

 

 

 

 

 

 

Please login or register to see this attachment.

Please login or register to see this attachment.

Please login or register to see this attachment.

Please login or register to see this attachment.

Please login or register to see this attachment.

Please login or register to see this attachment.

Edited by Alex Rob
Link to comment
Share on other sites

  • Answers 99
  • Created
  • Last Reply

Top Posters For This Question

Top Posters For This Question

Posted Images

Recommended Posts

  • 0

Hi. 

 

I have done a similar thing but not using the Fibaro app

 

I've done this using find friends on iOS and life360 which works on iOS and android

 

You might like to have a look

Please login or register to see this link.

 

I’m happy to help if you get stuck.

 

Ian

 

 

Link to comment
Share on other sites

  • 0

Interesting... for me it  works  (LUA code) and I have two Android and three iPhone users....

Probably stupid question, but did you set location permission on iPhone for fibaro app.?

 

 

Link to comment
Share on other sites

  • 0
  • Inquirer
  • Yes I did, maybe I should change to lua code ? The block scenes looks right ?

    Edited by Alex Rob
    Link to comment
    Share on other sites

    • 0
  • Inquirer
  • i konvertet the blocks to lua and even then there is no function. if i trigger scene manually everythings works, so i see that it stops by the GPS tracking.

     

    --[[
    %% autostart
    %% properties
    295 Location
    %% weather
    %% events
    %% globals
    --]]

    local startSource = fibaro:getSourceTrigger();
    if (
     ( (fibaro:calculateDistance(fibaro:getValue(295, "Location"), "68;15") <= 2500 and fibaro:calculateDistance(fibaro:getValue(295, "PreviousLocation"), "68;15") > 2500) )
    or
    startSource["type"] == "other"
    )
    then
        fibaro:call(45, "setValue", "85");
        fibaro:call(50, "setValue", "85");
        fibaro:call(55, "setValue", "85");
        setTimeout(function()
            fibaro:call(45, "setValue", "3");
        fibaro:call(50, "setValue", "3");
        fibaro:call(55, "setValue", "3");
        end, 600000)
    end

     

     

    and android user:

     

    --[[
    %% autostart
    %% properties
    298 Location
    %% weather
    %% events
    %% globals
    --]]

    local startSource = fibaro:getSourceTrigger();
    if (
     ( (fibaro:calculateDistance(fibaro:getValue(298, "Location"), "68;15") <= 4000 and fibaro:calculateDistance(fibaro:getValue(298, "PreviousLocation"), "68;15") > 4000) )
    or
    startSource["type"] == "other"
    )
    then
        fibaro:call(45, "setValue", "85");
        fibaro:call(50, "setValue", "85");
        fibaro:call(55, "setValue", "85");
        fibaro:call(298, "sendDefinedEmailNotification", "4");
        setTimeout(function()
            fibaro:call(45, "setValue", "2");
        fibaro:call(50, "setValue", "2");
        fibaro:call(55, "setValue", "2");
        end, 600000)
    end

     

    Link to comment
    Share on other sites

    • 0

    I believe that you set " How frequently GPS position from the user's iPhone should be collected? "  to some value and Run scene is  Automatic.

    Since you have condition     startSource["type"] == "other" that's what executes the scene manually, but it doesn't mean anything.

    What I think that  the scene is triggered as required, but your coordinates in condition

    if (
     ( (fibaro:calculateDistance(fibaro:getValue(295, "Location"), "68;15") <= 2500 and fibaro:calculateDistance(fibaro:getValue(295, "PreviousLocation"), "68;15") > 2500) )

    are  not correct... are your sure about longitude and latitude?

    Have checked your coordinates and it points to the sea ( near to Norway)

    Please login or register to see this attachment.

     

    Since you already have LUA code, please correct the coordinates exactly to your location.

    If in the future if you'll use block scene please correct the coordinates at location panel as well

    Just to make sure that the scene works, please add follow line to your code (marked blue)

     

    local startSource = fibaro:getSourceTrigger();

    fibaro:debug(fibaro:getValue(295, "Location"))
    if (
     ( (fibaro:calculateDistance(fibaro:getValue(295, "Location"), "68;15") <= 2500 and fibaro:calculateDistance(fibaro:getValue(295, "PreviousLocation"), "68;15") > 2500) )
    or
    startSource["type"] == "other"
    )

    Run the scene a while and when the scene will triggered by user location, you will see user' coordinates, which approximately should be used by you in code.

    Add same debug line to second scene as well.

    Let me know if it helps

    By the way you can merge both scenes to one scene only.

    Link to comment
    Share on other sites

    • 0
  • Inquirer
  • Hello, thanks for your help.

    i thought I got the right location set, I pointed out from a map directly. as U see on the picture it should be right.

    i got a frequently pos poll about 1 min since I did not manage to work I use 5 min.

    so If i transfer block scenes to lua should they not be right Changed.

    can u also merge both scene as block scene? I just started with Fibaro so I’m not good at lua code. 

     

    I will do the fixes and see if this is working but unsure why the location is pointing into the see. 

    Please login or register to see this attachment.

    Please login or register to see this attachment.

    Edited by Alex Rob
    Link to comment
    Share on other sites

    • 0

    Ok... let me know if it works after coordinates correction and I'll help you to merge the scenes

    Link to comment
    Share on other sites

    • 0
  • Inquirer
  • i will try to use block scenes but i check if the lua code got the right coordinates, as u see below it looks good now. will leave for work tomorrow so i will se if i get a email and light is triggered.

     

    --[[
    %% autostart
    %% properties
    2 Location
    %% weather
    %% events
    %% globals
    --]]

    local startSource = fibaro:getSourceTrigger();
    if (
     ( (fibaro:calculateDistance(fibaro:getValue(2, "Location"), "68.63000761962243;15.587984091824296") <= 3000 and fibaro:calculateDistance(fibaro:getValue(2, "PreviousLocation"), "68.63000761962243;15.587984091824296") > 3000) )
    or
    startSource["type"] == "other"
    )
    then
        fibaro:call(50, "setValue", "90");
        fibaro:call(55, "setValue", "90");
        fibaro:call(154, "setValue", "60");
        fibaro:call(2, "sendDefinedEmailNotification", "4");
        setTimeout(function()
            fibaro:call(50, "setValue", "2");
        fibaro:call(55, "setValue", "2");
        end, 900000)
    end

     

    Link to comment
    Share on other sites

    • 0

    You need to have this section up and running first I think...

    Please login or register to see this image.

    /monthly_2018_12/image.png.7b44815318d1a701a0a8240eaadca0f2.png" alt="image.png.7b44815318d1a701a0a8240eaadca0f2.png" />

    Link to comment
    Share on other sites

    • 0
  • Inquirer
  • i try to get this but dont know how i can get access to it.

    I innstalled to phones one with i phone and one with android gps signal will be transmitted each 5 min, and in phone settings is location always active and the app goes not in sleep modus i set this on on too. But still i dont see family panel

    Link to comment
    Share on other sites

    • 0

    By the way... few days ago I have updated the system to 4.520.

    Looks like GPS doen't work at all on this release. Have reported to Fibaro.

    So if you're using 4.520 version it might be that GPS tracking won't work for you.

    Link to comment
    Share on other sites

    • 0
  • Inquirer
  • Hello, 

     

    thanks for this information, so I don’t need to waste my time on this since it does not work. Strange they Fibaro support did not mentioned anything about it..... 

     

    still I did not got it work 

    Link to comment
    Share on other sites

    • 0

    Stop using this, even if it works (I had it working) i drains your battery very very fast (because of bad implementation)

    Link to comment
    Share on other sites

    • 0

    @cag014, did you receive any updates from the Fibaro on GPS issues with 4.520? With this update I also cannot get the GeoLocation and family locations working (in fact no GPS data responses from the mobiles at all.)

    Link to comment
    Share on other sites

    • 0

    No... no answer yet from Fibaro.

    Is there anyone that can provide an update on GPS tracking with 4.521 beta release? Is it work?

    Link to comment
    Share on other sites

    • 0
  • Inquirer
  • I sent a mail to Fibaro support and they should look into it. 

    So i hope they do a fast fix otherwise I will be disappointed that they don’t set a priority on this,. If they don’t invest so much time in home center 2 could be rather better and choose a different hub instead. 

    Link to comment
    Share on other sites

    • 0

    FYI,

      GPS back and works as usual on 4.530.

    Link to comment
    Share on other sites

    • 0

    Hi @cag014,

     

    I try almost everything, and I never see in HC2 to get the location  from mobile (doesn't matter android or  ios)

    if you suggest anything, I'm ready to try.

     

    thanks

    Link to comment
    Share on other sites

    • 0

    As I understand you've set your users to send GPS location every few minutes, right?

    Now, where you're trying to see in HC2 the GPS data?

    Link to comment
    Share on other sites

    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...