question

robin avatar image
robin asked

Kindle Fire HD7 - File System Insight needed navigating the Kindle Fire HD7

Attempting to understand the Kindle file system folder layout So far, using es3 the file manager, I have been able to learn that the log files for the SDK Tester resides in /mnt/sdcard/amazon_sdktester Every reference I see talks about the 'downloads' (plural - I do see /mnt/sdcard/download/ ) folder, but I am not able to locate on my device. Along with that, am trying to locate where the Silk browser stores it's settings, bookmarks and favorites. When viewing using the es3 file manager, every folder appears to be empty, containing no bytes of data. Other specific locations: [while surfing the web using the Silk browser] Where is localStorage data for Html5 apps for a specific domain? Where are bookmarks stored? Where is the AppCache for a specific domain? Where are the temporary files for each web page stored? .css .js .mp3 etc? When using the Web App Tester, where is the app specific detail stored? History, Session cookies etc Using the SDK tester, the info.log file references: file:///android_asset/web/js/interactive.js Where is that folder? One would think the root, but I don't see it visible there. What would really help; is there a document available [URL maybe] for the Kindle file system? no luck in: https://developer.amazon.com/help/faq.html http://www.amazon.com/gp/help/ http://kindle.s3.amazonaws.com/Kindle_Fire_Users_Guide.pdf http://aws.amazon.com/mobile/ Thank you in advance, Robin
fire tablet
10 |5000 characters needed characters left characters exceeded

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

robin avatar image
robin answered
http://docs.aws.amazon.com/silk/latest/developerguide/html5-apis.html#file-system-api Have attempted File System API example, but unable to determine where files are saved Is there a Kindle security setting that need be modified to get this example to work?
10 |5000 characters needed characters left characters exceeded

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Sujoy@Amazon avatar image
Sujoy@Amazon answered
Hi Robin, Thank you writing to us. "file:///android_asset/web/js/interactive.js" is the url of the js file which is packaged inside the apk. So any asset file could loaded as a File for apk/assets folder. I would like to ask you few questions? Why do you need these information? What are the use cases of of these information? What are you trying to achive in your app?
10 |5000 characters needed characters left characters exceeded

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

robin avatar image
robin answered
re: "Why do you need these information?" Observation, not all Html5 developers that wish to deploy apps through the Amazon web store have Java/Android experience. In response to your questions, ultimately, I am trying to get an Html5 app running inside the SDK tester. The SDK tester launches but just 'black screens' B.S.O.D. Currently, following the instructions under the 'web apps' link, I am attempting to get the SDK 'button-clicker' IAP Html5 app to function on my Kindle Fire HD7 [1] \Web\samples\button-clicker\ [3] There is a run time error on the Kindle device when attempting to execute the In-App-Purchasing example I never see the three orange buttons as in: Fig. 2: SDK Tester Home Page [2] As I indicated in the initial post, when I search the file system. I notice the SDK tester is throwing an error in it's error log, mnt/sdcard/amazon_sdktester/amazon.sdktester.info.log file that references interactive.js As the SDK tester is black screening, I felt there may be an issue with that file as it is stamped in the error log. So, far I have reinstalled the SDK tester from the App store and I have unpacked the SDK .zip file [3] to side load the .apk file and to upload the sample files to a hosting server. I'm not prepared, just yet, to perform a master reset erasing clues that might prevent this occurrence for others. Also, don't know the SDK tester or the file system well enough to understand where to start looking for clues. Q: What does 'mnt' stand for? Is there a web page that indicates the Kindle file naming convention list? [1] https://developer.amazon.com/sdk/webapps.html [2] https://developer.amazon.com/sdk/webapps/iap/testing-iap.html [3] https://developer.amazon.com/sdk/thank-you.html
10 |5000 characters needed characters left characters exceeded

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Sujoy@Amazon avatar image
Sujoy@Amazon answered
Hi Robin, Thank you for sharing the information. 'mnt' stands for mount. So when your sd card is mounted, you can access the root of the sdcard by accessing "mnt/sdcard". What error is reported in mnt/sdcard/amazon_sdktester/amazon.sdktester.info.log while your are running the button clicker sample app? I am forwarding your queries regarding the specifics of silk browser and web app tester to the appropriate team.
10 |5000 characters needed characters left characters exceeded

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

robin avatar image
robin answered
Sujoy, Thank you for the explanation of the folder name for 'mount' The reference in the 'info.log' file is: "Getting current interactive preferences on line 36 of file:///android_asset/web/js/interactive.js" re: What error is reported in mnt/sdcard/amazon_sdktester/amazon.sdktester.info.log while your are running the button clicker sample app? The info.log file is difficult to navigate as there are no line numbers or time stamps or even application start entry points. The same hold true for the 'error.log' file. I believe you meant to ask for "What error . . . in . . . ." 'error.log' and not 'info.log' "Failure during handlePurchaseUpdatesRequest : Invalid long: "null" " . . . and: "Unable to get item information during purchase" Robin
10 |5000 characters needed characters left characters exceeded

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Sujoy@Amazon avatar image
Sujoy@Amazon answered
Hi Robin, There are two things to confirm from you, 1. Did you place /mnt/sdcard/amazon.sdktester.json properly with all your items definition. Below is the link for guidance how to create or get JSON file out of all the items. https://developer.amazon.com/sdk/webapps/iap/testing-iap.html#Creating%20the%20JSON%20Data%20File 2. Do you have sdk tester installed in your device? Below is the link for more information on sdk tester https://developer.amazon.com/sdk/webapps/iap/testing-iap.html#SDK%20Tester%20Environments Also please let us know how you are running the button clicker app. Did you put all the required resources in a web server and fetich it through Amazon web app tester?
10 |5000 characters needed characters left characters exceeded

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

robin avatar image
robin answered
Responses to your questions: Q2: "2. Do you have sdk tester installed . . . " I clearly state both the web-app tester and SDK tester in my initial post above dated 'Posted: Sep 28, 2013 9:57 AM' ref: "Using the SDK tester, . . . " The SDK tester would not have created the folder that I mention "/mnt/sdcard/amazon_sdktester" until it is installed. Nor would the error and log file be created unless stamped by the SDK tester. ref: Your response "file:///android_asset/web/js/interactive.js" I also state "The SDK tester launches but just 'black screens' B.S.O.D." post above dated "Posted: Oct 5, 2013 11:42 AM" So, . . . yes, . . . the SDK tester is installed Q1: "1. Did you place /mnt/sdcard/amazon.sdktester.json properly with all your items definition." I followed the web page instructions for the button clicker app. I made several references to this above. 'Posted: Oct 5, 2013 11:42 AM' "I am attempting to get the SDK 'button-clicker' IAP Html5 app to function on my Kindle Fire HD7" You responded: In your post 'Posted: Oct 7, 2013 1:24 AM' you acknowledged this "while your are running the button clicker sample app?" These errors resulted from the button clicker app unpacked from the Amazon Apps-SDK.zip I haven't been able to advance any further through the instructions to attempt any of my own trials. Again, these errors are a result of the button clicker Html web example. recap: I d/l and unpacked the Apps-SDK.zip file mid-late August 2013 [1] Web/ -- Web APIs root folder button-clicker/ I u/l this folder verbatim to my host provider and viewed the index.html to verify three clickable Html square buttons below a large clickable button with 10 available clicks remaining. I followed the instructions [2] using the Android bridge adb push /path/to/amazon.sdktester.json /mnt/sdcard/amazon.sdktester.json I launch the app from the web-app tester 'Enter your app URL' click 'Save' [1] https://developer.amazon.com/sdk/thank-you.html [2] https://developer.amazon.com/sdk/webapps/iap/testing-iap.html#SDK%20Tester%20Environments
10 |5000 characters needed characters left characters exceeded

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Sujoy@Amazon avatar image
Sujoy@Amazon answered
Hi Robin, Sorry for the late response. Are you still have the issue to run the button clicker in web-app tester? Please let us know. Every app in Android lives in its own app sandbox environment, and cannot access app sandbox of other apps. This is a security feature of Android. files like file:///android_asset/web/js/interactive.js accessed in the tester lives in its own app sandbox. You will not be able to, and should not need to, see its content.
10 |5000 characters needed characters left characters exceeded

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

robin avatar image
robin answered
Thank you for responding Sujoy, Short answer, yes, since the last execution, I still have the same errors with the button clicker Html5 app launched inside the web-app tester. That said, I've uncovered an issue that may halt my ability to complete an Html5 app for release on Kindle devices. It makes no sense (for me) to resolve the IAP issues with the button clicker app, until it can be proven that it is possible to write data to the sdcard from the Silk browser. [1] Would you be so kind as to keep this thread alive until resolution is found on the above referenced thread. Thank you, Robin [1] https://forums.developer.amazon.com/forums/thread.jspa?threadID=1599&tstart=0 Amazon Mobile App Distribution Home » Forums » Kindle Fire » Building for Kindle Fire Thread: Kindle Fire HD7 - File System API Insight needed file write
10 |5000 characters needed characters left characters exceeded

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

rmandel@aws avatar image
rmandel@aws answered
You CANNOT write data from a webapp into the /mnt/sdcard partition via a Mobile Web App. Web Apps and their data are constrained in an Android application sandbox which is not accessible to the end user or to other applications or utilities (e.g. for viewing and/or clearing data). This is the case for Bookmarks, as well as temporary file data as well. An end user can flush the data for an application via the standard android mechanism (e.g. Settings -> Applications -> Installed Applications -> -> Clear Data
10 |5000 characters needed characters left characters exceeded

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.