View Single Post
Old 02-01-2017, 12:43 PM   #25
anarcat
Connoisseur
anarcat doesn't litteranarcat doesn't litter
 
anarcat's Avatar
 
Posts: 83
Karma: 192
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