Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Readers > Kobo Reader > Kobo Developer's Corner

Notices

Reply
 
Thread Tools Search this Thread
Old 01-31-2017, 02:50 PM   #16
anarcat
Connoisseur
anarcat began at the beginning.
 
anarcat's Avatar
 
Posts: 81
Karma: 10
Join Date: Jul 2013
Location: Planet Ocean
Device: Kobo Glo HD, Onyx Boox Note Pro 2, Samsung Galaxy Tab S5e, Pixel 4a
Quote:
Originally Posted by helour View Post
Look at gtalusan's source code here.
Maybe he can help.
so i read that code, and that's fickel, not nickel. it still treats nickel as a black box - we learn a few commands we can send to nickel regarding wifi stuff, but nothing about rescanning the library or other commands we can run.

what we need is the whole source code of the frigging kobo. or at least nickel.
anarcat is offline   Reply With Quote
Old 01-31-2017, 03:00 PM   #17
Terisa de morgan
Grand Sorcerer
Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.
 
Terisa de morgan's Avatar
 
Posts: 6,258
Karma: 11768331
Join Date: Jun 2009
Location: Madrid, Spain
Device: Kobo Clara/Aura One/Forma,XiaoMI 5, iPad, Huawei MediaPad, YotaPhone 2
Quote:
Originally Posted by anarcat View Post
what we need is the whole source code of the frigging kobo. or at least nickel.
Yeah, the company is going to give the software for free....
Terisa de morgan is offline   Reply With Quote
Advert
Old 01-31-2017, 03:23 PM   #18
anarcat
Connoisseur
anarcat began at the beginning.
 
anarcat's Avatar
 
Posts: 81
Karma: 10
Join Date: Jul 2013
Location: Planet Ocean
Device: Kobo Glo HD, Onyx Boox Note Pro 2, Samsung Galaxy Tab S5e, Pixel 4a
Quote:
Originally Posted by Terisa de morgan View Post
Yeah, the company is going to give the software for free....
Did you steal your device from the store? I bought mine.

Besides, tons of companies do exactly that. Your phone (assuming it's an Android phone, like about 80% of the phones out there) probably runs free software and you can often access the source code directly, which makes it easy to hack and extend, creating this amazing ecosystem of apps. I host the source code of wallabako on a Github alternative that publishes their source code for free as well - you could host your own Gitlab instance if you wished.

So yeah, there's no reason why Kobo wouldn't publish that source code, in my opinion - they published part of it, for free too.. I also suspect that *not* releasing it may be breaking some license agreements, but i haven't looked into this in details, and I am not a lawyer so i don't wish to get into this particular endeavor right now.

But getting access to the source code would be a great way to encourage development. That, or at least providing clear specifications, documentation and APIs...
anarcat is offline   Reply With Quote
Old 01-31-2017, 03:29 PM   #19
Terisa de morgan
Grand Sorcerer
Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.
 
Terisa de morgan's Avatar
 
Posts: 6,258
Karma: 11768331
Join Date: Jun 2009
Location: Madrid, Spain
Device: Kobo Clara/Aura One/Forma,XiaoMI 5, iPad, Huawei MediaPad, YotaPhone 2
Quote:
Originally Posted by anarcat View Post
Did you steal your device from the store? I bought mine.
The device? Yes. The source code? No

Quote:
Originally Posted by anarcat View Post
Besides, tons of companies do exactly that. Your phone (assuming it's an Android phone, like about 80% of the phones out there) probably runs free software and you can often access the source code directly, which makes it easy to hack and extend, creating this amazing ecosystem of apps. I host the source code of wallabako on a Github alternative that publishes their source code for free as well - you could host your own Gitlab instance if you wished.

And tons of companies don't, as the companies I've worked all my career.

Quote:
Originally Posted by anarcat View Post
So yeah, there's no reason why Kobo wouldn't publish that source code, in my opinion - they published part of it, for free too.. I also suspect that *not* releasing it may be breaking some license agreements, but i haven't looked into this in details, and I am not a lawyer so i don't wish to get into this particular endeavor right now.
I am not either but, as an application built over linux, I don't think they have to publish the code (using linux doesn't imply all your source code built over linux should be open source and distributed).

Quote:
Originally Posted by anarcat View Post
But getting access to the source code would be a great way to encourage development. That, or at least providing clear specifications, documentation and APIs...
But you're mixing a SO as Android or Linux with an application. I don't think Kobo is interested in encourage development as it gives them no advantage. I doubt some people developing some apps over Kobo is going to contribute to sell a lot more of Kobo out of an environment like this (and even here).
Terisa de morgan is offline   Reply With Quote
Old 01-31-2017, 03:46 PM   #20
anarcat
Connoisseur
anarcat began at the beginning.
 
anarcat's Avatar
 
Posts: 81
Karma: 10
Join Date: Jul 2013
Location: Planet Ocean
Device: Kobo Glo HD, Onyx Boox Note Pro 2, Samsung Galaxy Tab S5e, Pixel 4a
Quote:
Originally Posted by Terisa de morgan View Post
And tons of companies don't, as the companies I've worked all my career.
And the companies *I* worked for most of my life publish their source code. We're hardly a relevant sample anyways...

Quote:
Originally Posted by Terisa de morgan View Post
I am not either but, as an application built over linux, I don't think they have to publish the code (using linux doesn't imply all your source code built over linux should be open source and distributed).
It depends how the software is built. But you're right - if they just use the kernel, that's not a necessary condition.

Quote:
Originally Posted by Terisa de morgan View Post
But you're mixing a SO as Android or Linux with an application. I don't think Kobo is interested in encourage development as it gives them no advantage. I doubt some people developing some apps over Kobo is going to contribute to sell a lot more of Kobo out of an environment like this (and even here).
I like to think people don't just do things out of their own selfish interests. Because that's the end of civilization. But then maybe that's where we're going anyways...

Anyways, this is off-topic - it'd be nice to have the source or docs, we don't have it, oh well, moving on.
anarcat is offline   Reply With Quote
Advert
Old 01-31-2017, 04:11 PM   #21
tshering
Wizard
tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.
 
Posts: 3,489
Karma: 2914715
Join Date: Jun 2012
Device: kobo touch
Quote:
Originally Posted by anarcat View Post
that sounds a *lot* like the refresh-library.sh script from the wget-sync hooks... but i couldn't make head or tails of that thing...
I just tried the idea, and I like it. What follows is the minimal version, without testing whether there is an external sd inserted or not. In this case it is supposed that there is no external sd. I created /mnt/onboard/.mysd/ and put a book into it. Then, with nickel running, I did

Code:
(none) login: root
[root@(none) ~]# mkdir -p /mnt/onboard/.mysd
[root@(none) ~]# mount --bind /mnt/onboard/.mysd /mnt/sd
[root@(none) ~]# echo sd add /dev/mmcblk1p1 >> /tmp/nickel-hardware-status
[root@(none) ~]#
nickel reads the book from .mysd, and updates the library whenever you execute:
Code:
 echo sd add /dev/mmcblk1p1 >> /tmp/nickel-hardware-status
tshering is offline   Reply With Quote
Old 01-31-2017, 04:33 PM   #22
kido.resuri
Groupie
kido.resuri has a spectacular aura aboutkido.resuri has a spectacular aura aboutkido.resuri has a spectacular aura aboutkido.resuri has a spectacular aura aboutkido.resuri has a spectacular aura aboutkido.resuri has a spectacular aura aboutkido.resuri has a spectacular aura aboutkido.resuri has a spectacular aura aboutkido.resuri has a spectacular aura aboutkido.resuri has a spectacular aura aboutkido.resuri has a spectacular aura about
 
Posts: 172
Karma: 4282
Join Date: Dec 2016
Location: Hungary
Device: Kobo Aura H2O
Hmm.. interesting. The library entry would point to /mnt/sd/yourbook.epub?

I don't have Kobo with me now, but I'll try this tomorrow.

Last edited by kido.resuri; 01-31-2017 at 04:35 PM.
kido.resuri is offline   Reply With Quote
Old 01-31-2017, 04:41 PM   #23
tshering
Wizard
tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.
 
Posts: 3,489
Karma: 2914715
Join Date: Jun 2012
Device: kobo touch
Quote:
Originally Posted by kido.resuri View Post
Hmm.. interesting. The library entry would point to /mnt/sd/yourbook.epub?

I don't have Kobo with me now, but I'll try this tomorrow.
Yes it is file:///mnt/sd/mybook.epub.

Last edited by tshering; 01-31-2017 at 04:55 PM.
tshering is offline   Reply With Quote
Old 01-31-2017, 05:21 PM   #24
Terisa de morgan
Grand Sorcerer
Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.Terisa de morgan ought to be getting tired of karma fortunes by now.
 
Terisa de morgan's Avatar
 
Posts: 6,258
Karma: 11768331
Join Date: Jun 2009
Location: Madrid, Spain
Device: Kobo Clara/Aura One/Forma,XiaoMI 5, iPad, Huawei MediaPad, YotaPhone 2
Quote:
Originally Posted by anarcat View Post
Anyways, this is off-topic - it'd be nice to have the source or docs, we don't have it, oh well, moving on.
On that I agree with you, I was looking at an ereader in Spain only because they gave the source code and you could modify it.
Terisa de morgan is offline   Reply With Quote
Old 02-01-2017, 12:43 PM   #25
anarcat
Connoisseur
anarcat began at the beginning.
 
anarcat's Avatar
 
Posts: 81
Karma: 10
Join Date: Jul 2013
Location: Planet Ocean
Device: Kobo Glo HD, Onyx Boox Note Pro 2, Samsung Galaxy Tab S5e, Pixel 4a
Quote:
Originally Posted by tshering View Post
I just tried the idea, and I like it. What follows is the minimal version, without testing whether there is an external sd inserted or not. In this case it is supposed that there is no external sd. I created /mnt/onboard/.mysd/ and put a book into it. Then, with nickel running, I did

Code:
(none) login: root
[root@(none) ~]# mkdir -p /mnt/onboard/.mysd
[root@(none) ~]# mount --bind /mnt/onboard/.mysd /mnt/sd
[root@(none) ~]# echo sd add /dev/mmcblk1p1 >> /tmp/nickel-hardware-status
[root@(none) ~]#
nickel reads the book from .mysd, and updates the library whenever you execute:
Code:
 echo sd add /dev/mmcblk1p1 >> /tmp/nickel-hardware-status
that looks really awesome! i'll see if i can do something with this...

do we actually need to store the files in /mnt/sd for the refresh to kick in?

if we could fake remount the sd card *without* having to change anything, that would be ideal... then we could make this work for users with an sd card as well - just pretend the card was removed and put back in and we're done...
anarcat is offline   Reply With Quote
Old 02-01-2017, 12:43 PM   #26
anarcat
Connoisseur
anarcat began at the beginning.
 
anarcat's Avatar
 
Posts: 81
Karma: 10
Join Date: Jul 2013
Location: Planet Ocean
Device: Kobo Glo HD, Onyx Boox Note Pro 2, Samsung Galaxy Tab S5e, Pixel 4a
also, in my experience, just this is not sufficient:

Code:
 echo sd add /dev/mmcblk1p1 >> /tmp/nickel-hardware-status
... i guess you actually need to have that /mnt/sd mounted somehow *or* write files in there, not sure what..
anarcat is offline   Reply With Quote
Old 02-01-2017, 12:57 PM   #27
tshering
Wizard
tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.
 
Posts: 3,489
Karma: 2914715
Join Date: Jun 2012
Device: kobo touch
Quote:
Originally Posted by anarcat View Post
also, in my experience, just this is not sufficient:

Code:
 echo sd add /dev/mmcblk1p1 >> /tmp/nickel-hardware-status
... i guess you actually need to have that /mnt/sd mounted somehow *or* write files in there, not sure what..
With this command you make nickel only read the files that belong to the sd. Reading the whole user partition in this situation would be a waste of time and energy.
tshering is offline   Reply With Quote
Old 02-01-2017, 01:26 PM   #28
tshering
Wizard
tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.
 
Posts: 3,489
Karma: 2914715
Join Date: Jun 2012
Device: kobo touch
I just tried, and it works with inserted sd.
tshering is offline   Reply With Quote
Old 02-01-2017, 02:09 PM   #29
kido.resuri
Groupie
kido.resuri has a spectacular aura aboutkido.resuri has a spectacular aura aboutkido.resuri has a spectacular aura aboutkido.resuri has a spectacular aura aboutkido.resuri has a spectacular aura aboutkido.resuri has a spectacular aura aboutkido.resuri has a spectacular aura aboutkido.resuri has a spectacular aura aboutkido.resuri has a spectacular aura aboutkido.resuri has a spectacular aura aboutkido.resuri has a spectacular aura about
 
Posts: 172
Karma: 4282
Join Date: Dec 2016
Location: Hungary
Device: Kobo Aura H2O
Quote:
Originally Posted by tshering View Post
I just tried, and it works with inserted sd.
You can't use the real and virtual sd at the same time, can you?


Anyway, I tried this, and it works! I really like it! Maybe the database can be rewritten on reboot to look for the content on it's "real" place instead of the virtual sd. I tried to put a book in a subfolder and nickel had no problem with it, so one could easily do an UPDATE sql query on /mnt/sd/ebook or whatetever folder.

This way I could add any book with the hacked update server with the built-in sync.

Last edited by kido.resuri; 02-01-2017 at 02:12 PM.
kido.resuri is offline   Reply With Quote
Old 02-01-2017, 02:15 PM   #30
frostschutz
Linux User
frostschutz ought to be getting tired of karma fortunes by now.frostschutz ought to be getting tired of karma fortunes by now.frostschutz ought to be getting tired of karma fortunes by now.frostschutz ought to be getting tired of karma fortunes by now.frostschutz ought to be getting tired of karma fortunes by now.frostschutz ought to be getting tired of karma fortunes by now.frostschutz ought to be getting tired of karma fortunes by now.frostschutz ought to be getting tired of karma fortunes by now.frostschutz ought to be getting tired of karma fortunes by now.frostschutz ought to be getting tired of karma fortunes by now.frostschutz ought to be getting tired of karma fortunes by now.
 
frostschutz's Avatar
 
Posts: 2,279
Karma: 6123806
Join Date: Sep 2010
Location: Heidelberg, Germany
Device: none
Quote:
Originally Posted by kido.resuri View Post
You can't use the real and virtual sd at the same time, can you?
You can try using a subdir of /mnt/sd as mount point instead of /mnt/sd itself. (It will vanish and need to be re-mounted when someone actually puts in an sd card later)

The Kobo firmware also handles multiple SD cards, identifies them by the random fat identifier... not sure what it does here with no real sd card present
frostschutz is offline   Reply With Quote
Reply

Tags
filesystem, hack, reload, sdcard


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Refresh library MrX Calibre 11 06-07-2016 04:45 PM
Is it no possible to refresh the page automatically in Moon+ Reader? cicabum Android Devices 4 10-22-2015 12:23 PM
Library refresh after editing metadata kelleybean Library Management 2 01-13-2015 09:10 AM
Refresh library view? Pepin33 Development 4 08-31-2012 05:18 AM
7.40 - Automatically refresh the covers edbro Calibre 0 01-14-2011 10:02 PM


All times are GMT -4. The time now is 07:04 PM.


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