@Bernd M aus F
Dein angehängtes Bild wundert mich etwas! Wieso sieht man da den Gopal Hintergrund?
Sorry, wenns ne blöde Frage war!
@Bernd M aus F
Dein angehängtes Bild wundert mich etwas! Wieso sieht man da den Gopal Hintergrund?
Sorry, wenns ne blöde Frage war!
Hi jwoegebauer,
inspiriert durch einen Beitrag auf GpsPassion habe ich dein script zwischenzeitlich abgeändert.
# menu.mscr
# jwoegerbauer 08/14/2009
# GNU General Public License (GPL), Version 2, June 1991
#
ErrorLevel("off")
Local()
MouseClick(460, 230)
SET PNA_MENU, "\My Flash Disk\original-menu.exe"
Set PDA_MENU, "\Storage Card\MioAutoRun.exe"
i=1
While( i < 20 )
If( NOT FileExists(%PDA_MENU%))
Sleep 1000
Else
SetChoiceEntryFormat(35, 26, "Verdana")
ChoiceDefault("Startup Menu", "*** Startup Menu *** ^NL^Choose whether to run original navigation application ( Gopal ) or MioPocket.^NL^", "", 10, "Gopal", "MioPocket")
Case (1)
Run(%PNA_MENU%)
Exit
Case (2)
Run(%PDA_MENU%)
Exit
Case (0)
Run(%PDA_MENU%)
Exit
EndChoice
EndIf
i = i + 1
EndWhile
Run(%PNA_MENU%)
Exit
#
Hi Bernd M aus F
Das wird es sein was du letztlich haben willst.
@schlork,
ich starte MioPocket nicht automatisch (MioPocket.ini AutoLaunchMP=0), und arbeite für die Hauptanwendungen mit dem GoPalMenu (grosse Finger brauchen große Buttons!), was den Wert von MioPocket aber nicht schmälern soll, ganz im Gegenteil! Die Anwendungen die MioPocket mitbringt liegen alle unter Start/Programs/... und können bei Bedarf von dort aus gestartet werden.
@daniHG,
ja mein StartScript sieht fast genauso aus
Gruss, Bernd M aus F
Der osprey hat für die SD-Free Installation ein neues Startscript (wird bestimmt im nächsten release eingebaut). Das lässt auswählen welches Menu Original oder MP als Default gesetzt wird und nach den eingestellten Sekunden automatisch startet, wenn man nicht vorher manuell das andere wählt. Finde ich sehr praktisch und lässt sich bestimmt auf die SD Installation umbauen.
### MioPocket Installation Script ###
#####################################
ErrorLevel("off")
defaultChoice=1
timeout=0
cwf = SystemPath("ScriptPath")\SystemPath("ScriptName")&SystemPath("ScriptExt")
#Look up the path to the current script to determine where MioPocket is located
Drive = "\"&Part(SystemPath("ScriptPath"),"\",2)
If(NOT DirExists(Drive\"MioAutoRun"))
Message("MioPocket not found.^NL^Directory: """ & Drive\"MioAutoRun" & """ is missing.^NL^Please re-install.^NL^Your original navigation application will now run instead.", "Error")
Call RunOrigNavApp
ElseIf(NOT FileExists(Drive\"MioAutoRun\Scripts\Unlock.mscr") OR NOT FileExists(Drive\"MioAutoRun\Scripts\SysInfo-Start.mscr"))
Message("MioPocket not found.^NL^Some scripts are missing under:^NL^" & Drive\"MioAutoRun\Scripts" & "^NL^Please re-copy files.^NL^Your original navigation application will now run instead.", "Error")
Call RunOrigNavApp
Else
MioPocketINI = Drive\"MioAutoRun\MioPocket.ini"
#If the user has disabled the startup menu, automatically install MioPocket
If(IniRead(MioPocketINI, "Unlock", "StartupMenu") = 0)
#If the device has booted up 25 times since the last hard reset or shutdown, re-enable the startup menu, since the device could be stuck in an endless reboot cycle
If(RegRead("HKLM", "Comm", "BootCount") > 24)
IniWrite(MioPocketINI, "Unlock", "StartupMenu", "1")
Message("This device has soft-resetted 25 times since the last hard reset or shutdown. The startup menu has been re-enabled in case the device is stuck in a reboot cycle.", "Note")
Else
Call RunMioPocket
Exit
EndIf
EndIf
#If MioPocket is already installed, there is no need to display the upcoming menu, so exit
MioPocketInstalled = RegValueExists("HKLM", "SOFTWARE\MioPocket", "Drive")
If(MioPocketInstalled)
Exit
EndIf
NavAppName = SystemPath("ScriptName")
NavAppName = ToUpper(CharAt(NavAppName, 1)) & SubStr(NavAppName, 2)
While(not exitScript)
SetChoiceEntryFormat(35, 26, "Verdana")
ChoiceDefault("SD-Free Startup Menu", "*** SD-Free Startup Menu *** ^NL^Choose whether to run original navigation application (" & NavAppName & ") or MioPocket.", defaultChoice, timeout, "Run " & NavAppName, "Run MioPocket", "___________", "Set timeout", "Set default")
case 1
Call("RunOrigNavApp")
case 2
Call("RunMioPocket")
case 3
#Blank. Used for menu separator.
case 4
Call("SetTimeout")
case 5
Call("SetDefault")
case 0
Exit
EndChoice
EndWhile
EndIf
Sub RunOrigNavApp
#Check for where original Navigation Application executable was renamed/moved to, then run it
cwd = SystemPath("ScriptPath")
cwf = SystemPath("ScriptName")
files = Array(cwd \ cwf & "_orig.exe", cwd & "2" \ cwf & ".exe", cwd & "_org" \ cwf & ".exe", cwd \ "My" & cwf & ".exe")
found = FALSE
msg = ""
ForEach file in array (files)
If(not found AND FileExists(file))
RunWait(File)
found = TRUE
EndIf
msg = msg & file & "^NL^"
EndForEach
If(not found)
BigMessage("Original navigation application not found.^NL^It needs to be at either of the following locations:^NL^^NL^" & msg)
EndIf
exitScript = TRUE
EndSub
Sub RunMioPocket
#Check whether MioPocket is installed and store the answer in a variable
MioPocketInstalled = RegValueExists("HKLM", "SOFTWARE\MioPocket", "Drive")
#If MioPocket is installed, run the startup script; otherwise, run the unlock script to install MioPocket.
If(MioPocketInstalled)
If(not ScriptProcExists("Initialize.mscr") AND not ScriptProcExists("SysInfo-Start.mscr") AND not ProcExists("SystemInformation.exe"))
CallScript(Drive\"MioAutoRun\Scripts\SysInfo-Start.mscr")
EndIf
Else
Call("Unlock")
EndIf
exitScript = TRUE
EndSub
Sub SetTimeout
If(timeout = 0)
timeout = 1
ElseIf(timeout = 3)
timeout = 2
Else
timeout = (timeout / 5) + 2
EndIf
SetChoiceEntryFormat(26, 19)
newTimeout = Choice("Choose timeout", "Choose a timeout in seconds, after which the default menu option will automatically run.", timeout, 0, array("No timeout", "3 seconds", "5 seconds", "10 seconds", "15 seconds", "20 seconds", "25 seconds", "30 seconds", "35 seconds", "40 seconds", "45 seconds", "50 seconds", "55 seconds", "60 seconds"))
If(newTimeout <> timeout)
If(newTimeout = 1)
newTimeout = 0
ElseIf(newTimeout = 2)
newTimeout = 3
Else
newTimeout = (newTimeout - 2) * 5
EndIf
timeout = newTimeOut
EndIf
IniWrite(cwf, "", "timeout", timeout)
EndSub
Sub SetDefault
Choice("Choose default", "Choose the default menu item which will run after the timeout expires.", "Run " & NavAppName, "Run MioPocket")
case 1
IniWrite(cwf, "", "defaultChoice", "1")
case 2
IniWrite(cwf, "", "defaultChoice", "2")
EndChoice
EndSub
Sub Unlock
#If this is the first time installing MioPocket, unset the flag and ask about displaying the start menu in the future
If(IniRead(MioPocketINI, "Unlock", "StartupMenuFirstRun") = 1)
IniWrite(MioPocketINI, "Unlock", "StartupMenuFirstRun", 0)
Call("DisableMenu")
EndIf
CallScript(Drive\"MioAutoRun\Scripts\Unlock.mscr")
EndSub
Sub DisableMenu
Switch(Question("Choose YES to keep the previous startup menu or NO to always launch MioPocket. You will not be asked this again. If you choose NO, to re-enable the menu later, you will need to click on MP Settings on MioPocket's Settings page.","Keep Startup Menu?","YesNo"))
Case(Yes)
IniWrite(MioPocketINI, "Unlock", "StartupMenu", 1)
Case(No)
IniWrite(MioPocketINI, "Unlock", "StartupMenu", 0)
EndSwitch
EndSub
@Bernd M aus F
Ich hatte mal kurz ein 4430 um Miopocket drauf zu installieren. Ich konnte es nicht lange testen, denke aber die von Gopal gestartete Menu.exe (so hiess sie glaub) ist problematisch in Verbindung mit Miopocket.
Das mit den grossen Fingern kenne ich und es wäre für Miopocket eine weitere Bereicherung einen "fingerfreundlichen" Skin zu haben. Ich wollte mir schon lang mal selber einen bauen, hatte aber zu wenig zeit dazu. Was spricht denn für dich dagegen, Miopocket mit Gopal als Skin laufen zu lassen. Du könntest jedes neue release einfach aufspielen und nur jedes Mal deinen Skin zufügen.
Hi schlork
einen fingerfreundlichen Skin bauen, da muß ich erst mal tief durchatmen. Aber genau betrachtet mache ich nichts anders als das GoPal-Menu als fingerfreundlichen Skin laufen zu lassen. Sicher auch weil das GoPal-Menu fertig war und ich mich daran gewöhnt hatte als ich über MioPocket gestolpert bin. Hoffe jetzt nur das die Verwendung des GoPal-Menus nicht als uncool gilt ?
!
Was ich an MioPocket sehr schätze ist die riesige Programmsammlung, die zugehörigen Reg-Einträge (ohne die manches nicht ginge) und Scripten. Vor allem habe ich durch MioPocket viel gelernt und wie gesagt mich überhaupt an MortScript herangetraut. Worauf ich weniger stehe ist die Flut von Icons auf dem Desktop. Da arbeite ich lieber klassisch mit Start/Programme/... .
An MioPocket selbst habe ich nichts verändert, ein neues Release wird einfach einkopiert. Ob das StartScript geändert werden muß hängt davon ab was sich bei MioPocket geändert hat. Bisher vertragen sich MioPocket und GoPal sehr gut, nur beim Softreset kommt manchmal der Fehler vom Explorer. Aber deswegen läuft trotzdem alles, so dass ich ihn einfach ignoriere.
Nächtliche Grüße aus Franken
Bernd M aus F
Hi jwoegebauer,
inspiriert durch einen Beitrag auf GpsPassion habe ich dein script zwischenzeitlich abgeändert.
...
@daniHG,
habe Deinen Änderung bei mir eingebaut. Da meine ursprüngliche Fassung eine Hard-Reset-Erkennung beinhaltete, sieht mein Skript jetzt so aus:
# menu.mscr
# jwoegerbauer 12/05/2009
# GNU General Public License (GPL), Version 2, June 1991
#
ErrorLevel("off")
Local()
MouseClick(460, 230)
SET PNA_MENU, "\My Flash Disk\original-menu.exe"
Set PDA_MENU, "\Storage Card\MioAutoRun.exe"
i=1
GoPAL = 0
MioPocket = 0
While( i < 20 )
If(FileExists(%PDA_MENU%))
SetChoiceEntryFormat(35, 26, "Verdana")
ChoiceDefault("Startup Menu", "*** Startup Menu *** ^NL^Choose whether to run original navigation application ( Gopal ) or MioPocket.^NL^", "", 10, "Gopal", "MioPocket")
Case (1)
GoPAL = 1
Case (2)
MioPocket=1
Case (0)
GoPAL=1
EndChoice
If(GoPAL)
If(NOT FileExists("\Windows\SoftReset.txt"))
CallScript("RepairHardReset.mscr")
WriteFile("\Windows\SoftReset.txt", "", TRUE)
Reset
EndIf
Run(%PNA_MENU%)
Exit
ElseIf(MioPocket=1)
Run(%PDA_MENU%)
Exit
Endif
EndIf
i = i + 1
Sleep 1000
EndWhile
If(NOT FileExists("\Windows\SoftReset.txt"))
CallScript("RepairHardReset.mscr")
WriteFile("\Windows\SoftReset.txt", "", TRUE)
Reset
EndIf
Run(%PNA_MENU%)
Exit
EDIT:
@Bernd M aus F
VipMSCRexe is a utility to run MortScript without Assigning .mscr extension to MortScriptexe.
Advantages of this Utility:
You can have only one installation of MortScript and may be all your script in one another folder.
Now if you want to call any of script copy this exe and rename to your scriptname.exe
Basically if you have script name sashimi.mscr then copy this exe and rename to sashimi.exe and put it in any folder
Root or storage card any where and run exe will execute your script you do not give any path or tell where it located etc.
Wo findest Du dieses Tool?
Download von hier .