Skip to content

ASk1/dsm7-usb-serial-drivers

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Missing USB serial drivers for DSM 7

Supported drivers

  • cp210x
  • ch341

Supported platforms

  • apollolake (linux-4.4.x)
  • armada38x (linux-3.10.x-bsp)
  • armadaxp (linux-3.x)
  • avoton (linux-3.10.x)
  • braswell (linux-3.10.x)
  • geminilake (linux-4.4.x)
  • monaco (linux-3.10.x)
  • v1000 (linux-4.4.x)

Feel free to request other drivers or platforms. You can find out which platform your NAS is using on this page.

Installation

NB: the following steps will require SSH access and administrator rights. For the latter, either use sudo for each command or use su to log in as root.

  • The kernel modules for each supported platform can be found in modules/. Copy the required files to your Synology and move them to /lib/modules
  • To make DSM 7 automatically load the kernel modules at boot time, copy the file 90-usb-serial.conf to /usr/lib/modules-load.d/
  • Run systemctl restart systemd-modules-load to load the modules
Alternative method to load the modules at boot time
  • Copy the included file usb-serial-drivers.sh to /usr/local/etc/rc.d
  • Make sure that the file has executable permissions: chmod +x /usr/local/etc/rc.d/usb-serial-drivers.sh

After completing the previous step, run the script to load the modules:

# /usr/local/etc/rc.d/usb-serial-drivers.sh

Building from source

I've built these modules in an Ubuntu 18.04.5 virtual machine on my Synology NAS.

To set up the build environment, I followed the steps in this document. The different NAS targets/platforms can be installed next to each other.

To build the modules for a particular platform, I follow these steps:

sudo rm -fr /toolkit/build_env/ds.$platform-7.0/source
sudo /toolkit/pkgscripts-ng/PkgCreate.py -X 1 -P 1 -v 7.0 --min-sdk 7.0 -p $platform $module
cp -v /toolkit/build_env/ds.$platform-7.0/source/$module/*.ko /tmp

Replace $platform with the NAS platform, for example apollolake. Replace $module with the source directory name (found in sources/ in this repository) relevant for that particular platform. For example, apollolake requires the 4.4.x sources.

Put together, to build for apollolake, the commands become:

sudo rm -fr /toolkit/build_env/ds.apollolake-7.0/source
sudo /toolkit/pkgscripts-ng/PkgCreate.py -X 1 -P 1 -v 7.0 --min-sdk 7.0 -p apollolake 4.4.x
cp -v /toolkit/build_env/ds.apollolake-7.0/source/$module/*.ko /tmp

Due to some concurrency issues that I haven't bothered to look into, the second step (PkgCreate) sometimes fails with a compilation error. If that happens, start over.

The last step will copy the driver modules to /tmp

Disclaimer

I don't/can't test every driver. Use at your own peril.

Attribution

I'm using the source code (as-is) for the drivers included in the Linux kernel from the Synology Open Source Project.

About

Synology DSM 7 USB serial drivers

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • C 94.6%
  • Shell 4.9%
  • Makefile 0.5%