# Alexa 'On Device Activity' not working

**URL:** <https://discourse.nodered.org/t/alexa-on-device-activity-not-working/80901>\
**Category:** General\
**Created:** [30 August 2023 08:33 UTC](https://discourse.nodered.org/t/alexa-on-device-activity-not-working/80901 "2023-08-30T08:33:53Z")\
**Posts on this page:** 14\
**Page:** 11

<div class="post-metadata">

**Author:** ![xx\_Nexus\_xx](https://avatars.discourse-cdn.com/v4/letter/x/54ee81/32.png) [@xx\_Nexus\_xx](https://discourse.nodered.org/u/xx_Nexus_xx)\
**Post date:** [2 April 2024 22:20 UTC](https://discourse.nodered.org/t/alexa-on-device-activity-not-working/80901/204 "2024-04-02T22:20:51Z")

</div>

I moved away from Alexa and have migrated over to SIRI 😉 ... the [homebridge](https://flows.nodered.org/node/node-red-contrib-homekit-bridged) node works great for me to manage all my devices in the house with voice commands ... and again ... all local .. no cloud 😉

negative side ... i have lots of alexa devices in my drawer ☹

---

<div class="post-metadata">

**Author:** ![dynamicdave](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/dynamicdave/32/96_2.png) [@dynamicdave](https://discourse.nodered.org/u/dynamicdave)\
**Post date:** [3 April 2024 06:16 UTC](https://discourse.nodered.org/t/alexa-on-device-activity-not-working/80901/205 "2024-04-03T06:16:29Z")

</div>

> [@Sean-McG](#):
>
> I have used a virtual light, then I can monitor on the same topic, but use 100 different brightness levels for different commands.

Thanks Sean for this creative idea - so simple, so effective and so very clever.

---

<div class="post-metadata">

**Author:** ![dynamicdave](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/dynamicdave/32/96_2.png) [@dynamicdave](https://discourse.nodered.org/u/dynamicdave)\
**Post date:** [3 April 2024 07:43 UTC](https://discourse.nodered.org/t/alexa-on-device-activity-not-working/80901/206 "2024-04-03T07:43:18Z")

</div>

Hi Sean,  
Just taking your creative idea a stage further with two virtual dimmable lights (using your technique).

 ![VSH_C](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/5/f/5fec2144c5051a0dda9c9823066e7fcfb92f6972.png)  
The 'Command' VSH node deals with commands like "turn on, turn off laser" etc.  
Now for the clever bit.  
The 'Location' VSH node will set a variable from words like... "I'm in the kitchen", "I'm in the lounge" or just "kitchen" or "lounge". Then I should be able to send a string to the appropriate Echo device.

 ![VSH_D](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/f/a/faa8c84387e1101642c59364e545ddf7354f41be.png)

I had to set the increments to 5-steps as my eyesight and fingers let me down (old age thing) when trying to set the brightness levels in the Alexa app.

The above flow will direct my weather report to the appropriate Alexa device.

---

<div class="post-metadata">

**Author:** ![Sean-McG](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/sean-mcg/32/54677_2.png) [@Sean-McG](https://discourse.nodered.org/u/Sean-McG)\
**Post date:** [3 April 2024 10:22 UTC](https://discourse.nodered.org/t/alexa-on-device-activity-not-working/80901/207 "2024-04-03T10:22:21Z")

</div>

> [@xx\_Nexus\_xx](#):
>
> negative side ... i have lots of alexa devices in my drawer ☹

It sounds like @dynamicdave might need them he only has 8 😉

---

<div class="post-metadata">

**Author:** ![Sean-McG](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/sean-mcg/32/54677_2.png) [@Sean-McG](https://discourse.nodered.org/u/Sean-McG)\
**Post date:** [3 April 2024 10:32 UTC](https://discourse.nodered.org/t/alexa-on-device-activity-not-working/80901/208 "2024-04-03T10:32:55Z")

</div>

> [@dynamicdave](#):
>
> If I ask one of them to turn On/Off

I meant that some of your topics look like Tasmota devices, (not sure if this was just for testing), but you do know that they can work **directly** with Alex without a virtual node ?

---

<div class="post-metadata">

**Author:** ![dynamicdave](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/dynamicdave/32/96_2.png) [@dynamicdave](https://discourse.nodered.org/u/dynamicdave)\
**Post date:** [6 April 2024 16:50 UTC](https://discourse.nodered.org/t/alexa-on-device-activity-not-working/80901/209 "2024-04-06T16:50:10Z")

</div>

Quick update for anyone trying out Sean's @Sean-McG creative Alexa solution. Here's an example...

 ![VSH_E](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/e/d/ed302e74008d0062498b897a6fccf0c8501b1402.png)  
I'm using various brightness levels to turn On/Off some SonOff S20's devices that power a laser, a computer & access point in our lounge and computer in my office.

When you create the Alexa Routine you need to make sure the Power setting is **On** in both situations.  
I found to this out to my cost in wasted debugging time that if the Power setting is Off then the brightness value is not sent - which confuses the decoding in the Node-RED flow. It seemed natural to set the Power setting to Off when I wanted to turn, say, the laser Off - but be warned, use **On** in both situations.

---

<div class="post-metadata">

**Author:** ![franz](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/franz/32/71949_2.png) [@franz](https://discourse.nodered.org/u/franz)\
**Post date:** [22 May 2024 18:04 UTC](https://discourse.nodered.org/t/alexa-on-device-activity-not-working/80901/210 "2024-05-22T18:04:22Z")

</div>

node-red-contrib-alexa-remote2-applestrudel ver 5.0.50 no longer works again. i am using 🤯  
 ![Schermata del 2024-05-22 20.02.44](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/1/c/1c6c17a6a50c9cf1bad7987064a56252419abc5d.jpeg)

```auto
Unhandled rejection RequestError: Error: read ETIMEDOUT

    at new RequestError (/data/node_modules/request-promise-core/lib/errors.js:14:15)

    at Request.plumbing.callback (/data/node_modules/request-promise-core/lib/plumbing.js:87:29)

    at Request.RP$callback [as _callback] (/data/node_modules/request-promise-core/lib/plumbing.js:46:31)

    at self.callback (/data/node_modules/request/request.js:185:22)

    at Request.emit (node:events:513:28)

    at Request.onRequestError (/data/node_modules/request/request.js:877:8)

    at ClientRequest.emit (node:events:513:28)

    at TLSSocket.socketErrorListener (node:_http_client:494:9)

    at TLSSocket.emit (node:events:513:28)

    at emitErrorNT (node:internal/streams/destroy:157:8)

    at emitErrorCloseNT (node:internal/streams/destroy:122:3)

    at processTicksAndRejections (node:internal/process/task_queues:83:21)

```

and alexa loses proxy authentication

---

<div class="post-metadata">

**Author:** ![Sean-McG](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/sean-mcg/32/54677_2.png) [@Sean-McG](https://discourse.nodered.org/u/Sean-McG)\
**Post date:** [22 May 2024 18:34 UTC](https://discourse.nodered.org/t/alexa-on-device-activity-not-working/80901/211 "2024-05-22T18:34:47Z")

</div>

Dare I say still working for me ...... (so far)

---

<div class="post-metadata">

**Author:** ![franz](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/franz/32/71949_2.png) [@franz](https://discourse.nodered.org/u/franz)\
**Post date:** [6 June 2024 08:38 UTC](https://discourse.nodered.org/t/alexa-on-device-activity-not-working/80901/212 "2024-06-06T08:38:12Z")

</div>

I can't understand why after a day or so of operation it asks for authentication and crashes.  
 ![Schermata del 2024-06-06 10.32.44](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/a/d/adb92708669c431394ddeaa8db918bdb236cd04d.jpeg)  
 ![Schermata del 2024-06-05 11.59.56](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/d/0/d0e1f0dcc232db80ae11b7f6fc035ed09c3d9127.jpeg)  
 ![Schermata del 2024-06-05 11.59.28](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/a/7/a703c267c349b99d6892cbdb5504bc17cc74cc71.jpeg)

😬 😮‍💨

---

<div class="post-metadata">

**Author:** ![Sean-McG](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/sean-mcg/32/54677_2.png) [@Sean-McG](https://discourse.nodered.org/u/Sean-McG)\
**Post date:** [6 June 2024 22:40 UTC](https://discourse.nodered.org/t/alexa-on-device-activity-not-working/80901/213 "2024-06-06T22:40:12Z")

</div>

@dynamicdave you can get the location by using the "other" node set as follows.

If you trigger this after receiving a VSH command, then you can grab **msg.payload[0].name** which contains the device that last heard a command.

![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/7/3/733dacd3a98abfabd20c42c3bb373fa5a3c914ef.png)

---

<div class="post-metadata">

**Author:** ![dynamicdave](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/dynamicdave/32/96_2.png) [@dynamicdave](https://discourse.nodered.org/u/dynamicdave)\
**Post date:** [7 June 2024 05:14 UTC](https://discourse.nodered.org/t/alexa-on-device-activity-not-working/80901/214 "2024-06-07T05:14:31Z")

</div>

Just tried your suggestion and get this error message (on the Alexa Other node)...  
`"Activity update is running, please try again later."`  
Any ideas what is wrong?

Note:  
I have Alexa also running on another RPi using the same Amazon account - not sure if that will affect the operation of the 'Other' node?.

![friday_alexa](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/d/c/dc19665e455887c11f28df31a03cc25de0b7081c.png)

---

<div class="post-metadata">

**Author:** ![Sean-McG](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/sean-mcg/32/54677_2.png) [@Sean-McG](https://discourse.nodered.org/u/Sean-McG)\
**Post date:** [7 June 2024 22:33 UTC](https://discourse.nodered.org/t/alexa-on-device-activity-not-working/80901/215 "2024-06-07T22:33:22Z")

</div>

I just tried and saw the same message, if you make a change to the node settings and redeploy it seems to fix it, but not sure what the problem is.

I never had this error before, I also note that it returns 10 events regardless of the settings. So it's likely that its suffering from some changes by Amazon 🙄

---

<div class="post-metadata">

**Author:** ![dynamicdave](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/dynamicdave/32/96_2.png) [@dynamicdave](https://discourse.nodered.org/u/dynamicdave)\
**Post date:** [8 June 2024 06:59 UTC](https://discourse.nodered.org/t/alexa-on-device-activity-not-working/80901/216 "2024-06-08T06:59:32Z")

</div>

How weird is that? It works fine now and reports the device name.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/1X/d073cd938eafa2e558d7c2cd59003b3ef4963033.png) [@system](https://discourse.nodered.org/u/system)\
**Post date:** [7 August 2024 07:00 UTC](https://discourse.nodered.org/t/alexa-on-device-activity-not-working/80901/217 "2024-08-07T07:00:20Z")

</div>

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.

[Previous page](https://discourse.nodered.org/t/alexa-on-device-activity-not-working/80901.md?page=10)
