x
This website is using cookies. We use cookies to ensure that we give you the best experience on our website. More info. That's Fine
HPC:Factor Logo 
 
Latest Forum Activity

Launch Applications from CF at Startup

1 2
Rocketman Page Icon Posted 2005-07-27 3:52 PM
#
Avatar image of Rocketman
H/PC Philosopher

Posts:
343
Status:
In my experience with my J720, almost all applications are happy to run from CF. Although many need to be installed to ram to begin with, most can be moved over to flash afterwards. I have managed to get my allocated ram storage down to a little over 4 MB, so even leaving a little wiggle room, I have 25+ MB of ram for running program. With that much ram free, why do I care? Firstly, I do a lot of multitasking and secondly, it looks like Minimo will take up 20+ MB if it can ever be backported to HPC. I was looking at ways of shaving off a bit more space and have hit a few barriers:

- Background image takes up ~450 KB, due to support for only bmp format.
- Applications that you want to automatically start after a soft reset need to be located in ram. If you try to use shortcuts pointing to CF, inconsistent results will occur, as it tends to take a few seconds after a soft reset for the CF to be initialized/mounted. Thus, sometimes the shortcut will be run before the target it is pointing to is available to the system.

I tried addressing the first problem by using a poorly documented/translated japanese program called SQ.exe. This program does let you use jpeg images (if you install the right program plugin and can extract the stupid lzh archive) for backgrounds, but only if you use their desktop/shell replacement mode. You can switch back and forth between the SQ desktop/shell and the original one very easily, but the jpeg image will only appear on the SQ desktop. There are enough deficiencies in the SQ desktop/shell that it pains me to use it just to get jpeg background support.

The second problem could be addressed with a simple application launcher program, but I haven't found one that does what I want. The application launcher would be a small stub of an executable (no more than 5-10 KB) whose sole function would be to wait 5 or so seconds after it is launched, execute a list of programs (located on CF) and the terminate itself. This is such a simple program, yet it would help me free up at least another 500 KB. I could easily write it, but it would mean going through the whole process of setting up a build environment. I wonder if HPC supports batch files that could be used for the same purpose.
 Top of the page
cmonex Page Icon Posted 2005-07-27 5:08 PM
#
Avatar image of cmonex
H/PC Oracle

Posts:
16,175
Location:
Budapest, Hungary
Status:
yes, if i remember correctly, you can setup batch files.. someone wrote about it a lot, do a search for it here

but i think 1 MB doesn't really matter.. 25 or 26 MB.. what's the difference

until chiark finishes minimo , you can try netfront, good as an alternative browser to IE4. it consumes quite some memory but not 20+.
 Top of the page
Rocketman Page Icon Posted 2005-07-27 7:10 PM
#
Avatar image of Rocketman
H/PC Philosopher

Posts:
343
Status:
I will take a look at the possibilities of using batch files. If I come up with something, I will certainly share.

Yeah, I currently use Netfront, IE and FTX for browsing. I also frequently RDP into one of my server boxes and browse from there, as well. Netfront is definitely the best of the 3 on the HPC, but it has some odd quirks. When I start Netfront, it sits at a splash screen that says "constructing the environment file. Please wait..." for a while and then I get "File Write Error - Cannot Save File" I can click the ok button and Netfront then starts right up and operates normally. Once started, Netfront works really well for me. The only major quirk I have noticed is that every once in a while punctuation characters ('s in particular) get replaced by little hollow box characters. Anyone got any ideas on these two errors?
 Top of the page
Snappy! Page Icon Posted 2005-07-27 7:34 PM
#
Avatar image of Snappy!
H/PC Elder

Posts:
1,712
Location:
New Mexico, US
Status:
Here you go ...

http://www.jlime.com/phpBB2/viewtopic.php?t=24&highlight=autorun

Quote

Hi,

I've been playing about, and it looks like it should be possible to start/reboot linux on the jornada 680/690 without going through all the wince calibration / setup.

I've created an autorun.inf which autoruns 'shlo-hp680.exe' from the root of the storage card - just drop the autorun.inf into the root of the storage card.

( http://www.heenan.me.uk/jlime/autorun.inf for a copy)

This works pretty well, so long as you insert the card after wince has got to the first 'setup' screen! (Any earlier and the setup dialogue ends up on top of shlo dialogue)

One thing that could be improved would be if there was a way to make shlo start linux without waiting for you to click on the dialogue - does anyone know if there's a way to do this, or have a copy of the source for the shlo we're using?


[autorun.sh3]
open=shlo-hp680.exe

For 720, it prob is

[autorun.arm]
open=runMyapp.exe
 Top of the page
cmonex Page Icon Posted 2005-07-27 7:34 PM
#
Avatar image of cmonex
H/PC Oracle

Posts:
16,175
Location:
Budapest, Hungary
Status:
hehe this is exactly my setup too

you're getting the error message because you installed netfront on CF. you don't need to care about it, but if you would like Netfront to start faster, install it in RAM and then copy it to CF. maybe you won't get the error messages either then.

punctuation characters.. no idea, never experienced it.
 Top of the page
Rocketman Page Icon Posted 2005-07-27 9:11 PM
#
Avatar image of Rocketman
H/PC Philosopher

Posts:
343
Status:
I tried the autorun.inf thing and couldn't get it to execute anything. I placed a file named "autorun.inf" in the root of the CF card. The contents of the file were:

[autorun.arm]
open=lf.exe

where lf.exe was the executable I was testing with. The executable was in the root directory too.
 Top of the page
anakin
anakin Page Icon Posted 2005-07-27 9:32 PM
#
Status:
What about J690 (2.11) can I install and run applications from CF card? Please advise ...
 Top of the page
wallythacker Page Icon Posted 2005-07-27 9:42 PM
#
Avatar image of wallythacker
H/PC Elder

Posts:
2,156
Location:
Barrie, Ontario
Status:
I have a partial solution, still working on it.

Contents of my autoexec.cmd.ink in \windows\startup

31#"cmd" /c "\Windows\autoexec.cmd"

Don't ask me anything about the number of the meaning of it.CE placed it there when I created the shortcut to \windows\autoexec.cmd

Contents of \windows\autoexec.cmd

:top
if not exist \"storage card\mips\calcnote.exe" goto top
\"storage card\mips\calcnote"
exit

It is an alpha for demonstration purposes. The first line is a label. The second line is a test to see if the executable on the storage card is available, ie, is the CF card initialized. If it's not jump to :top and check again. If the .exe. is there then execute the next line, which in the alpha is calcnote.

Bug: Major bug, once everything is done the command console is still open and has to be manually closed. Everything else works fine, there is no delay in booting or error messages about things on the CF that are missing.

And cmonex, 25 or 26mb? isa *big* deal. I can list a hundred progams that will run nicely within that meg of space and the same number that won't if the ram isn't available
 Top of the page
cmonex Page Icon Posted 2005-07-27 10:25 PM
#
Avatar image of cmonex
H/PC Oracle

Posts:
16,175
Location:
Budapest, Hungary
Status:
anakin - 2005-07-28 3:32 AM

What about J690 (2.11) can I install and run applications from CF card? Please advise ...


you can
 Top of the page
cmonex Page Icon Posted 2005-07-27 10:26 PM
#
Avatar image of cmonex
H/PC Oracle

Posts:
16,175
Location:
Budapest, Hungary
Status:
wallythacker - 2005-07-28 3:42 AM

Don't ask me anything about the number of the meaning of it.CE placed it there when I created the shortcut to \windows\autoexec.cmd


in theory the number is the number of the letters in the command, but in practice you can use any other number there.


Quote

And cmonex, 25 or 26mb? isa *big* deal. I can list a hundred progams that will run nicely within that meg of space and the same number that won't if the ram isn't available


ok, can you list them? or i don't get what you mean
 Top of the page
Snappy! Page Icon Posted 2005-07-27 10:28 PM
#
Avatar image of Snappy!
H/PC Elder

Posts:
1,712
Location:
New Mexico, US
Status:
Rocketman - 2005-07-27 7:11 PM

I tried the autorun.inf thing and couldn't get it to execute anything. I placed a file named "autorun.inf" in the root of the CF card. The contents of the file were:

[autorun.arm]
open=lf.exe

where lf.exe was the executable I was testing with. The executable was in the root directory too.


Ooops, my guess is it could be an in correct cpu naming ...

[autorun.arm4] or

[autorun.arm3] or

[autorun.arm2]

EDIT: I assume you removed and re-inserted the CF card while it is powered on?

Correct me if I am wrong, but I think placing shortcuts in \windows\startup will only run when there is a soft or hard reset.

Edited by Snappy! 2005-07-27 10:35 PM
 Top of the page
wallythacker Page Icon Posted 2005-07-27 10:32 PM
#
Avatar image of wallythacker
H/PC Elder

Posts:
2,156
Location:
Barrie, Ontario
Status:
cmonex, you're pulling my leg on this one aren't you?

I can't run any program if there's no ram left, hence I'll take an extra free meg any way I can get it.
 Top of the page
cmonex Page Icon Posted 2005-07-27 10:40 PM
#
Avatar image of cmonex
H/PC Oracle

Posts:
16,175
Location:
Budapest, Hungary
Status:
naah i wasn't

anyway.. it never made a difference to me if there was 25 or 26 MB ram available after a reset.. it is really rare that this 1 MB would matter, isn't it
though i remember now trying to run destinator on my 720 without a CF (in fact i had a CF card but didn't know how to put the maps there). destinator needs 9 MB ram to run, the executable and maps etc occupied 19 MB, the system needs another 2.5 MB after a soft reset, and there are some hundred KB's-1 MB inevitably occupied in the storage ram too. so after i started destinator, 200-500 KB was left out of the whole 32 MB ram still the program worked wonderfully, no slowdown or running out of ram. (fortunately i found out soon how to put the maps on CF )
but in this case nothing would have helped if there hadn't been enough free ram..
 Top of the page
wallythacker Page Icon Posted 2005-07-27 11:20 PM
#
Avatar image of wallythacker
H/PC Elder

Posts:
2,156
Location:
Barrie, Ontario
Status:
Ah, cmonex, sounds like your "dumbest hpc moment" there

I'm bummed, still can't get the command window to close after everything is done. I'm too tired to google or read docs. I'm hoping someone just steps in with the answer.

Beta: Changelog
autoexec.cmd.ink , unchanged

\windows\autoexec.cmd
:top
if not exist \"storage card\mips\cfboot.cmd" goto top
\"storage card\mips\cfboot.cmd"
exit

This time I'm testing for and transferring control to the .cmd file on the cf card. cfboot.cmd is my batch file with the programs I want executed from the CF card at boot time.

\storage card\mips\cfboot.cmd
\"storage card\mips\soundwidget.m"
\other programs one per line I want to execute.....

It might come to me in my sleep, doubt it tho'

Edited by wallythacker 2005-07-27 11:31 PM
 Top of the page
cmonex Page Icon Posted 2005-07-28 10:53 PM
#
Avatar image of cmonex
H/PC Oracle

Posts:
16,175
Location:
Budapest, Hungary
Status:
try quit command,
i was just going through some screenshots in wince history here, when i saw this:
http://www.hpcfactor.com/support/windowsce/wince211/0024-cmd.gif

or doesn't it help?
 Top of the page
1 2
Jump to forum:
Seconds to generate: 0.234 - Cached queries : 72 - Executed queries : 8