@@ -113,6 +113,12 @@ void USB2SnesStatut::onRomStarted()
113113 sDebug () << " Rom started" ;
114114 QString text = usb2snes->infos ().at (2 );
115115 ui->romNameLabel ->setText (text);
116+ if (usb2snes->firmwareVersion ().majorVersion () == 8 )
117+ {
118+ ui->romPatchedLabel ->setText (tr (" Running USB2Snes V8, can't know if patched ROM" ));
119+ ui->patchROMpushButton ->setEnabled (true );
120+ return ;
121+ }
116122 if (!isPatchedRom ())
117123 {
118124 ui->romPatchedLabel ->setText (tr (" ROM is not patched for savestate" ));
@@ -185,6 +191,12 @@ bool USB2SnesStatut::validVersion()
185191bool USB2SnesStatut::isPatchedRom ()
186192{
187193 sDebug () << " Checking for patched rom" ;
194+ /* if (usb2snes->firmwareVersion() > QVersionNumber(7))
195+ {
196+ QByteArray data = usb2snes->getAddress(0xFC2000, 15, USB2snes::SNES);
197+ QByteArray cmpv8 = QByteArray::fromHex("0101102020200000000000000000");
198+ return data == cmpv8;
199+ }*/
188200 QByteArray data = usb2snes->getAddress (0x2A90 , 1 , USB2snes::CMD);
189201 if (data[0 ] != (char ) 0x60 )
190202 return true ;
@@ -270,5 +282,9 @@ void USB2SnesStatut::on_pushButton_clicked()
270282
271283void USB2SnesStatut::on_statusPushButton_clicked ()
272284{
285+ if (usb2snes->state () == USB2snes::None)
286+ {
287+ usb2snes->connect ();
288+ }
273289 QToolTip::showText (ui->statusPushButton ->mapToGlobal (QPoint (0 ,0 )), ui->statusPushButton ->toolTip (), ui->statusPushButton , QRect (), 5000 );
274290}
0 commit comments