Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Readers > Kobo Reader

Notices

Reply
 
Thread Tools Search this Thread
Old 09-27-2022, 01:05 PM   #1
chaley
Grand Sorcerer
chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.
 
Posts: 12,447
Karma: 8012886
Join Date: Jan 2010
Location: Notts, England
Device: Kobo Libra 2
I am willing to help with the calibre kobo driver

First, I wasn't sure whether to put this here or in the calibre devices forum. I decided to try here first. Mods, feel free to move it.

I am willing to help maintain the calibre kobo driver. I understand the calibre device driver architecture. I have a fair understanding of the built-in calibre kobo driver, having hacked it to do some things I wanted. I understand sqlite databases. Releasing changes isn't a problem.

However, what I don't know is important. I don't know how to check if firmware changes require driver changes, including database schema changes. I know nothing of "nickel".

Thus, for me to be of help I need to work with someone who knows the stuff I don't know. Does such a person exist? Does this person already have things under control?

If this is a non-problem then fine. I have other ways of spending my time.
chaley is offline   Reply With Quote
Old 09-27-2022, 01:57 PM   #2
rtiangha
Evangelist
rtiangha ought to be getting tired of karma fortunes by now.rtiangha ought to be getting tired of karma fortunes by now.rtiangha ought to be getting tired of karma fortunes by now.rtiangha ought to be getting tired of karma fortunes by now.rtiangha ought to be getting tired of karma fortunes by now.rtiangha ought to be getting tired of karma fortunes by now.rtiangha ought to be getting tired of karma fortunes by now.rtiangha ought to be getting tired of karma fortunes by now.rtiangha ought to be getting tired of karma fortunes by now.rtiangha ought to be getting tired of karma fortunes by now.rtiangha ought to be getting tired of karma fortunes by now.
 
Posts: 495
Karma: 356531
Join Date: Jul 2016
Location: 'burta, Canada
Device: Kobo Glo HD
You should get into contact with PeterT as he's also volunteered to help with maintaining the Kobo the driver but is also trying to reverse engineer what davidfor did.

From my (limited) understanding from looking at the code (and I'm sure people will correct me if I'm wrong; please do!), when new devices enter the market, entries for its Product ID needs to be entered into the driver so Calibre can recognize it. This can be gotten from looking at the firmware, but if you want Calibre to support it on Day 1 release, that'll only work if you get access to pre-release firmware (ex. You're a Kobo Beta Tester), or if you ask Kobo really, really nicely.

Next, each device has a minimum firmware version, which I think is the version it ships with (because it may be a device specific version not released to the public) which you'd need to input. This is so the device can work out of the box with Calibre, even if there is no upgrade available at time of release.

In terms of database schema changes in between firmware releases, the driver would need to be changed to deal with them, and the database version number would need to be incremented. To figure out what changed, you'd need to look at the database that gets shipped with (or upgraded by) that firmware version. I think davidfor was able to keep on top of that because being a beta tester, he had access to pre-release firmware and could peek at the accompanying database files to see if anything changed (of course, in order to keep confidentiality, he'd only commit code changes after a new device or firmware was officially released, which is why Calibre support sometimes lags behind by a few days).

Finally, the Max Firmware value would be updated once new firmware was released and verified that everything was still working (was more important in the beginning when database schema changes were more frequent; less important today as the db rarely changes which is why it's (usually) safe to check the Unsupported Firmware option while waiting for Calibre to catch up).

That's about all I could glean by looking at the driver code and the commit history to see what davidfor did whenever new firmware or devices came out. But while I'm a computer scientist by degree, I'm not a strong coder so I'll leave this stuff to people who better know what they're doing, with my sincere gratitude and appreciation that they're picking up the mantle.

Last edited by rtiangha; 09-27-2022 at 02:02 PM.
rtiangha is offline   Reply With Quote
Advert
Old 09-27-2022, 03:41 PM   #3
chaley
Grand Sorcerer
chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.
 
Posts: 12,447
Karma: 8012886
Join Date: Jan 2010
Location: Notts, England
Device: Kobo Libra 2
Quote:
Originally Posted by rtiangha View Post
You should get into contact with PeterT as he's also volunteered to help with maintaining the Kobo the driver but is also trying to reverse engineer what davidfor did.
Thanks much. I will do that. And I am glad that @PeterT is picking up the ball.

The driver is based on the Sony PRS driver that I (mostly) wrote some 10 years ago. There is a lot of stuff in it that doesn't make sense for the kobo, for example the code around collection sort values. Perhaps I can help explain some of it. I can also help explain the collection template stuff that @davidfor added, as I did some of the early versions.
chaley is offline   Reply With Quote
Old 10-02-2022, 11:36 AM   #4
Cactus Chef
Fanatic
Cactus Chef ought to be getting tired of karma fortunes by now.Cactus Chef ought to be getting tired of karma fortunes by now.Cactus Chef ought to be getting tired of karma fortunes by now.Cactus Chef ought to be getting tired of karma fortunes by now.Cactus Chef ought to be getting tired of karma fortunes by now.Cactus Chef ought to be getting tired of karma fortunes by now.Cactus Chef ought to be getting tired of karma fortunes by now.Cactus Chef ought to be getting tired of karma fortunes by now.Cactus Chef ought to be getting tired of karma fortunes by now.Cactus Chef ought to be getting tired of karma fortunes by now.Cactus Chef ought to be getting tired of karma fortunes by now.
 
Cactus Chef's Avatar
 
Posts: 574
Karma: 7058832
Join Date: Apr 2019
Location: East Coast, United States
Device: Kobo Sage, Kobo Clara HD, Galaxy Tab S5e, Kindle 4th Gen
I've glanced at the code, too, and sometimes it seems like adding "support" is just a matter of bumping up a few values here and there. What's not clear to me is where those magic hex values come from for the DEVICE_PRODUCT_ID. Is that coming from the manufacturer, or something generated by the driver to keep track of the unique devices?
Cactus Chef is offline   Reply With Quote
Old 10-02-2022, 11:56 AM   #5
chaley
Grand Sorcerer
chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.
 
Posts: 12,447
Karma: 8012886
Join Date: Jan 2010
Location: Notts, England
Device: Kobo Libra 2
Quote:
Originally Posted by Cactus Chef View Post
I've glanced at the code, too, and sometimes it seems like adding "support" is just a matter of bumping up a few values here and there. What's not clear to me is where those magic hex values come from for the DEVICE_PRODUCT_ID. Is that coming from the manufacturer, or something generated by the driver to keep track of the unique devices?
The device USB ids come from the manufacturer. You can easily get them for a new device using calibre's "Get information to setup the user defined device" dialog (Preferences / Miscellaneous). It asks you to unplug the device (if needed), then plug it in. It displays the USB ids that appeared. These ids get added to the appropriate driver. For example, going through the process using my Pixel 6 I get:
Code:
USB Vendor ID (in hex): 0x18d1
USB Product ID (in hex): 0x4ee1
USB Revision ID (in hex): 0x510
One problem: sometimes manufacturers just make up the ids instead of getting them "officially". We have seen conflicts where a device appears as something else. Fortunately this doesn't often happen, and AFAIK never happens with quality companies.

Another problem: sometimes the new devices don't quite act the same as the previous ones. This is why the KOBOTOUCH driver lists the ids one by one; it can do different things depending on them.
chaley is offline   Reply With Quote
Advert
Old 10-09-2022, 07:16 PM   #6
Cootey
Absentminded Reader
Cootey ought to be getting tired of karma fortunes by now.Cootey ought to be getting tired of karma fortunes by now.Cootey ought to be getting tired of karma fortunes by now.Cootey ought to be getting tired of karma fortunes by now.Cootey ought to be getting tired of karma fortunes by now.Cootey ought to be getting tired of karma fortunes by now.Cootey ought to be getting tired of karma fortunes by now.Cootey ought to be getting tired of karma fortunes by now.Cootey ought to be getting tired of karma fortunes by now.Cootey ought to be getting tired of karma fortunes by now.Cootey ought to be getting tired of karma fortunes by now.
 
Cootey's Avatar
 
Posts: 1,324
Karma: 7387565
Join Date: Apr 2017
Device: Kobo Mini, Libra Colour & Elipsa; Kindle Paperwhite 3 & 4; iOS apps
Quote:
Originally Posted by rtiangha View Post
You should get into contact with PeterT as he's also volunteered to help with maintaining the Kobo the driver but is also trying to reverse engineer what davidfor did.
I hate to ask this, but did something happen to davidfor? I've been away from the forums for a month or so. I can't see a forum post about it here or in Kobo dev. Could somebody share a link? Thanks.
Cootey is offline   Reply With Quote
Old 10-09-2022, 07:22 PM   #7
Sirtel
Grand Sorcerer
Sirtel ought to be getting tired of karma fortunes by now.Sirtel ought to be getting tired of karma fortunes by now.Sirtel ought to be getting tired of karma fortunes by now.Sirtel ought to be getting tired of karma fortunes by now.Sirtel ought to be getting tired of karma fortunes by now.Sirtel ought to be getting tired of karma fortunes by now.Sirtel ought to be getting tired of karma fortunes by now.Sirtel ought to be getting tired of karma fortunes by now.Sirtel ought to be getting tired of karma fortunes by now.Sirtel ought to be getting tired of karma fortunes by now.Sirtel ought to be getting tired of karma fortunes by now.
 
Sirtel's Avatar
 
Posts: 13,473
Karma: 239219543
Join Date: Jan 2014
Location: Estonia
Device: Kobo Sage & Libra 2
Quote:
Originally Posted by Cootey View Post
I hate to ask this, but did something happen to davidfor? I've been away from the forums for a month or so. I can't see a forum post about it here or in Kobo dev. Could somebody share a link? Thanks.
https://www.mobileread.com/forums/sh...d.php?t=348925
Sirtel is offline   Reply With Quote
Old 10-09-2022, 08:12 PM   #8
Cootey
Absentminded Reader
Cootey ought to be getting tired of karma fortunes by now.Cootey ought to be getting tired of karma fortunes by now.Cootey ought to be getting tired of karma fortunes by now.Cootey ought to be getting tired of karma fortunes by now.Cootey ought to be getting tired of karma fortunes by now.Cootey ought to be getting tired of karma fortunes by now.Cootey ought to be getting tired of karma fortunes by now.Cootey ought to be getting tired of karma fortunes by now.Cootey ought to be getting tired of karma fortunes by now.Cootey ought to be getting tired of karma fortunes by now.Cootey ought to be getting tired of karma fortunes by now.
 
Cootey's Avatar
 
Posts: 1,324
Karma: 7387565
Join Date: Apr 2017
Device: Kobo Mini, Libra Colour & Elipsa; Kindle Paperwhite 3 & 4; iOS apps
Quote:
Originally Posted by Sirtel View Post
Thank you. I feared the worst when I read that PeterT was trying to reverse engineer the plugin. I'm sad for David's passing.

Did David also code Obok? I always assumed that he did because the Kobo driver and Obok were distributed together.

I haven't been a programmer for a long time, and I'm far too rusty to offer any help. All I can do is offer my encouragement. PeterT has a tough road ahead of him. I hope that he, and possibly Chaley, the best of success with this venture.
Cootey is offline   Reply With Quote
Old 10-10-2022, 12:58 AM   #9
DNSB
Bibliophagist
DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.
 
DNSB's Avatar
 
Posts: 46,210
Karma: 168983734
Join Date: Jul 2010
Location: Vancouver
Device: Kobo Sage, Libra Colour, Lenovo M8 FHD, Paperwhite 4, Tolino epos
Quote:
Originally Posted by Cootey View Post
Did David also code Obok? I always assumed that he did because the Kobo driver and Obok were distributed together.
Davidfor was involved with creating the Obok DRM removal for Kobo ebooks plugin but it was never distributed with the Kobo driver. It was and is available as a part of the DeDRM plugin packages.
DNSB is offline   Reply With Quote
Old 10-10-2022, 03:09 AM   #10
Cootey
Absentminded Reader
Cootey ought to be getting tired of karma fortunes by now.Cootey ought to be getting tired of karma fortunes by now.Cootey ought to be getting tired of karma fortunes by now.Cootey ought to be getting tired of karma fortunes by now.Cootey ought to be getting tired of karma fortunes by now.Cootey ought to be getting tired of karma fortunes by now.Cootey ought to be getting tired of karma fortunes by now.Cootey ought to be getting tired of karma fortunes by now.Cootey ought to be getting tired of karma fortunes by now.Cootey ought to be getting tired of karma fortunes by now.Cootey ought to be getting tired of karma fortunes by now.
 
Cootey's Avatar
 
Posts: 1,324
Karma: 7387565
Join Date: Apr 2017
Device: Kobo Mini, Libra Colour & Elipsa; Kindle Paperwhite 3 & 4; iOS apps
Quote:
Originally Posted by DNSB View Post
Davidfor was involved with creating the Obok DRM removal for Kobo ebooks plugin but it was never distributed with the Kobo driver. It was and is available as a part of the DeDRM plugin packages.

Ah, thanks for the correction. It’s been a long time since I installed the DeDRM plugin packages. That’s exactly why I thought they were distributed together.
Cootey is offline   Reply With Quote
Old 10-10-2022, 05:49 AM   #11
DrChiper
Bookish
DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.
 
DrChiper's Avatar
 
Posts: 1,017
Karma: 2003162
Join Date: Jun 2011
Device: PC, t1, t2, t3, Clara BW, Clara HD, Libra 2, Libra Color, Nxtpaper 11
Quote:
Originally Posted by chaley View Post
The device USB ids come from the manufacturer. You can easily get them for a new device using calibre's "Get information to setup the user defined device" dialog (Preferences / Miscellaneous). It asks you to unplug the device (if needed), then plug it in. It displays the USB ids that appeared.
Neat trick. I did not knew this.
For more information about genuine Vendor IDs, look here

My Kobo provides:
Code:
USB Vendor ID (in hex): 0x2237
0x2237 translates to 8759 (decimal) which according the above mentioned list belongs indeed to Kobo Inc.

Quote:
Originally Posted by chaley View Post
One problem: sometimes manufacturers just make up the ids instead of getting them "officially". We have seen conflicts where a device appears as something else. Fortunately this doesn't often happen, and AFAIK never happens with quality companies.
That also applies to USB cables (E-markers) in which Vendor IDs regularly identify themselves as 0x0000 indicating they are not genuine. Using the list above you can see whether obtained USB cables are indeed "official" ones.

Last edited by DrChiper; 10-10-2022 at 05:53 AM.
DrChiper is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Kobo Glo Driver for calibre 1.5 mischl Devices 27 11-14-2014 03:46 PM
New Calibre Kobo Driver allows deleting of Kobo Free books timlegge Kobo Reader 46 08-27-2011 10:16 PM
Touch Updates to Calibre Kobo driver for Touch timlegge Kobo Reader 20 07-22-2011 07:05 AM
Updated Kobo driver in Calibre 0.7.5 timlegge Kobo Reader 22 06-29-2010 08:14 AM
Calibre now has Kobo driver ! taming Kobo Reader 18 05-27-2010 07:36 PM


All times are GMT -4. The time now is 04:58 AM.


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