#rpi4 responsiveness testing
1 messages ยท Page 1 of 1 (latest)
hey
the test flow looks like this:
motion sensor from HA
on motion, call a service. like scene.turn_on or something
Could you send me an export?
sure. it will be broken but you can adjust
np
[{"id":"e99aec0fe257eb14","type":"server-state-changed","z":"2b61c8e726eb5e3b","name":"Adamo Motion","server":"b676fe65.dd3da","version":4,"exposeToHomeAssistant":false,"haConfig":[{"property":"name","value":""},{"property":"icon","value":""}],"entityidfilter":"binary_sensor.office_motion_occupancy","entityidfiltertype":"exact","outputinitially":true,"state_type":"str","haltifstate":"on","halt_if_type":"str","halt_if_compare":"is","outputs":2,"output_only_on_state_change":true,"for":"","forType":"num","forUnits":"minutes","ignorePrevStateNull":false,"ignorePrevStateUnknown":false,"ignorePrevStateUnavailable":false,"ignoreCurrentStateUnknown":true,"ignoreCurrentStateUnavailable":true,"outputProperties":[{"property":"payload","propertyType":"msg","value":"","valueType":"entityState"},{"property":"data","propertyType":"msg","value":"","valueType":"eventData"},{"property":"topic","propertyType":"msg","value":"","valueType":"triggerId"}],"x":640,"y":960,"wires":[["dbe6dca6ea947425","7727c3705bab664f"],[]]},{"id":"dbe6dca6ea947425","type":"api-call-service","z":"2b61c8e726eb5e3b","name":"activate night scene","server":"b676fe65.dd3da","version":5,"debugenabled":false,"domain":"scene","service":"turn_on","areaId":[],"deviceId":[],"entityId":["scene.office_nighttime"],"data":"{}","dataType":"jsonata","mergeContext":"","mustacheAltTags":false,"outputProperties":[],"queue":"none","x":1020,"y":960,"wires":[[]]},{"id":"7727c3705bab664f","type":"debug","z":"2b61c8e726eb5e3b","name":"time debug","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":990,"y":900,"wires":[]},{"id":"b676fe65.dd3da","type":"server","name":"Home Assistant","version":5,"addon":false,"rejectUnauthorizedCerts":false,"ha_boolean":"y|yes|true|on|home|open","connectionDelay":true,"cacheJson":true,"heartbeat":false,"heartbeatInterval":"30","areaSelector":"friendlyName","deviceSelector":"friendlyName","entitySelector":"friendlyName","statusSeparator":"at: ","statusYear":"hidden","statusMonth":"short","statusDay":"numeric","statusHourCycle":"h12","statusTimeFormat":"h:m:s.ms","enableGlobalContextStore":true}]
what's that bug node on your screenshot?
time debug?
oh you can ignore that
i didn't export that in the above code
it's just a switch i use for testing
ok, I thought it's important for this test, that's why I wanted to see the export.
so
you can see in this test screenshot, the detection event was at 26.594 seconds, but the activation event of the scene was at 27.003 seconds
the little white text under each blue node
for me, that's basically a half-second delay ๐ฆ
curious what yours would be
OH i might need you to adjust how time is printed in NR.
so you can see microseconds
if you go to the (i) info tab in the right panel, open Global Configuration Nodes > server > home assistant
at the bottom of the config for the server node is a "Time Format" which i set to show ms
give me few more secs
no rush. ty so much
would you mind using an events: state node instead to trigger?
it looks like you are using an events: all HA node
yes, as am using a zigbee button, but I'll try state
RPI4
RPI3 with NR Addon
time differs as the RPI3 is in different country
holy moly. both are under 50ms though
that's near instant.
i changed mine to do input_boolean.toggle as well, but i'm still seeing 350ms+
one other thing. if you look in your debug log in NR, and expand payload > new state
what is the blue number you see for transition time?
sec, I'll connect debug node
sorry: debug > data >new_State>timesinncechangedMs
8ms
RPI4, Raspbian
RPI3, HASS OS
do you have lotta automations running there?
RPI4, Raspbian - Zigbee motion sensor
i have 86ms
8x yours
btw i tested this with ALL flows OFF in NR except to this one. no impact.
i DO have a lot of automations: about 100
actually, 186 (not all are enabled)
that's interesting, but unfortunately far beyond my understanding. Have you tried the input_boolean as a trigger?
Woow 100, i have just few basically controlling only my TRVs and fishtank. However alongside with HASS i am running few more servers.
I've read somewhere that NR is quite limited in terms of number of operations, so probably this might be your issue, but if you are saying all your automations has been off, then I don't know.
NR itself isn't runninng many ops. Like i said i disabled all flows except for the simple one we're using, same delay.
on your pi4, do you use a memory card or SSD?
Memory card
dang. yeah me too. i thought maybe that was the bottleneck
do you know exact type of you SD card? I tried 32gb and 64gb sandisk A1 and A2. A1 is good, as it should be supported by RPI4, but A2 is not and the effect is the SD Card gets slower. But my experience is that you would really feel that slowliness, It drove me crazy. However I've endup using some old 16GB Sandisk, cause I wasn;t happy even with that 32GB A1 Sandisk performance.
SanDisk 64GB Micro SDXC Extreme Memory Card
it's an A2 / Class 3
sorry, "class speed 10" w/e that means
SanDisk Extreme PRO. Capacity: 64 GB, Flash card type: MicroSDXC, Flash memory class: Class 10, Internal memory type: UHS-I, Read speed: 200 MB/s, Write speed: 140 MB/s, UHS Speed Class: Class 3 (U3), Video Speed Class: V30. Protection features: Shock resistant, Temperature proof, Water resistant...
i'm using this one: https://smile.amazon.com/gp/product/B07KYSTT2V/ref=ppx_yo_dt_b_search_asin_title?ie=UTF8&psc=1
Record the action and get Full HD & 4K Ultra HD video on Android smartphones, cameras and GoPro action cameras. The SanDisk Extreme microSDXC UHS-I Card endures tough conditions and rugged terrains. The extremely fast speeds help capture the adventures you journey on. Transfer your data quickly a...
your link looks faster, but is still A2
yeah, it was PRO version, I had an issue to properly install even docker. I tried that several times with automated scripts and always failed at some point. So I got rid of it and got back to my 16GB granny.
You are running hassos right? So there's not a chance to run some performance test
i am
well I think if you would experience same issue as I did, the slowliness would be more noticeable. Also state changes should be kept in memory so I would not expect the SD Card having impact on this
hmm. so it would appear at first blush that my hardware is capable of your speed, which is VERY fast
Unfortunately I really can't say much about it. But yeah, 500ms and 50ms is quite a difference. Especially if you are running 100 automations. I would try a different SD card, simple setup only with that one testing automation, to see what will be the result
oof. that's a big hit to my family's approval factor haha
haha. In the middle of the night, it will be a test for 30 mins ๐
I have another RPI3 around, so probably I can give it a try now. Let me check, cause I just moved
found it. And apparently it was running on that A2 Card
so your RPI3 results above were with an A2 card
(btw i did test now with the input bool toggle. same results. about 350ms - better than 500ms but still)
no, results above are from RPI3 in my parents house
oh. ok so you're checking your local RPI3 with the A2 card now (in NR)?
yes am gonna check RPI I was not using atm
np, I just had some issues to load the image, hopefully I'll be able to run it now.
Ignore this message
I was able to make it run, the issue is am unable to turn on the milliseconds. However the change itself takes 18ms
weird that you can turn on ms. you could add some debug nodes with payload data
they probably have timestamps on them you could try
thank you though, 18ms seems good still, better than my pi4 which is concerning
what's your number on trigger?
86ms