Devo 12S no button inputs after renaming mixer

More
02 Apr 2017 10:26 #61061 by M8A4X
Hi everyone!

With the latest nightly build for the Devo 12S I have to following issue (did not check on previous firmwares):

When renaming a mixer, e.g. "Virt1" to any other name and also back to "Virt1" after entering the letters by the touchscreen the buttons "Ext, Ent, Up, Dn, R, L" are no longer recognized for inputs to the menu, only the touchscreen is available for inputs.
However the buttons are recognized correct in the "Button monitor" in "Transmitter menu".
The functionality comes back when I powercycle the transmitter.

If the buttons are used for changing the name of the mixer, they keep working as normal.
When using the touchscreen for mixer name inputs, the first input causes a "refresh" of the screen, the letter which should be input has to be pressed again to be entered in the name field. The further touch inputs are as expected.

Just for information: When using the touch inputs for a model name this does not happen, the buttons work fine after touch inputs are made.

Am I missing something to "switch back to button input" or is this a bug in the firmware?

Best regards
Max

Please Log in or Create an account to join the conversation.

More
04 Apr 2017 18:10 - 04 Apr 2017 18:12 #61163 by vlad_vy
I can reproduce it if I enter into rename by button then use touchscreen. It looks like button remains pressed and mix up with touchscreen.

Attachments:
Last edit: 04 Apr 2017 18:12 by vlad_vy.

Please Log in or Create an account to join the conversation.

More
04 Apr 2017 18:25 #61165 by FDR
Does it work the same in the emulator, or only in the TX?

Please Log in or Create an account to join the conversation.

More
04 Apr 2017 18:29 #61166 by vlad_vy
I use emulator, since my real Tx use v5.0.0

Please Log in or Create an account to join the conversation.

More
04 Apr 2017 18:40 #61168 by FDR
I see, I should have known from the screenshot...

Please Log in or Create an account to join the conversation.

More
05 Apr 2017 11:22 - 05 Apr 2017 11:32 #61201 by vlad_vy
It looks like "objTOUCHED = NULL;" will fix the problem. If button is released, with touchscreen we have "objTOUCHED = NULL;", but with Tx buttons we have not "objTOUCHED = NULL;".

src/gui/button.c
int GUI_TouchButton(struct guiObject *obj, int press_type)
{
    //press_type: 1=long_press, -1=release
    struct guiButton *button = (struct guiButton *)obj;
    if (press_type == 0) {
        button->flags &= ~FLAG_LONGPRESS;
    } else if (press_type == 1) {
        button->flags |= FLAG_LONGPRESS;
        return 0;
    }
    OBJ_SET_DIRTY(objTOUCHED, 1);
    if (press_type == -1) {
        if(button->CallBack) {
            button->CallBack(objTOUCHED, button->cb_data);
            //The object may have been destroyed by now, the obj may be invalid
        }
        objTOUCHED = NULL;
    }
    return 1;
}

Attachments:
Last edit: 05 Apr 2017 11:32 by vlad_vy.

Please Log in or Create an account to join the conversation.

More
05 Apr 2017 18:00 #61205 by M8A4X
Thank you all for the response!

Vlad_vy, you seem to have found the cause of the input issue or even better the solution for it!
Can you somehow put it in an test build or in a nightly build?
I am by far not skilled enough to change code by myself...

Thanks in advance!

Greetings,
Max

Please Log in or Create an account to join the conversation.

More
06 Apr 2017 08:11 #61208 by vlad_vy
Fixed, you can try the next Nightly Build.

Please Log in or Create an account to join the conversation.

More
06 Apr 2017 16:31 - 06 Apr 2017 16:31 #61217 by M8A4X
Perfect! It works :)

Thank you, vlad_vy!
Last edit: 06 Apr 2017 16:31 by M8A4X.

Please Log in or Create an account to join the conversation.

Time to create page: 0.072 seconds
Powered by Kunena Forum