Register Guidelines E-Books Search Today's Posts Mark Forums Read

Go Back   MobileRead Forums > E-Book Readers > Amazon Kindle > Kindle Developer's Corner

Notices

Reply
 
Thread Tools Search this Thread
Old 03-23-2013, 02:26 PM   #106
Awak
Wuxia Novels Fan
Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.
 
Posts: 64
Karma: 173552
Join Date: Feb 2013
Location: Earth
Device: Kindle PW
I have put up a lot of debugging codes and testing codes in the program. To avoid any confusion, I need to do some clean up before release the source code to internet...

I still need to learn "push it up" on top of the old version, hopefully it is not too hard to commit the files again...
Awak is offline   Reply With Quote
Old 03-23-2013, 02:41 PM   #107
twobob
( ͡° ͜ʖ ͡°){ʇlnɐɟ ƃǝs}Týr
twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.
 
twobob's Avatar
 
Posts: 6,586
Karma: 6299991
Join Date: Jun 2012
Location: uti gratia usura (Yao ying da ying; Mo ying da yieng)
Device: PW-WIFI|K5-3G+WIFI| K4|K3-3G|DXG|K2| Rooted Nook Touch
change to GIT dir

git status (check you are happy with what it says)

if some new files are missing from the tracking...
git add ./*

then/or

git commit -a
(enter revision info)

git push

should do the job
twobob is offline   Reply With Quote
Advert
Old 03-23-2013, 02:42 PM   #108
twobob
( ͡° ͜ʖ ͡°){ʇlnɐɟ ƃǝs}Týr
twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.
 
twobob's Avatar
 
Posts: 6,586
Karma: 6299991
Join Date: Jun 2012
Location: uti gratia usura (Yao ying da ying; Mo ying da yieng)
Device: PW-WIFI|K5-3G+WIFI| K4|K3-3G|DXG|K2| Rooted Nook Touch
go to bed. I'll test it now.

EDIT: still doesnt launch Yes the keystore should be fine

Fix it tomorrow - Ill look at the code when you UP it.

Last edited by twobob; 03-23-2013 at 02:46 PM.
twobob is offline   Reply With Quote
Old 03-23-2013, 02:59 PM   #109
Awak
Wuxia Novels Fan
Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.
 
Posts: 64
Karma: 173552
Join Date: Feb 2013
Location: Earth
Device: Kindle PW
Interestingly, your crash log looks exactly same as what yahwing give us:

https://www.mobileread.com/forums/sho...5&postcount=87

What is going on here? I have not changed anything on development environment: But yahwing cannot run the previous version while you can, and now you cannot run this latest version while I can in my Kindle...

What is this "kindlet.internal.security.Kindle tSecretKey" doing in the project??

They really are "Secret" with secret behavior!
Awak is offline   Reply With Quote
Old 03-23-2013, 03:03 PM   #110
twobob
( ͡° ͜ʖ ͡°){ʇlnɐɟ ƃǝs}Týr
twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.
 
twobob's Avatar
 
Posts: 6,586
Karma: 6299991
Join Date: Jun 2012
Location: uti gratia usura (Yao ying da ying; Mo ying da yieng)
Device: PW-WIFI|K5-3G+WIFI| K4|K3-3G|DXG|K2| Rooted Nook Touch
hah yeah.

I will happily build it from source myself and check it once it is up.

Maybe I can spot something.

This is the whole point behind pushing up EACH REVISION to git really. so we can all have a good look and see if there is something obvious in the changes...

four eyes are better than two. 6 is better than 4 yada yada and so forth.

I can at least DIFF the changes then and see what might be causing it.
twobob is offline   Reply With Quote
Advert
Old 03-23-2013, 03:05 PM   #111
twobob
( ͡° ͜ʖ ͡°){ʇlnɐɟ ƃǝs}Týr
twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.
 
twobob's Avatar
 
Posts: 6,586
Karma: 6299991
Join Date: Jun 2012
Location: uti gratia usura (Yao ying da ying; Mo ying da yieng)
Device: PW-WIFI|K5-3G+WIFI| K4|K3-3G|DXG|K2| Rooted Nook Touch
it would also rule out your build process as the cuplrit
twobob is offline   Reply With Quote
Old 03-24-2013, 08:02 PM   #112
Awak
Wuxia Novels Fan
Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.
 
Posts: 64
Karma: 173552
Join Date: Feb 2013
Location: Earth
Device: Kindle PW
Quote:
Originally Posted by twobob View Post
it would also rule out your build process as the cuplrit
I tend to think it must be something has changed on your kindle that cause it and pretty sure you cannot even run the previous version now even you have done that without problem before...

It could be because you have the WiFi ON while running the Chinese Chess program and it has picked up something from the internet. It might be because you have changed the firmware of your kindle recently.

I may come up with some more possible reasons later ... ...
Awak is offline   Reply With Quote
Old 03-24-2013, 08:04 PM   #113
twobob
( ͡° ͜ʖ ͡°){ʇlnɐɟ ƃǝs}Týr
twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.
 
twobob's Avatar
 
Posts: 6,586
Karma: 6299991
Join Date: Jun 2012
Location: uti gratia usura (Yao ying da ying; Mo ying da yieng)
Device: PW-WIFI|K5-3G+WIFI| K4|K3-3G|DXG|K2| Rooted Nook Touch
pfft. Zero chance of that.
twobob is offline   Reply With Quote
Old 03-24-2013, 11:34 PM   #114
vanhoavn
Member
vanhoavn solves Fermat’s last theorem while doing the crossword.vanhoavn solves Fermat’s last theorem while doing the crossword.vanhoavn solves Fermat’s last theorem while doing the crossword.vanhoavn solves Fermat’s last theorem while doing the crossword.vanhoavn solves Fermat’s last theorem while doing the crossword.vanhoavn solves Fermat’s last theorem while doing the crossword.vanhoavn solves Fermat’s last theorem while doing the crossword.vanhoavn solves Fermat’s last theorem while doing the crossword.vanhoavn solves Fermat’s last theorem while doing the crossword.vanhoavn solves Fermat’s last theorem while doing the crossword.vanhoavn solves Fermat’s last theorem while doing the crossword.
 
Posts: 15
Karma: 28498
Join Date: May 2011
Device: Kindle 3 3G
Looking at the log tell us the origin of problem:
Quote:
at com.amazon.kindle.kindlet.internal.security.G.getC hars(vrc:1333)
at vn.vhn.amazon.kindle.chinesechess.posCollection.lo calIsSolved(Unknown Source)
It seems that the application cannot read from its local preferences storage due to some security error. I think that the local storage is encrypted by the sign or anything relating to the application.
You may resolve that error by a try catch in that function

Code:
try{
//reading from pref
}catch(Exception ex){
//reading error, clear all the pref, and then try reading again
}
vanhoavn is offline   Reply With Quote
Old 03-25-2013, 01:03 AM   #115
Awak
Wuxia Novels Fan
Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.
 
Posts: 64
Karma: 173552
Join Date: Feb 2013
Location: Earth
Device: Kindle PW
Quote:
Originally Posted by vanhoavn View Post
Looking at the log tell us the origin of problem:

It seems that the application cannot read from its local preferences storage due to some security error. I think that the local storage is encrypted by the sign or anything relating to the application.
You may resolve that error by a try catch in that function

Code:
try{
//reading from pref
}catch(Exception ex){
//reading error, clear all the pref, and then try reading again
}
HA! Good to hear you again! What is this "local preferences storage"?

I am still learning and don't understand how this work:

1. Where is all the Chess Puzzles stored?

2. Is that true this "SecureStorage" only half used out of its 512 bytes? Most of the 256 bytes (other than the 256 bytes for Chess Map) are not used? Where is this storage exist? Part of the data section in .awz2 file?

3. What do you mean by "clear all the pref, and then try reading again"?
How to clear the pref?

4. The crash log says it comes from the routine "posCollection.localIsSolved()", but I don't see anything special on this routine and my kindle can run it without problem...

Since I cannot reproduct the problems on my kindle, what should I do in this case?


I am sorry there are so many questions I want to know the answers - As I am now quite "HOT" on this Chess Program - I cannot sleep or eat until I know the inside out of it...

Hope that you don't mind to help me a bit .
Awak is offline   Reply With Quote
Old 03-25-2013, 01:56 AM   #116
ixtab
(offline)
ixtab ought to be getting tired of karma fortunes by now.ixtab ought to be getting tired of karma fortunes by now.ixtab ought to be getting tired of karma fortunes by now.ixtab ought to be getting tired of karma fortunes by now.ixtab ought to be getting tired of karma fortunes by now.ixtab ought to be getting tired of karma fortunes by now.ixtab ought to be getting tired of karma fortunes by now.ixtab ought to be getting tired of karma fortunes by now.ixtab ought to be getting tired of karma fortunes by now.ixtab ought to be getting tired of karma fortunes by now.ixtab ought to be getting tired of karma fortunes by now.
 
ixtab's Avatar
 
Posts: 2,907
Karma: 6736092
Join Date: Dec 2011
Device: K3, K4, K5, KPW, KPW2
Quote:
Originally Posted by Awak View Post
HA! Good to hear you again! What is this "local preferences storage"?

I am still learning and don't understand how this work:

1. Where is all the Chess Puzzles stored?

2. Is that true this "SecureStorage" only half used out of its 512 bytes? Most of the 256 bytes (other than the 256 bytes for Chess Map) are not used? Where is this storage exist? Part of the data section in .awz2 file?

3. What do you mean by "clear all the pref, and then try reading again"?
How to clear the pref?

4. The crash log says it comes from the routine "posCollection.localIsSolved()", but I don't see anything special on this routine and my kindle can run it without problem...

Since I cannot reproduct the problems on my kindle, what should I do in this case?


I am sorry there are so many questions I want to know the answers - As I am now quite "HOT" on this Chess Program - I cannot sleep or eat until I know the inside out of it...

Hope that you don't mind to help me a bit .
Essentially, the answer to almost all of those questions is here.

Regarding where it is stored: /mnt/us/developer/<AZW2 Title>/metadata/.secure_store.
ixtab is offline   Reply With Quote
Old 03-25-2013, 02:45 AM   #117
vanhoavn
Member
vanhoavn solves Fermat’s last theorem while doing the crossword.vanhoavn solves Fermat’s last theorem while doing the crossword.vanhoavn solves Fermat’s last theorem while doing the crossword.vanhoavn solves Fermat’s last theorem while doing the crossword.vanhoavn solves Fermat’s last theorem while doing the crossword.vanhoavn solves Fermat’s last theorem while doing the crossword.vanhoavn solves Fermat’s last theorem while doing the crossword.vanhoavn solves Fermat’s last theorem while doing the crossword.vanhoavn solves Fermat’s last theorem while doing the crossword.vanhoavn solves Fermat’s last theorem while doing the crossword.vanhoavn solves Fermat’s last theorem while doing the crossword.
 
Posts: 15
Karma: 28498
Join Date: May 2011
Device: Kindle 3 3G
Yes, the answers for 2nd,3rd and 4th question is in ixtab's link
And for 1st, they're *.vh files.
vanhoavn is offline   Reply With Quote
Old 03-25-2013, 03:43 AM   #118
Awak
Wuxia Novels Fan
Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.
 
Posts: 64
Karma: 173552
Join Date: Feb 2013
Location: Earth
Device: Kindle PW
Quote:
Originally Posted by vanhoavn View Post
Yes, the answers for 2nd,3rd and 4th question is in ixtab's link
And for 1st, they're *.vh files.
They are *.vh files inside the source code project only, but we just copy the ".azw2" file to the kindle - So it must has all the necessary data (all the chess puzzles and all the SecureStorage contents) inside this ".azw2" file.

My guess is when you run this ".azw2" file the VERY first time on the kindle, it will auto-create the file in "/mnt/us/developer/<AZW2 Title>/metadata/.secure_store" by itself.

I suspect the ALL Chess Puzzles will also store somewhere (not in the RAM, but the /mnt/us directory) as part of initialization when you run the ".azw2" file.

The troubled routine:

Quote:
private boolean localIsSolved(int name, int id)
{
char l[] = context.getSecureStorage().getChars("pos:".concat( itemName[name].concat(String.valueOf(id))));

return l != null && l.length == 4 && l[0] == solved[0] && l[1] == solved[1] && l[2] == solved[2] && l[3] == solved[3]; }
has a "secret" key of

char solved[] = { 'v', 'h', 's', 'v' };

to compare with.

I suspect this secure store has been corrupted and the application (Chess Program) should able to generate it again somehow (I don't know how yet...).

From the link given by ixtab:

Quote:
In the remote case that corruption happens outside of the application's life cycle the store will simply respond as if it is empty. (This can also happen if the device is restored to factory settings.) For most use cases, the application should be built to deal gracefully with this.
================================================== ======

I presume the *.vh files have their own format or encrypted and you just cannot edit or add another one without a special software tool to do it, right?


WOW! I have learnt a lot of things here - Thanks a lot Guy!
Awak is offline   Reply With Quote
Old 03-25-2013, 03:47 AM   #119
vanhoavn
Member
vanhoavn solves Fermat’s last theorem while doing the crossword.vanhoavn solves Fermat’s last theorem while doing the crossword.vanhoavn solves Fermat’s last theorem while doing the crossword.vanhoavn solves Fermat’s last theorem while doing the crossword.vanhoavn solves Fermat’s last theorem while doing the crossword.vanhoavn solves Fermat’s last theorem while doing the crossword.vanhoavn solves Fermat’s last theorem while doing the crossword.vanhoavn solves Fermat’s last theorem while doing the crossword.vanhoavn solves Fermat’s last theorem while doing the crossword.vanhoavn solves Fermat’s last theorem while doing the crossword.vanhoavn solves Fermat’s last theorem while doing the crossword.
 
Posts: 15
Karma: 28498
Join Date: May 2011
Device: Kindle 3 3G
all *.vh files should be included within the azw2, but securestorage contents are not.
About the method to read them, it's in the source code already
vanhoavn is offline   Reply With Quote
Old 03-25-2013, 04:00 AM   #120
Awak
Wuxia Novels Fan
Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.Awak can program the VCR without an owner's manual.
 
Posts: 64
Karma: 173552
Join Date: Feb 2013
Location: Earth
Device: Kindle PW
Quote:
Originally Posted by vanhoavn View Post
all *.vh files should be included within the azw2, but securestorage contents are not.
What do you mean? Then who create this SecureStorage in the first place?

We don't have an installation program here, it must be generated when you run the application the VERY first time!

Otherwise, the SecureStorage will be there long before you have the application - May be when you have the Developer Certificate installed ???
Awak is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
For when chess in the kindle? KRorschachZ Amazon Kindle 33 05-06-2011 06:08 PM
Working Chess on Kindle 3 tigran Amazon Kindle 15 03-16-2011 03:23 PM
New Kindle Game: Chess ($2.99) arcadata Deals and Resources (No Self-Promotion or Affiliate Links) 1 02-11-2011 09:07 AM
For Chess fans everywhere - Capablanca's Chess Fundamentals Greg Anos Reading Recommendations 21 10-31-2010 01:46 PM


All times are GMT -4. The time now is 08:57 PM.


MobileRead.com is a privately owned, operated and funded community.