Announcement

Collapse
No announcement yet.

PHLocation V2 Feature requests

Collapse
This is a sticky topic.
X
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • #16
    It's a particle electron with their asset tracker add on board. I have the code on GitHub here.

    Comment


    • #17
      Originally posted by mitchmitchell1616 View Post
      It's a particle electron with their asset tracker add on board. I have the code on GitHub here.
      Cool, thanks. I have an Electron kicking around that I was thinking of using for that. Need to add solar panels to the trailer first though.
      HS 3.0.0.531: 1985 Devices 1128 Events
      Z-Wave 3.0.1.260: 122 Nodes on one Z-Net

      Comment


      • #18
        If you want to see the node-red code let me know, I've not figured out how to share that code on github yet.

        Comment


        • #19
          Originally posted by mitchmitchell1616 View Post
          If you want to see the node-red code let me know, I've not figured out how to share that code on github yet.
          Thanks, are you sending data directly to HS with it, or through node-red?
          HS 3.0.0.531: 1985 Devices 1128 Events
          Z-Wave 3.0.1.260: 122 Nodes on one Z-Net

          Comment


          • #20
            I have a fairly complex flow in Node Red that does things like text me via Twilio and speak through our Google Home Mini if something changes, but I could have used Particle webhooks to send the location data to HS, it was just easier to pull it out of Node Red since I am fairly conversant in that app.

            Comment


            • #21
              Originally posted by mitchmitchell1616 View Post
              I have a fairly complex flow in Node Red that does things like text me via Twilio and speak through our Google Home Mini if something changes, but I could have used Particle webhooks to send the location data to HS, it was just easier to pull it out of Node Red since I am fairly conversant in that app.
              Got it, thanks. I'll try the direct to HS route first.
              HS 3.0.0.531: 1985 Devices 1128 Events
              Z-Wave 3.0.1.260: 122 Nodes on one Z-Net

              Comment


              • #22
                Not related to previous posts, but it would be great to see the static maps feature back in PHL2 when possible Paul. Just current locations of all users, maybe last 24h (or configurable) history of each users if its a simple addition. i use the images to create a video feed so i can display them on BlueIris NVR software along with other IP cams and weather radar streams.

                Comment


                • #23
                  Originally posted by mikesnook View Post
                  Not related to previous posts, but it would be great to see the static maps feature back in PHL2 when possible Paul. Just current locations of all users, maybe last 24h (or configurable) history of each users if its a simple addition. i use the images to create a video feed so i can display them on BlueIris NVR software along with other IP cams and weather radar streams.
                  I'm working on static maps today. Initially this will only be available as an event action and will only work with Google and Mapquest providers. This will save me a lot of work adding extra controls to the GUI to cater for static maps until we see how it goes.

                  Would you be willing to test a version with static maps?

                  Paul..

                  Comment


                  • #24
                    Originally posted by sooty View Post

                    I'm working on static maps today. Initially this will only be available as an event action and will only work with Google and Mapquest providers. This will save me a lot of work adding extra controls to the GUI to cater for static maps until we see how it goes.

                    Would you be willing to test a version with static maps?

                    Paul..
                    Hi Paul,
                    That sounds good, sure I can test it out, I chucked this together to keep me going, so its really not urgent if you have other code to write.

                    Code:
                    Sub Main(parm as object)
                    
                    'Triggered by location changes on either PHLocation2 user.
                    
                    Dim strAllUsersMapURLPathString, strMapURLHostString, MikeLatLongStr, WifeLatLongStr, GoogleAPIKey, StrImageSize, GetStatusStr, strUserMikeMapURLPathString, strUserWifeMapURLPathString
                    
                    GoogleAPIKey = "<APIKEY>"
                    StrImageSize = "640x360"
                    
                    MikeLatLongStr = hs.DeviceValueEx(4285) & "," & hs.DeviceValueEx(4286)
                    WifeLatLongStr = hs.DeviceValueEx(4308) & "," & hs.DeviceValueEx(4309)
                    
                    strMapURLHostString = "https://maps.googleapis.com"
                    strAllUsersMapURLPathString = "/maps/api/staticmap?size=" & StrImageSize & "&maptype=roadmap&markers=color:blue%7Clabel:M%7C" & MikeLatLongStr  & "&markers=color:pink%7Clabel:E%7C" & WifeLatLongStr & "&key=" & GoogleAPIKey
                    strUserMikeMapURLPathString = "/maps/api/staticmap?size=" & StrImageSize & "&maptype=roadmap&markers=color:blue%7Clabel:M%7C" & MikeLatLongStr & "&key=" & GoogleAPIKey
                    strUserWifeMapURLPathString = "/maps/api/staticmap?size=" & StrImageSize & "&maptype=roadmap&markers=color:pink%7Clabel:E%7C" & WifeLatLongStr & "&key=" & GoogleAPIKey
                    
                    'Download Images
                    hs.GetURLImage(strMapURLHostString,strAllUsersMapURLPathString, TRUE, 443, "/html/PHLocation2/Maps/Scripted-AllUsers.png")
                    hs.GetURLImage(strMapURLHostString,strUserMikeMapURLPathString, TRUE, 443, "/html/PHLocation2/Maps/Scripted-UsersMike.png")
                    hs.GetURLImage(strMapURLHostString,strUserWifeMapURLPathString, TRUE, 443, "/html/PHLocation2/Maps/Scripted-UsersWife.png")
                    
                    End Sub

                    Thanks,
                    Mike


                    Comment


                    • #25
                      Originally posted by mikesnook View Post

                      Hi Paul,
                      That sounds good, sure I can test it out, I chucked this together to keep me going, so its really not urgent if you have other code to write.

                      Code:
                      Sub Main(parm as object)
                      
                      'Triggered by location changes on either PHLocation2 user.
                      
                      Dim strAllUsersMapURLPathString, strMapURLHostString, MikeLatLongStr, WifeLatLongStr, GoogleAPIKey, StrImageSize, GetStatusStr, strUserMikeMapURLPathString, strUserWifeMapURLPathString
                      
                      GoogleAPIKey = "<APIKEY>"
                      StrImageSize = "640x360"
                      
                      MikeLatLongStr = hs.DeviceValueEx(4285) & "," & hs.DeviceValueEx(4286)
                      WifeLatLongStr = hs.DeviceValueEx(4308) & "," & hs.DeviceValueEx(4309)
                      
                      strMapURLHostString = "https://maps.googleapis.com"
                      strAllUsersMapURLPathString = "/maps/api/staticmap?size=" & StrImageSize & "&maptype=roadmap&markers=color:blue%7Clabel:M%7C" & MikeLatLongStr & "&markers=color:pink%7Clabel:E%7C" & WifeLatLongStr & "&key=" & GoogleAPIKey
                      strUserMikeMapURLPathString = "/maps/api/staticmap?size=" & StrImageSize & "&maptype=roadmap&markers=color:blue%7Clabel:M%7C" & MikeLatLongStr & "&key=" & GoogleAPIKey
                      strUserWifeMapURLPathString = "/maps/api/staticmap?size=" & StrImageSize & "&maptype=roadmap&markers=color:pink%7Clabel:E%7C" & WifeLatLongStr & "&key=" & GoogleAPIKey
                      
                      'Download Images
                      hs.GetURLImage(strMapURLHostString,strAllUsersMapURLPathString, TRUE, 443, "/html/PHLocation2/Maps/Scripted-AllUsers.png")
                      hs.GetURLImage(strMapURLHostString,strUserMikeMapURLPathString, TRUE, 443, "/html/PHLocation2/Maps/Scripted-UsersMike.png")
                      hs.GetURLImage(strMapURLHostString,strUserWifeMapURLPathString, TRUE, 443, "/html/PHLocation2/Maps/Scripted-UsersWife.png")
                      
                      End Sub

                      Thanks,
                      Mike

                      I'm pretty much committed to it now and should have something "testable" later today or perhaps tomorrow.

                      For now it will be an event action similar to the current one for dynamic maps so you can do single or multiple users current location or single user history.

                      Paul..

                      Comment


                      • #26
                        Originally posted by mikesnook View Post
                        Not related to previous posts, but it would be great to see the static maps feature back in PHL2 when possible Paul. Just current locations of all users, maybe last 24h (or configurable) history of each users if its a simple addition. i use the images to create a video feed so i can display them on BlueIris NVR software along with other IP cams and weather radar streams.
                        Mike, Is it possible to share how you are "video feeding" the static images to BlueIris? Mike
                        Computer: CUK Intel NUC7i7BNH
                        Op System: Windows 10 Pro - Work Station
                        HS Version: HS3 Pro Edition 3.0.0.435

                        Plug-Ins: BLBackup, BLGData, BLRoombaWifi, Device History, EasyTrigger, ImperiHome, Nest, PHLocation, Pushover 3P, Restart, Sonos, UltraCID3, UltraWeatherWU3, Z-Wave, and Jon00 scripts.

                        Comment


                        • #27
                          Originally posted by MNB View Post

                          Mike, Is it possible to share how you are "video feeding" the static images to BlueIris? Mike
                          Sure Mike, for the maps i created a network IP camera in BI with the following settings:

                          Address: https://homeseerServer.domain.com
                          Make: Generic/Onvif
                          Model: JPEG,GIF etc. Image requests
                          Path: /PHLocation2/Maps/Scripted-AllUsers.png
                          Camera: 0
                          Set the max framerate to 6 seconds
                          Media/Video Port: 443

                          PS For the weather radar, i download images from NWS and create a live stream from hundreds of images using ffmpeg and the Ngix RTMP streaming server to receive the stream.

                          There was a how-to on the old HS forum.... :-(

                          Thanks,
                          Mike


                          Comment


                          • #28
                            Thank-you sir! As I'm awaiting the "Polar Vortex" to arrive this afternoon it gives me some time to play with HS... Mike
                            Computer: CUK Intel NUC7i7BNH
                            Op System: Windows 10 Pro - Work Station
                            HS Version: HS3 Pro Edition 3.0.0.435

                            Plug-Ins: BLBackup, BLGData, BLRoombaWifi, Device History, EasyTrigger, ImperiHome, Nest, PHLocation, Pushover 3P, Restart, Sonos, UltraCID3, UltraWeatherWU3, Z-Wave, and Jon00 scripts.

                            Comment


                            • #29
                              Originally posted by MNB View Post
                              Thank-you sir! As I'm awaiting the "Polar Vortex" to arrive this afternoon it gives me some time to play with HS... Mike
                              No problem, lol same down here

                              Comment


                              • #30
                                MIke I pared down you script to only include AllUsers and UsesMike and am using my PH2 Lat/Log from my iPhone... but I'm not seeing any new png file nor is my BI showing a image. I had set up an event that would trigger on Location change, but when I do a manual RUN of the event (should bypass the trigger and only run the script) looking at my HS3 Log I see the event followed with the script executing without any errors but no PNG or BlueIris image being displayed, am I missing something?
                                Computer: CUK Intel NUC7i7BNH
                                Op System: Windows 10 Pro - Work Station
                                HS Version: HS3 Pro Edition 3.0.0.435

                                Plug-Ins: BLBackup, BLGData, BLRoombaWifi, Device History, EasyTrigger, ImperiHome, Nest, PHLocation, Pushover 3P, Restart, Sonos, UltraCID3, UltraWeatherWU3, Z-Wave, and Jon00 scripts.

                                Comment

                                Working...
                                X