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 06-05-2020, 03:43 PM   #1
Flaviocc
Zealot
Flaviocc began at the beginning.
 
Posts: 127
Karma: 10
Join Date: May 2019
Location: Brazil
Device: Kindle PPW5 / Kobo Aura One
Plugging and unplugging via USB

Is there a hack to avoid plugging and unplugging the Kobo from USB when we are working on Calibre?

Does this hack exist or is it possible?

I always had this same doubt about the kindle...
Flaviocc is offline   Reply With Quote
Old 06-05-2020, 04:06 PM   #2
NiLuJe
BLAM!
NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.
 
NiLuJe's Avatar
 
Posts: 13,478
Karma: 26012494
Join Date: Jun 2010
Location: Paris, France
Device: Kindle 2i, 3g, 4, 5w, PW, PW2, PW5; Kobo H2O, Forma, Elipsa, Sage, C2E
Err, what do you mean by that, exactly?
NiLuJe is offline   Reply With Quote
Advert
Old 06-05-2020, 04:12 PM   #3
Deskisamess
Wizard
Deskisamess ought to be getting tired of karma fortunes by now.Deskisamess ought to be getting tired of karma fortunes by now.Deskisamess ought to be getting tired of karma fortunes by now.Deskisamess ought to be getting tired of karma fortunes by now.Deskisamess ought to be getting tired of karma fortunes by now.Deskisamess ought to be getting tired of karma fortunes by now.Deskisamess ought to be getting tired of karma fortunes by now.Deskisamess ought to be getting tired of karma fortunes by now.Deskisamess ought to be getting tired of karma fortunes by now.Deskisamess ought to be getting tired of karma fortunes by now.Deskisamess ought to be getting tired of karma fortunes by now.
 
Deskisamess's Avatar
 
Posts: 2,609
Karma: 42697471
Join Date: Sep 2012
Location: Ohio
Device: iPhone 7+, iPad mini, 2021 iPad Pro 12.9",Paperwhite 6.8"
To eject and reconnect without physically unplugging and replugging?
Deskisamess is offline   Reply With Quote
Old 06-05-2020, 04:23 PM   #4
NiLuJe
BLAM!
NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.
 
NiLuJe's Avatar
 
Posts: 13,478
Karma: 26012494
Join Date: Jun 2010
Location: Paris, France
Device: Kindle 2i, 3g, 4, 5w, PW, PW2, PW5; Kobo H2O, Forma, Elipsa, Sage, C2E
Or to transfer stuff wirelessly from start to finish?

(Because both are doable, so, ask a better question ).
NiLuJe is offline   Reply With Quote
Old 06-05-2020, 04:48 PM   #5
Flaviocc
Zealot
Flaviocc began at the beginning.
 
Posts: 127
Karma: 10
Join Date: May 2019
Location: Brazil
Device: Kindle PPW5 / Kobo Aura One
Quote:
Originally Posted by Deskisamess View Post
To eject and reconnect without physically unplugging and replugging?
Sorry my question wasn't well posted.

Yes, eject and reconnect without physically unplugging and replugging.

Quote:
Originally Posted by NiLuJe View Post
Or to transfer stuff wirelessly from start to finish?
This is a nice solution too

Last edited by Flaviocc; 06-05-2020 at 05:00 PM.
Flaviocc is offline   Reply With Quote
Advert
Old 06-05-2020, 04:54 PM   #6
Deskisamess
Wizard
Deskisamess ought to be getting tired of karma fortunes by now.Deskisamess ought to be getting tired of karma fortunes by now.Deskisamess ought to be getting tired of karma fortunes by now.Deskisamess ought to be getting tired of karma fortunes by now.Deskisamess ought to be getting tired of karma fortunes by now.Deskisamess ought to be getting tired of karma fortunes by now.Deskisamess ought to be getting tired of karma fortunes by now.Deskisamess ought to be getting tired of karma fortunes by now.Deskisamess ought to be getting tired of karma fortunes by now.Deskisamess ought to be getting tired of karma fortunes by now.Deskisamess ought to be getting tired of karma fortunes by now.
 
Deskisamess's Avatar
 
Posts: 2,609
Karma: 42697471
Join Date: Sep 2012
Location: Ohio
Device: iPhone 7+, iPad mini, 2021 iPad Pro 12.9",Paperwhite 6.8"
From my limited experience with Calibre, I know certain actions can't be performed when a device is attached. It would be nice to be able to eject the device without physically disconnecting and plugging back in to remount.

There may be techie ways to achieve this, of which I've no idea.
Deskisamess is offline   Reply With Quote
Old 06-05-2020, 05:05 PM   #7
hobnail
Running with scissors
hobnail ought to be getting tired of karma fortunes by now.hobnail ought to be getting tired of karma fortunes by now.hobnail ought to be getting tired of karma fortunes by now.hobnail ought to be getting tired of karma fortunes by now.hobnail ought to be getting tired of karma fortunes by now.hobnail ought to be getting tired of karma fortunes by now.hobnail ought to be getting tired of karma fortunes by now.hobnail ought to be getting tired of karma fortunes by now.hobnail ought to be getting tired of karma fortunes by now.hobnail ought to be getting tired of karma fortunes by now.hobnail ought to be getting tired of karma fortunes by now.
 
Posts: 1,552
Karma: 14325282
Join Date: Nov 2019
Device: none
If (like me) you're worried about wearing out or damaging the USB connector on your ereader my solution is to use a USB extension cable, so that you have two cables between your computer and your ereader. The main one is plugged into the back of the computer and the extension is plugged into that. Then I just unplug the extension cable from the main cable, wait a few moments for the Kobo to update its database, then plug it back in so that Calibre can update the series info/metadata.

I can't find it but there was another thread where someone asked this question and one of the responses was about some box that had a switch to disconnect and connect the USB but I think they said it wasn't reliable.
hobnail is offline   Reply With Quote
Old 06-05-2020, 05:05 PM   #8
twowheels
Wizard
twowheels ought to be getting tired of karma fortunes by now.twowheels ought to be getting tired of karma fortunes by now.twowheels ought to be getting tired of karma fortunes by now.twowheels ought to be getting tired of karma fortunes by now.twowheels ought to be getting tired of karma fortunes by now.twowheels ought to be getting tired of karma fortunes by now.twowheels ought to be getting tired of karma fortunes by now.twowheels ought to be getting tired of karma fortunes by now.twowheels ought to be getting tired of karma fortunes by now.twowheels ought to be getting tired of karma fortunes by now.twowheels ought to be getting tired of karma fortunes by now.
 
twowheels's Avatar
 
Posts: 1,790
Karma: 13412766
Join Date: Nov 2010
Device: Kobo Clara HD, iPad Pro 10", iPhone 15 Pro
The easiest way is to unmount and re-mount. If you choose the usual eject, then some OSes will actually turn off the device and it cannot be re-mounted without disconnecting.

On Linux, I use pmount and pumount to connect & disconnect the media.

On MacOS, I usually use `diskutil eject /Volumes/<name>`, though that has the same problem. You can also unmount and remount, using this:

diskutil unmount /Volumes/<name>

then to find it again:

diskutil list | grep Volume

and then remount with:

diskutil mount <id, from last column>


EDIT: For MacOS You can also use the graphical "Disk Utility" program, right click on the drive and choose "unmount", then "remount" -- NOT eject.
...

for Windows, well, you're on your own.

Last edited by twowheels; 06-05-2020 at 05:07 PM.
twowheels is offline   Reply With Quote
Old 06-05-2020, 05:08 PM   #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: 35,513
Karma: 145557716
Join Date: Jul 2010
Location: Vancouver
Device: Kobo Sage, Forma, Clara HD, Lenovo M8 FHD, Paperwhite 4, Tolino epos
Quote:
Originally Posted by hobnail View Post
I can't find it but there was another thread where someone asked this question and one of the responses was about some box that had a switch to disconnect and connect the USB but I think they said it wasn't reliable.
I suspect that was a post by @davidfor. I have a similar device and it works with USB ports that supply enough voltage that the voltage drop across the device does not take the voltage out of spec. So it works if the ereader is plugged directly into my laptop or into a powered USB hub but did not work when I tried a passive USB hub.
DNSB is offline   Reply With Quote
Old 06-05-2020, 05:17 PM   #10
Flaviocc
Zealot
Flaviocc began at the beginning.
 
Posts: 127
Karma: 10
Join Date: May 2019
Location: Brazil
Device: Kindle PPW5 / Kobo Aura One
@hobnail,

yes my concern is damage the connector in the future with the constant in and out the usb plug.

@twowheels,

windows here
Flaviocc is offline   Reply With Quote
Old 06-05-2020, 05:44 PM   #11
twowheels
Wizard
twowheels ought to be getting tired of karma fortunes by now.twowheels ought to be getting tired of karma fortunes by now.twowheels ought to be getting tired of karma fortunes by now.twowheels ought to be getting tired of karma fortunes by now.twowheels ought to be getting tired of karma fortunes by now.twowheels ought to be getting tired of karma fortunes by now.twowheels ought to be getting tired of karma fortunes by now.twowheels ought to be getting tired of karma fortunes by now.twowheels ought to be getting tired of karma fortunes by now.twowheels ought to be getting tired of karma fortunes by now.twowheels ought to be getting tired of karma fortunes by now.
 
twowheels's Avatar
 
Posts: 1,790
Karma: 13412766
Join Date: Nov 2010
Device: Kobo Clara HD, iPad Pro 10", iPhone 15 Pro
Quote:
Originally Posted by Flaviocc View Post
@hobnail,

yes my concern is damage the connector in the future with the constant in and out the usb plug.

@twowheels,

windows here
This looks promising, but I don't have a Windows computer to test on:

https://superuser.com/questions/7048...cript-software
twowheels is offline   Reply With Quote
Old 06-05-2020, 05:52 PM   #12
NiLuJe
BLAM!
NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.
 
NiLuJe's Avatar
 
Posts: 13,478
Karma: 26012494
Join Date: Jun 2010
Location: Paris, France
Device: Kindle 2i, 3g, 4, 5w, PW, PW2, PW5; Kobo H2O, Forma, Elipsa, Sage, C2E
Hmm, AFAIK, a plain old OS eject will do just fine, and is actually necessary here.

i.e., you *want* the Kobo to detect a true eject, so it can remount it and process the new content, to account for the double cycle necessary to handle metadata updating, as was mentioned earlier.

Then, you just kindly tell the Kobo that, yes, it's still plugged in, please show me the "Connect" popup again:

Code:
echo "usb plug add" > /tmp/nickel-hardware-status
There's a NickelMenu action for that:

Code:
menu_item : main : USB : nickel_misc : force_usb_connection
(Incidentally, this is what I've been doing since day 1 with a Kobo & Calibre, on my end).

Last edited by NiLuJe; 06-05-2020 at 06:00 PM.
NiLuJe is offline   Reply With Quote
Old 06-05-2020, 05:54 PM   #13
NiLuJe
BLAM!
NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.
 
NiLuJe's Avatar
 
Posts: 13,478
Karma: 26012494
Join Date: Jun 2010
Location: Paris, France
Device: Kindle 2i, 3g, 4, 5w, PW, PW2, PW5; Kobo H2O, Forma, Elipsa, Sage, C2E
As for the wireless route, that's either a pure DIY approach with whatever transfer/sync/cloud solution you want in a script that you run with NM or KFMon (e.g., rsync, rclone, sftp, scp, ftp; you name it).

Or as an OPDS client against e.g., Calibre via KOReader.

Or as a Calibre Wireless Smart Device client, e.g., via KOReader or @sherman's UNCaGED.

Note that with (most) wireless approaches, you lose much of the niceties involved in Calibre actually knowing that it's dealing with a Kobo, because it doesn't know that anymore.

Last edited by NiLuJe; 06-05-2020 at 06:01 PM.
NiLuJe is offline   Reply With Quote
Old 06-05-2020, 06:00 PM   #14
Flaviocc
Zealot
Flaviocc began at the beginning.
 
Posts: 127
Karma: 10
Join Date: May 2019
Location: Brazil
Device: Kindle PPW5 / Kobo Aura One
Quote:
Originally Posted by NiLuJe View Post
Hmm, AFAIK, a plain old OS eject will do just fine, and is actually necessary here.

i.e., you *want* the Kobo to detect a true eject, so it can remount it and process the new content, to account for the double cycle necessary to handle metadata updating, as was mentioned earlier.

Then, you just kindly tell the Kobo that, yes, it's still plugged in, please show me the "Connect" popup again:

Code:
echo "usb plug add" > /tmp/nickel-hardware-status
There's a NickelMenu action for that:

Code:
menu_item : main : USB : nickel_misc : force_usb_connection
Nice!

I'll try the Nickel menu. That solution is perfect for what I want.

Tks.
Flaviocc is offline   Reply With Quote
Old 06-05-2020, 06:03 PM   #15
NiLuJe
BLAM!
NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.
 
NiLuJe's Avatar
 
Posts: 13,478
Karma: 26012494
Join Date: Jun 2010
Location: Paris, France
Device: Kindle 2i, 3g, 4, 5w, PW, PW2, PW5; Kobo H2O, Forma, Elipsa, Sage, C2E
On Windows, you'll want to go with the "Eject this device safely" USB thingy in the status bar.

On macOS, with a right click > Eject on the volume's icon on the desktop (or the Eject button below it in Finder).

(Replace that with the actual proper name of those things, because I'm not running either of those right now ^^)

On Linux, via the eject command .
NiLuJe is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Troubleshooting reconnecting to Kindle without unplugging the USB chord? shinew Amazon Kindle 6 06-02-2014 10:07 AM
Windows 8 message when plugging Kobo Touch in filthyPierre Kobo Reader 4 12-20-2012 09:21 PM
Kobo crashes my pc after plugging in USB Fredness Kobo Tablets 4 12-26-2011 08:26 PM
PRS-650 Unplugging USB - warning! Neon Kitten Sony Reader 27 12-23-2010 07:16 PM
Unplugging reader from USB ? MO74 Sony Reader 2 01-04-2010 07:03 PM


All times are GMT -4. The time now is 05:03 AM.


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