* hdmi_cec
* Improve HDMI CEC startup
* hdmi_cec
* Improve HDMI CEC startup
* Use ADV7513 interrupt registers for CEC
Set ADV7513 main 0xE1 to the CEC I2C map address, 0xE2 to 0x00 to power the CEC block, and 0xE3 |= 0x0E for CEC control setup.
Keep HPD forced high through main 0xD6 = 0xC0 after the startup pulse, but clear main 0x94[7] so HPD does not drive the shared HDMI interrupt line.
Clear main 0xA1[6] so the monitor-sense/video-active block stays powered; ADV7513 interrupt status registers 0x94-0x97 are only valid while that block is alive.
Set main 0x95 = 0x07 to enable only CEC RX-ready interrupts, use main 0x97 to clear RX/TX interrupt latches, and clear 0x96/0x97 at init.
Read CEC RX-ready from CEC map 0x49, keep CEC RX enabled with 0x4A = 0x08, release consumed RX slots through 0x4A, and remove fallback polling of RX length registers 0x25/0x37/0x48.
Use main 0x97 bits for CEC TX done/retry/arbitration status, keep CEC TX disabled through 0x11 except while sending, and set the CEC clock divider 0x4E = 0x3D.
Gate RX handling on fpga_get_hdmi_int() so normal CEC polling no longer performs DDC/CEC I2C reads unless the FPGA HDMI interrupt bit is asserted.
Reply to CEC vendor/name discovery so displays can identify MiSTer after registration.
---------
Co-authored-by: misteraddons <51079966+misteraddons@users.noreply.github.com>
* Add video_mode FIFO command for CRT video mode switching
- video.cpp: Add video_mode_cmd() that parses custom modelines and
applies them via video_set_mode(), with hfreq safety check blocking
modes outside 15625-16500Hz to protect 15kHz CRT monitors
- video.h: Declare video_mode_cmd()
- input.cpp: Dispatch "video_mode" commands from MiSTer_cmd FIFO
to video_mode_cmd()
* Remove hfreq guard from video_mode_cmd
The horizontal frequency check was limiting the command to 15kHz modes only. Removing it allows custom modelines with any frequency to be applied. Software at the other end must take care of not calling this API with unsafe frequencies.
* Add OpenFIRE lightguns to guns whitelist
* Add preliminary OpenFIRE support
Guns are detected as light guns based on static VID and OpenFIRE name prefix, as the PID can be any number of different values depending on the user.
Because OpenFIRE guns can be polled through serial devices, a basic (read: hacky) heuristic is used to poll for serial port paths and send a signal to compatible guns to enable their MiSTer compatible mode.
* Tabbbbbs
* Directly open and write to file rather than rely on system echo
Gun sends a mix of keyboard presses, mouse button presses and EV_ABS position data.
Added a QUIRK_LIGHTGUN_MOUSE quirk which passes the mouse button presses through the input system like other EV_KEY events instead of using them for mouse updates. This allows the mouse buttons to be mapped like regular joystick or keyboard buttons.
Added the left mouse button as a keycode that is accepted by the lightgun calibration menu.
Assign player if mouse button is pressed.
* Modifications to input handling to prevent held inputs from being
overridden by an alternate input mapped to the same button.
i.e. R-Type holding fire to charge special shot will not be
disrupted if a secondary fire button is pressed, autofire
or not.
* Modifications to input handling to prevent held inputs from being overridden by an alternate input mapped to the same button.
i.e. R-Type holding fire to charge special shot will not be
disrupted if a secondary fire button is pressed, autofire
or not.
* Prevent held inputs from being disrupted by alternate inputs.
i.e. in R-Type, if holding the fire button to charge a special shot,
tapping an alternately assigned fire button will not cause the charge
to stop.
A small bug was introduced with the new dead zone code that made it ignore "quirks" regarding DS3/DS4. These devices should automatically be given a dead zone of 10, as it was before.
* RetroZord VID:PID
Added the VID;PID to make_unique, and to the two special input modes.
Removed the Arduino Leonardo specific PID, leaving only he main arduino VID. So any DIY adapter using an arduino will work.
* Use UNIQ field on RetroZord Adapter
* input.cpp: pass dev nr to joy_analog
This allows for per-controller behavior
* N64: add emulation for the analog joystick
This applies the reduced-range octagonal gate of the N64 analog stick to
regular analog sticks.
The code was mostly written by Patrick Pollock with small optimizations
by Martin Donlon and myself.
- add Thrustmaster Guillemot Force Feedback Racing Wheel (06f8:0004)
case to setup_wheel for axis 8 (wheel), 9 (accel) and 10 (brake) with
FF_AUTOCENTER support. This wheel uses the built-in `iforce` kernel
module
- prevent input_cb from skipping axis 7 and 8 (previously assumed to be
both paddle axis) if QUIRK_WHEEL is set on the device
- add wh_pedal_invert field to indicate that the pedal range needs to be
inverted after normalization as the device input goes from minimum (0)
offset to maximum (255) offset on pedal depression rather than maximum
to minimum (like the existing supported wheels)
- comment the existing wh_ fields in setup_wheel to indicate their
function
Fixes#799
Co-authored-by: Dominic Evans <oldmanuk@gmail.com>
Add ini option `unique_mapping` which makes controller mappings unique to the physical port the controller is connected to.
Calculates a uint32_t unique_hash for each device during enumeration.
Co-authored-by: Martin Donlon <github-martin@donlons.com>