Stop transferring iop, and signal an interrupt.
| 160 | |
| 161 | // Stop transferring iop, and signal an interrupt. |
| 162 | static __fi void EndIOP() |
| 163 | { |
| 164 | SIF_LOG("Sif0: End IOP"); |
| 165 | sif0data = 0; |
| 166 | sif0.iop.end = false; |
| 167 | sif0.iop.busy = false; |
| 168 | |
| 169 | if (sif0.iop.cycles == 0) |
| 170 | { |
| 171 | DevCon.Warning("SIF0 IOP: cycles = 0"); |
| 172 | sif0.iop.cycles = 1; |
| 173 | } |
| 174 | // Hack alert |
| 175 | // Parappa the rapper hates SIF0 taking the length of time it should do on bigger packets |
| 176 | // I logged it and couldn't work out why, changing any other SIF timing (EE or IOP) seems to have no effect. |
| 177 | if (sif0.iop.cycles > 1000) |
| 178 | sif0.iop.cycles >>= 1; //2 word per cycle |
| 179 | |
| 180 | PSX_INT(IopEvt_SIF0, sif0.iop.cycles); |
| 181 | } |
| 182 | |
| 183 | // Handle the EE transfer. |
| 184 | static __fi void HandleEETransfer() |
no test coverage detected