richrd / nxt-python

Automatically exported from code.google.com/p/nxt-python
GNU General Public License v3.0
1 stars 0 forks source link

EOPD accuracy bug #22

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. instantiate EOPD object
2. call EOPD.get_processed_value()

What is the expected output? What do you see instead?
A value that scales linearly as the distance from the target changes is 
expected. An erratic or unchanging value is returned instead.

What version of nxt-python are you using? On what operating system?
Revision 275 on Ubuntu 10.10

Please provide any additional information below.
I've attached a Subversion patch. 

Original issue reported on code.google.com by jerradge...@gmail.com on 23 Jan 2011 at 2:47

Attachments:

GoogleCodeExporter commented 9 years ago
EOPD.set_range_long() and EOPD.set_range_short() seem to function correctly 
with this patch.

Original comment by jerradge...@gmail.com on 23 Jan 2011 at 2:48

GoogleCodeExporter commented 9 years ago
Updated patch for revision 276.

Original comment by jerradge...@gmail.com on 23 Jan 2011 at 3:37

Attachments:

GoogleCodeExporter commented 9 years ago
After some testing, I found that my previous patch can sometimes cause a zero 
division error. This patch fixes that.

Original comment by jerradge...@gmail.com on 23 Jan 2011 at 3:49

Attachments:

GoogleCodeExporter commented 9 years ago
I see. I thought I had followed spec regarding sqrt(), but I guess it was 
wrong. The hardware never lies. Fixed in r277. Thanks so much.

Original comment by marcus@wanners.net on 23 Jan 2011 at 3:56

GoogleCodeExporter commented 9 years ago

Original comment by marcus@wanners.net on 23 Jan 2011 at 3:56

GoogleCodeExporter commented 9 years ago
Ok...can you make a patch against r277? I'm having some merging issues and am 
too mentally tired to reliably do it manually.

Original comment by marcus@wanners.net on 23 Jan 2011 at 4:00

GoogleCodeExporter commented 9 years ago
This one should work with revision 277. I'm working on the hitechnic.Compass 
class now.

Original comment by jerradge...@gmail.com on 23 Jan 2011 at 4:06

Attachments:

GoogleCodeExporter commented 9 years ago
Thanks. Patch works great.

Original comment by marcus@wanners.net on 23 Jan 2011 at 5:35