Announcing: libSAPI

For the past ten years BuLogics has been working hard to make wireless technology easier. From Z-Wave to Zigbee, there is a lot of knowledge “squirreled away” in our developers’ and engineers’ heads at BuLogics.  Edge cases, strange bugs, and real-world scenarios that weren’t imagined when the specifications were created.…

Continue reading

Closure Problem in Python

I’ve seen several posts now with people complaining about the following python code: >>> funcs = [] >>> for i in range(11): … def func(x): … return x + i … funcs.append(func) … >>> funcs[1](5) 15 Most people first looking at the code would expect the value of funcs[1](5) to…

Continue reading