Replies: 2 comments 12 replies
-
Which firmware are you using? You can see it in the bottom right. If you aren't doing so already, could you try this with the latest beta version, installing the firmware from there? To do so click "Try New Beta Features" on the settings panel of the app. Thanks! |
Beta Was this translation helpful? Give feedback.
0 replies
-
That did the trick! Thanks so much.. my setup is running so much quicker now :) I don't suppose you happen to know the Issue number of the bug that was causing this so that I can read about it? No worries if not. Thanks for your help again. |
Beta Was this translation helpful? Give feedback.
12 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I'm unsure whether I should raise this as a bug but figured I'd start with a discussion just incase there is something I can change in my setup to make this work. As a bit of a background I've spent a couple of days trying to debug a quickly degrading performance in my two-way broadcast/observe City Hub setup. I boiled my code down to the absolute basics and it seems to me that for two hubs that are both broadcasting/observing to each other, the speed of execution quickly slows to a complete crawl.
I'm using Pyrbricks Code and two City Hubs. Both hubs are disconnected from the computer and the programs are run by using the button on the hub to rule out the bluetooth connection to the PC causing any slowness.
To recreate..
Hub1.py
Hub2.py
As you can see it's a very simple program where Hub2 is simply copying the light pattern of Hub1, from Red to Orange to Green. Then finally when Hub1 has received a message that Hub2 has turned Green, it waits for 5 seconds then starts the loop again.
I timed how long it takes between Hub 1 turning Red to Hub 2 turning Green and these are the first 8 loops ignoring the first which darts by in a second or so. Timings are approximate.. I did this using a manual stopwatch as I'm unable to see debug output when running the code on the hubs, obviously.
Loop 1: 4.03s
Loop 2: 11.93s
Loop 3: 21.04s
Loop 4: 34.58s
Loop 5: 46.86s
Loop 6: 63.04s
Loop 7: 81.17s
Loop 8: 81.83s
So as you can see it takes no time to degrade to a complete crawl.
Am I doing something wrong in this code? Is this a known issue? Should I raise it as a bug?
EDIT: I should add that I also tried both Hub1.py and Hub2.py on each piece of City Hub hardware to rule out one of them being faulty. The same issue occurs.
Beta Was this translation helpful? Give feedback.
All reactions