Forum | Documentation | Website | Blog

Skip to content
Snippets Groups Projects
Commit 09c3e6da authored by Robert Nelson's avatar Robert Nelson
Browse files

bb-usb-gadgets (1.20211012.0)


Signed-off-by: default avatarRobert Nelson <robertcnelson@gmail.com>
parent bd0fc80e
Branches
No related merge requests found
......@@ -114,6 +114,21 @@ run_libcomposite () {
mkdir -p functions/acm.usb0
ln -s functions/acm.usb0 configs/c.1/
#mkdir -p functions/mass_storage.usb0
#echo 0 > functions/mass_storage.usb0/stall
#echo /dev/nbd0 > functions/mass_storage.usb0/lun.0/file
#ln -s functions/mass_storage.usb0 configs/c.1/
if [ -f /usr/bin/umtprd ] ; then
mkdir -p functions/ffs.mtp
ln -s functions/ffs.mtp configs/c.1
mkdir /dev/ffs-mtp
mount -t functionfs mtp /dev/ffs-mtp
/usr/bin/umtprd &
sleep 1
fi
fi
ls /sys/class/udc/ > UDC
......
......@@ -4,11 +4,27 @@ log="bb-usb-gadgets"
#Examples
#https://github.com/linux-usb-gadgets/libusbgx/tree/master/examples
#built_in="gadget-acm-ecm"
#built_in="gadget-ffs"
#built_in="gadget-hid"
#built_in="gadget-midi"
#built_in="gadget-ms"
#built_in="gadget-printer"
#built_in="gadget-rndis-os-desc"
#built_in="gadget-uac2"
#built_in="gadget-uvc"
#/usr/bin/gadget-export
#/usr/bin/gadget-import
#/usr/bin/gadget-vid-pid-remove
#/usr/bin/show-gadgets
#/usr/bin/show-udcs
#echo "${log} /usr/bin/$build_in"
#/usr/bin/$built_in
#Someday...
#Someday... (RNDIS os-desc broken...)
#echo "${log}: gt load --off bbb-acm-ncm-rndis.scheme g_multi"
#gt load --off bbb-acm-ncm-rndis.scheme g_multi
##update mac addresss...
......
......@@ -4,8 +4,7 @@ After=usb-gadget.target
ConditionFileIsExecutable=/usr/bin/bb-start-usb-gadgets
[Service]
Type=oneshot
#ExecStartPre=/sbin/modprobe nbd
Type=forking
ExecStartPre=/sbin/modprobe libcomposite
ExecStart=/usr/bin/bb-start-usb-gadgets
......
......@@ -14,3 +14,4 @@ debian/usb0-DHCP.network /etc/bbb.io/templates/
debian/usb0-DHCPServer.network /etc/bbb.io/templates/
debian/usb1-DHCP.network /etc/bbb.io/templates/
debian/usb1-DHCPServer.network /etc/bbb.io/templates/
debian/bbb-umtprd.conf /etc/bbb.io/templates/
......@@ -14,4 +14,20 @@ if [ ! -f /etc/systemd/network/usb1.network ] ; then
cp -v /etc/bbb.io/templates/usb1-DHCPServer.network /etc/systemd/network/usb1.network
fi
if [ ! -d /etc/umtprd/ ] ; then
mkdir /etc/umtprd/ || true
fi
if [ ! -f /etc/umtprd/umtprd.conf ] ; then
cp -v /etc/bbb.io/templates/bbb-umtprd.conf /etc/umtprd/umtprd.conf
else
rm -rf /etc/umtprd/umtprd.conf
cp -v /etc/bbb.io/templates/bbb-umtprd.conf /etc/umtprd/umtprd.conf
fi
#if [ ! -d /opt/mtp/ ] ; then
# mkdir /opt/mtp
# chown -R 1000:1000 /opt/mtp
#fi
#DEBHELPER#
#
# uMTP Responder config file
#
# Loop / daemon mode
# Set to 0 to shutdown when the link is disconnected.
loop_on_disconnect 1
# storage command : Create add a storage entry point. Up to 16 entry points supported
# Syntax : storage "PATH" "NAME"
# NOTICE: currently the systemd unit file allows r/w
# access only to /var/lib/umtp
# See /usr/share/doc/umtp-responder/README.Debian
#Disable wide options;
#storage "/boot" "/boot/ (RW)" "rw"
#storage "/etc/wpa_supplicant/" "WiFi Credentials (RW)" "rw"
#storage "/etc/systemd/network/" "Network Configuration (RW)" "rw"
#storage "/opt/mtp" "/opt/mtp/ Examples (RW)" "rw"
storage "/opt" "/opt/ (RW)" "rw"
#
# Uncomment the following line if you want to
# override the system default umask value for
# the uploaded files.
#
umask 022
# Set the USB manufacturer string
manufacturer "BeagleBoard.org"
# Set the USB Product string
product "BeagleBoard.org"
# Set the USB Serial number string
serial "01234567"
# Set the MTP firmware version
firmware_version "Rev A"
# Set the USB interface string. Should be always "MTP"
interface "MTP"
# Set the USB Vendor ID, Product ID and class
usb_vendor_id 0x1D6B # Linux Foundation
usb_product_id 0x0100 # PTP Gadget
usb_class 0x6 # Image
usb_subclass 0x1 # Still Imaging device
usb_protocol 0x1 #
# Device version
usb_dev_version 0x3008
# inotify support
# If you want disable the events support (beta), uncomment the following line :
# no_inotify 0x1
#
# Internal buffers size
#
# Internal default usb_max_rd_buffer_size and usb_max_wr_buffer_size value set to 0x10000.
# Internal default read_buffer_cache_size value set to 0x100000.
# Uncomment the following lines to reduce the buffers sizes to fix USB issues on iMX6 based systems.
usb_max_rd_buffer_size 0x200 # MAX usb read size. Must be a multiple of 512 and be less than read_buffer_cache_size
usb_max_wr_buffer_size 0x200 # MAX usb write size. Must be a multiple of 512.
read_buffer_cache_size 0x4000 # Read file cache buffer. Must be a 2^x value.
#
# USB gadget device driver path
#
########################################################################
#
# -- Generic FunctionFS Mode --
#
########################################################################
usb_functionfs_mode 0x1
usb_dev_path "/dev/ffs-mtp/ep0"
usb_epin_path "/dev/ffs-mtp/ep1"
usb_epout_path "/dev/ffs-mtp/ep2"
usb_epint_path "/dev/ffs-mtp/ep3"
usb_max_packet_size 0x200
bb-usb-gadgets (1.20211012.0-0~bullseye+20211013) bullseye; urgency=low
* Rebuild for repos.rcn-ee.com
-- Robert Nelson <robertcnelson@gmail.com> Wed, 13 Oct 2021 10:54:33 -0500
bb-usb-gadgets (1.20211007.2-0~bullseye+20211007) bullseye; urgency=low
* Rebuild for repos.rcn-ee.com
......
......@@ -6,8 +6,8 @@ Build-Depends: debhelper (>= 10)
Standards-Version: 4.5.1
Package: bb-usb-gadgets
Architecture: arm64
Pre-Depends: gt, libusbgx
Architecture: all
Pre-Depends: gt, libusbgx, umtp-responder
Depends: ${shlibs:Depends}, ${misc:Depends}, bc, systemd (>= 230)
Description: usb gadget customizations
usb gadget customizations
......
......@@ -2,7 +2,7 @@
package_name="bb-usb-gadgets"
debian_pkg_name="${package_name}"
package_version="1.20211007.2"
package_version="1.20211012.0"
package_source=""
src_dir=""
......@@ -15,4 +15,4 @@ debian_version="${package_version}-0"
debian_untar=""
debian_patch=""
bullseye_version="~bullseye+20211007"
bullseye_version="~bullseye+20211013"
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment