11 November 2012, 15:57 | #1 |
Unregistered User
Join Date: Sep 2012
Location: Copenhagen / DK
Age: 43
Posts: 4,190
|
How to detect WinUAE
Whenever I move my CF card from the Amiga to WinUAE, I have to comment out the ACATune line in S-S, as it will not boot otherwise. Is there a way to detect WinUAE and only run acatune in case it is running on a real Amiga?
|
11 November 2012, 17:17 | #2 |
WinUAE developer
Join Date: Aug 2001
Location: Hämeenlinna/Finland
Age: 49
Posts: 26,516
|
Something like this should work:
version >nil: uaehf.device 1 if warn ; no uaehf.device found endif (do not attempt to use any side-effect to detect emulation, it will break someday..) |
11 November 2012, 23:22 | #3 |
Unregistered User
Join Date: Sep 2012
Location: Copenhagen / DK
Age: 43
Posts: 4,190
|
I get an error if I put that in the beginning of my startup-sequence: 'version failed returncode 20'.
|
12 November 2012, 01:29 | #4 |
2 contact me: email only!
Join Date: May 2001
Location: Auckland / New Zealand
Posts: 3,182
|
You'll need to add the "failat" command above the version command.
|
12 November 2012, 04:10 | #5 |
Registered User
Join Date: Nov 2005
Location: Sweden
Posts: 749
|
*shrugs* i haven't been able to incorporate this, but then again, i fail to grasp the most about the Amiga...
|
12 November 2012, 05:03 | #6 |
2 contact me: email only!
Join Date: May 2001
Location: Auckland / New Zealand
Posts: 3,182
|
Add "failat 200" to the top of your script, ensure failat is in your c: path (with WB2.x+ it may already be in ROM) and it should work fine! (It just means that an error of 200 or higher is required to break your script).
|
12 November 2012, 16:52 | #7 |
Registered User
Join Date: Mar 2004
Location: finland
Posts: 1,838
|
What's the highest fail - I never used higher than 21 in my s-s.
|
12 November 2012, 17:17 | #8 |
Registered User
Join Date: Jan 2002
Location: Germany
Posts: 7,001
|
OK = 0
WARN = 5 ERROR = 10 FAIL = 20 These are the defined return values. A bad program might return anything between 0 and 4294967295, though. |
12 November 2012, 17:30 | #9 | |
Registered User
Join Date: Jan 2002
Location: Germany
Posts: 7,001
|
Quote:
Perhaps you like this small program. Run it like this: Code:
DetectUAE IF NOT WARN ACATune ... EndIF |
|
12 November 2012, 18:16 | #10 |
Paranoid Amigoid
Join Date: Mar 2008
Location: Athens/Greece
Age: 45
Posts: 1,978
|
Thanks a lot Thomas mate.
I was seeking a solution like this as well, since ACATune nowadays, report that it found the board (ACA1230@28 if chipset=AGA or ACA620@25 if chipset<>AGA) even if it doesn't exist = WinUAE. This solved the problem once and for all |
12 November 2012, 19:29 | #11 |
Unregistered User
Join Date: Sep 2012
Location: Copenhagen / DK
Age: 43
Posts: 4,190
|
How does it work? Also by detecting if uaehf.device exist?
Edit: And thanks Codetapper, it now works as it's supposed to. For reference, the S-S part looks like this: Code:
failat 200 version >nil: uaehf.device 1 if warn acatune -maprom devs:kickstarts/kick40068.a1200 >nil: endif Last edited by demolition; 12 November 2012 at 19:38. |
12 November 2012, 21:31 | #12 |
Registered User
Join Date: Jan 2002
Location: Germany
Posts: 7,001
|
|
13 November 2012, 10:56 | #13 |
WinUAE developer
Join Date: Aug 2001
Location: Hämeenlinna/Finland
Age: 49
Posts: 26,516
|
|
13 November 2012, 11:21 | #14 |
Oldtimer
Join Date: Nov 2010
Location: VXO / Sweden
Posts: 153
|
|
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
Thread Tools | |
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
WinUAE won't detect roms in main folder | Maren | support.WinUAE | 11 | 01 October 2010 10:39 |
Is winuae able to detect emulated (Amiga) output resolution? | ceztko | support.WinUAE | 5 | 11 March 2007 23:36 |
WinUAE 1.3 does not detect my Amiga 2.5" IDE HDD | gizmomelb | support.WinUAE | 2 | 18 July 2006 14:46 |
WinUAE doesn't detect joystick button (via ppjoy) | oldpx | support.WinUAE | 16 | 15 July 2004 22:42 |
WinUAE won't detect written CD³² CDs | MethodGit | support.WinUAE | 34 | 04 April 2003 22:41 |
|
|