Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

(unnecessary?) warning "The HID scheme 'nil' is not installed" #1120

Closed
telephon opened this issue Jun 1, 2014 · 6 comments
Closed

(unnecessary?) warning "The HID scheme 'nil' is not installed" #1120

telephon opened this issue Jun 1, 2014 · 6 comments
Labels
comp: sclang sclang C++ implementation (primitives, etc.). for changes to class lib use "comp: class library"

Comments

@telephon
Copy link
Member

telephon commented Jun 1, 2014

On startup, sclang tries to load the GeneralHID spec:
GeneralHID.fromID( this.platform.defaultHIDScheme );
It is not clear whether this is really necessary; in any case, it posts a warning:

WARNING: GeneralHID.fromID : The HID scheme 'nil' is not installed
The current scheme is still 'nil'!
RESULT = 0

Should the call just be removed and happen on demand?

@sensestage
Copy link
Contributor

On 01-06-14 22:03, Julian Rohrhuber wrote:

On startup, sclang tries to load the GeneralHID spec:
|GeneralHID.fromID( this.platform.defaultHIDScheme );|
It is not clear whether this is really necessary; in any case, it posts
a warning:

|WARNING: GeneralHID.fromID : The HID scheme 'nil' is not installed
The current scheme is still 'nil'!
RESULT = 0
|

Should the call just be removed and happen on demand?

yes, please!

I will need to look into removing GeneralHID, while still maintaining
possible advantages it had over plain LID interfacing (i.e. extending
the LID interface with the features of GeneralHID).
As a cross platform forwarding scheme GeneralHID should be deprecated,
now that we have HID.

But we should keep LID as it does provide access to some devices on
Linux that you do not get via HID.

sincerely,
Marije

@telephon
Copy link
Member Author

Ok, I've added a branch with the removed classes: d7d0bb1
Would that be OK to merge? I have kept the PgeneralHID and GeneralHIDGui code for future usage, but I guess it may look different?

@sensestage
Copy link
Contributor

GeneralHID is still fully functional for Linux, so I would not like to
remove it completely yet.

Maybe for now just change this bit:

*fromID { arg id;

  •  var newScheme = schemes[ id.asSymbol ];
    
  •  if( newScheme.notNil, {
    
  •      scheme = newScheme;
    
  •  }, {
    
  •      if(thisProcess.platform.name != \windows){ // on win we know it's
    
    not yet supported
  •          ("GeneralHID.fromID : The HID scheme '" ++ id ++ "' is not
    
    installed\n" ++
  •          "The current scheme is still '" ++ if( scheme.notNil, { scheme.id
    
    }) ++ "'!").warn;
  •      }
    
  •  });
    
  •  ^scheme;
    
  • }

To:

*fromID { arg id;
var newScheme = schemes[ id.asSymbol ];
if( newScheme.notNil, {
scheme = newScheme;
}, {
if(thisProcess.platform.name == \linux){ // only supported on linux
right now
("GeneralHID.fromID : The HID scheme '" ++ id ++ "' is not
installed\n" ++
"The current scheme is still '" ++ if( scheme.notNil, { scheme.id })
++ "'!").warn;
}
});
^scheme;
}

On 11-06-14 22:29, Julian Rohrhuber wrote:

Ok, I've added a branch with the removed classes: d7d0bb1
d7d0bb1
Would that be OK to merge? I have kept the PgeneralHID and GeneralHIDGui
code for future usage, but I guess it may look different?


Reply to this email directly or view it on GitHub
#1120 (comment).

@telephon
Copy link
Member Author

Hm, it would really be nice not to have two implementations for the same thing. Couldn't GeneralHID be rewritten by redirecting to the new HID, and then be deprecated? Or is there any fundamental difference that needs support?

@sensestage
Copy link
Contributor

Hi,

the fundamental thing is that the new HID implementation on Linux does
not detect the internal keyboard, trackpad and such on Linux. So this is
why I do not want to deprecate LID.
GeneralHID as a layer should be removed in the future, but some features
that are in there should be ported to LID before doing so.
I will have to find some time in the future to do this; hopefully in
August, after I have had some holidays.

I think that any further layers to unify access to input devices should
be in an external toolkit like Modality.

sincerely,
Marije

On 28-06-14 00:06, Julian Rohrhuber wrote:

Hm, it would really be nice not to have two implementations for the same
thing. Couldn't GeneralHID be rewritten by redirecting to the new HID,
and then be deprecated? Or is there any fundamental difference that
needs support?


Reply to this email directly or view it on GitHub
#1120 (comment).

@sensestage
Copy link
Contributor

fully fixed in pull request #1573

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
comp: sclang sclang C++ implementation (primitives, etc.). for changes to class lib use "comp: class library"
Projects
None yet
Development

No branches or pull requests

2 participants