Application request: EXE launcher lazarus / 35-Windows CE ---------------------------------------------------------------------- CM630 · 2014-12-13 06:57 I would to ask if s.o. could make a simple application for me, to run on Win CE. The application should do the following: When the app is started it should open another EXE, which is stored in another folder. The path of the file to be launched is to be retrieved from a TEXT file. This program would be useful, because the main startup application of my (an probably not only my) navigation device can launch an EXE, stored in a dedicated area of its internal flash drive. But actually after an application is run (i.e. 7ZFile manager), it has access to the full flash drive. My idea is to run the EXE, that hopefully s.o. would build for me, and from it to run the Windows explorer. Of course, if someone would agree to do this for me, I would write the app myself and ask for some one to compile it for me to run on the Win CE. ---------------------------------------------------------------------- bambamns · 2015-01-03 05:42 It is not so hard to compile application for WinCE - just read a few wiki : http://wiki.lazarus.freepascal.org/Windows_CE_Interface http://wiki.lazarus.freepascal.org/Windows_CE_Development_Notes http://wiki.lazarus.freepascal.org/WinCE_Programming_Tips ---------------------------------------------------------------------- Leledumbo · 2015-01-03 06:54 I don't really understand, are you asking for someone to write the app for you, or just compile it for you? Your first and last paragraph seems contradicting... ---------------------------------------------------------------------- typo · 2015-01-03 11:45 Why not to set on Project Options > Target OS > WinCE? ---------------------------------------------------------------------- CM630 · 2015-01-03 11:53 Upon writing the first post I expected that both would be fine for me. I expected that building for WinCE would be much more difficult. Finally it occurred that Lazarus apps don't work on my device, so none would do. ---------------------------------------------------------------------- Leledumbo · 2015-01-03 13:36 Quote from: paskal on January 03, 2015, 12:53:45 pmUpon writing the first post I expected that both would be fine for me. I expected that building for WinCE would be much more difficult. Finally it occurred that Lazarus apps don't work on my device, so none would do. Have you tried a hello, world app? ---------------------------------------------------------------------- CM630 · 2015-01-03 14:38 I have created a single form app with a button on it. It runs in the emulator, but does not run on my device. Forum member chrgra sent me an app, which as far as I understood works on his WinCE5 device, but it still does not run on mine. ---------------------------------------------------------------------- Leledumbo · 2015-01-03 14:56 Quote from: paskal on January 03, 2015, 03:38:59 pmI have created a single form app with a button on it. It runs in the emulator, but does not run on my device. Forum member chrgra sent me an app, which as far as I understood works on his WinCE5 device, but it still does not run on mine. Could you check the WinCE version? ---------------------------------------------------------------------- CM630 · 2015-01-03 16:13 System properties says: Microsoft Windows CE MSB2531.UM.2014-10.15 (c) 2006 Microsoft Corp... Processor Type: MStart Semiconductor CPU should be:Mstar2531 800MHz Manufacturer website sais it is Win 6.0 CE. I have some Memory Settings (Storage Memory and Program Memory). I can adjust how to distribute it. Could this help? ---------------------------------------------------------------------- Leledumbo · 2015-01-03 17:28 Quote from: paskal on January 03, 2015, 05:13:52 pmManufacturer website sais it is Win 6.0 CE. Looks like it's unsupported (unless this wiki page is outdated): http://wiki.freepascal.org/WinCE_port ---------------------------------------------------------------------- CM630 · 2015-01-03 18:17 Applications which work on WinCE 6.0 in emulator do not run on my WinCE 6.0 device. Probably I should contact some of the compiler developers but currently I cannot spend time for that. ---------------------------------------------------------------------- chrgra · 2015-01-04 00:41 Maybe thisc could  solve it (copied from the Lazarus for Android wiki) The mysterious JNI Crash See the thread: http://groups.google.com/group/android- ndk/browse_thread/thread/ba542483f062a828 The problem was that vm^^.GetEnv would crash in HTC Wildfire, Alcatel and in the emulator with SIGILL but not in Xperia Mini, HTC Desire HD, Motorola Atrix and other smartphones. The answer was that one needs to specify -CpARMV6 when building because older instructions might fail in some devices ---------------------------------------------------------------------- CM630 · 2015-01-04 20:02 1. I changed Project-> Project Options->Config and target-> Target Processor= ARMV6 Same errors as shown on the image. 2.  In Project-> Project Options-> Other -> Custom Options I added -CpARMV6. App did not compile and I got in the message window: Code: [Select]Options changed, recompiling clean with -B D:\ok\wince\lib\arm-wince\project1.s: Assembler messages: D:\ok\wince\lib\arm-wince\project1.s:26: Error: cannot represent BFD_RELOC_ARM_PCREL_BLX relocation in this object file format D:\ok\wince\lib\arm-wince\project1.s:41: Error: cannot represent BFD_RELOC_ARM_PCREL_BLX relocation in this object file format D:\ok\wince\lib\arm-wince\project1.s:44: Error: cannot represent BFD_RELOC_ARM_PCREL_BLX relocation in this object file format D:\ok\wince\lib\arm-wince\project1.s:45: Error: cannot represent BFD_RELOC_ARM_PCREL_BLX relocation in this object file format project1.lpr(22) Error: Error while assembling exitcode 1 project1.lpr(22) Fatal: There were 2 errors compiling module, stopping Should I put -CpARMV6 somewhere else? ---------------------------------------------------------------------- Cyrax · 2015-01-04 20:24 Have you tried to use FPC trunk compiler to build your WinCE app? ---------------------------------------------------------------------- engkin · 2015-01-04 22:04 Quote from: CM630 on January 03, 2015, 03:38:59 pmI have created a single form app with a button on it. It runs in the emulator, but does not run on my device. Quote from: CM630 on January 03, 2015, 05:13:52 pmMSB2531.UM.2014-10.15 (c) 2006 Microsoft Corp... Processor Type: MStart Semiconductor CPU should be:Mstar2531 800MHz A quick search indicated that your CPU is *probably* a "Dual Core ARM Cortex-A7". I *guess* you need to use "ARMv7M". Whatever CPU you have, you need to rebuild the RTL and anything else that links into your project for your CPU. IAW, setting project options is *not* enough. Take a closer look at Setting up the Windows CE interface manually mentioned in the first answer you received in this thread from bambamns. ---------------------------------------------------------------------- CM630 · 2015-02-05 12:31 Thanks for the help. For the time being, I have stopped working on that, because the task is too insignificant, in comparison with the time and effort to complete it. I suppose nobody works on WinCE support  anymore, so trying this and that and reporting it in the bugtracker will be useless. ---------------------------------------------------------------------- avra · 2015-02-06 07:52 Have you tried to build console application for your WinCE? If starting EXE is all that is needed maybe that could do the trick? ---------------------------------------------------------------------- CM630 · 2015-02-06 16:19 WinCE has no console, but I tried. Same crashes occur. But I have installed TotalCommander and run it upon startup, it is quite enough for me.