Mortscript applications repository   

Postby Bleep55 » Sun Sep 02, 2012 7:50 pm

Fatboyfun wrote:You can have a message when enabled, but there are no image handling commands at all in mortscript, so no to the icon, unless you are using something like system information (or even the windows ce desktop) where you can swap an icon file and refresh the screen.


I just returned from vacation and the GPS (MioC230) was on for 2 weeks in my wife's car the whole time. I thought the "Auto Power Off" was enabled and did not notice that the GPS remained on when I parked the car before leaving.
I am using a "System Information" based unlock that I created and am trying to figure a way to show on the main screen that "Auto Power Off" has been enabled.
Any suggestions???

Thanks
Bleep55
Bleep55 offline


User avatar Junior Member



 
Joined: Fri May 21, 2010 3:27 am
Posts: 20
Has thanked: 0 time
Been thanked: 0 time

Postby Fatboyfun » Sun Sep 02, 2012 8:43 pm

There are several ways...

1, A separate script added to the startup sequence that is responsible for starting and monitoring the APO script, and restarts it if for some reason it stops, I'm using something similar for an unrelated project, and it works well.
2, You can use the APO script to swap a red icon for a green icon on the systeminformation display, the SI screen will need to be refreshed, would work but provides no feedback if the script stops, unless you use another script to monitor it, but if you have a sat nav app running, you won't know if it's working or not.
3, Play a short sound effect when power is removed as the countdown starts so you know it will switch off.

The first two would be complicated, the last is easy.
Fatboyfun offline


User avatar Ex Moderator



 
Joined: Mon May 17, 2010 5:34 pm
Posts: 5782
Has thanked: 2 times
Been thanked: 408 times

Postby Jaguarp » Mon Dec 10, 2012 2:34 am

I bought cheap Chinese 7" WinCE GPS and I'm trying to use it as in-dash device, mainly for music from microSD (Renault's head unit only supports CD) via FM transmitter. Installed Auto Power Off (works great), device wakes up upon powering USB (Chinese factory setting) and goes to sleep as intended. But after reboot Auto Power Off is disabled so I have to enable it manually. So I installed Simple Launcher Plus to start Nitrogen and APO on startup but it's not working as I expected. Renamed Nitrogen.exe to Nitrogen_old.exe, renamed RenameMe files and copied them together with mortscript.exe and SIPTool.exe to Nitrogen folder, started it, chose Nitrogen.exe and AutoPowerOff.exe (no arguments - I don't know what they are) and when I start Nitrogen.exe (renamed) everything goes ok. But upon reboot nothing happens - I have to start Nitrogen manually.
Where did I go wrong?
Jaguarp offline


User avatar Junior Member



 
Joined: Wed Nov 28, 2012 9:55 pm
Posts: 6
Has thanked: 0 time
Been thanked: 0 time

Postby Fatboyfun » Mon Dec 10, 2012 7:39 am

You have the option with simple launcher plus to either wait for the application called to complete and exit, or to start it and carry on to the next, did you set this up correctly?

You should in this case not wait for the application to complete.
Fatboyfun offline


User avatar Ex Moderator



 
Joined: Mon May 17, 2010 5:34 pm
Posts: 5782
Has thanked: 2 times
Been thanked: 408 times

Postby Jaguarp » Mon Dec 10, 2012 10:10 am

That's how I set it. Now that I have read my previous post I noticed one misinformation - when I start Nitrogen.exe (renamed) for the fist time or after deleting LaunchOrder.ini I have to choose Nitrogen_old as first application, otherwise nitrogen doesn't start, just APO. Maybe I misunderstood something, I expected this to work same as if I added .lnk file to Windowst\Startup on my WinMo 6.0 phone, and when I reboot it, application associated with that .lnk file starts. Am I wrong?
Jaguarp offline


User avatar Junior Member



 
Joined: Wed Nov 28, 2012 9:55 pm
Posts: 6
Has thanked: 0 time
Been thanked: 0 time

Postby Fatboyfun » Mon Dec 10, 2012 12:41 pm

It should do, the script runs each app as windows does, I'm not sure what's wrong, I'll look into it more when I get home later...
Fatboyfun offline


User avatar Ex Moderator



 
Joined: Mon May 17, 2010 5:34 pm
Posts: 5782
Has thanked: 2 times
Been thanked: 408 times

Postby Fatboyfun » Tue Dec 11, 2012 10:19 pm

I can't see why this won't work, I even tested it again on my device and it works as intended, Only thing i can think of is maybe the "_" character is causing a problem, try renaming Nitrogen.exe to Nitrogen2.exe.
Fatboyfun offline


User avatar Ex Moderator



 
Joined: Mon May 17, 2010 5:34 pm
Posts: 5782
Has thanked: 2 times
Been thanked: 408 times

Postby oodathort » Fri Dec 21, 2012 5:23 pm

Hi can you help me Im trying to get TMC working in Primo using a usb device a TMC reciever and installed in a wince5 dynavin unit this is the mortscript Im trying to use but keep getting syntax error

REGEDIT4

[HKEY_LOCAL_MACHINE\Drivers\USB\LoadClients\1027_24 577]

[HKEY_LOCAL_MACHINE\Drivers\USB\LoadClients\1027_24 577\Default]

[HKEY_LOCAL_MACHINE\Drivers\USB\LoadClients\1027_24 577\Default\Default]

[HKEY_LOCAL_MACHINE\Drivers\USB\LoadClients\1027_24 577\Default\Default\FTDI_DEVICE]
"DLL"="ftdi_ser"

[HKEY_LOCAL_MACHINE\Drivers\USB\LoadClients\Default \Default\255]

[HKEY_LOCAL_MACHINE\Drivers\USB\LoadClients\Default \Default\255\FTDI_DEVICE]
"DLL"="ftdi_ser"

[HKEY_LOCAL_MACHINE\Drivers\USB\ClientDrivers\FTDI_ DEVICE]
"Index"=dword:00000001
"InitialIndex"=dword:00000001 <--- This is for which com port to use 1...9
"Dll"="ftdi_ser"
"Prefix"="COM"
"Version"="1.0.2.11"
"ActiveSyncSetting"=dword:0003e880
"LatencyTimer"=dword:00000010
"DeviceArrayIndex"=dword:00000000


Regards

Stu
oodathort offline


Junior Member



 
Joined: Sat Nov 05, 2011 1:29 pm
Posts: 26
Has thanked: 0 time
Been thanked: 1 time

Postby Fatboyfun » Fri Dec 21, 2012 10:23 pm

Those are not Mortscript commands, they are entries from a .reg file.
Fatboyfun offline


User avatar Ex Moderator



 
Joined: Mon May 17, 2010 5:34 pm
Posts: 5782
Has thanked: 2 times
Been thanked: 408 times

Postby oodathort » Sat Dec 22, 2012 8:19 am

Hi thanks for the super quick reply can you help me here is the article that I have been following I have been able to load the driver and the head unit seems to accept it I did create a folder called reg and placed in $msd$/apps/registry/ custom with the code in it but get a syntax error code.

TMC to USB Port (for Chinese GPS)

--------------------------------------------------------------------------------
Dear All,

I would like to share my experience in this TMC project.
Recently I bought a Chinese GPS 100 unit to connect to my JVC KD AVX40
This has an av out in 320x240 and JVC has an AV in.
You can control the unit via touchpad.

It works correctly to my unit so I decided to get a TMC for this product.
This unit has One USB port which is in Host mode.
So Put a normal USB hub on it and it worked well with Pendrive and External Mouse
Next step, I got a FTDI USB to Rs232 device.

It has FTDI 232BM chip for UART connection it's very important to use chip like this , because of the windows ce driver

I've opened it and I removed chip called SP213EHCA.
In every RS232 there are 2 chips on the board. One is for USB to UART , and the second is for Uart To Rs232.

Because the every TMC receiver uses TTL communication which is working on 3.3v I need to "convert" the unit to USB to UART TTL only.
Obviously you can build a small circuit for this communication, but for myself it was easier to use this solution.

After I removed the Rs232 chip.
Datasheet Page 5 for picture of the pin outs.
You can download it from the FTDI website

The Tmc Receiver pin out is :
Pin definition:
Pin1 Vcc: 5V +- 10%
Pin2 TX: 3.3V TTL level, TMC data output.
Pin3 RX: 3.3V TTL level, receive commands.
Pin4 GND <-- It's not ground It's 5V !!!
Pin5 GND (for mini-USB only)

I soldered a mini USB mother type connector to the chip legs:
PIN2 goes to chip leg 24
PIN3 goes to chip leg 25
PIN5 goes to chip leg 17

So after this I connected the Royaltek TMC unit to my "hacked Rs232" board.
I put the "hacked rs232" to hub and I used a USB mini usb cable for power the tmc unit, so I connect the cable to hub and after that to the tmc.

After this I used this driver for windows ce 5.0
You can download it from the ftdi web site

I have to use mortscript which copy a self made reg file to the registry and copy the ftdi dll to /windows/ folder

Reg:

REGEDIT4

[HKEY_LOCAL_MACHINE\Drivers\USB\LoadClients\1027_24 577]

[HKEY_LOCAL_MACHINE\Drivers\USB\LoadClients\1027_24 577\Default]

[HKEY_LOCAL_MACHINE\Drivers\USB\LoadClients\1027_24 577\Default\Default]

[HKEY_LOCAL_MACHINE\Drivers\USB\LoadClients\1027_24 577\Default\Default\FTDI_DEVICE]
"DLL"="ftdi_ser"

[HKEY_LOCAL_MACHINE\Drivers\USB\LoadClients\Default \Default\255]

[HKEY_LOCAL_MACHINE\Drivers\USB\LoadClients\Default \Default\255\FTDI_DEVICE]
"DLL"="ftdi_ser"

[HKEY_LOCAL_MACHINE\Drivers\USB\ClientDrivers\FTDI_ DEVICE]
"Index"=dword:00000001
"InitialIndex"=dword:00000001 <--- This is for which com port to use 1...9
"Dll"="ftdi_ser"
"Prefix"="COM"
"Version"="1.0.2.11"
"ActiveSyncSetting"=dword:0003e880
"LatencyTimer"=dword:00000010
"DeviceArrayIndex"=dword:00000000

This reg file is directly uses COM PORT 1 (It was free in my device )

After this I created a very small circuit which holds the usb power for 20sec
parallely my reg and driver is installing in this time.
When I reached 20sec My Hive based Windows Registry will recognize the FTDI device and there are no pop up meassegas appear ....

IGO recognized the TMC device hardware

The reason I write this how to , because I read so many forums ,and web pages to find a solution for this , but i didn't find anything.

GNS is providing a TMC receiver for CAR PC but with a prolific based USB to UART chip, and the ARM based cpu is not understanding the driver

Ough I forget the tmc receiver what used:
Royaltek RTA-3000

Have a nince day I hope that I could help to someone
oodathort offline


Junior Member



 
Joined: Sat Nov 05, 2011 1:29 pm
Posts: 26
Has thanked: 0 time
Been thanked: 1 time

Postby Fatboyfun » Sun Dec 23, 2012 12:36 am

Are you able to elaborate on syntax error?

Try with a blank file and adding one entry at a time until it fails.
Fatboyfun offline


User avatar Ex Moderator



 
Joined: Mon May 17, 2010 5:34 pm
Posts: 5782
Has thanked: 2 times
Been thanked: 408 times

Postby oodathort » Sun Dec 23, 2012 8:51 am

Hi

REGEDIT4

[HKEY_LOCAL_MACHINE\Drivers\USB\LoadClients\1027_24 577]

[HKEY_LOCAL_MACHINE\Drivers\USB\LoadClients\1027_24 577\Default]

[HKEY_LOCAL_MACHINE\Drivers\USB\LoadClients\1027_24 577\Default\Default]

[HKEY_LOCAL_MACHINE\Drivers\USB\LoadClients\1027_24 577\Default\Default\FTDI_DEVICE]
"DLL"="ftdi_ser"

[HKEY_LOCAL_MACHINE\Drivers\USB\LoadClients\Default \Default\255]

[HKEY_LOCAL_MACHINE\Drivers\USB\LoadClients\Default \Default\255\FTDI_DEVICE]
"DLL"="ftdi_ser"

[HKEY_LOCAL_MACHINE\Drivers\USB\ClientDrivers\FTDI_ DEVICE]

i can insert the above without a problem as soon as i try to insert index on it shows syntax error

Regards

Stu
oodathort offline


Junior Member



 
Joined: Sat Nov 05, 2011 1:29 pm
Posts: 26
Has thanked: 0 time
Been thanked: 1 time

Postby Fatboyfun » Mon Dec 24, 2012 7:52 pm

What is the exact error message, and did you try just using the section that contains the index line?
Fatboyfun offline


User avatar Ex Moderator



 
Joined: Mon May 17, 2010 5:34 pm
Posts: 5782
Has thanked: 2 times
Been thanked: 408 times

Postby irinuca » Thu Dec 27, 2012 1:36 pm

This is a simple MortScript aplication which create an entry on PDA (320x240) TodayScreen.
I upgraded it to launch an interface that will quickly access various navigation systems and other tools.
After launching the navigation system, the interface will close to save RAM memory .
Also you can SetPath on each navi icon by acces SetPath icon (double blue arrow on top right corner).

Image

[Please Register or Login to download file]
irinuca offline


Junior Member



 
Joined: Sat May 22, 2010 5:41 pm
Posts: 12
Has thanked: 2 times
Been thanked: 9 times

Postby oodathort » Thu Dec 27, 2012 1:52 pm

Hi FBS

that problem is sorted thanks for your help while your on do you have the latest UK maps and Primo 2 or a decent Primo 1 that will use TMC or sys file to use TMC

Thanks :)
oodathort offline


Junior Member



 
Joined: Sat Nov 05, 2011 1:29 pm
Posts: 26
Has thanked: 0 time
Been thanked: 1 time

PreviousNext

Return to Tools & Tutorials

 


  • Related topics
    Replies
    Views
    Last post

Who is online

Users browsing this forum: No registered users and 6 guests