Home of the Squeezebox™ & Transporter® network music players.
Results 1 to 4 of 4
  1. #1
    Senior Member
    Join Date
    Mar 2011
    Posts
    242

    How to send a long key press - without been able to send a long key press

    ...to clarify the weird title a bit:

    i'm using the FLIRC USB adaptor with a joggler. Even though the vendor says: long press is possible, it won't work

    What i need is a number 5 long press, which is in the Default.map 5.hold

    I get this working with command line tools (lms cli) and other solutions like squeezy.

    but how can i send external tool commands or cli commands via a single button press, as i'm unable to send a long press.....

    with the FLIRC it's only a number 5 press, which will be a preset command, but thats the short press 5

    Any ideas?

  2. #2
    Senior Member ralphy's Avatar
    Join Date
    Jan 2006
    Location
    Canada
    Posts
    2,964
    A long key press cannot be simulated using the flirc usb adapter and jivelite.

    The flirc emulates a keyboard the there's no facility in the keyboard handler in jive to support it.

    You can map a separate key to the long press function that you what to use.
    Ralphy

    1-Touch, 5-Classics, 3-Booms, 2-UE Radio
    Squeezebox client builds donations always appreciated.

  3. #3
    Senior Member
    Join Date
    Mar 2011
    Posts
    242
    Quote Originally Posted by ralphy View Post

    You can map a separate key to the long press function that you what to use.
    Yes, perhaps this would help. But i fail with that until now.
    Let me explain:
    as i know, that via cli (curl & http) the 5.hold button would work, i've edited the Default.map file and changed the 5.hold setting to the normal "5" button.
    But.... i've expected now, the same happens as executed with curl&http but this is not he case.

    let's assume i'm in material web playing a song. As i have the trackstat plugin installed, the 5.hold would lead to a 5 star rating. This works fine with curl&http. But with modified Default.map, the (short)5 press leads to starting "preset_5" which isn't the same at the end.

    What do I not see here?

  4. #4
    Senior Member
    Join Date
    Mar 2011
    Posts
    242
    this curl works:

    curl -X POST -d '{"id":0,"params":["bb:bb:5a:21:df:c6",["button","5.hold"]],"method":"slim.request"}' http://192.168.0.30:9000/jsonrpc.js

    the references in Default.map are:

    5.hold = preset_5
    5.hold_release = preset_release5
    preset_5.hold = favorites_add5
    5.hold = letter_5

    and for button 5

    5 = numberScroll_5
    5 = numberLetter_5

    so i've tried to change the Default.map to

    5 = preset_5. (doesn't work)

    or

    5 = letter_5 (doesn't work)

    so, perhaps i haven't changed the correct references.....

    Any insight here? What needs to be done to simulate the curl command with a button press?

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •