mortscript scripts project - Windows Mobile Development and Hacking General

Hi all,
I propose this new thread to put together many of the scripts spread around in a way that anybody can benefit from it with easy an easy configuration.
The standard I propose is the following:
Split all user parameters from the code itself
Split part of codes wich are dependant on each one user configuration from the code itself
Put together scripts that make little use of system resources and battery
Each relevant post could contain a script with credits to the contributors and the wish list for additional code and this post could act as an index to the relevant posts.
My first attempt:
WIFI_ON
WIFI_OFF
I have created two notifications using dotfred taskmanager.
When I connect to my wifi at home it:
updates my gmail email
updates Spb Insight RSS Feed
downloads weather forecast pictures from my country (to use in my desktop theme)
downloads favourite stocks data and graphs (to use in my desktop theme)
updates quickgps info
updates gmail email
When I disconnect it copies weather data from one program to another:
[*]In this case it copies WAD2 weather info to S2U2. (thanks to alanlsmith at lakeridge forums)
In this example, somebody may share their code to update yahoo accounts or other RSS programs, etc. We could also share other ways of waking up the device. Any user could simply adjust the parameter files and be up and running.
My wish list now is:
* add log code that can be "plugged" to any of the scripts.
* add code to sync when connected to the PC
* give credit to all the people whose code I am using.
* create a include module of paths values so everybody can install this where they want, both the scripts and the registry values created.
* register when the info of each module was last updated so to decide if it should update it again or not: eg. a user may want to update email every hour but the weather or RRS info only once a day.
* create a structure for launching the desired tweaks (on/off), registry exports, registry imports, etc.
Hope some of you want to try and others find useful this scripts

cruiserrr said:
Hi all,
I propose this new thread to put together many of the scripts spread around in a way that anybody can benefit from it with easy an easy configuration.
Each relevant post could contain a script with credits to the contributors and the wish list for additional code and this post could act as an index to the relevant posts.
Hope some of you want to try and others find useful this scripts
Click to expand...
Click to collapse
Like this http://forum.xda-developers.com/showthread.php?t=289197

Not really !
I read this thread quite often because is full of good code and ideas.
My idea is rather to build something really easy to set-up for new users that can also save tons of times for advanced users. Is more a "sashimi" like, giving UI for tweaks, automation, backup, scripts & icon generation menu, links maintenance, set-up after hard-reset, profiles, backups, interaction for themes apps such as rl-today, s2u2 or wad...
The mortscript accumulation thread is simply great and people exchange lots of codes and ideas but each one has to take the bits and re-code. That's why I propose to build a small "application" so we can consolidate and reuse the code we generate... and have fun by doing so !
(In fact, similar ideas to split Q&A and scripts have been expressed more or less in the same thread several times)

Wombat's PhoneRoam Script
Here is my first attempt of writing a script with Mortscript
It keeps you connected to High Speed Data Only and disconnects if you stray onto G or E type networks to save on Roaming Charges.
I hope you enjoy
http://forum.xda-developers.com/showthread.php?t=462964

Related

Feature requests - give them to me!

Hey,
I am parsing a list of feature requests for the next update on touch innovation
Basically post whatever you want to see on there to make your browsing experience easier!
Thanks
(see sig for link)
not sure if you have this already
but how about a mobile version of the site where you can
easily download the cab files to the phone
-=edit=-
Sorry you have already something similar
Keep up the good work
Yeah I do,
It will automatically re-direct you if your on your phone! But this feature is to be improved. I am also recoding the website's html to make it more cross-browser compatible!
Another feature soon to come will be "Add applications LIVE to the website" where you can add a program, choose the category and it will add it, with of course lots of security such as only cabs and zips allowed, and it will warn you when you download a "User-submitted" application, that it is liable for virus's. But each and everyone will be checked by our admin team.
Any more ideas?
Thanks
Specific descriptions of what the programs are and do. The "copy and paste" of the author's descriptions aren't always descriptive enough to figure out what the programs really do or if they're worth a try.
The names themselves are good clues, but it's limiting.
I would also suggest taking out the narrative and simply write what the programs are. For example:
HTC Home Customizer:
"Do you have a HTC phone, that has the htc today plugin? No? Ah well doesn't matter because this programs automatically downloads and installs it for you, not only that.. but it lets you customize it to the tiniest detail.
Enjoy!"
Why not just say that it "The program customizes and if needed, installs the HTC Today plugin."
One sentence that says the same thing.
Or...
iContact - Burt Edition:
"Truburt has done it again. Yet more features, including:
- Improved scroll speed
- Improved search feature
- Lots of small improvements
- Lots of bug fixes.
Enjoy!"
This should be in the features section and a description of the program (it's differences to the others) should be there.
You get the idea. There's a lot of good stuff there, but I might just be the only one that have a hard time figuring out what the new programs do. It'll be obvious to a regular user, but to someone new, it'll be hard to figure out the difference between the three... four... five? iContact programs.
On that note, I suggest removing the old versions of Burt's iContact.
And maybe put the Main Features right under the Information section.

[Software] Finansist.PDA v1.2 (24.12.2009)

Finansist.PDA
Hi all!
I glad to show my first project for PPC - Finansist.PDA
Use Finansist.PDA to take account of your finances with the possibility of synchronizing with multiple computers. Program Finansist.PDA offers many functions (some of them are in development) to obtain the current exchange rate from the Internet, show reports, etc.
There are maybe some control layout bugs at different screen resolutions (I've tested at 320*240).
Known bugs and issues:
* After you change the lang - you need reboot application
System Requirements:
* Windows Mobile 5, 6, 6.1, 6.5 (not tested yet)
* DotNet Compact Framework 3.5
Website: http://finansist.chanaev.ru/
Important! To update aplication without lose my data you need copy file MainDB.fdb from path_where_you_install_application\Database\ to any safe place (for example to \My Documents). After that install new version and copy this file back, overwriting existing new file.
Download:
Version 1.0 CAB: View attachment 222095
Changelog:
Initional release with base functions
Version 1.1 CAB: View attachment 222096
Changelog:
If the application installed in a folder other than \Program Files\Finansist PDA\ - required to manually correct the configuration file. Otherwise application don't work.
Controls layout for different screen resolution and layouts
Possibility to add payment into root categories
Cleanup initial database
Category which are curently selected in a category tree goes to New Payment form.
Interface changes in category tree context menu.
Subcategory payments included in output table when category in treeview clicked.
Database errors now also processed by translation module
Autoselect language during first launch
Field «Translated by:» in programm «About» form
Version 1.2 CAB: View attachment 260889
Changelog:
Possibility to set number of displayed rows in the table of payments
Possibility to display payments in subcategories with selected category payments
Possibility to work with many databases. You can disable dialog of database selection and work just with one database. Also you can create, open, compress, delete, set password see database properties and so on.
Database password protection
Many world currencies. For better usability you can select currencies which you use. Non-active will be not displayed in system (for exapmple in account management).
Database versioning. Converting to new format processed automatically without any data lost. This version has database v1. Finansist v1.1 and v1.0 had v0 database.
Possibility to copy databases from PC and back via ActiveSync. First step into records synchronizing. PC client available at the website.
Basic help at english language actually contained general information.
Fixed dates range calculation in Reports
Fixed some crashes in account management
Improvement of internal algorhythms for better perfomance and so on.
Feedback are welcome!
Enjoy =)
Change Currency
Hi, could you tell me how to change the currency???? I use TT$
hmm
Thanks for it
zjxpot, Unfortunately right now there is no possibility to do it. This function is in development stage. I guess it will be avaible as soon as possible.
yonta, you are welcome
2All, I've published new version. See changes and download app from header post.
Password
Hi in menu/option the password box is disabled how do I enable also in new payment regular payment is disabled how to enable or are those option for future use??? btw nice program
Finansist PDA v1.2 has been released after long time pause. Many changes in code, some new feautures and improvements. Work with PC as main feature must simplify process of money tracking and reporting. Don't forget about backup data at your device before first sync. List of changes is in header. Enjoy.
zjxpot, new version support many currencies
chanaev said:
Finansist PDA v1.2 has been released after long time pause. Many changes in code, some new feautures and improvements. Work with PC as main feature must simplify process of money tracking and reporting. Don't forget about backup data at your device before first sync. List of changes is in header. Enjoy.
zjxpot, new version support many currencies
Click to expand...
Click to collapse
Thanks for your work, I will check it out, All the best during this holiday season to you and your family
congrats on the new version

[TOOL][25-09-2009] MortScript Suite 2.0

Hello to all,
"Script Suite 2.0" is ready and it's my first "developer" contribution to this forum.
I'll try to extend with other scripts and contribution by other people to have a full library of scripts able to extends functionalities for programs like WAD, Throttle Launcher, and every other similar fundamentally able to read on registry and to show pics
Infact all scripts write on registry all the info needed, and save on the configured folders the pic.
I made my best to make very easy to use and configure for final user.
So in the end I built everything so that to make them fully working you would need 3 steps:
1- Downloading the package
2- Installing mortscript
3- Configure a single properties.ini file
Scripts are organized in folders, so if somebody doesn't want some of them, he can simply delete the folder and clean the sections on properties.ini.
I already planned many new scripts and some improvements, of course every suggestion is welcome, both for new scripts and for improvements
Before to go on I want to thank:
- Mort for Mortscript and MortPlayer. Really both programs wonderful and powerful
- Gslide for Gslide program. Great mortscript programming and organization here, without studying his work I couldn't give you tasks and rss scripts.
- Alan Smith on this forum for Mail and SMS scripts
- Alfonso Presa for Message2Reg (to use the above scripts)
- Jokes On You for sms' sender pic inspiration
- Rats for moon script inspiration
- Rumball for stock scripts inspiration
I hope I didn't forget anyone, if somebody find his work here please tell me to give him his right!
In following posts some explanation about how to use the "suite"
As proof, I applied all scripts on a WAD skin:
http://www.lakeridgesoftware.com/forum/showthread.php?t=15662
Changelog
v2.0
- Better list management (with delete)
- Last caller pic (similar to last sms sender pic)
- Refactoring to use common functionalities. In particular, now is possible to have advanced connection, advanced line formatting and scrolling list functions available for every scripts needing them
- Meteo - MoonState, script retrieving info about moon state on the internet
- Mail - used new functions to format subject and body
- Rss,tasks - Implemented list scrolling in rss and tasks using the common script
- Implemented scrolling photo
- Stocks - add dynamic stock sign (plus/minus)
- Location - take info from cellId and save as a string if you like
- GPS - Current location info + calculate directions
- Scheduler - improved management
v1.0
- Agenda - Saint of the day, tasks
- GPS - Read basic information from GPS
- Images - choose random images from a folder (and one level subfolder), open album on directory set as parameter
- Mail, Messages - integration of Alan Smith scripts
- Meteo - Meteo radars list
- Music - Mortscript controls and data from registry, search and download album art from internet
- RSS - Download feeds and open link if click on article
- Scheduler - scripts to launch the other auto-updating scripts
- Stocks - Stock info with managing of bought quotes
Properties.ini
Explaining Properties.ini
As said in first post, editing Properties.ini is the only thing you need to use all the info provided by scripts.
I think the best thing to do is to provide a sample Properties.ini (fully working on my machine) and to explain section for section:
[Registry]
RegRoot=HKCU
RegPath=\Software\My_Utilities\
*** Here everyone is free to configure his own registry path where to store information. However I would suggest to don't change it simply because all the info related to Message2Reg will go under this path (no way to change...) so I think it's better to have everything at a place. Moreover, the name is enough generic to be good for everybody.
[Connection]
#Type=Check|3g
Type=Check
RetryTimeout=5
Retries=3
3gNetwork=Vodafone Web GPRS
*** Added this section to let you decide how to manage connection.
Type: currently only two values are managed.
- Check means if connection is already present then use it.
- 3g means if connection is not present than force a 3g connection.
- I thought about a "wifi" managing too but didn't find a good tool to use on my HD to toggle WiFi. Every suggestion is accepted
RetryTimeout: how much to wait for connection
Retries: how many times retry the check.
- In this example we'll wait max 15 (=3x5) seconds before to say connection failed.
3gNetwork: Name of 3g network to use
[GPS]
RefreshGPSTime=5
RefreshCityTime=5
RefreshAutoTime=600
#Unit=Km|Mp
Unit=Km
ExpressWay=true
*** Here you configure the refresh GPS interval in seconds. Of course GPS must be active
RefreshCityTime indicates how many minutes wait before to update current location (you need a connection)
RefreshAutoTime indicate how many seconds wait before to automatically update the directions.
Unit indicate the unit measure chosen
ExpressWay indicate if you want to use motorway in calculating directions.
[Images]
GraphicsPath=\Program Files\Lakeridge\WisBar Advance Desktop\Themes\Filli_Common\Graphic\
ScriptsPath=\Program Files\Lakeridge\WisBar Advance Desktop\Themes\Filli_Common\Scripts\
RefreshImagesTime=120
*** Here you can configure:
*** scripts path (variable extensively used practically by every script)
*** graphics path, that is where your theme graphical files are
*** Time in minutes to wait before to change images
[Folders]
BigImageP1=\Storage Card\Skin\Wad2\Wallpaper800_P|file|bigImage.jpg
BigImageP2=\Storage Card\Skin\Wad2\Wallpaper800_P|file|bigImage2.jpg
BigImageP3=\Storage Card\Skin\Wad2\Wallpaper800_P|file|bigImage3.jpg
BigImageP4=\Storage Card\Skin\Wad2\Wallpaper800_P|file|bigImage4.jpg
BigImageL1=\Storage Card\Skin\Wad2\Wallpaper800_L|file|bigImageL.jpg
AnalogClock=\Storage Card\Skin\Wad2\BKG_CLock|file|AnalogClock\WadClock .png
SmallImageP=\Storage Card\Foto\My Pictures\|file|smallImage.jpg
SmallImageL=\Storage Card\Foto\My Pictures L\|file|smallImage2.jpg
OthersBigP=\Storage Card\Skin\Wad2\Wallpaper800_P\Other|dir|othersBigP .jpg
OthersBigL=\Storage Card\Skin\Wad2\Wallpaper800_L\Other|dir|othersBigL .jpg
OthersSmallP=\Storage Card\Skin\Wad2\Wallpaper800_P\Other|dir|othersSmal lP.jpg
OthersSmallL=\Storage Card\Skin\Wad2\Wallpaper800_L\Other|dir|othersSmal lL.jpg
*** Here it's possible to configure a free and dynamic list, that is you can name directories as you want and put all the directories you want. As you can see every folder has 3 properties, separated by "|":
*** Path
*** Type (dir or file)
*** Destination file
*** How it works? Well, those info needs to included Random.mscr script. For every folder, if type is "file" will randomly choose a file directly in that folder, else ("dir") will be chosen a file in a subdir. The chosen file will be saved in "GraphicsPath/Destination file".
"dir" is very important if you have a lot of wallpapers for example (I noticed more than 400 files in a single directory will slow down machine) or if you like to organize your photo in subfolder.
After you configured your list, start "randoms.mscr", and every RefreshImagesTime you'll have a new pic.
[FormatLongText]
LengthOfText=350
NoOfLines=10
LineLength=40
Adjust=2
*** Those parameters (mainly LineLength) needs to manage long strings in scripts like mail, rss, tasks, and other info you can retrieve from internet. If text/line is too long it will be cut and "..." will be inserted at end.
[Mail]
RefreshMailTime=30
*** Simply set how to wait until next mail sync
[MailServices]
MailService1=Gmail
MailService2=Hotmail
*** Free and dynamic list to set all the mail service you need
[Messaging]
ContactsPath=\Storage Card\Contacts\Contacts128\
*** This needs to know where to get sender sms or caller pic if you want to show in your skin
[Meteo]
RefreshMeteoTime=180
*** Here you can configure minutes before every radar download
[Radars]
1=http://static.die.net/earth/mercator/800.jpg
2=http://static.die.net/moon/400.jpg
3=http://magazine.enel.it/meteo/img/v_meteoimg/msg/italy/bis/curr_ita.jpg
4=http://eur.yimg.com/w/wcom/eur_italy_outlook_it_IT_440_dmy_y.jpg
5=http://oiswww.eumetsat.org/IPPS/html/latestImages/EUMETSAT_MSG_RGB-naturalcolor-centralEurope.jpg
6=http://eur.yimg.com/w/wcom/eur_satintl_440_dmy_y.jpg
7=http://oiswww.eumetsat.org/IPPS/html/latestImages/EUMETSAT_MSG_VIS006EColor-centralEurope.jpg
8=http://www.inmh.ro/images/mradar.jpeg
9=http://www.meteoromania.ro/images/harta/temp.jpg
*** Dynamic list to use all the meteo radar you wants. You need to name them as a sequence number if you want switching by them working
[Internet]
DefaultBrowser = \Windows\OperaL.exe
*** Choose your browser to start rss links
[RSS]
MaxElementsForFeed=10
RefreshRSSTime=60
*** Here you can configure RSS refresh time in minutes, and max number of elements for each RSS Feed. Can be handy if you have very big feeds but you needs only few on WAD2.
[RSS Feeds]
Repubblica Home=http://rss.feedsportal.com/c/32275/f/438637/index.rss
*** Free and dynamic list for RSS, you are free to choose name, simply set correctly the link!
[Tasks]
RefreshTasksTime=60
*** How many minutes wait before to refresh tasks in case you changed them.
[Stocks]
Interval=20
StartHour=8:0
StopHour=17:50
chartDownload=1
*** Refresh parameters for stocks. On weekend download is already disabled, for working days you can choose the interval (how many minutes to wait before next update), start and stop hour (for minutes less than 10 doesn't put "0" in front) and if you want to download charts
[StockList]
Borsa Milano = FTSEMIB.MI|FTSEMIB.MI|0|0|I
Euro Dollaro = EURUSD|EURUSD|5000|1,32|X
Euro Ron = EURRON|EURRON|0|0|X
Google = GOOG|GOOG|0|0|A
*** Free and dynamic list to manage your stocks.
*** First field is the name you find on Yahoo
*** Second field the one found on google (sometime they differs)
*** Third field how many stocks you own
*** Fourth field average price for your bought stocks
*** Fifth field type of stock, "X" for money change, "I" for general index, "A" for normal quotes. It's important to download the correct info/graphs
[Location]
RefreshLocationTime=5
*** Indicate how many minutes wait before to update current location (based on cellId)
Folders
Here some explanation about how to use the scripts inside folders
*** Agenda
- Tasks.mscr retrieve tasks from outlook and put on registry so you can read them in WAD
- ScrollTasks.mscr needs to scroll up and down tasks
- SantodelGiorno.mscr retrieve the Catholic Saint of the day from internet and put info on the internet. More a sample to see how to treat info coming from the net.
*** GPS
- GPSScript.mscr write on registry some info about GPS. It works only if GPS is active, of course.
- FindCity.mscr find all info about your current city and current address. It works thanks to GPSToday, which activate GPS and take some info (other are taken from internet)
- GetDirections.mscr calculate path between two address. It needs a connection. Can be used once or called automatically every a configurable number of seconds ([GPS] RefreshAutoTime)
- ScrollDirections.mscr to scroll up and down directions
*** Images
- Randoms.mscr will choose randomly files as explained in above post. It will take a file from the configured directory (or subdirectory), will save the chosen directory on registry, and will copy the file on the configured one.
- AlbumCameraFolder.exe can be used inside WAD2 to open the related image folder inside album.
For example "AlbumCameraFolder.exe BigImageP1" will open the "\Storage Card\Skin\Wad2\Wallpaper800_P" folder, if you use the above properties.ini file
Instead "AlbumCameraFolder.exe OthersBigP" willl open the randomly chosen subdir under "\Storage Card\Skin\Wad2\Wallpaper800_P\Other", because type was "dir".
Practically speaking in WAD you'll find a photo, and clicking on it you'll open the folder where the photo is.
- ScrollPhoto.mscr to scroll up and down photos in the same folder of current one in a linear way
- callerPic.mscr make possible to use the pic of last caller
*** Location
- Location.mscr read the current cellId and Lac and put in registry
- saveLocation.mscr let you save current location using the name you like
*** Mail
Those are the Alan Smith scripts, simply adapted to this organization, and more:
- SyncService.exe will sync the single service
- SyncAllServices.mscr will read your configured mail services and will update all of them
- OpenMailInbox.exe needs to open a service inbox
*** Messages
Again Alan Smith files, and more:
- senderPic.exe to update the sms sender pic when browsing them on WAD2
*** Meteo
- Moonphases.mscr download moon pic and read moon phases from internet
- DownloadMeteoRadar.mscr downloads all the Radars link configured.
- ChangeMeteoRadar.mscr needs to browse beetwen radars images in skin, and accept "next" or "prev" as directions
*** Music
- Various mortplayer remote controls to be used from skin
- WADAlbumArt.mscr go to internet trying to find the album art according to information stored on mp3, and written on registry by mortplayer (basycally author/album). If cover it's already present it will not try to download again
*** RSS
- MortXML.xml and RSS.xml are "services" scripts and don't needs to be touched
- DownloadRSS.xml will download feeds and update registry
- SetCurrentRSS.exe will set the current feed so to switch beetwen them on your skins
- OpenCurrentLink.exe it's to be associated to text read by WAD on registry to start the browser and read the news.
- ScrollRSSInfo needs to scroll RSS articles
*** Scheduler
- ScheduledDownload.mscr it's just a script to start all downloads together (for now). Maybe it will become a "serious" scheduler, however for now all single scripts have their own scheduling
*** Stocks
- StockConfig.mscr will read info from Stock List in configuration and update registry. Every time you change something in the list you need to run this script
- UpdateStocks.mscr in practice is the scheduler. If you are in the configured days and hours it will start the downloads
- DownloadGraph.mscr and DownloadStocks.mscr are the scripts to download the graph images and the stock informations. Normally they are managed by UpdateStocks.mscr
- SetCurrentStock.mscr and RefreshCurrent.mscr permits to browse beetwen graphs and informations and to update graphs.
*** Utility
- Connect.mscr let you choose how you want to manage connections. At the moment, it can simple check if a connection already exist or force a 3g connection. I would like to implement forcing a Wifi connection, however I still didn't find a reliable tool to toggle wifi
- FormatLine.mscr needs to clean texts and to format them in various lines if too long
- ScrollList.mscr it's the general script to manage scrolling generic lists of element up and down.
Good work, well done
Great work! Should put it in the MortScript examples accumulation thread, too.
I find that when the phone is off, although the location.mscr does run every 5 minutes, the location data obtained from rilcmdline during phone off is still the location data when the phone was last turned on. I proof it by putting a timestamp at the showedLocation field.
In summary, the location cannot update when phone is off. Is there any solution for this? Thanks.
actually this was posted in the examples a long time ago.
it's also been listed in the Morstscript Compendium of course...
Hi,
Me again.
So I am going to add RSS to StatusTicker with your RSS script.
With this rss:
Craigslist=http://losangeles.craigslist.org/sfv/zip/index.rss
It downloads the RSS file just fine. But it doesn't seem to be parsing the headers back into the registry.
I only just got started. If you happen to know what's making it not work that would be cool. I will look some more.
thanks much
ahlok_hk said:
Great work! Should put it in the MortScript examples accumulation thread, too.
I find that when the phone is off, although the location.mscr does run every 5 minutes, the location data obtained from rilcmdline during phone off is still the location data when the phone was last turned on. I proof it by putting a timestamp at the showedLocation field.
In summary, the location cannot update when phone is off. Is there any solution for this? Thanks.
Click to expand...
Click to collapse
Sorry for late answer, I had little time for phone lately.
However I simply used a freeware rilcmdline.exe I've found on the forum and I'm saving results on registry so to be available for other applications. I'm afraid the problem you said is about exe and I can't do anything with exe
A chance could be to activate screen before to update RIL, but I'm afraid battery will last very little after.
On the other side, I see this important if you use location to switch profiles, but if like me you only need a visual information, well, you'll have to switch on the phone to see location on WAD so no problem
howdykeith said:
Hi,
Me again.
So I am going to add RSS to StatusTicker with your RSS script.
With this rss:
Craigslist=http://losangeles.craigslist.org/sfv/zip/index.rss
It downloads the RSS file just fine. But it doesn't seem to be parsing the headers back into the registry.
I only just got started. If you happen to know what's making it not work that would be cool. I will look some more.
thanks much
Click to expand...
Click to collapse
Hello howdy,
sorry for late answer, as I said before had very little time for phone.
Strange your RSS doesn't work, I used the same script with little modifications for a Twitter script I'm going to post some time in v3.0.
You would need together the Download_RSS.mscr, RSS.mscr and MortXML.mscr script because everything would work (about writing in registry).
I use those scripts every day so let me know where the problem is (I'm sure you correctly setup the .ini file...)

[APP][PRJ] MyDVD Collection - a Barcorama companion

Hey guys,
I'm delving into PPC development for the first time (have done other development in .NET but never for PPC). I'm creating an application called MyDVD Collection. It will be a handheld database for keeping track of DVDs/CDs/Console games. Now, what's going to make mine a little different than others like this is that I have designed it to work in conjunction w/ Barcorama. Basically, you'll be able to set this program as the external executable which Barcorama passes its scanned barcode to. It will then check your collection to see if you already own it, give you the ability to add it if it does not exist, and will eventually pull information from the Internet about that item and auto fill (as soon as I find a reliable way to do that).
So far, I have the basic database structure defined and have the screen built to view the items in the database, as well as a way to filter that view. Next is to build the entry form for adding items, and a basic search function. I should have an alpha version ready for testing soon. If anyone is interested in testing, please let me know.

[Q] What debug and log tools are available?

Hi,
I'm interested to know which debugging/logging tools are available.
I'd like to get more information about the processes at startup, and specially logs of the CPU usage by each application over a period of time.
I've been searching for some time and the only I've found are the old Htc Test applications, but can't get what I want.
Noted that HTC devices have a builtin debug tool (debuglog.dll). Anyone knows how to use it?
Also found the following the following post describing the HTCDiagDriver and the possibility to analyze the device using QUALCOMM eXtensible Diagnostic Monitor.
http://forum.xda-developers.com/showpost.php?p=12624471&postcount=2
Anyone uses it?
Global debuglog can be enabled via DebugTool.exe (available in Htc Test Applications). It depends on debuglog.dll, yeah. Read manual, it works quite well.
Then, if you want to get log for selected app, launch it via IDA.
Also we have CeLog available, I will post needed launchers soon. I can hardly call it useful as we have retail/ship SYS builds. The only useful purpose for us is page faults chart.
EDIT: CeLog attached.
Some of the builds come with the Perfman package. That s.o.b. will really slow down your device, though, and it creates a massive log file, which I could never find the tools to analyze. I think celog does it, though, which is pretty sweet.
The htc debugger works better. You just change one of the debug flags and reset, and the device starts writing the log file. It doesn't slow down the device nearly as much as perfman. I think celog may work on that log file, too. You can royally eff up your device with that tool, though, if you mess with the radio flags. It's pretty cool how it writes to flash memory. Too bad you can't change other things with it like the page pool size.
ultrashot said:
Also we have CeLog available, I will post needed launchers soon. I can hardly call it useful as we have retail/ship SYS builds. The only useful purpose for us is page faults chart.
EDIT: CeLog attached.
Click to expand...
Click to collapse
I have been playing with the tool on my Tornado and observed the following (usage related):
Use it while the device is disconnected from PC. The overhead of repllog.exe (connected to ActiveSync on XP PC) and syncing is just filling your log. For my installation (no further MS Mobile development tools on the PC) kerneltracker.exe does not connect to the device anyway.
Though obvious, the files CeLog*.exe have to run on the device, so copy them to a convenient place there.
The CeLogAttach.exe seems to start the kernel logging and it slows down the device (kind of obvious). There is no way to stop this logging. Something like CeLogDetach would be needed, if it exists, to restore the state before CeLogAttach.exe was run.
The CeLogFlush.exe will flush the existing log but also immediately start the logging again.
The CeLogStopFlush.exe does just what the name tells - it stops the flush to file of the (still ongoing) logging.
After transfering the celog.clg file (from \Release\ directory of the device) it can be opened in kerneltracker.exe. Then you see all the kernelactivities logged and aligned per process/thread on a zoom-able timeline (10ms - 10s) including the labels of the logged primitives. With event filtering you can sort out what you are not interested in. Here you may need advice on what to look after when you want to hunt down a certain device behaviour.
I have checked for page-faults, Virtual Memory related actions (Allocate, Copy, Free) and also Module actions (load, free) to get a clue if and how modules and paging (or better said: the use of the Page-Pool) is correlated. Nothing eye-striking coming up here, but it may just be for the unknowing observer like myself.
@ultrashot: I could not find anything I would call a "page faults chart" - where is that - or what is that?
Looking further: If I change certain device properties (like increase the pagepool or playing with OSB advanced options) I fear that the logged information here is just far too detailed for a useful compare. For that you would have to create identical conditions for the action under scrutiny - something that cannot be done with a disconnected device.
So I have to admit that all objective compare of such tuning and tweaking is far above my head and I just have to join the many that make more or less clever assumptions trusting on their model of actions in their heads. I hope that the better knowing heads continue to spread their wisdom without only telling RTFM or guide with LMGTFY (which can help if the results really point to right places).
tobbbie said:
@ultrashot: I could not find anything I would call a "page faults chart" - where is that - or what is that?
Click to expand...
Click to collapse
Use Event filter->Miscellaneous->Page fault.
I am not too advanced user of this tool. If we had builds with extra celog instrumentation, we could have take much more from this tool. However, there are some articles in the internets about celog, so anyone who wants to be get more info may just try to google it. I don't want
ultrashot said:
Use Event filter->Miscellaneous->Page fault.
Click to expand...
Click to collapse
That is what I did already when telling about the items I cared below. Page faults are however part of generic virtual memory management and they do also apply for any normal loaded executables. As you know I seek for traces of module related paging and the use of the page-pool.
So it will stay with the trial and error and side-by-side compare with two devices having different settings. Not a big thing doing that...
Some interesting articles on MSDN regarding the paging pool (aka "pagepool"):
Kernel Blog article explaining the fundamentals (highly recommended): http://blogs.msdn.com/b/ce_base/archive/2008/01/19/paging-and-the-windows-ce-paging-pool.aspx
Pagepool Variable explained and simple methods to measure impact: http://msdn.microsoft.com/en-us/library/aa451041.aspx
-> this is what kitchentools are patching in the kernel
Then some more backup on virtual memory - just to complete on that:
http://blogs.msdn.com/b/ce_base/archive/2006/10/30/what-is-virtual-memory.aspx
http://blogs.msdn.com/b/hegenderfer/archive/2007/08/31/slaying-the-virtual-memory-monster.aspx
http://blogs.msdn.com/b/hegenderfer...aying-the-virtual-memory-monster-part-ii.aspx
And to get back to the debug tools topic of this thread, linked form the first article an introduction to the Remote Kernel Tracker to explain what you can actually see there (and why you cannot see certain things as we have shipped ROM builds and not profiling builds to deal with): http://blogs.msdn.com/b/sloh/archive/2005/05/17/introduction-to-remote-kernel-tracker.aspx
Great insight if you want to get a glimpse of how Windows CE operates under the hood.
...reading a little deeper in the MSDN articles, Sue Loh mentions there when talking about the paging pool size determination:
The best tool I know is that readlog.exe will print you a page fault report if you turn on the “verbose” and “summary” options. If you get multiple faults on the same pages, your pool may be too small (you may also be unloading and re-loading the same module, ejecting its pages from memory, so look for module load events in the log too). If you don’t get many repeats, your pool may be bigger than you need.
Click to expand...
Click to collapse
To avoid dealing with a full setup of the Mobile Development toolsets, could any one (ultrashot - you have been so helpful - could you??) post that mentioned "readlog" tool? If there is something like "CeLogDetach.exe", please add it too.
BTW: you may notice that the paging pool is a central part of the Windows CE memory management when it comes to running executable code from "memory mapped files" (as Sue Loh calls them). In my understanding these are simply what we know as "modules".
A lot of tweaking strategies go around that when building ROMs with OSBuilder. There are several ways how to avoid or optimize the use of the paging pool for certain or all modules in OSB. I think these options deserve an own thread and I am not sure if the one OSB thread we have should be cluttered with discussing this.
don't have any of those.

Categories

Resources