'잡동사니'에 해당되는 글 13313건
- 2024.10.16 병문안
- 2024.10.15 아버지 수술 끝
- 2024.10.14 수술전 상담
- 2024.10.13 fftest 소스코드와 설정 값
- 2024.10.12 evtest 를 이용하여 진동패드 진동시키기
- 2024.10.12 ffbchecker 컴파일 및 설치
- 2024.10.12 자전거 안장 땡김 4
- 2024.10.12 new-lg4ff 와 oversteer 설치 시도
- 2024.10.11 플심용 자작 시뮬레이터 2
- 2024.10.11 아두이노 FFB 휠 소스코드
아래 소스를 보고 설정을 보니 조금 이해가 가는 느낌 0.1mg
/* download a periodic sinusoidal effect */ memset(&effects[0],0,sizeof(effects[0])); effects[0].type = FF_PERIODIC; effects[0].id = -1; effects[0].u.periodic.waveform = FF_SINE; effects[0].u.periodic.period = 100; /* 0.1 second */ effects[0].u.periodic.magnitude = 0x7fff; /* 0.5 * Maximum magnitude */ effects[0].u.periodic.offset = 0; effects[0].u.periodic.phase = 0; effects[0].direction = 0x4000; /* Along X axis */ effects[0].u.periodic.envelope.attack_length = 1000; effects[0].u.periodic.envelope.attack_level = 0x7fff; effects[0].u.periodic.envelope.fade_length = 1000; effects[0].u.periodic.envelope.fade_level = 0x7fff; effects[0].trigger.button = 0; effects[0].trigger.interval = 0; effects[0].replay.length = 20000; /* 20 seconds */ effects[0].replay.delay = 1000; /* download a constant effect */ effects[1].type = FF_CONSTANT; effects[1].id = -1; effects[1].u.constant.level = 0x2000; /* Strength : 25 % */ effects[1].direction = 0x6000; /* 135 degrees */ effects[1].u.constant.envelope.attack_length = 1000; effects[1].u.constant.envelope.attack_level = 0x1000; effects[1].u.constant.envelope.fade_length = 1000; effects[1].u.constant.envelope.fade_level = 0x1000; effects[1].trigger.button = 0; effects[1].trigger.interval = 0; effects[1].replay.length = 20000; /* 20 seconds */ effects[1].replay.delay = 0; /* download a condition spring effect */ effects[2].type = FF_SPRING; effects[2].id = -1; effects[2].u.condition[0].right_saturation = 0x7fff; effects[2].u.condition[0].left_saturation = 0x7fff; effects[2].u.condition[0].right_coeff = 0x2000; effects[2].u.condition[0].left_coeff = 0x2000; effects[2].u.condition[0].deadband = 0x0; effects[2].u.condition[0].center = 0x0; effects[2].u.condition[1] = effects[2].u.condition[0]; effects[2].trigger.button = 0; effects[2].trigger.interval = 0; effects[2].replay.length = 20000; /* 20 seconds */ effects[2].replay.delay = 0; /* download a condition damper effect */ effects[3].type = FF_DAMPER; effects[3].id = -1; effects[3].u.condition[0].right_saturation = 0x7fff; effects[3].u.condition[0].left_saturation = 0x7fff; effects[3].u.condition[0].right_coeff = 0x2000; effects[3].u.condition[0].left_coeff = 0x2000; effects[3].u.condition[0].deadband = 0x0; effects[3].u.condition[0].center = 0x0; effects[3].u.condition[1] = effects[3].u.condition[0]; effects[3].trigger.button = 0; effects[3].trigger.interval = 0; effects[3].replay.length = 20000; /* 20 seconds */ effects[3].replay.delay = 0; /* a strong rumbling effect */ effects[4].type = FF_RUMBLE; effects[4].id = -1; effects[4].u.rumble.strong_magnitude = 0x8000; effects[4].u.rumble.weak_magnitude = 0; effects[4].replay.length = 5000; effects[4].replay.delay = 1000; /* a weak rumbling effect */ effects[5].type = FF_RUMBLE; effects[5].id = -1; effects[5].u.rumble.strong_magnitude = 0; effects[5].u.rumble.weak_magnitude = 0xc000; effects[5].replay.length = 5000; effects[5].replay.delay = 0; |
[링크 : https://github.com/flosse/linuxconsole/blob/master/utils/fftest.c]
[링크 : https://www.kernel.org/doc/html/v5.2/input/ff.html] 리눅스 커널에서의 ffb 내용
weak/strong rumble 하려면 다 안넣어줘도 된다는 거군..
attack fade는 충격의 앞/뒤라고 보면 될 듯
[링크 : https://learn.microsoft.com/en-us/previous-versions/windows/desktop/ee416225(v=vs.85)]
'모종의 음모 > motion simulator' 카테고리의 다른 글
ffb direction on windows (0) | 2024.10.21 |
---|---|
ffb window api (0) | 2024.10.20 |
evtest 를 이용하여 진동패드 진동시키기 (0) | 2024.10.12 |
ffbchecker 컴파일 및 설치 (0) | 2024.10.12 |
new-lg4ff 와 oversteer 설치 시도 (0) | 2024.10.12 |
force feedback과는 별개로 진동이 되는 녀석은 진동만 시킬수 있나 본데?
$ fftest /dev/input/event16 Force feedback test program. HOLD FIRMLY YOUR WHEEL OR JOYSTICK TO PREVENT DAMAGES Device /dev/input/event16 opened Features: * Absolute axes: X, Y, Z, RX, RY, RZ, Hat 0 X, Hat 0 Y, [3F 00 03 00 00 00 00 00 ] * Relative axes: [00 00 ] * Force feedback effects types: Periodic, Rumble, Gain, Force feedback periodic effects: Square, Triangle, Sine, [00 00 00 00 00 00 00 00 00 00 03 07 01 00 00 00 ] * Number of simultaneous effects: 16 Setting master gain to 75% ... OK Uploading effect #0 (Periodic sinusoidal) ... OK (id 0) Uploading effect #1 (Constant) ... Error: Invalid argument Uploading effect #2 (Spring) ... Error: Invalid argument Uploading effect #3 (Damper) ... Error: Invalid argument Uploading effect #4 (Strong rumble, with heavy motor) ... OK (id 1) Uploading effect #5 (Weak rumble, with light motor) ... OK (id 2) Enter effect number, -1 to exit Use effects 4 and 5 to test rumble effects: Enter effect number, -1 to exit 4 Now Playing: Strong Rumble Enter effect number, -1 to exit 5 Now Playing: Weak Rumble Enter effect number, -1 to exit |
[링크 : https://askubuntu.com/questions/1139960/how-to-enable-a-vibration-in-a-pc-gamepad-in-xubuntu-18-10]
evtest와는 별개라 설치를 해주어야 한다.
$ fftest 명령어 'fftest' 을(를) 찾을 수 없습니다. 그러나 다음을 통해 설치할 수 있습니다: sudo apt install joystick |
설치하고 해보니 권한이 부족하댄다 -_-
$ fftest Force feedback test program. HOLD FIRMLY YOUR WHEEL OR JOYSTICK TO PREVENT DAMAGES Open device file: Permission denied |
그래서 sudo로 해주니 뜬금없이(?) event0를 붙여 버리네?
$ sudo fftest Force feedback test program. HOLD FIRMLY YOUR WHEEL OR JOYSTICK TO PREVENT DAMAGES Device /dev/input/event0 opened Features: * Absolute axes: [00 00 00 00 00 00 00 00 ] * Relative axes: [00 00 ] * Force feedback effects types: Force feedback periodic effects: [00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ] * Number of simultaneous effects: 0 Uploading effect #0 (Periodic sinusoidal) ... Error:: Function not implemented Uploading effect #1 (Constant) ... Error: Function not implemented Uploading effect #2 (Spring) ... Error: Function not implemented Uploading effect #3 (Damper) ... Error: Function not implemented Uploading effect #4 (Strong rumble, with heavy motor) ... Error: Function not implemented Uploading effect #5 (Weak rumble, with light motor) ... Error: Function not implemented Enter effect number, -1 to exit |
그래서 0이 먼가 봤는데 어라.. sleep button.. 야이 -_-
$ sudo evtest No device specified, trying to scan all of /dev/input/event* Available devices: /dev/input/event0: Sleep Button /dev/input/event1: Lid Switch /dev/input/event10: HDA Intel PCH Line /dev/input/event11: HDA Intel PCH Dock Line Out /dev/input/event12: HDA Intel PCH Headphone /dev/input/event13: HDA Intel PCH HDMI/DP,pcm=3 /dev/input/event14: Wacom Serial Penabled 2FG Touchscreen Pen /dev/input/event15: Wacom Serial Penabled 2FG Touchscreen Finger /dev/input/event16: GreenAsia Inc. USB Joystick /dev/input/event2: Power Button /dev/input/event3: AT Translated Set 2 keyboard /dev/input/event4: PS/2 Generic Mouse /dev/input/event5: SynPS/2 Synaptics TouchPad /dev/input/event6: HP WMI hotkeys /dev/input/event7: ST LIS3LV02DL Accelerometer /dev/input/event8: Video Bus /dev/input/event9: HDA Intel PCH Mic Select the device event number [0-16]: ^C |
일반 사용자로 하니 지금 새로 추가된 조이스틱만 뜬다.
아무튼 이렇게 event 번호를 획득하고
$ evtest No device specified, trying to scan all of /dev/input/event* Not running as root, no devices may be available. Available devices: /dev/input/event16: GreenAsia Inc. USB Joystick Select the device event number [0-16]: |
fftest 뒤에 장치명을 붙여주면 된다니까
$ fftest --help Force feedback test program. HOLD FIRMLY YOUR WHEEL OR JOYSTICK TO PREVENT DAMAGES Usage: fftest /dev/input/eventXX Tests the force feedback driver |
일반 사용자 권한으로 조이스틱을 연결하면 똭!
ok 뜨는게 0,4,5 뿐인데
먼가 진동이 오긴한다!
$ fftest /dev/input/event16 Force feedback test program. HOLD FIRMLY YOUR WHEEL OR JOYSTICK TO PREVENT DAMAGES Device /dev/input/event16 opened Features: * Absolute axes: X, Y, Z, RZ, Hat 0 X, Hat 0 Y, Misc , [27 00 03 00 00 01 00 00 ] * Relative axes: [00 00 ] * Force feedback effects types: Periodic, Rumble, Gain, Force feedback periodic effects: Square, Triangle, Sine, [00 00 00 00 00 00 00 00 00 00 03 07 01 00 00 00 ] * Number of simultaneous effects: 16 Setting master gain to 75% ... OK Uploading effect #0 (Periodic sinusoidal) ... OK (id 0) Uploading effect #1 (Constant) ... Error: Invalid argument Uploading effect #2 (Spring) ... Error: Invalid argument Uploading effect #3 (Damper) ... Error: Invalid argument Uploading effect #4 (Strong rumble, with heavy motor) ... OK (id 1) Uploading effect #5 (Weak rumble, with light motor) ... OK (id 2) Enter effect number, -1 to exit |
'모종의 음모 > motion simulator' 카테고리의 다른 글
ffb window api (0) | 2024.10.20 |
---|---|
fftest 소스코드와 설정 값 (0) | 2024.10.13 |
ffbchecker 컴파일 및 설치 (0) | 2024.10.12 |
new-lg4ff 와 oversteer 설치 시도 (0) | 2024.10.12 |
플심용 자작 시뮬레이터 (2) | 2024.10.11 |
qt로 되어서 빌드가 조금 귀찮았는데
문제는 인터넷 상에 문서가 별로 없어서
어떻게 써야지 핸들이 턱에 걸려서 휙~ 돌아가게 제어할수 있는지 모르겠다
qt 때문에 설치해야 할 패키지
$ sudo apt-get install qtbase5-dev |
[링크 : https://askubuntu.com/questions/374755/what-package-do-i-need-to-build-a-qt-5-cmake-application]
빌드는 아래 명령으로 하면 된다.
$ git clone https://github.com/MadCatX/FFBChecker $ cd FFBChecker $ mkdir build $ cd build $ cmake ../ -DCMAKE_BUILD_TYPE=Release $ make $ ./FFBChecker |
[링크 : https://github.com/MadCatX/FFBChecker]
+
Type을 periodic force로 하면, waveform에 따라서 하위 항목이 변하진 않는다.
설정값을 어떻게 넣어야 하나..
[링크 :https://vru.vibrationresearch.com/lesson/sine-test-control-parameters/]
'모종의 음모 > motion simulator' 카테고리의 다른 글
fftest 소스코드와 설정 값 (0) | 2024.10.13 |
---|---|
evtest 를 이용하여 진동패드 진동시키기 (0) | 2024.10.12 |
new-lg4ff 와 oversteer 설치 시도 (0) | 2024.10.12 |
플심용 자작 시뮬레이터 (2) | 2024.10.11 |
ffb (force feedback) linux driver (0) | 2024.10.07 |
와....!
10년간 불편했던게 한번에 해소됨
한번 땡겨나 볼걸.. 왜 이렇게 불편하게 탔었을까..
물론 핸들스템 길이도 줄여놔서 더 효과가 있는 거겠지만..
'개소리 왈왈 > 자전거' 카테고리의 다른 글
오랫만(?)에 서울로 자전거 (1) | 2024.10.09 |
---|---|
서울 자전거 (0) | 2024.10.06 |
자전거 대행진 취소 (0) | 2024.04.18 |
오랫만에 약간 먼 자전거 (0) | 2024.04.06 |
서울 자전거 대행진 신청 (0) | 2024.04.01 |
[링크 : https://github.com/berarma/new-lg4ff]
[링크 : https://github.com/berarma/oversteer]
$ git clone https://github.com/berarma/new-lg4ff.git $ git clone https://github.com/berarma/oversteer.git $ cd new-lg4ff/ $ make $ sudo make install $ cd../oversteer $ sudo apt install python3 python3-gi python3-gi-cairo python3-pyudev python3-xdg python3-evdev gettext meson appstream-util desktop-file-utils python3-matplotlib python3-scipy $ meson setup build $ cd build $ ninja install $ oversteer |
force feedback 항목이 궁금했는데
gain만 조정이 가능하고 별다른 진동생성은 안되는 것 같기도 하...다?
장치 연결
[ 77.978347] usb 2-1.1: new full-speed USB device number 4 using ehci-pci [ 78.062096] usb 2-1.1: New USB device found, idVendor=046d, idProduct=c294, bcdDevice=13.27 [ 78.062122] usb 2-1.1: New USB device strings: Mfr=0, Product=2, SerialNumber=0 [ 78.062130] usb 2-1.1: Product: Driving Force GT [ 78.098925] hid: raw HID events driver (C) Jiri Kosina [ 78.110749] usbcore: registered new interface driver usbhid [ 78.110757] usbhid: USB HID core driver [ 78.131441] input: Driving Force GT as /devices/pci0000:00/0000:00:1d.0/usb2/2-1/2-1.1/2-1.1:1.0/0003:046D:C294.0001/input/input22 [ 78.131592] logitech 0003:046D:C294.0001: input,hidraw0: USB HID v1.00 Joystick [Driving Force GT] on usb-0000:00:1d.0-1.1/input0 [ 78.316051] usb 2-1.1: USB disconnect, device number 4 [ 78.526300] usb 2-1.1: new full-speed USB device number 5 using ehci-pci [ 78.612544] usb 2-1.1: New USB device found, idVendor=046d, idProduct=c29a, bcdDevice=13.27 [ 78.612570] usb 2-1.1: New USB device strings: Mfr=0, Product=2, SerialNumber=0 [ 78.612579] usb 2-1.1: Product: Driving Force GT [ 78.621082] input: Driving Force GT as /devices/pci0000:00/0000:00:1d.0/usb2/2-1/2-1.1/2-1.1:1.0/0003:046D:C29A.0002/input/input23 [ 78.622541] logitech 0003:046D:C29A.0002: input,hidraw0: USB HID v1.11 Joystick [Driving Force GT] on usb-0000:00:1d.0-1.1/input0 [ 78.622611] logitech 0003:046D:C29A.0002: Force feedback support for Logitech Gaming Wheels |
$ lsusb -t -v /: Bus 001.Port 001: Dev 001, Class=root_hub, Driver=ehci-pci/3p, 480M ID 1d6b:0002 Linux Foundation 2.0 root hub |__ Port 001: Dev 002, If 0, Class=Hub, Driver=hub/6p, 480M ID 8087:0024 Intel Corp. Integrated Rate Matching Hub /: Bus 002.Port 001: Dev 001, Class=root_hub, Driver=ehci-pci/3p, 480M ID 1d6b:0002 Linux Foundation 2.0 root hub |__ Port 001: Dev 002, If 0, Class=Hub, Driver=hub/8p, 480M ID 8087:0024 Intel Corp. Integrated Rate Matching Hub |__ Port 001: Dev 005, If 0, Class=Human Interface Device, Driver=usbhid, 12M ID 046d:c29a Logitech, Inc. |__ Port 004: Dev 003, If 0, Class=Video, Driver=uvcvideo, 480M ID 04f2:b242 Chicony Electronics Co., Ltd |__ Port 004: Dev 003, If 1, Class=Video, Driver=uvcvideo, 480M ID 04f2:b242 Chicony Electronics Co., Ltd |
oversteer 상에는 특별한(?) 게 활성화 되진 않는다.
'모종의 음모 > motion simulator' 카테고리의 다른 글
evtest 를 이용하여 진동패드 진동시키기 (0) | 2024.10.12 |
---|---|
ffbchecker 컴파일 및 설치 (0) | 2024.10.12 |
플심용 자작 시뮬레이터 (2) | 2024.10.11 |
ffb (force feedback) linux driver (0) | 2024.10.07 |
ffb - force feedback (0) | 2023.08.25 |
[링크 : https://www.youtube.com/watch?v=1IoPEn1yBRA]
[링크 : https://flightsimulation.romandesign.ca/roman-design-motion-vr-cockpit-project/]
'모종의 음모 > motion simulator' 카테고리의 다른 글
ffbchecker 컴파일 및 설치 (0) | 2024.10.12 |
---|---|
new-lg4ff 와 oversteer 설치 시도 (0) | 2024.10.12 |
ffb (force feedback) linux driver (0) | 2024.10.07 |
ffb - force feedback (0) | 2023.08.25 |
AVR FFB(force feedback) (0) | 2021.06.29 |
흐음.. 되어있는걸로 하는게 더 편하려나?
'embeded > arduino(genuino)' 카테고리의 다른 글
1.8인치 TFT LCD with SDcard (0) | 2024.10.18 |
---|---|
arducam esp8266 https post 예제 (0) | 2024.01.31 |
433MHz RF 통신 (0) | 2023.12.07 |
아두이노 dht11 (0) | 2022.11.14 |
아두이노 Serial.print()와 Serial.write() (0) | 2022.11.14 |