abi>>forums

abi>>forums (http://www.anythingbutipod.com/forum/index.php)
-   Zen X-Fi2 Applications & Development (http://www.anythingbutipod.com/forum/forumdisplay.php?f=221)
-   -   Eread - text file reader (http://www.anythingbutipod.com/forum/showthread.php?t=58052)

breakb 10-03-2010 11:26 AM

Eread - text file reader
 
4 Attachment(s)
Hello everyone!

Since Zen Xfi 2 doesn't have a build in text file reader i developed a text reading app myself.
The current version(0.95) has most of the features of the planned final version.
During the use of it on Zen I didn't notice any bugs, nor were there any crashes, however I can't guarantee full stability. If the app chrashes, please post a message here describing how it happened. The data file will reset and the library will be empty after crash.
I want to add support for fb2 files, but that comes after proper text file support and gui.


Features:
  • Text file support - ASCII and UTF8 with Byte Order Mark encoding with unlimited file size.
  • Full Unicode support!(As full as lua run time supports it..)
  • Navigation - next page, previous page, first page, last page, scroll up+down.
  • Automatically picks up contents lines like chapters etc in text files.
  • Support for bookmarking.
  • Support for font scaling, screen rotation and color switching.
  • More to come.

Controls:
  • In reader:
    • Tap on screen to go to next page or previous page.
    • Click home button for next page.
    • Hold home or click power button to go to menu.
  • In menu:
    • Tap the empty area in main menu to go back to book.
    • Press home or power button to exit Eread while in main menu.
  • Buttons in menu:
    • Left: Table of contents, Bookmark list, Add bookmark
    • Bottom: Library, Open new book, go to start, go to end, show help.
    • Right: Increase/decrease font size, rotate screen, switch colors.

Known bugs/ unfinished features:
  • No backlight changing.

History:
  • 03/10/2010 version 0.8(Initial release)
  • 08/10/2010 version 0.9(Big changes with many parts completely rewritten for a better app with new functionality)
  • 10/10/2010 version 0.95

JJLoke 10-04-2010 05:02 AM

There are 2 text file reader made by fellow forumers.

It is good to make one on your own, and ask advice from them.

If it support readability of east asian language as well, I will support u !!

matthijs1929 10-06-2010 02:55 PM

NICE!!!!!

Brett_val 10-06-2010 03:03 PM

This is very impressive! I spend some time reading the code and it was very interesting! At least for me it was.. like the commands in tables, I was wondering lately if this was possible, nice to see a good example of it.

The app works quite smooth, loads files fast, and is actually quite intuitive but it may be confusing at first. It may be nice to write words next to the buttons so you don't have to try them all out, or maybe use some more descriptive icons for them.

Some small remarks:
-It's too bad you can't scroll text by moving.
-The time is 1 hour off but that's because of some "bug" in the player, but you might want to compensate for that in the code.
-The "next"-button (go to end) does nothing.

I did found a crash; black screen and it needs a discscan when I turn it on again. Also, the data.lua file is gone and you have to reload that from the pc. To recreate this I zoom out two steps, then skip a page down and then skip up a bunch of times (by pressing the left side of the screen).

That's the only real issue I could find, but overall very good app and you really seem to know your Lua:)

jbob182 10-06-2010 04:17 PM

I just tried it and well..... It works really good! Keep up the good work! and i agree with Brett_Val the code is very intersting i learned a bit from looking at it. Have you had any previouse experince in lua?'


i tested a few storys i test a longer one The Most Dangerous Game and my Wave Crave instruction file and to my surprise it worked great. Though since the screen is a bit small the text gets bumped over some so my wavecrave readme got a little messed up

breakb 10-08-2010 04:50 PM

Hey, thanks for your responses, i've uploaded a new version which has lots and lots of improvements.
This is my first actuall project in Lua, but i have experience in programming in several other languages so this helped :D
I'm working on the scroll by move, and go to end for the next version.
And I will also add a help button which will show text beside buttons to describe what they do.
Also thanks for that bug report, Ill look into it.

serawong 10-17-2010 09:14 PM

hi...

i have loaded the app.. and put in some text files ... but i could not seems to load any of the text file...

can i know how do i really load the text files thru this program to start reading?

breakb 10-18-2010 11:15 AM

There is a plus(add new book file) button in the main menu. Click it and type in the name of the file.
Just make sure that the text files are in same folder as the app and type in the file's full name(with .txt) as you add it.

Zurimor 10-19-2010 07:23 AM

It's really nice, but it doesn't display ,,, on my Zen. Instead there is an empty space. I solved this problem by changing all ,,, to ae,oe,ue,ss with word, but it would be great if you could fix this.

breakb 10-19-2010 10:39 AM

Hmm does it display the ,, in sample text file(sample.txt)? Because I have them there and they show up perfectly on my zen.
If it does show them in sample file, but not in your own text file then its probably not in UTF8 encoding. Unfortunately Eread only supports UTF8 so if your files are in other unicode format you have to convert them ( Save As and UTF-8 encoding in notepad).

Zurimor 10-23-2010 01:56 AM

Thanks, that helped me. A very nice app. :)

breakb 10-28-2010 05:50 AM

New version soon
 
1 Attachment(s)
For those who are interested in dev progress and Fb2 support - I've implemented a basic Fb2 importer with support for embedded images:cool:
Also in the new version I reworked the main menu, added support for UTF-16 text files and accelerometer screen rotation + much more smaller fixes. I will release it soon, just need to work more on Fb2 and testing.

jlim5270 11-28-2010 07:07 PM

Cant open the zip Eread0.95 any help?

Brett_val 11-29-2010 03:54 PM

Quote:

Originally Posted by jlim5270 (Post 517771)
Cant open the zip Eread0.95 any help?

How to put an application onto your device.

See step 2: try it with another unzipping program.

xJaNx 01-19-2011 07:23 AM

Thanks for the great app. :)
But I was doing some reading earlier on and it suddenly crashed - the player shut down and after I turned it on again, the app refused to open.

Any help? :(

Habhome 01-19-2011 09:23 AM

Quote:

Originally Posted by xJaNx (Post 530988)
Thanks for the great app. :)
But I was doing some reading earlier on and it suddenly crashed - the player shut down and after I turned it on again, the app refused to open.

Any help? :(

Begin with the first points here:
How to fix most problems with your X-Fi2

Brett_val 01-19-2011 02:03 PM

Quote:

Originally Posted by xJaNx (Post 530988)
Thanks for the great app. :)
But I was doing some reading earlier on and it suddenly crashed - the player shut down and after I turned it on again, the app refused to open.

Any help? :(

The file where the app stores settings might be faulty after a crash, try to copy the data.lua file from the zip to the player again and overwrite.

Alex/AT 01-25-2011 11:52 AM

I may've found the reason behind book reader crashing here and there on page renewal.

Looks like some interrupts are processed by X-Fi cooperatively. When it has not enough timeslice to process one interrupt and another one comes, the CPU is shutdown immediately (hardware probably thinks that OS has hung).

If so, the remedy is to add some timeslice returns to the book reader page renewal process. It works for me, it's up to you to check if it works for you.

Open main.lua in your raw text/code editor (Word/Wordpad won't do, Notepad may do, FAR will do for sure).

Find:
Code:

screen.fillrect(0,0,ScreenWidth,ScreenHeight,bcgColor)
Below, add line:
Code:

os.sleep(5)
Find:
Code:

function(lineStart,lineEnd,x,lineHeight)
Below, add line:
Code:

os.sleep(5)
Save the file, and it's done.

Mangoon 03-09-2011 11:42 AM

Can you add a second file to ereader the file is a text file where you can write the name and type of the text file in and the ereader read the names aout of this file.
Is it possible for you because when you want to add more than one file and don't remeber the name of it than it's hard.

Creativejuan 06-19-2011 01:50 PM

Hey this is a great app but I don't know where to paste the text file I created so that I can view it on the player. Could you help me with this please? Thanks


All times are GMT -5. The time now is 10:21 AM.