Mobileread
Terminal program for PB622/623
#1  jtt 09-02-2013, 07:39 PM
Hi,

having tried to use poterm on my PB622 and PB623 devices I found that the lack of buttons on these devices was keeping me from using all its capabilities and decided to write my own version more geared towards use on devices with a touch screen (and using it as a chance to learn how to use the libinkview API;-). You can download the program, including the sources (available under the GPL3), as a "tar.gz" archive from here:

http://users.physik.fu-berlin.de/~jtt/PB/pbterm.tar.gz

Just the compiled program (and the optional configuration file) can be found as a "zip" file at:

http://users.physik.fu-berlin.de/~jtt/PB/pbterm.zip

For more information and instructions on how to install and use the program etc. see

http://users.physik.fu-berlin.de/~jtt/PB/README-pbterm.txt

Note that the program didn't work on the PB622 with firmware version 4.0.373. But it worked after upgrading to the newest 4.2 version. On the PB623 I have only tested it with firmware version 4.3.

Since I don't have any other PocketBook devices beside the PB622 and PB623 I can't tell if the program will also work on other models. If you try the program I would be delighted to get reports about bugs and proposals for new features. My email address is jt@toerring.de and my homepage is http://toerring.de if you want to contact me directly.

Best regards, Jens
Reply 

#2  dark_skeleton 09-03-2013, 06:34 AM
Thanks, works great so far on my PB622 @fw 4.2
Reply 

#3  jtt 09-03-2013, 09:22 AM
Hi,

Quote dark_skeleton
Thanks, works great so far on my PB622 @fw 4.2
Thanks for letting me know! I just found out that it looks as if one actually can use pseudo-terminals on PocketBooks (I had read somewhere that there would be some permission isues with that, but this doesn't seem to be the case anymore;-) and now am trying to updating the program to use that instead of a set of pipes. I'll post here again if I get it to work.

Best regards, Jens
Reply 

#4  jtt 09-03-2013, 06:16 PM
Hi,

a new version of the program, using a pseudoterminal instead of a set of pipes for the internal communication with the shell, is ready for download. Just use the links from my first post, they will now let you download the new 1.1 version of the program.

Best regards, Jens
Reply 

#5  jtt 09-05-2013, 10:20 AM
Hi,

again there's a new version: realizing that with using a PTY now also job control is possible I added a new submenu for sending ^C and ^Z to the shell. Besides, a few minor bugs have been fixed.

Best regards, Jens
Reply 

#6  MartinZ 09-05-2013, 03:44 PM
Hi jtt,

it does not work on PB903 with Firmware 2.06 (although it has a Stylus touch Screen).

it does not work on my PB603 with latest Firmware as well.

Perhaps i would have success by building it from source. But i did not yet. Just tried the .app.
Reply 

#7  jtt 09-05-2013, 04:40 PM
Hi Martin,

Quote MartinZ
it does not work on PB903 with Firmware 2.06 (although it has a Stylus touch Screen).

it does not work on my PB603 with latest Firmware as well.

Perhaps i would have success by building it from source. But i did not yet. Just tried the .app.
I unfortunately can't make any useful statements about other devices than the ones I have and tested it on - and even on the PB622, which I would tend to assume to be rather similar to the PB623, it only worked after the upgrade to the newest FW version. Before it simply crashed om start-up and a backtrace() showed that it happened already on the topmost level (i.e. with only a single entry in the backtrace, something that I can't remember to have seen before in more than two decades of programming under UNIX), so there were no hints at what might have gone wrong...

One question: on my device, when I run 'strings' on the application ('ldd' unfortunately seems to be missing on the device and from the SDK), one of the first things I see is '/lib/ld-linux.so.3'. Some of the programs I downloaded to try and that didn't work had '/lib/ld-linux.so.2' instead there. Perhaps the PB903 is, even with the new FW, still using the 2 version of ld-linux.so. In that case I'm rather sure you will have to compile it yourself in order to get it to run.

Best regards, Jens
Reply 

#8  rkomar 09-05-2013, 06:28 PM
The /lib/ld-linux.so.2 library was used on the older 3XX models. They also used a different ABI, so the programs for it are incompatible with devices made over the last three years. That would explain why you couldn't run those on your new devices. There is only one SDK for the newer devices, and the binaries built with it should be compatible across all of them. It's possible that the pty permissions are different between devices and firmware versions, though. If you really want to know about such details, you can download the firmware updates for each model, unpack them (search for pbfwsplit.pl online), and see what /dev/ and /etc/ look like for each one.
Reply 

#9  paolog 09-06-2013, 05:46 AM
hi Jens

perfect!!!!

I'm using poterm since I bought my device one year ago, but with the touch limitatons you mentioned it was not very handy

thanks a lot for sharing your work

Reply 

#10  jtt 09-06-2013, 08:36 AM
Hi rkomar,

thanks for the information about the ld-linux.so.2/3 issue.

And then thank you even more for the stuff about the splitter program for SWUPDATE.BIN, that's very, very interesting;-) Perhaps it would even be possible to reassemble it again... The only drawback is that, at least with the firmware file I had a look at, /dev doesn't have PTYs, I guess they get created automatically on system startup.

Why the program crashes on some systems and not on others is still a mystery to me, at least when, as you say, it should work on all newer systems. My debugging attempt with the PB622 with older firmware didn't lead to any useful clues - all I found was that it's a SEGFAULT. Ok, I know how easy they are to make and how hard to find, but i hope my program is rather clean (no direct memory allocation, just via C++ methods) and I don't see where I could possibly write into memory I do not "own", so I'm tempted to blame the firmware;-) Well, it could be that exceptions are not enabled and thus an object creation failing due to memory exhaustion may have, instead throwing an exception, crashed the program in some ugly way. Got to look into that...

Best regards, Jens
Reply 

  Next »  Last »  (1/8)
Today's Posts | Search this Thread | Login | Register