€•n~Œsphinx.addnodes”Œdocument”“”)”}”(Œ rawsource”Œ”Œchildren”]”(Œ translations”Œ LanguagesNode”“”)”}”(hhh]”(hŒ pending_xref”“”)”}”(hhh]”Œdocutils.nodes”ŒText”“”ŒChinese (Simplified)”…””}”Œparent”hsbaŒ attributes”}”(Œids”]”Œclasses”]”Œnames”]”Œdupnames”]”Œbackrefs”]”Œ refdomain”Œstd”Œreftype”Œdoc”Œ reftarget”Œ/translations/zh_CN/input/ff”Œmodname”NŒ classname”NŒ refexplicit”ˆuŒtagname”hhh ubh)”}”(hhh]”hŒChinese (Traditional)”…””}”hh2sbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ/translations/zh_TW/input/ff”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)”}”(hhh]”hŒItalian”…””}”hhFsbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ/translations/it_IT/input/ff”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)”}”(hhh]”hŒJapanese”…””}”hhZsbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ/translations/ja_JP/input/ff”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)”}”(hhh]”hŒKorean”…””}”hhnsbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ/translations/ko_KR/input/ff”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)”}”(hhh]”hŒPortuguese (Brazilian)”…””}”hh‚sbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ/translations/pt_BR/input/ff”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)”}”(hhh]”hŒSpanish”…””}”hh–sbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ/translations/sp_SP/input/ff”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubeh}”(h]”h ]”h"]”h$]”h&]”Œcurrent_language”ŒEnglish”uh1h hhŒ _document”hŒsource”NŒline”NubhŒsection”“”)”}”(hhh]”(hŒtitle”“”)”}”(hŒForce feedback for Linux”h]”hŒForce feedback for Linux”…””}”(hh¼h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hºhh·h²hh³Œ6/var/lib/git/docbuild/linux/Documentation/input/ff.rst”h´KubhŒ field_list”“”)”}”(hhh]”(hŒfield”“”)”}”(hhh]”(hŒ field_name”“”)”}”(hŒAuthor”h]”hŒAuthor”…””}”(hh×h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÕhhÒh³hÊh´KubhŒ field_body”“”)”}”(hŒ6Johann Deneux on 2001/04/22.”h]”hŒ paragraph”“”)”}”(hhéh]”(hŒJohann Deneux <”…””}”(hhíh²hh³Nh´NubhŒ reference”“”)”}”(hŒjohann.deneux@gmail.com”h]”hŒjohann.deneux@gmail.com”…””}”(hhöh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”Œrefuri”Œmailto:johann.deneux@gmail.com”uh1hôhhíubhŒ> on 2001/04/22.”…””}”(hhíh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hëh³hÊh´Khhçubah}”(h]”h ]”h"]”h$]”h&]”uh1håhhÒubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÐh³hÊh´KhhÍh²hubhÑ)”}”(hhh]”(hÖ)”}”(hŒUpdated”h]”hŒUpdated”…””}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÕhjh³hÊh´Kubhæ)”}”(hŒ7Anssi Hannula on 2006/04/09. ”h]”hì)”}”(hŒ6Anssi Hannula on 2006/04/09.”h]”(hŒAnssi Hannula <”…””}”(hj1h²hh³Nh´Nubhõ)”}”(hŒanssi.hannula@gmail.com”h]”hŒanssi.hannula@gmail.com”…””}”(hj9h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”Œrefuri”Œmailto:anssi.hannula@gmail.com”uh1hôhj1ubhŒ> on 2006/04/09.”…””}”(hj1h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hëh³hÊh´Khj-ubah}”(h]”h ]”h"]”h$]”h&]”uh1håhjubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÐh³hÊh´KhhÍh²hubeh}”(h]”h ]”h"]”h$]”h&]”uh1hËhh·h²hh³hÊh´Kubhì)”}”(hŒaYou may redistribute this file. Please remember to include shape.svg and interactive.svg as well.”h]”hŒaYou may redistribute this file. Please remember to include shape.svg and interactive.svg as well.”…””}”(hjeh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hëh³hÊh´Khh·h²hubh¶)”}”(hhh]”(h»)”}”(hŒ Introduction”h]”hŒ Introduction”…””}”(hjvh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hºhjsh²hh³hÊh´K ubhì)”}”(hX’This document describes how to use force feedback devices under Linux. The goal is not to support these devices as if they were simple input-only devices (as it is already the case), but to really enable the rendering of force effects. This document only describes the force feedback part of the Linux input interface. Please read joydev/joystick.rst and input.rst before reading further this document.”h]”hX’This document describes how to use force feedback devices under Linux. The goal is not to support these devices as if they were simple input-only devices (as it is already the case), but to really enable the rendering of force effects. This document only describes the force feedback part of the Linux input interface. Please read joydev/joystick.rst and input.rst before reading further this document.”…””}”(hj„h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hëh³hÊh´Khjsh²hubeh}”(h]”Œ introduction”ah ]”h"]”Œ introduction”ah$]”h&]”uh1hµhh·h²hh³hÊh´K ubh¶)”}”(hhh]”(h»)”}”(hŒInstructions to the user”h]”hŒInstructions to the user”…””}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hºhjšh²hh³hÊh´Kubhì)”}”(hŒ&To enable force feedback, you have to:”h]”hŒ&To enable force feedback, you have to:”…””}”(hj«h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hëh³hÊh´Khjšh²hubhŒenumerated_list”“”)”}”(hhh]”(hŒ list_item”“”)”}”(hŒNhave your kernel configured with evdev and a driver that supports your device.”h]”hì)”}”(hŒNhave your kernel configured with evdev and a driver that supports your device.”h]”hŒNhave your kernel configured with evdev and a driver that supports your device.”…””}”(hjÄh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hëh³hÊh´KhjÀubah}”(h]”h ]”h"]”h$]”h&]”uh1j¾hj»h²hh³hÊh´Nubj¿)”}”(hŒQmake sure evdev module is loaded and /dev/input/event* device files are created. ”h]”hì)”}”(hŒPmake sure evdev module is loaded and /dev/input/event* device files are created.”h]”hŒPmake sure evdev module is loaded and /dev/input/event* device files are created.”…””}”(hjÜh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hëh³hÊh´KhjØubah}”(h]”h ]”h"]”h$]”h&]”uh1j¾hj»h²hh³hÊh´Nubeh}”(h]”h ]”h"]”h$]”h&]”Œenumtype”Œarabic”Œprefix”hŒsuffix”Œ.”uh1j¹hjšh²hh³hÊh´Kubhì)”}”(hXKBefore you start, let me WARN you that some devices shake violently during the initialisation phase. This happens for example with my "AVB Top Shot Pegasus". To stop this annoying behaviour, move your joystick to its limits. Anyway, you should keep a hand on your device, in order to avoid it to break down if something goes wrong.”h]”hXOBefore you start, let me WARN you that some devices shake violently during the initialisation phase. This happens for example with my “AVB Top Shot Pegasusâ€. To stop this annoying behaviour, move your joystick to its limits. Anyway, you should keep a hand on your device, in order to avoid it to break down if something goes wrong.”…””}”(hjûh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hëh³hÊh´K hjšh²hubhì)”}”(hŒgIf you have a serial iforce device, you need to start inputattach. See joydev/joystick.rst for details.”h]”hŒgIf you have a serial iforce device, you need to start inputattach. See joydev/joystick.rst for details.”…””}”(hj h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hëh³hÊh´K&hjšh²hubh¶)”}”(hhh]”(h»)”}”(hŒDoes it work ?”h]”hŒDoes it work ?”…””}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hºhjh²hh³hÊh´K*ubhì)”}”(hŒJThere is an utility called fftest that will allow you to test the driver::”h]”hŒIThere is an utility called fftest that will allow you to test the driver:”…””}”(hj(h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hëh³hÊh´K,hjh²hubhŒ literal_block”“”)”}”(hŒ% fftest /dev/input/eventXX”h]”hŒ% fftest /dev/input/eventXX”…””}”hj8sbah}”(h]”h ]”h"]”h$]”h&]”Œ xml:space”Œpreserve”uh1j6h³hÊh´K.hjh²hubeh}”(h]”Œ does-it-work”ah ]”h"]”Œdoes it work ?”ah$]”h&]”uh1hµhjšh²hh³hÊh´K*ubeh}”(h]”Œinstructions-to-the-user”ah ]”h"]”Œinstructions to the user”ah$]”h&]”uh1hµhh·h²hh³hÊh´Kubh¶)”}”(hhh]”(h»)”}”(hŒInstructions to the developer”h]”hŒInstructions to the developer”…””}”(hj[h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hºhjXh²hh³hÊh´K1ubhì)”}”(hŒ•All interactions are done using the event API. That is, you can use ioctl() and write() on /dev/input/eventXX. This information is subject to change.”h]”hŒ•All interactions are done using the event API. That is, you can use ioctl() and write() on /dev/input/eventXX. This information is subject to change.”…””}”(hjih²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hëh³hÊh´K3hjXh²hubh¶)”}”(hhh]”(h»)”}”(hŒQuerying device capabilities”h]”hŒQuerying device capabilities”…””}”(hjzh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hºhjwh²hh³hÊh´K8ubj7)”}”(hX#include #include #define BITS_TO_LONGS(x) \ (((x) + 8 * sizeof (unsigned long) - 1) / (8 * sizeof (unsigned long))) unsigned long features[BITS_TO_LONGS(FF_CNT)]; int ioctl(int file_descriptor, int request, unsigned long *features);”h]”hX#include #include #define BITS_TO_LONGS(x) \ (((x) + 8 * sizeof (unsigned long) - 1) / (8 * sizeof (unsigned long))) unsigned long features[BITS_TO_LONGS(FF_CNT)]; int ioctl(int file_descriptor, int request, unsigned long *features);”…””}”hjˆsbah}”(h]”h ]”h"]”h$]”h&]”jFjGuh1j6h³hÊh´K #include int ioctl(int file_descriptor, int request, struct ff_effect *effect);”h]”hŒw#include #include int ioctl(int file_descriptor, int request, struct ff_effect *effect);”…””}”hjµsbah}”(h]”h ]”h"]”h$]”h&]”jFjGuh1j6h³hÊh´Kphj¤h²hubhì)”}”(hŒ"request" must be EVIOCSFF.”h]”hŒ“request†must be EVIOCSFF.”…””}”(hjÃh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hëh³hÊh´Kuhj¤h²hubhì)”}”(hX¤"effect" points to a structure describing the effect to upload. The effect is uploaded, but not played. The content of effect may be modified. In particular, its field "id" is set to the unique id assigned by the driver. This data is required for performing some operations (removing an effect, controlling the playback). The "id" field must be set to -1 by the user in order to tell the driver to allocate a new effect.”h]”hX°“effect†points to a structure describing the effect to upload. The effect is uploaded, but not played. The content of effect may be modified. In particular, its field “id†is set to the unique id assigned by the driver. This data is required for performing some operations (removing an effect, controlling the playback). The “id†field must be set to -1 by the user in order to tell the driver to allocate a new effect.”…””}”(hjÑh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hëh³hÊh´Kwhj¤h²hubhì)”}”(hŒ%Effects are file descriptor specific.”h]”hŒ%Effects are file descriptor specific.”…””}”(hjßh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hëh³hÊh´Khj¤h²hubhì)”}”(hŒ£See for a description of the ff_effect struct. You should also find help in a few sketches, contained in files shape.svg and interactive.svg:”h]”hŒ£See for a description of the ff_effect struct. You should also find help in a few sketches, contained in files shape.svg and interactive.svg:”…””}”(hjíh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hëh³hÊh´Khj¤h²hubŒkfigure”Œ kernel_figure”“”)”}”(hhh]”hŒfigure”“”)”}”(hhh]”(hŒimage”“”)”}”(hŒ(.. kernel-figure:: shape.svg Shape ”h]”h}”(h]”h ]”h"]”h$]”h&]”Œuri”Œinput/shape.svg”Œ candidates”}”Œ*”jsuh1jhjh³hÊh´KubhŒcaption”“”)”}”(hŒShape”h]”hŒShape”…””}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jh³hÊh´K‡hjubeh}”(h]”Œid1”ah ]”h"]”h$]”h&]”uh1jhjþubah}”(h]”h ]”h"]”h$]”h&]”uh1jühj¤h²hh³hÊh´Nubjý)”}”(hhh]”j)”}”(hhh]”(j)”}”(hŒ5.. kernel-figure:: interactive.svg Interactive ”h]”h}”(h]”h ]”h"]”h$]”h&]”Œuri”Œinput/interactive.svg”j}”jjEsuh1jhj7h³hÊh´Kubj)”}”(hŒ Interactive”h]”hŒ Interactive”…””}”(hjGh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jh³hÊh´K‹hj7ubeh}”(h]”Œid2”ah ]”h"]”h$]”h&]”uh1jhj4ubah}”(h]”h ]”h"]”h$]”h&]”uh1jühj¤h²hh³hÊh´Nubeh}”(h]”Œuploading-effects-to-the-device”ah ]”h"]”Œuploading effects to the device”ah$]”h&]”uh1hµhjXh²hh³hÊh´Klubh¶)”}”(hhh]”(h»)”}”(hŒ"Removing an effect from the device”h]”hŒ"Removing an effect from the device”…””}”(hjmh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hºhjjh²hh³hÊh´Kubj7)”}”(hŒ(int ioctl(int fd, EVIOCRMFF, effect.id);”h]”hŒ(int ioctl(int fd, EVIOCRMFF, effect.id);”…””}”hj{sbah}”(h]”h ]”h"]”h$]”h&]”jFjGuh1j6h³hÊh´K“hjjh²hubhì)”}”(hŒoThis makes room for new effects in the device's memory. Note that this also stops the effect if it was playing.”h]”hŒqThis makes room for new effects in the device’s memory. Note that this also stops the effect if it was playing.”…””}”(hj‰h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hëh³hÊh´K•hjjh²hubeh}”(h]”Œ"removing-an-effect-from-the-device”ah ]”h"]”Œ"removing an effect from the device”ah$]”h&]”uh1hµhjXh²hh³hÊh´Kubh¶)”}”(hhh]”(h»)”}”(hŒ#Controlling the playback of effects”h]”hŒ#Controlling the playback of effects”…””}”(hj¢h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hºhjŸh²hh³hÊh´K™ubhì)”}”(hŒ=Control of playing is done with write(). Below is an example:”h]”hŒ=Control of playing is done with write(). Below is an example:”…””}”(hj°h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hëh³hÊh´K›hjŸh²hubj7)”}”(hX #include #include struct input_event play; struct input_event stop; struct ff_effect effect; int fd; ... fd = open("/dev/input/eventXX", O_RDWR); ... /* Play three times */ play.type = EV_FF; play.code = effect.id; play.value = 3; write(fd, (const void*) &play, sizeof(play)); ... /* Stop an effect */ stop.type = EV_FF; stop.code = effect.id; stop.value = 0; write(fd, (const void*) &stop, sizeof(stop));”h]”hX #include #include struct input_event play; struct input_event stop; struct ff_effect effect; int fd; ... fd = open("/dev/input/eventXX", O_RDWR); ... /* Play three times */ play.type = EV_FF; play.code = effect.id; play.value = 3; write(fd, (const void*) &play, sizeof(play)); ... /* Stop an effect */ stop.type = EV_FF; stop.code = effect.id; stop.value = 0; write(fd, (const void*) &stop, sizeof(stop));”…””}”hj¾sbah}”(h]”h ]”h"]”h$]”h&]”jFjGuh1j6h³hÊh´KŸhjŸh²hubeh}”(h]”Œ#controlling-the-playback-of-effects”ah ]”h"]”Œ#controlling the playback of effects”ah$]”h&]”uh1hµhjXh²hh³hÊh´K™ubh¶)”}”(hhh]”(h»)”}”(hŒSetting the gain”h]”hŒSetting the gain”…””}”(hj×h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hºhjÔh²hh³hÊh´K¸ubhì)”}”(hŒºNot all devices have the same strength. Therefore, users should set a gain factor depending on how strong they want effects to be. This setting is persistent across access to the driver.”h]”hŒºNot all devices have the same strength. Therefore, users should set a gain factor depending on how strong they want effects to be. This setting is persistent across access to the driver.”…””}”(hjåh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hëh³hÊh´KºhjÔh²hubj7)”}”(hX/* Set the gain of the device int gain; /* between 0 and 100 */ struct input_event ie; /* structure used to communicate with the driver */ ie.type = EV_FF; ie.code = FF_GAIN; ie.value = 0xFFFFUL * gain / 100; if (write(fd, &ie, sizeof(ie)) == -1) perror("set gain");”h]”hX/* Set the gain of the device int gain; /* between 0 and 100 */ struct input_event ie; /* structure used to communicate with the driver */ ie.type = EV_FF; ie.code = FF_GAIN; ie.value = 0xFFFFUL * gain / 100; if (write(fd, &ie, sizeof(ie)) == -1) perror("set gain");”…””}”hjósbah}”(h]”h ]”h"]”h$]”h&]”jFjGuh1j6h³hÊh´KÀhjÔh²hubeh}”(h]”Œsetting-the-gain”ah ]”h"]”Œsetting the gain”ah$]”h&]”uh1hµhjXh²hh³hÊh´K¸ubh¶)”}”(hhh]”(h»)”}”(hŒEnabling/Disabling autocenter”h]”hŒEnabling/Disabling autocenter”…””}”(hj h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hºhj h²hh³hÊh´KÌubhì)”}”(hŒÀThe autocenter feature quite disturbs the rendering of effects in my opinion, and I think it should be an effect, which computation depends on the game type. But you can enable it if you want.”h]”hŒÀThe autocenter feature quite disturbs the rendering of effects in my opinion, and I think it should be an effect, which computation depends on the game type. But you can enable it if you want.”…””}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hëh³hÊh´KÎhj h²hubj7)”}”(hŒãint autocenter; /* between 0 and 100 */ struct input_event ie; ie.type = EV_FF; ie.code = FF_AUTOCENTER; ie.value = 0xFFFFUL * autocenter / 100; if (write(fd, &ie, sizeof(ie)) == -1) perror("set auto-center");”h]”hŒãint autocenter; /* between 0 and 100 */ struct input_event ie; ie.type = EV_FF; ie.code = FF_AUTOCENTER; ie.value = 0xFFFFUL * autocenter / 100; if (write(fd, &ie, sizeof(ie)) == -1) perror("set auto-center");”…””}”hj(sbah}”(h]”h ]”h"]”h$]”h&]”jFjGuh1j6h³hÊh´KÔhj h²hubhì)”}”(hŒ$A value of 0 means "no auto-center".”h]”hŒ(A value of 0 means “no auto-centerâ€.”…””}”(hj6h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hëh³hÊh´KÞhj h²hubeh}”(h]”Œenabling-disabling-autocenter”ah ]”h"]”Œenabling/disabling autocenter”ah$]”h&]”uh1hµhjXh²hh³hÊh´KÌubh¶)”}”(hhh]”(h»)”}”(hŒDynamic update of an effect”h]”hŒDynamic update of an effect”…””}”(hjOh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hºhjLh²hh³hÊh´Káubhì)”}”(hX©Proceed as if you wanted to upload a new effect, except that instead of setting the id field to -1, you set it to the wanted effect id. Normally, the effect is not stopped and restarted. However, depending on the type of device, not all parameters can be dynamically updated. For example, the direction of an effect cannot be updated with iforce devices. In this case, the driver stops the effect, up-load it, and restart it.”h]”hX©Proceed as if you wanted to upload a new effect, except that instead of setting the id field to -1, you set it to the wanted effect id. Normally, the effect is not stopped and restarted. However, depending on the type of device, not all parameters can be dynamically updated. For example, the direction of an effect cannot be updated with iforce devices. In this case, the driver stops the effect, up-load it, and restart it.”…””}”(hj]h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hëh³hÊh´KãhjLh²hubhì)”}”(hŒšTherefore it is recommended to dynamically change direction while the effect is playing only when it is ok to restart the effect with a replay count of 1.”h]”hŒšTherefore it is recommended to dynamically change direction while the effect is playing only when it is ok to restart the effect with a replay count of 1.”…””}”(hjkh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hëh³hÊh´KêhjLh²hubeh}”(h]”Œdynamic-update-of-an-effect”ah ]”h"]”Œdynamic update of an effect”ah$]”h&]”uh1hµhjXh²hh³hÊh´Káubh¶)”}”(hhh]”(h»)”}”(hŒ'Information about the status of effects”h]”hŒ'Information about the status of effects”…””}”(hj„h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hºhjh²hh³hÊh´Kîubhì)”}”(hŒ„Every time the status of an effect is changed, an event is sent. The values and meanings of the fields of the event are as follows::”h]”hŒƒEvery time the status of an effect is changed, an event is sent. The values and meanings of the fields of the event are as follows:”…””}”(hj’h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hëh³hÊh´Kðhjh²hubj7)”}”(hXqstruct input_event { /* When the status of the effect changed */ struct timeval time; /* Set to EV_FF_STATUS */ unsigned short type; /* Contains the id of the effect */ unsigned short code; /* Indicates the status */ unsigned int value; }; FF_STATUS_STOPPED The effect stopped playing FF_STATUS_PLAYING The effect started to play”h]”hXqstruct input_event { /* When the status of the effect changed */ struct timeval time; /* Set to EV_FF_STATUS */ unsigned short type; /* Contains the id of the effect */ unsigned short code; /* Indicates the status */ unsigned int value; }; FF_STATUS_STOPPED The effect stopped playing FF_STATUS_PLAYING The effect started to play”…””}”hj sbah}”(h]”h ]”h"]”h$]”h&]”jFjGuh1j6h³hÊh´Kóhjh²hubj<)”}”(hŒû- Status feedback is only supported by iforce driver. If you have a really good reason to use this, please contact linux-joystick@atrey.karlin.mff.cuni.cz or anssi.hannula@gmail.com so that support for it can be added to the rest of the drivers.”h]”j³)”}”(hhh]”j¿)”}”(hŒóStatus feedback is only supported by iforce driver. If you have a really good reason to use this, please contact linux-joystick@atrey.karlin.mff.cuni.cz or anssi.hannula@gmail.com so that support for it can be added to the rest of the drivers.”h]”hì)”}”(hŒóStatus feedback is only supported by iforce driver. If you have a really good reason to use this, please contact linux-joystick@atrey.karlin.mff.cuni.cz or anssi.hannula@gmail.com so that support for it can be added to the rest of the drivers.”h]”(hŒqStatus feedback is only supported by iforce driver. If you have a really good reason to use this, please contact ”…””}”(hj¹h²hh³Nh´Nubhõ)”}”(hŒ'linux-joystick@atrey.karlin.mff.cuni.cz”h]”hŒ'linux-joystick@atrey.karlin.mff.cuni.cz”…””}”(hjÁh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”Œrefuri”Œ.mailto:linux-joystick@atrey.karlin.mff.cuni.cz”uh1hôhj¹ubhŒ or ”…””}”(hj¹h²hh³Nh´Nubhõ)”}”(hŒanssi.hannula@gmail.com”h]”hŒanssi.hannula@gmail.com”…””}”(hjÕh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”Œrefuri”Œmailto:anssi.hannula@gmail.com”uh1hôhj¹ubhŒ@ so that support for it can be added to the rest of the drivers.”…””}”(hj¹h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hëh³hÊh´Mhjµubah}”(h]”h ]”h"]”h$]”h&]”uh1j¾hj²ubah}”(h]”h ]”h"]”h$]”h&]”jtjuuh1j²h³hÊh´Mhj®ubah}”(h]”h ]”h"]”h$]”h&]”uh1j;hjh²hh³Nh´Nubeh}”(h]”Œ'information-about-the-status-of-effects”ah ]”h"]”Œ'information about the status of effects”ah$]”h&]”uh1hµhjXh²hh³hÊh´Kîubeh}”(h]”Œinstructions-to-the-developer”ah ]”h"]”Œinstructions to the developer”ah$]”h&]”uh1hµhh·h²hh³hÊh´K1ubeh}”(h]”Œforce-feedback-for-linux”ah ]”h"]”Œforce feedback for linux”ah$]”h&]”uh1hµhhh²hh³hÊh´Kubeh}”(h]”h ]”h"]”h$]”h&]”Œsource”hÊuh1hŒcurrent_source”NŒ current_line”NŒsettings”Œdocutils.frontend”ŒValues”“”)”}”(hºNŒ generator”NŒ datestamp”NŒ source_link”NŒ source_url”NŒ toc_backlinks”Œentry”Œfootnote_backlinks”KŒ sectnum_xform”KŒstrip_comments”NŒstrip_elements_with_classes”NŒ strip_classes”NŒ report_level”KŒ halt_level”KŒexit_status_level”KŒdebug”NŒwarning_stream”NŒ traceback”ˆŒinput_encoding”Œ utf-8-sig”Œinput_encoding_error_handler”Œstrict”Œoutput_encoding”Œutf-8”Œoutput_encoding_error_handler”j<Œerror_encoding”Œutf-8”Œerror_encoding_error_handler”Œbackslashreplace”Œ language_code”Œen”Œrecord_dependencies”NŒconfig”NŒ id_prefix”hŒauto_id_prefix”Œid”Œ dump_settings”NŒdump_internals”NŒdump_transforms”NŒdump_pseudo_xml”NŒexpose_internals”NŒstrict_visitor”NŒ_disable_config”NŒ_source”hÊŒ _destination”NŒ _config_files”]”Œ7/var/lib/git/docbuild/linux/Documentation/docutils.conf”aŒfile_insertion_enabled”ˆŒ raw_enabled”KŒline_length_limit”M'Œpep_references”NŒ pep_base_url”Œhttps://peps.python.org/”Œpep_file_url_template”Œpep-%04d”Œrfc_references”NŒ rfc_base_url”Œ&https://datatracker.ietf.org/doc/html/”Œ tab_width”KŒtrim_footnote_reference_space”‰Œsyntax_highlight”Œlong”Œ smart_quotes”ˆŒsmartquotes_locales”]”Œcharacter_level_inline_markup”‰Œdoctitle_xform”‰Œ docinfo_xform”KŒsectsubtitle_xform”‰Œ image_loading”Œlink”Œembed_stylesheet”‰Œcloak_email_addresses”ˆŒsection_self_link”‰Œenv”NubŒreporter”NŒindirect_targets”]”Œsubstitution_defs”}”Œsubstitution_names”}”Œrefnames”}”Œrefids”}”Œnameids”}”(jjj—j”jUjRjMjJjj j¡jžjgjdjœj™jÑjÎjjjIjFj~j{jjuŒ nametypes”}”(j‰j—‰jU‰jM‰j‰j¡‰jg‰jœ‰jщj‰jI‰j~‰j‰uh}”(jh·j”jsjRjšjJjj jXjžjwjdj¤j™jjjÎjŸjjÔjFj j{jLjjj)jjWj7uŒ footnote_refs”}”Œ citation_refs”}”Œ autofootnotes”]”Œautofootnote_refs”]”Œsymbol_footnotes”]”Œsymbol_footnote_refs”]”Œ footnotes”]”Œ citations”]”Œautofootnote_start”KŒsymbol_footnote_start”KŒ id_counter”Œ collections”ŒCounter”“”}”jJKs…”R”Œparse_messages”]”Œtransform_messages”]”Œ transformer”NŒ include_log”]”Œ decoration”Nh²hub.