arachnidlabs / reload-pro

Schematics and code for the Re:load Pro
http://www.arachnidlabs.com/reload-pro/
Apache License 2.0
98 stars 32 forks source link

Current not set correctly when monitoring #64

Open knarfS opened 9 years ago

knarfS commented 9 years ago

When setting the actual current via serial ("set XXX") or via the encoder while monitoring the values (via "monitor XXX" or a thread that calls "read" frequently), the actual current is sometimes set to 0.

When the actual values are requested every 10 ms, more than 50% of the set commands fail, resulting with a set current of 0 mA. Even with a interval of 500 ms the current is sometimes set to 0.

I think (gut feeling) that the problem is worse when using the monitor command.

ATM I'm writing a client application for the RLP, but this problem makes it hard to graph/monitor the actual values.

Arachnid commented 9 years ago

Hm, this sounds like a race condition. I'll look into it ASAP.