05 May 2016, 16:03 | #1 |
Only Amiga!
Join Date: Jan 2008
Location: London / UK
Age: 53
Posts: 512
|
Roadshow Shutdown Issue
I have finially got my WHDLoad-Cleanup script working the way it should thanks to Thomas in this thread!
The line I have in WHDLoad-Cleanup is AddNetInterface DEVS:NetInterfaces/~(#?.info) QUIET This works just fine when I have my PCMCIA Network card inserted, games fire up and when I exit, Roadshow starts up and my cnet.device also works just fine. But sometimes I used My A1200 without the network card attached, and when I do I get this screen... I don't want to have to keep editing the file when this happens. Is there a way I can make it so that that what my network card is not installed it will not bother me with this error? I would have thought that having QUIET at the end would have done this but clearly not. I know it's not the biggest problem in the world to simply close the windows but I would like to get it working nicely, if only so I learn how to do it. Last edited by manic23; 05 May 2016 at 16:56. |
06 May 2016, 00:00 | #2 |
Registered User
Join Date: Sep 2007
Location: Stockholm
Posts: 4,334
|
Get http://aminet.net/package/util/cli/cardInfo
Make a script that says something like: Code:
CardInfo -p <your card's ID> If WARN QUIT ELSE AddNetInterface DEVS:NetInterfaces/~(#?.info) QUIET ENDIF |
06 May 2016, 09:51 | #3 |
Only Amiga!
Join Date: Jan 2008
Location: London / UK
Age: 53
Posts: 512
|
Roadshow Shutdown Issue
Thanks idrougge I will try that.
Edit: still getting: The command you specified via execute cleanup had failed (returncode=10 doserror=0) I have cardinfo in my C directory Sent from my iPhone using Tapatalk Last edited by manic23; 06 May 2016 at 10:50. |
06 May 2016, 19:57 | #4 |
Registered User
Join Date: Sep 2007
Location: Stockholm
Posts: 4,334
|
What does it say if you run the script from a shell?
|
07 May 2016, 09:51 | #5 |
Only Amiga!
Join Date: Jan 2008
Location: London / UK
Age: 53
Posts: 512
|
It says...
PCMCIA card owned by: compactflash.device ERROR: Unable to claim card I am typing, cardinfo -p compactflash.device I have also tried the volume name and CF0 Sent from my iPhone using Tapatalk |
07 May 2016, 11:10 | #6 |
Registered User
Join Date: Sep 2007
Location: Stockholm
Posts: 4,334
|
The thing after -p should be an identifier string for your card. Check the documentation for CardInfo.
Also, check what Code:
echo $RC |
07 May 2016, 20:03 | #7 |
Only Amiga!
Join Date: Jan 2008
Location: London / UK
Age: 53
Posts: 512
|
I restarted with no Workbench running just the command line and was able to run cardinfo like that. My card ID is 1050, I tried running the command again, cardinfo -p 1050 but still get the error.
I tried running ehco $RC but nothing happened, no result. Thanks for all your help idrougge, really apreciate it, but I'll just live with the error, it;'s not really a major issue and I dont want to take up any more of your time. |
07 May 2016, 20:16 | #8 |
Registered User
Join Date: Sep 2007
Location: Stockholm
Posts: 4,334
|
Try to switch "if WARN" to "if ERROR".
|
07 May 2016, 21:03 | #9 |
Only Amiga!
Join Date: Jan 2008
Location: London / UK
Age: 53
Posts: 512
|
Ok I'll give it a go thanks again
Sent from my iPad using Tapatalk |
08 May 2016, 03:25 | #10 |
Registered User
Join Date: Sep 2007
Location: Stockholm
Posts: 4,334
|
Alternatively, if that doesn't work, try this:
Code:
Assign EXISTS CFD: (or whatever your compact flash device is called) If NOT WARN QUIT ELSE AddNetInterface DEVS:NetInterfaces/~(#?.info) QUIET ENDIF |
08 May 2016, 10:14 | #11 |
Only Amiga!
Join Date: Jan 2008
Location: London / UK
Age: 53
Posts: 512
|
Thanks that 2nd suggestion worked fine when the cf card if inserted, I get no error message when exiting a game. But when the network card is inserted it does not restart the tcp ip stack when exiting lol
Sent from my iPhone using Tapatalk |
08 May 2016, 13:17 | #12 |
Registered User
Join Date: Sep 2007
Location: Stockholm
Posts: 4,334
|
Try changing the CFD: to the volume name of your CF card.
|
08 May 2016, 15:22 | #13 |
Only Amiga!
Join Date: Jan 2008
Location: London / UK
Age: 53
Posts: 512
|
SUCCESS!!!!
Thank you so much for your efforts idrougge, that worked! Now when I have the CF card in I can play games without the annoying error when quitting and when I have the network card in everything works as expected, my network card starts up no problem. You are a genius! Just in case anyone comes across this thread and finds it useful, below is the script that works. Easier to post here rather than wading through all the above posts. This script assumes that you have a CF card named AmigaCF, obviously change this to whatever your CF is called... Code:
Assign EXISTS AmigaCF: If NOT WARN QUIT ELSE AddNetInterface DEVS:NetInterfaces/~(#?.info) QUIET ENDIF Last edited by manic23; 08 May 2016 at 15:42. |
08 May 2016, 16:32 | #14 |
Registered User
Join Date: Sep 2007
Location: Stockholm
Posts: 4,334
|
It's still not the ideal solution because it fails if you insert a card with another name or your PCMCIA slot is empty.
The problem is that CardInfo can't be run if the PCMCIA port is in use by cfd.device. The case if the slot is empty can still be handled by CardInfo, making the script a bit more resilient: Code:
Assign EXISTS AmigaCF: If NOT WARN QUIT ENDIF CardInfo -p <your network card's ID> IF WARN QUIT ELSE AddNetInterface DEVS:NetInterfaces/~(#?.info) QUIET ENDIF Last edited by idrougge; 08 May 2016 at 16:59. |
08 May 2016, 16:42 | #15 |
Only Amiga!
Join Date: Jan 2008
Location: London / UK
Age: 53
Posts: 512
|
OK, thanks for that I will give it a go. I must admit I had not though about if the PCMCIA slot is empty! It's not really an issue for me about difference CF names, as I only use one card at the moment, but even if I end up using more, I can just give them all the same name!!
Last edited by manic23; 08 May 2016 at 16:50. |
08 May 2016, 17:12 | #16 |
Only Amiga!
Join Date: Jan 2008
Location: London / UK
Age: 53
Posts: 512
|
Hmm, can't seem to get that one working, get the old failed at return code error again.
|
08 May 2016, 17:21 | #17 |
Registered User
Join Date: Sep 2007
Location: Stockholm
Posts: 4,334
|
I'm not on an A1200 right now (and usually am not), but it seems that CardInfo reports WARN if the card is not found but ERROR if the card.resource can't be opened (because it's in use by cfd.device). So this might work for all occasions:
Code:
CardInfo -p <your network card's ID> >NIL: IF 0 AddNetInterface DEVS:NetInterfaces/~(#?.info) QUIET ELSE QUIT ENDIF |
08 May 2016, 17:29 | #18 |
Only Amiga!
Join Date: Jan 2008
Location: London / UK
Age: 53
Posts: 512
|
Sorry do you mean to add that to to the after the first ENDIF or is that the full script now?
|
08 May 2016, 17:52 | #19 |
Registered User
Join Date: Sep 2007
Location: Stockholm
Posts: 4,334
|
That's the full script. No warranty.
|
08 May 2016, 17:53 | #20 |
Only Amiga!
Join Date: Jan 2008
Location: London / UK
Age: 53
Posts: 512
|
Lol ok thanks still not working but don't worry I rarely have no card inserted anyway so I'll live with what you have me thanks again
Sent from my iPhone using Tapatalk |
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
Thread Tools | |
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Roadshow 68K - Needs your support! | mech | Amiga scene | 90 | 16 September 2015 01:01 |
Shutdown | Sim085 | support.Other | 2 | 26 March 2015 00:29 |
Virus that stays in memory even after shutdown | cosmiq | Coders. General | 54 | 01 March 2014 17:27 |
Roadshow Update released | AndreasM | News | 0 | 11 November 2013 14:44 |
Trying to run RoadShow | Retrofan | support.Apps | 10 | 10 May 2013 21:00 |
|
|