This commit is contained in:
Kovid Goyal 2018-10-04 18:13:34 +05:30
commit 6a20a354bb
No known key found for this signature in database
GPG Key ID: 06BC317B515ACE7C

View File

@ -1335,7 +1335,7 @@ class KOBOTOUCH(KOBO):
# Starting with firmware version 3.19.x, the last number appears to be is a # Starting with firmware version 3.19.x, the last number appears to be is a
# build number. A number will be recorded here but it can be safely ignored # build number. A number will be recorded here but it can be safely ignored
# when testing the firmware version. # when testing the firmware version.
max_supported_fwversion = (4, 10, 11586) max_supported_fwversion = (4, 10, 11626)
# The following document firwmare versions where new function or devices were added. # The following document firwmare versions where new function or devices were added.
# Not all are used, but this feels a good place to record it. # Not all are used, but this feels a good place to record it.
min_fwversion_shelves = (2, 0, 0) min_fwversion_shelves = (2, 0, 0)
@ -1347,6 +1347,7 @@ class KOBOTOUCH(KOBO):
min_auraone_fwversion = (3, 20, 7280) min_auraone_fwversion = (3, 20, 7280)
min_fwversion_overdrive = (4, 0, 7523) min_fwversion_overdrive = (4, 0, 7523)
min_clarahd_fwversion = (4, 8, 11090) min_clarahd_fwversion = (4, 8, 11090)
# min_forma_fwversion = (4, 10, 11xxx) # TODO: Update when known.
has_kepubs = True has_kepubs = True
@ -1372,6 +1373,7 @@ class KOBOTOUCH(KOBO):
AURA_H2O_EDITION2_PRODUCT_ID = [0x4227] AURA_H2O_EDITION2_PRODUCT_ID = [0x4227]
AURA_ONE_PRODUCT_ID = [0x4225] AURA_ONE_PRODUCT_ID = [0x4225]
CLARA_HD_PRODUCT_ID = [0x4228] CLARA_HD_PRODUCT_ID = [0x4228]
FORMA_PRODUCT_ID = [0x4229]
GLO_PRODUCT_ID = [0x4173] GLO_PRODUCT_ID = [0x4173]
GLO_HD_PRODUCT_ID = [0x4223] GLO_HD_PRODUCT_ID = [0x4223]
MINI_PRODUCT_ID = [0x4183] MINI_PRODUCT_ID = [0x4183]
@ -1381,7 +1383,7 @@ class KOBOTOUCH(KOBO):
AURA_HD_PRODUCT_ID + AURA_H2O_PRODUCT_ID + AURA_H2O_EDITION2_PRODUCT_ID + \ AURA_HD_PRODUCT_ID + AURA_H2O_PRODUCT_ID + AURA_H2O_EDITION2_PRODUCT_ID + \
GLO_PRODUCT_ID + GLO_HD_PRODUCT_ID + \ GLO_PRODUCT_ID + GLO_HD_PRODUCT_ID + \
MINI_PRODUCT_ID + TOUCH_PRODUCT_ID + TOUCH2_PRODUCT_ID + \ MINI_PRODUCT_ID + TOUCH_PRODUCT_ID + TOUCH2_PRODUCT_ID + \
AURA_ONE_PRODUCT_ID + CLARA_HD_PRODUCT_ID AURA_ONE_PRODUCT_ID + CLARA_HD_PRODUCT_ID + FORMA_PRODUCT_ID
BCD = [0x0110, 0x0326, 0x401] BCD = [0x0110, 0x0326, 0x401]
@ -1440,6 +1442,14 @@ class KOBOTOUCH(KOBO):
# Used for library lists # Used for library lists
' - N3_LIBRARY_GRID.parsed':[(149, 198), 0, 200,False,], # Used for library lists ' - N3_LIBRARY_GRID.parsed':[(149, 198), 0, 200,False,], # Used for library lists
} }
FORMA_COVER_FILE_ENDINGS = {
# Used for screensaver, home screen
' - N3_FULL.parsed': [(1440,1920), 0, 200,True,],
# Used for Details screen before FW2.8.1, then for current book tile on home screen
' - N3_LIBRARY_FULL.parsed':[(355, 473), 0, 200,False,],
# Used for library lists
' - N3_LIBRARY_GRID.parsed':[(149, 198), 0, 200,False,], # Used for library lists
}
# Following are the sizes used with pre2.1.4 firmware # Following are the sizes used with pre2.1.4 firmware
# COVER_FILE_ENDINGS = { # COVER_FILE_ENDINGS = {
# ' - N3_LIBRARY_FULL.parsed':[(355,530),0, 99,], # Used for Details screen # ' - N3_LIBRARY_FULL.parsed':[(355,530),0, 99,], # Used for Details screen
@ -3006,6 +3016,9 @@ class KOBOTOUCH(KOBO):
def isClaraHD(self): def isClaraHD(self):
return self.detected_device.idProduct in self.CLARA_HD_PRODUCT_ID return self.detected_device.idProduct in self.CLARA_HD_PRODUCT_ID
def isForma(self):
return self.detected_device.idProduct in self.FORMA_PRODUCT_ID
def isGlo(self): def isGlo(self):
return self.detected_device.idProduct in self.GLO_PRODUCT_ID return self.detected_device.idProduct in self.GLO_PRODUCT_ID
@ -3036,6 +3049,8 @@ class KOBOTOUCH(KOBO):
_cover_file_endings = self.AURA_ONE_COVER_FILE_ENDINGS _cover_file_endings = self.AURA_ONE_COVER_FILE_ENDINGS
elif self.isClaraHD(): elif self.isClaraHD():
_cover_file_endings = self.GLO_HD_COVER_FILE_ENDINGS _cover_file_endings = self.GLO_HD_COVER_FILE_ENDINGS
elif self.isForma():
_cover_file_endings = self.FORMA_COVER_FILE_ENDINGS
elif self.isGlo(): elif self.isGlo():
_cover_file_endings = self.GLO_COVER_FILE_ENDINGS _cover_file_endings = self.GLO_COVER_FILE_ENDINGS
elif self.isGloHD(): elif self.isGloHD():
@ -3066,7 +3081,9 @@ class KOBOTOUCH(KOBO):
elif self.isAuraOne(): elif self.isAuraOne():
device_name = 'Kobo Aura ONE' device_name = 'Kobo Aura ONE'
elif self.isClaraHD(): elif self.isClaraHD():
device_name = 'Clara HD' device_name = 'Kobo Clara HD'
elif self.isForma():
device_name = 'Kobo Forma'
elif self.isGlo(): elif self.isGlo():
device_name = 'Kobo Glo' device_name = 'Kobo Glo'
elif self.isGloHD(): elif self.isGloHD():