TRIGGERcmd
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Register
    • Login
    1. Home
    2. hm123
    H
    • Profile
    • Following 0
    • Followers 0
    • Topics 2
    • Posts 3
    • Best 1
    • Controversial 0
    • Groups 0

    hm123

    @hm123

    1
    Reputation
    38
    Profile views
    3
    Posts
    0
    Followers
    0
    Following
    Joined Last Online

    hm123 Unfollow Follow

    Best posts made by hm123

    • Google assistant say the Raspberry Pi temperature

      I put my Rasberry Pi in a handmade box and I am concerned about it's temperature. So I created this trigger to be able to check the Pi temperature using google assistant.

      {"trigger":"Pi temperature","command":"python3 /home/pi/temperature.py","ground":"background","voice":"system temperature","voiceReply":"The pi temperature is {{result}} degrees","allowParams": "false"}
      

      The Python3 script

      #!/usr/bin/env python3
      
      import subprocess
      import os
      
      reply = str(subprocess.check_output(['vcgencmd', 'measure_temp']))
      result = reply[reply.find('=') + 1: reply.find('C')- 1]
      os.system('~/.TRIGGERcmdData/sendresult.sh ' + result)
      
      posted in Raspberry Pi
      H
      hm123

    Latest posts made by hm123

    • Google assistant say the Raspberry Pi temperature

      I put my Rasberry Pi in a handmade box and I am concerned about it's temperature. So I created this trigger to be able to check the Pi temperature using google assistant.

      {"trigger":"Pi temperature","command":"python3 /home/pi/temperature.py","ground":"background","voice":"system temperature","voiceReply":"The pi temperature is {{result}} degrees","allowParams": "false"}
      

      The Python3 script

      #!/usr/bin/env python3
      
      import subprocess
      import os
      
      reply = str(subprocess.check_output(['vcgencmd', 'measure_temp']))
      result = reply[reply.find('=') + 1: reply.find('C')- 1]
      os.system('~/.TRIGGERcmdData/sendresult.sh ' + result)
      
      posted in Raspberry Pi
      H
      hm123
    • RE: foreground triggers not working

      Obviously I can not run GUI programs as root. Background triggers work fine and do the job anyway. Thank you

      posted in General Discussion
      H
      hm123
    • foreground triggers not working

      Raspberry Pi 4 with Raspbian Buster. Installed Triggercmd following the instructions. Background trigger "reboot" works fine but the foreground are not. Like this one working when I try it in terminal, but not working triggered by Triggercmd:

      {"trigger":"Gnome Editor","command":"gedit","ground":"foreground","voice":"edit","allowParams": "false"}

      I am new to linux so I may me missing something

      posted in General Discussion
      H
      hm123