TRIGGERcmd
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Register
    • Login
    1. Home
    2. Popular
    Log in to post
    • All Time
    • Day
    • Week
    • Month
    • All Topics
    • New Topics
    • Watched Topics
    • Unreplied Topics
    • All categories
    • Antonio Francisco S.SantosA

      Tentando Executar um Script python no terminal LX com o TriggerCMD mas não estou conseguindo

      Raspberry Pi
      • • • Antonio Francisco S.Santos
      80
      0
      Votes
      80
      Posts
      5.0k
      Views

      Antonio Francisco S.SantosA

      @Antonio-Francisco-S-Santos Desculpe, O Código que me refiro é esse aqui:

      #!/usr/bin/python3

      coding=utf8

      import sys
      import time
      import math
      import hiwonder.Mpu6050 as Mpu6050
      import hiwonder.ActionGroupControl as AGC
      import hiwonder.Board as Board

      mpu = Mpu6050.mpu6050(0x68)#启动Mpu6050
      mpu.set_gyro_range(mpu.GYRO_RANGE_2000DEG)#设置Mpu6050的陀螺仪的工作范围
      mpu.set_accel_range(mpu.ACCEL_RANGE_2G)#设置Mpu6050的加速度计的工作范围

      count1 = 0
      count2 = 0

      def standup():
      global count1, count2

      try: accel_date = mpu.get_accel_data(g=True) #获取传感器值 angle_y = int(math.degrees(math.atan2(accel_date['y'], accel_date['z']))) #将获得的数据转化为角度值 if abs(angle_y) > 105: #y轴角度大于160,count1加1,否则清零 count1 += 1 else: count1 = 0 if abs(angle_y) < 85: #y轴角度小于10,count2加1,否则清零 count2 += 1 else: count2 = 0 time.sleep(0.1) if count1 >= 1: #往前倒了一定时间后起来 count1 = 0 print("equilibrio_1!")#打印执行的动作名 AGC.runActionGroup('equilibrio_1')#执行动作 Board.setPWMServoPulse(1, 1300, 700) Board.setPWMServoPulse(2, 1500, 700) time.sleep(0.8) AGC.runActionGroup('stand') elif count2 >= 1: #往后倒了一定时间后起来 count2 = 0 print("equilibrio_2!")#打印执行的动作名 AGC.runActionGroup('equilibrio_2')#执行动作 Board.setPWMServoPulse(1, 1500, 700) Board.setPWMServoPulse(2, 1500, 700) time.sleep(0.8) AGC.runActionGroup('stand') except BaseException as e: print(e)

      if name == 'main':
      print("Fall_and_Stand Init")
      print("Fall_and_Stand Start")
      while True : #循环检测机器人的状态
      standup()
      key = time.sleep(0.1)
      if key == 27:
      break

    • RussR

      New SmartThings integration (2023)

      Announcements
      • smartthings • • Russ
      43
      0
      Votes
      43
      Posts
      5.0k
      Views

      RussR

      @Irfan-Khan-0, I just tested it an it's working for me.

      Could you try clicking the "Regenerate" button to regenerate the Client ID and Client Secret under App credentials, then copy/paste those into your user profile?

      And make sure the "SmartThings Device Cloud Credentials Client ID" values (starts with st-) and the "SmartThings Device Cloud Credentials Client Secret" value match those values under App Details?

      If those 4 values match, and you have these URL's setup, it should work:
      Authorization URI: https://www.triggercmd.com/oauth/authorize
      Token URI: https://www.triggercmd.com/oauth/token

    • RussR

      Raspberry Pi setup

      Raspberry Pi
      • raspberry pi • • Russ
      40
      0
      Votes
      40
      Posts
      17.8k
      Views

      Jorge FuentesJ

      That's brilliant, thank you for the information.

    • RussR

      Press the Down Arrow key (or any other key)

      Windows
      • • • Russ
      40
      1
      Votes
      40
      Posts
      13.9k
      Views

      A

      @marcos-ibarra
      I'm not into AU3 that much (while knowing AHK better), what about triggering OBS's Control(s) directly, instead of Send(ing) a key in a less reliable way?

      https://www.autoitscript.com/autoit3/docs/functions/ControlCommand.htm

      That way the window wouldn't even have to be active, only existing!

    • D

      Open Specific Netflix Movie with Alexa

      Windows
      • • • dlaugh14
      40
      0
      Votes
      40
      Posts
      9.5k
      Views

      RussR

      @Nico-Ramirez, Google Translate translated what you said to this:
      Question, I use python, when I make sure that the argument is empty, could you help me with what serious or problem, please

      I'm not sure what the problem is. Please clarify.

    • ?

      TRIGGERcmd not starting at boot

      General Discussion
      • • • A Former User
      40
      1
      Votes
      40
      Posts
      3.2k
      Views

      RussR

      Thanks @trinib, and thank you for reporting the problem. I should be able to reproduce it and fix it in the next version. I thought I had it fixed but apparently not.

      EDIT: I confirmed if the agent starts and can't access the Internet, it closes. It should keep trying to connect, so I'll fix this soon.

    • ?

      Google home and TriggerCMD stop working when Google home is set to French

      General Discussion
      • • • A Former User
      39
      0
      Votes
      39
      Posts
      11.7k
      Views

      RussR

      @buaamm, so far I've added Japanese support for TRIGGERcmd Smart Home - both Alexa and Google Assistant.

      Would you mind testing? Please tell me if I got anything wrong.

    • RussR

      SmartThings integration - flip a virtual switch to run a command

      Instructions
      • • • Russ
      38
      0
      Votes
      38
      Posts
      18.2k
      Views

      JTJ

      @Russ thanks for coming up with a solution so quickly. I followed your instructions and I am up and running again! 👍

    • B

      Alexa doesn't find the commands

      General Discussion
      • • • buzz
      36
      0
      Votes
      36
      Posts
      7.5k
      Views

      RussR

      @Eduardo-Henrique, I tried all of those characters and I could not get it to break.

      So maybe that was not the problem. Can you send me the computer name you were using when it wasn't working?

    • Matt PackwoodM

      Freezing in Monterey

      Mac
      • • • Matt Packwood
      35
      0
      Votes
      35
      Posts
      3.2k
      Views

      Matt PackwoodM

      @russ I saw that, many thanks!

    • RussR

      Autohotkey script for Play, Pause, Volume Up/Down, Next/Previous

      Windows
      • • • Russ
      34
      2
      Votes
      34
      Posts
      24.0k
      Views

      RussR

      @William-Santiago-Ortiz-Trejos, for some reason your files with a .ahk extension aren't associated with AutoHotkey. That's supposed to happen when you install it, but maybe an antivirus program blocked it?

      To fix it you could try running the batch file in this article from your C:\Program Files\AutoHotkey folder:
      https://www.autohotkey.com/board/topic/13627-no-ahk-file-association/

    • J

      Linux VM - TriggerCMD shows messages like it's working, but commands don't actually execute

      General Discussion
      • • • Joe
      33
      0
      Votes
      33
      Posts
      2.7k
      Views

      RussR

      @Joe,

      1 - Only Foreground Triggers work in a user's regular account - because the background service only runs as root and uses /root/.TRIGGERcmdData.

      2 - Root can support both Foreground and Background Triggers - because you can install the background service (see #1), and because you can login as root and run the agent in foreground mode.

      3 - But running Triggers as Root will mask/override all the Triggers in your regular account - I wouldn't say mask/override, it's just separate as you covered in #4. Running the agent as root will create another separate computer entry in your account associated with /root/.TRIGGERcmdData. That computer will be named the same initially, but you could rename it.

      4 - The exception to (3) is if you can instantiate two "Computers" -- one pointing to Root for the "Background", and a separate "Computer" pointing to your normal Linux account to support the "Foreground" - correct, although as you pointed out in #2, you could also run the foreground agent as root.

      You create a separate computer just by running the agent as the other user. If the ~/.TRIGGERcmdData directory doesn't exist, the agent will prompt you for a token, create a computer record in your account, and store the ID for that computer in the computerid.cfg file.

      Different Linux accounts could setup different computer records, or you could give everyone sudo access to be able to edit /root/.TRIGGERcmdData/commands.json to run background command via the background agent.

      The agent stores the .TRIGGERcmdData directory in the home folder of the user running the agent. The files in that directory are the key point of connection to the mother ship.

      Good questions @Joe.

    • Steve PorterS

      Command format on Raspi

      Raspberry Pi
      • • • Steve Porter
      32
      0
      Votes
      32
      Posts
      2.9k
      Views

      tuicemenT

      @steve-porter yep that will mess things up. I remember reading another post about that so that isn't something that you alone have experienced. I found a couple times the file didn't update for me for different errors in command lines.
      I've gotten into the habit of double checking if it saves.

    • Frank MalczewskiF

      Customer Support? TRIGGERcmdAgent keeps stopping

      General Discussion
      • • • Frank Malczewski
      30
      0
      Votes
      30
      Posts
      1.8k
      Views

      RussR

      @Frank-Malczewski, thanks for letting me know. Sorry that's necessary but I'm glad it's working for you. I've seen those extra tray icons before - the icon doesn't get removed when you kill the agent without using the Quit function.

    • F

      No puedo conectar a triggercmd desde google homa

      General Discussion
      • • • Fernando Mateos
      29
      0
      Votes
      29
      Posts
      7.0k
      Views

      Roberto OteroR

      @Russ Thank u Ross.

    • RussR

      How to use Off Command

      Instructions
      • • • Russ
      28
      0
      Votes
      28
      Posts
      49.0k
      Views

      RussR

      @Xander, there's no official x86 TRIGGERcmd agent version. If you updated agent.js, you've got the latest functionality.

    • Luiz Henrique Dela GiustinaL

      Problem: Run Call Of Duty Warzone

      Windows
      • • • Luiz Henrique Dela Giustina
      28
      0
      Votes
      28
      Posts
      2.8k
      Views

      Marcos BarquetM

      @Arthur-Oscar could you share the files again, thanks!

    • N

      ahcmd.exe problem

      General Discussion
      • • • newstuffoldstuff
      28
      0
      Votes
      28
      Posts
      3.0k
      Views

      RussR

      @newstuffoldstuff, I see. If you want to avoid reducing your User Access Control setting, you could try installing the background service and running it as a background command. It will run as Local System.

    • Tiago MártiresT

      Boot on Arch

      General Discussion
      • • • Tiago Mártires
      27
      0
      Votes
      27
      Posts
      2.7k
      Views

      Gustavo SoaresG

      @Russ, very good. I think applying a decode('utf-8') should solve this problem. I really hadn't tried using special characters yet.

    • RussR

      How to use IFTTT with TRIGGERcmd

      Instructions
      • • • Russ
      25
      0
      Votes
      25
      Posts
      23.8k
      Views

      RussR

      @Mittal-Makwana, nice, what command does that?