Merge pull request #14 from ubports/add-sd

Add microSD card to JumpDrive
This commit is contained in:
Martijn Braam 2020-05-02 17:07:19 +02:00 committed by GitHub
commit 1b0f0ea334
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 7 additions and 1 deletions

View File

@ -38,6 +38,8 @@ setup_usb_configfs() {
|| echo " Couldn't create $CONFIGFS/g1/functions/$usb_rndis_function"
mkdir $CONFIGFS/g1/functions/"$usb_mass_storage_function" \
|| echo " Couldn't create $CONFIGFS/g1/functions/$usb_mass_storage_function"
mkdir $CONFIGFS/g1/functions/"$usb_mass_storage_function/lun.1" \
|| echo " Couldn't create $CONFIGFS/g1/functions/$usb_mass_storage_function/lun.1"
# Create configuration instance for the gadget
mkdir $CONFIGFS/g1/configs/c.1 \
@ -54,9 +56,11 @@ setup_usb_configfs() {
# Set up mass storage to internal EMMC
echo $EMMC > $CONFIGFS/g1/functions/"$usb_mass_storage_function"/lun.0/file
echo $SD > $CONFIGFS/g1/functions/"$usb_mass_storage_function"/lun.1/file
# Rename the mass storage device
echo "JumpDrive" > $CONFIGFS/g1/functions/"$usb_mass_storage_function"/lun.0/inquiry_string
echo "JumpDrive eMMC" > $CONFIGFS/g1/functions/"$usb_mass_storage_function"/lun.0/inquiry_string
echo "JumpDrive microSD" > $CONFIGFS/g1/functions/"$usb_mass_storage_function"/lun.1/inquiry_string
# Link the rndis/mass_storage instance to the configuration
ln -s $CONFIGFS/g1/functions/"$usb_rndis_function" $CONFIGFS/g1/configs/c.1 \

View File

@ -1,5 +1,6 @@
PLATFORM=pine64-pinephone
EMMC=/dev/mmcblk2
SD=/dev/mmcblk0
LED=pinephone\:red\:user
TRIGGER=mmc2
ERRORLINES=80

View File

@ -1,2 +1,3 @@
PLATFORM=pine64-pinetab
EMMC=/dev/mmcblk2
SD=/dev/mmcblk0