FUNHOUSE SLIDER DEAD ZONE

Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.
Locked
User avatar
RufusVS2020
 
Posts: 65
Joined: Thu Nov 19, 2020 6:31 pm

FUNHOUSE SLIDER DEAD ZONE

Post by RufusVS2020 »

I posted this message on another thread, but I'll post it here as a preface:
I got my Funhouse a couple days ago, and everything seems to be working EXCEPT the slider.
Occasionally 10 will light up, glitchy, go out without moving my finger, and show up at different
positions on the slider bar. It sounds like the changes described here are not in the built in code
and reloading from library should fix that. Is that right? Other pieces seem to work: PIR, Captouch,
up/down/sel buttons, speaker, leds, reset, etc. Haven't testing stemma or wifi yet. Boot mode works.
So I guess the first step is reloading the funhouse firmware.
I searched for alternate demo code and found (somewhere) another .uf2 file with a different binary, and
still had the same problem.

So I loaded CircuitPython and loaded the funhouse-simpletest.py program. One I got the dependent
libraries loaded, It ran fine. My slider performed a bit better, but still seemed to have a dead zone. About
1/4 or 1/3 away from the bottom. It would return values at (1.0, 0.9, 0.8, 0.6, 0.5, 0.2, 0.1, 0.0). See the gap?
I just noticed the other numbers coming in the serial port. (8 8) (7 8)... (0 8) but never (3 8). is this a hardware
or software problem?

Thanks for insight. As I do more tests I'll add info.

User avatar
ejb
 
Posts: 38
Joined: Tue Apr 19, 2011 10:01 pm

Re: FUNHOUSE SLIDER DEAD ZONE

Post by ejb »

I've noticed the same issue. There does seem to be a dead zone located just where you mentioned.

User avatar
ejb
 
Posts: 38
Joined: Tue Apr 19, 2011 10:01 pm

Re: FUNHOUSE SLIDER DEAD ZONE

Post by ejb »

I wonder if it's just a limitation of their design and is the same for the entire production or if some of the boards are defective?

User avatar
RufusVS2020
 
Posts: 65
Joined: Thu Nov 19, 2020 6:31 pm

Re: FUNHOUSE SLIDER DEAD ZONE

Post by RufusVS2020 »

Found the "dead zone problem":

In the slider method in peripherals.py, there is a line:

Code: Select all

        cap_map = b"\x01\x03\x02\x05\x04\x0c\x08\x18\x10"
Which needs to be changed to:

Code: Select all

        cap_map = b"\x01\x03\x02\x06\x04\x0c\x08\x18\x10"
(change 0x05 to 0x06)

The code is designed to track when you are pressing a single contact or two adjacent contacts. If you take the binary of
the values, you should have a single bit or two adjacent bits. The binary for 0x05 is 0b00101 which clearly does not have
the required adjacent bits. 0x06 is 0b00110 which is the correct pattern. So when your finger makes contact to those two points, there was no pattern to match, so the function returned None, instead of a scaled value.

Works as expected now.

Now how do I submit a bug fix?

User avatar
adafruit_support_carter
 
Posts: 29457
Joined: Tue Nov 29, 2016 2:45 pm

Re: FUNHOUSE SLIDER DEAD ZONE

Post by adafruit_support_carter »


Locked
Please be positive and constructive with your questions and comments.

Return to “AdaBox! Show us what you made!”