The latest version includes experimental sequential triggers. There is one caveat though, the initial trigger seq = 1; will always be executed. This is a flaw in the design. I intended to resolve this later by refactoring and maybe moving the project to Python instead of C. I only released it as is since I too am suffering from Bluetooth issues that require both bluetooth and bluebinder to be restarted.
Pressing the assist button twice really fast will launch seq = 1; and seq = 2; pressing it once will only launch seq = 1;
hereās an example cfg for camera as seq = 1; and restarting the fingerprint service as seq = 2;
// Not recommended to run keymapper as root,
// Provide full correct-cmdline e.g /usr/bin/invoker -s -n -d 5 --type=silica-media,silica-qt5 -A -- /usr/bin/jolla-camera
// Otherwise the process will never die
// seq is the order of operation. If pressed once, then seq 1 will exec. If pressed twice very fast then seq 2 will exec after seq 1
name = "TEST CONFING";
keymap = {
assist_button_1 = {
seq = 1;
proc = "Camera Starting...";
trigger = 457;
process_name = "/usr/bin/jolla-camera";
cmd = "/usr/bin/invoker -s -n -d 5 --type=silica-media,silica-qt5 -A -- /usr/bin/jolla-camera";
};
assist_button_2 = {
seq = 2;
proc = "";
trigger = 457;
process_name = "";
cmd = "systemctl restart sailfish-fpd";
};
};
Hey,
this is awesome! Could you do a config for enabling /disabling screen rotation?
i dont know which one would be the best way, but maybe using the dconf method would be an option.
because i hate it when the screen just randomly rotates on me and i always have it turned off. Sometimes i need it tho. Then its always so fiddly to do it on the screen.
best case scenario imo would be if you could rotate the phone, doesnt matter. If you press the button, the screen rotates in the direction youre holding it in and then its disabled again.
is there maybe a way to read out the sensors for the orientation and then setting the dconf key accordingly?
I wouldnāt suggest disabling screen rotation/orientation. I would rather have it as dynamic or maybe something along the lines of your suggestion.
You can get the current orientation position using dbus-send --system --type=method_call --print-reply --dest=com.nokia.SensorService /SensorManager/orientationsensor local.OrientationSensor.orientation
It has 6 positions.
#1: speaker facing right, landscape
#2: speaker facing left, landscape
#3: speaker facing down, portrait
#4: speaker facing up, portrait
#5: screen is facing is down
#6: screen is facing up
You can create a script and simply call it from the config. Something likeā¦
Just out of curiosity. Is somthing changed between 4.6 and 5.0? My 10 III with 4.6 version opens camera on long press of that button. I havenāt made any modifications to mce.