lircrc 7.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405
  1. # -*- mode: conf-space -*-
  2. begin
  3. flags = startup_mode
  4. mode = main
  5. end
  6. begin
  7. prog = irexec
  8. button = KEY_GREEN
  9. button = KEY_MODE
  10. config = osd-text
  11. flags = quit
  12. end
  13. ######## MAIN MODE #############################################
  14. begin main
  15. begin
  16. prog = irexec
  17. button = KEY_POWER
  18. mode = tv
  19. config = osd-text "mode: tv" ; toggle-tvtime &
  20. flags = quit
  21. end
  22. begin
  23. prog = irexec
  24. button = KEY_SCREEN
  25. mode = mouse
  26. config = osd-text "mode: mouse"
  27. flags = quit
  28. end
  29. begin
  30. prog = irexec
  31. button = KEY_MODE
  32. mode = mouse
  33. config = osd-text "mode: mouse"
  34. flags = quit
  35. end
  36. begin
  37. prog = irexec
  38. button = KEY_RED
  39. config = xterm -e alsamixer &
  40. flags = quit
  41. end
  42. # OSD sleep
  43. begin
  44. prog = irexec
  45. button = KEY_5
  46. config = osd-sleep
  47. repeat = 1
  48. flags = quit
  49. end
  50. begin
  51. prog = irexec
  52. button = KEY_0
  53. config = osd-sleep 0
  54. repeat = 1
  55. flags = quit
  56. end
  57. begin
  58. prog = irexec
  59. button = KEY_1
  60. config = osd-sleep +1
  61. repeat = 1
  62. flags = quit
  63. end
  64. begin
  65. prog = irexec
  66. button = KEY_7
  67. config = osd-sleep -1
  68. repeat = 1
  69. flags = quit
  70. end
  71. begin
  72. prog = irexec
  73. button = KEY_2
  74. config = osd-sleep +3
  75. repeat = 1
  76. flags = quit
  77. end
  78. begin
  79. prog = irexec
  80. button = KEY_8
  81. config = osd-sleep -3
  82. repeat = 1
  83. flags = quit
  84. end
  85. begin
  86. prog = irexec
  87. button = KEY_3
  88. config = osd-sleep +10
  89. repeat = 1
  90. flags = quit
  91. end
  92. begin
  93. prog = irexec
  94. button = KEY_9
  95. config = osd-sleep -10
  96. repeat = 1
  97. flags = quit
  98. end
  99. # EMMS control
  100. begin
  101. prog = irexec
  102. button = KEY_PLAYPAUSE
  103. config = emacsclient -s server-emms --eval '(emms-pause)'
  104. flags = quit
  105. end
  106. begin
  107. prog = irexec
  108. button = KEY_GREEN
  109. button = KEY_RECORD
  110. config = emacsclient -s server-emms --eval '(emms-previous)'
  111. flags = quit
  112. end
  113. begin
  114. prog = irexec
  115. button = KEY_GREEN
  116. button = KEY_STOP
  117. config = emacsclient -s server-emms --eval '(emms-next)'
  118. flags = quit
  119. end
  120. begin
  121. prog = irexec
  122. button = KEY_RECORD
  123. config = emacsclient -s server-emms --eval '(al/emms-seek-backward 10)'
  124. flags = quit
  125. end
  126. begin
  127. prog = irexec
  128. button = KEY_STOP
  129. config = emacsclient -s server-emms --eval '(al/emms-seek-forward 10)'
  130. flags = quit
  131. end
  132. begin
  133. prog = irexec
  134. button = KEY_OK
  135. config = emacsclient -s server-emms --eval '(al/emms-mpv-show-progress)'
  136. flags = quit
  137. end
  138. begin
  139. prog = irexec
  140. button = KEY_ZOOM
  141. config = emacsclient -s server-emms --eval '(al/emms-mpv-toggle-fullscreen)'
  142. flags = quit
  143. end
  144. begin
  145. prog = irexec
  146. button = KEY_VOLUMEDOWN
  147. config = emacsclient -s server-emms --eval '(al/emms-seek-backward 60)'
  148. flags = quit
  149. end
  150. begin
  151. prog = irexec
  152. button = KEY_VOLUMEUP
  153. config = emacsclient -s server-emms --eval '(al/emms-seek-forward 60)'
  154. flags = quit
  155. end
  156. # Volume control
  157. begin
  158. prog = irexec
  159. button = KEY_MUTE
  160. config = osd-sound sset Master toggle
  161. end
  162. begin
  163. prog = irexec
  164. button = KEY_CHANNELUP
  165. repeat = 1
  166. config = osd-sound sset Master 3%+
  167. end
  168. begin
  169. prog = irexec
  170. button = KEY_CHANNELDOWN
  171. repeat = 1
  172. config = osd-sound sset Master 3%-
  173. end
  174. end main
  175. ######## MOUSE MODE ############################################
  176. begin mouse
  177. begin
  178. prog = irexec
  179. button = KEY_SCREEN
  180. mode = main
  181. config = osd-text "mode: main"
  182. flags = quit
  183. end
  184. begin
  185. prog = irexec
  186. button = KEY_MODE
  187. mode = tv
  188. config = osd-text "mode: tv"
  189. flags = quit
  190. end
  191. begin
  192. prog = irexec
  193. button = KEY_CHANNELUP
  194. repeat = 1
  195. flags = quit
  196. end
  197. begin
  198. prog = irexec
  199. button = KEY_CHANNELDOWN
  200. repeat = 1
  201. flags = quit
  202. end
  203. end mouse
  204. ######## TV MODE ###############################################
  205. begin tv
  206. begin
  207. prog = irexec
  208. button = KEY_POWER
  209. mode = main
  210. config = osd-text "mode: main" ; tvtime-command QUIT
  211. flags = quit
  212. end
  213. begin
  214. prog = irexec
  215. button = KEY_MODE
  216. mode = main
  217. config = osd-text "mode: main"
  218. flags = quit
  219. end
  220. begin
  221. prog = irexec
  222. button = KEY_OK
  223. config = tvtime-command DISPLAY_INFO
  224. flags = quit
  225. end
  226. begin
  227. prog = irexec
  228. button = KEY_SCREEN
  229. config = tvtime-command TOGGLE_ASPECT
  230. flags = quit
  231. end
  232. begin
  233. prog = irexec
  234. button = KEY_VOLUMEUP
  235. config = tvtime-command CHANNEL_UP
  236. flags = quit
  237. end
  238. begin
  239. prog = irexec
  240. button = KEY_VOLUMEDOWN
  241. config = tvtime-command CHANNEL_DOWN
  242. flags = quit
  243. end
  244. begin
  245. prog = irexec
  246. button = KEY_1
  247. config = tvtime-command CHANNEL_1
  248. flags = quit
  249. end
  250. begin
  251. prog = irexec
  252. button = KEY_2
  253. config = tvtime-command CHANNEL_2
  254. flags = quit
  255. end
  256. begin
  257. prog = irexec
  258. button = KEY_3
  259. config = tvtime-command CHANNEL_3
  260. flags = quit
  261. end
  262. begin
  263. prog = irexec
  264. button = KEY_4
  265. config = tvtime-command CHANNEL_4
  266. flags = quit
  267. end
  268. begin
  269. prog = irexec
  270. button = KEY_5
  271. config = tvtime-command CHANNEL_5
  272. flags = quit
  273. end
  274. begin
  275. prog = irexec
  276. button = KEY_6
  277. config = tvtime-command CHANNEL_6
  278. flags = quit
  279. end
  280. begin
  281. prog = irexec
  282. button = KEY_7
  283. config = tvtime-command CHANNEL_7
  284. flags = quit
  285. end
  286. begin
  287. prog = irexec
  288. button = KEY_8
  289. config = tvtime-command CHANNEL_8
  290. flags = quit
  291. end
  292. begin
  293. prog = irexec
  294. button = KEY_9
  295. config = tvtime-command CHANNEL_9
  296. flags = quit
  297. end
  298. begin
  299. prog = irexec
  300. button = KEY_0
  301. config = tvtime-command CHANNEL_0
  302. flags = quit
  303. end
  304. begin
  305. prog = irexec
  306. button = KEY_ZOOM
  307. config = tvtime-command TOGGLE_FULLSCREEN
  308. flags = quit
  309. end
  310. begin
  311. prog = irexec
  312. button = KEY_AGAIN
  313. config = tvtime-command CHANNEL_PREV
  314. flags = quit
  315. end
  316. # Volume control
  317. begin
  318. prog = irexec
  319. button = KEY_MUTE
  320. config = osd-sound sset Line toggle
  321. end
  322. begin
  323. prog = irexec
  324. button = KEY_CHANNELUP
  325. repeat = 1
  326. config = osd-sound sset Line 3%+
  327. end
  328. begin
  329. prog = irexec
  330. button = KEY_CHANNELDOWN
  331. repeat = 1
  332. config = osd-sound sset Line 3%-
  333. end
  334. end tv
  335. ######## GLOBAL KEYS ###########################################
  336. begin
  337. prog = irexec
  338. button = KEY_INFO
  339. config = toggle-osd-clock &
  340. end
  341. begin
  342. prog = irexec
  343. button = KEY_TEXT
  344. config = stumpish -e al/toggle-root < /dev/null
  345. end
  346. begin
  347. prog = irexec
  348. button = KEY_VIDEO
  349. button = KEY_VIDEO
  350. config = sudo chvt 11
  351. config = sudo chvt 7
  352. end
  353. # space, escape and 'q' keys
  354. begin
  355. prog = irexec
  356. button = KEY_GREEN
  357. button = KEY_CAMERA
  358. config = xdotool key q
  359. flags = quit
  360. end
  361. begin
  362. prog = irexec
  363. # freeze key
  364. button = KEY_CAMERA
  365. config = xdotool key space
  366. flags = quit
  367. end
  368. begin
  369. prog = irexec
  370. # tv key
  371. button = KEY_TUNER
  372. config = xdotool key Escape
  373. flags = quit
  374. end