07-18-2013, 06:43 AM | #1 |
ebook fan
Posts: 735
Karma: 2528718
Join Date: Dec 2010
Device: PocketBook 301+, Kindle 3 Wi-Fi, Onyx Boox A62, Kindle Touch
|
Kobo files monitor
Hi!
File monitor is a simple tool that allows to track opening of the specific files (e.g. png icons) and run specific commands in response. For today it seems that is is the only way to run shell scripts and programs on kobo. Earlier it was the part of KoboLauncher, but I decided to improve it and make the separate installation. You can download it (including the sources) here: http://pbchess.vlasovsoft.net/files/kobo/fmon.zip Installation: Just install KoboRoot.tgz Adding custom commands: 1. Copy launcher png icon to the kobo flash root directory (e.g. reboot.png) 2. Create the script for this icon in the .kobo/fmon Example reboot.sh: (script for reboot.png): Code:
$root/.kobo/fmon/fmon $root/reboot.png $root/.kobo/KoboLauncher/utils/reboot.sh >> $root/.kobo/fmon/fmon.log.txt 2>&1 & launcher.sh (script for starting KoboLauncher): Code:
$root/.kobo/fmon/fmon $root/launcher.png $root/.kobo/KoboLauncher/KoboLauncher.sh >> $root/.kobo/fmon/fmon.log.txt 2>&1 & 1. on_start.sh is executed from on_animator.sh when onboard flash is already mounted. There is almost no risk to spoil your kobo boot process editing on_start.sh because on_animator.sh is a background process. have fun! Last edited by sergeyvl12; 07-26-2013 at 08:13 AM. |
07-18-2013, 06:49 AM | #2 |
Enthusiast
Posts: 46
Karma: 54894
Join Date: Jun 2013
Device: kobo
|
Hello,
Thank You! Could you please provide the source file also and how you compile (or Makefile) ? That way we can customize it as needed |
Advert | |
|
07-18-2013, 06:51 AM | #3 |
ebook fan
Posts: 735
Karma: 2528718
Join Date: Dec 2010
Device: PocketBook 301+, Kindle 3 Wi-Fi, Onyx Boox A62, Kindle Touch
|
|
07-18-2013, 06:55 AM | #4 |
Guru
Posts: 897
Karma: 149877
Join Date: Jul 2013
Location: Netherlands
Device: Cracked HiSenseA5ProCC, Cracked OnyxNotePro, Note5, Kobo Glo, Aura
|
Great! I am going to try it.
|
07-18-2013, 06:55 AM | #5 |
Enthusiast
Posts: 46
Karma: 54894
Join Date: Jun 2013
Device: kobo
|
My bad - just seen that . sergeyvl12 10x again!!
|
Advert | |
|
07-18-2013, 07:10 AM | #6 |
♫
Posts: 660
Karma: 506380
Join Date: Aug 2010
Location: Germany
Device: Kobo Aura / PB Lux 2 / Bookeen Frontlight / Kobo Mini / Nook Color
|
Thanks, works great!
I have copied all files to the fmon directory, you wrote "fmon executable", did you mean just the file called fmon? Because I guess the etc folder is also needed... |
07-18-2013, 07:30 AM | #7 |
Wizard
Posts: 3,489
Karma: 2914715
Join Date: Jun 2012
Device: kobo touch
|
|
07-18-2013, 07:40 AM | #8 |
Wizard
Posts: 3,489
Karma: 2914715
Join Date: Jun 2012
Device: kobo touch
|
Is there any special reason for putting
Code:
if [ -e /mnt/onboard/.kobo/on_start.sh ]; then /mnt/onboard/.kobo/on_start.sh & |
07-18-2013, 07:58 AM | #9 |
ebook fan
Posts: 735
Karma: 2528718
Join Date: Dec 2010
Device: PocketBook 301+, Kindle 3 Wi-Fi, Onyx Boox A62, Kindle Touch
|
|
07-18-2013, 08:04 AM | #10 | |
ebook fan
Posts: 735
Karma: 2528718
Join Date: Dec 2010
Device: PocketBook 301+, Kindle 3 Wi-Fi, Onyx Boox A62, Kindle Touch
|
Quote:
Another advantage is that on_animator.sh is not changed in the latest FWs. So, there is no need to make the separate install for each firmware. But ... you need to install file monitor again after you update FW because kobo uses the full update and on_animator.sh will be overwritten. |
|
07-18-2013, 08:23 AM | #11 |
Wizard
Posts: 3,489
Karma: 2914715
Join Date: Jun 2012
Device: kobo touch
|
Thank you, Sergey!
Thank you also for the code. I just compiled it in order to test whether I have the tool chain correctly installed. Last edited by tshering; 07-18-2013 at 08:42 AM. |
07-18-2013, 03:41 PM | #12 |
Wizard
Posts: 4,465
Karma: 6900052
Join Date: Dec 2009
Location: The Heart of Texas
Device: Boox Note2, AuraHD, PDA,
|
Let the .png creation begin! Thanks sooo... much, Sergey!
Now we can have both Sergey's Launcher with USBnet and pchess, as well as Giorgio's Koreader port. And Markismus might even package it all together for us. These are good times, for us all. Perhaps a contest for the Koreader.png? I can't wait to see what Markismus adds to his .rar. Well, lets see, where did I put my copy of Gimp2? Luck; Ken Last edited by Ken Maltby; 07-18-2013 at 04:06 PM. |
07-18-2013, 07:23 PM | #13 |
Wizard
Posts: 4,465
Karma: 6900052
Join Date: Dec 2009
Location: The Heart of Texas
Device: Boox Note2, AuraHD, PDA,
|
Markismus:
I downloaded this image and sized it into a .png matching Sergey's original dimensions, you could use it if you were to add the "Kobo Files Monitor" to your .rar (Hint, hint...) to have a Koreader launching image. (You can right click on the Attached Image and save it on your computer.) Luck; Ken Last edited by Ken Maltby; 07-18-2013 at 11:09 PM. |
07-19-2013, 01:22 AM | #14 |
Wizard
Posts: 4,465
Karma: 6900052
Join Date: Dec 2009
Location: The Heart of Texas
Device: Boox Note2, AuraHD, PDA,
|
I installed the Kobo Files Monitor and it is working as expected. I used the image I posted to launch Koreader, which it does but for some reason it is not opening in the Koreader's File Manager but instead it opens in a book. Don't understand why the same bash script commands are having a different result, now. I suspect that I need to correct the folder I an in to call the script commands. In any case the the Files Monitor is working.
Luck; Ken I made the needed corrections (thanks to cgm999), I needed to add the proper argument in an .sh file. Last edited by Ken Maltby; 07-19-2013 at 12:27 PM. |
07-19-2013, 04:23 AM | #15 |
Guru
Posts: 897
Karma: 149877
Join Date: Jul 2013
Location: Netherlands
Device: Cracked HiSenseA5ProCC, Cracked OnyxNotePro, Note5, Kobo Glo, Aura
|
@Ken
I am not quite there yet. I just got up and I am still enjoying my working Aura. I am a bit miffed that I can't use my step approach myself, since the KoboLaucher changed into fmon and cgm999 put in a new koreader version. I don't think you have to resize pictures. I don't even know if it should be png-files. I'll try and see. Anyway I'll document the steps taken and the files copied and drop it in a box. |
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Use DXG 3.2.1 as second monitor? | bloor | Kindle Developer's Corner | 25 | 04-09-2012 05:13 PM |
kobo annotation and non-Kobo files | carandol | Kobo Reader | 2 | 11-26-2011 03:15 PM |
text files on Kobo | pyrokamileon | Kobo Reader | 2 | 07-15-2011 01:08 AM |
Monitor Folders | richacol | Calibre | 0 | 05-22-2009 11:00 AM |