Skip to content
View in the app

A better way to browse. Learn more.

Armbian Community Forums

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Android USB Serial Communication with H5

Featured Replies

I'm trying to establish usb serial communication between an Orange Pi PC2 H5 running armbian and a samsung galaxy note 4. I'm configuring the micro USB port on the Orange Pi with libcomposite and opening up an acm port. On the android end I'm using a library by mik3y (https://github.com/mik3y/usb-serial-for-android) to establish the communication. The trouble that I'm running into getting Android drivers to support USB serial communication with the H5. I may just be just configuring the orange pi wrong. Here is the libcomposite setup script:

 

#!/bin/bash/
modprobe libcomposite
cd /sys/kernel/config/usb_gadget/
mkdir -p g1
cd g1
echo 0xa4ac > idProduct
echo 0x0525 > idVendor
echo 0x0100 > bcdDevice
echo 0x0200 > bcdUSB
mkdir -p strings/0x409
echo serial > strings/0x409/serialnumber
echo manufacturer > strings/0x409/manufacturer
echo product > strings/0x409/product
mkdir -p configs/c.1/strings/0x409
echo "Config 1: ECM network  > configs/c.1/strings/0x409/configuration
echo 250 > configs/c.1/MaxPower

mkdir -p functions/acm.usb0
ln -s functions/acm.usb0 configs/c.1/

ls /sys/class/udc > UDC

 

I used this guide to for the libcomposite setup (http://isticktoit.net/?p=1383). the mik3y usb serial drivers natively support FT232R, CDC/ACM serial services, and CP2102. I can't find any documentation detailing the H5 usb controller or drivers. is this even possible or would it be better to go with a external controller and run SPI communication over the GPIO pins. The only reason I'm not already doing that is I'm already using the SPI controller to control a custom made device. Thanks for any help!
 

 

Edited by anthony4tner

Guest
This topic is now closed to further replies.

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.