没有合适的资源?快使用搜索试试~ 我知道了~
TI-Android-guide
需积分: 1 0 下载量 138 浏览量
2013-01-21
14:30:38
上传
评论
收藏 378KB PDF 举报
温馨提示
针对于TI开发板DM37X系列模块移植的操作手册。
资源推荐
资源详情
资源评论
TI-Android-ICS-PortingGuide
1
TI-Android-ICS-PortingGuide
This page is currently under construction. The content of this page is due to change quite frequently and thus the quality and accuracy are
not guaranteed until this message has been removed. Please feel free to contribute to this page while construction is in progress.
About this manual
The goal of Porting Guide is to provide valuable information and instructions to people who want to run Android OS
on their (new) HW. Information covered here will mainly be useful to port Android ICS DevKit Sitara-based
devices.
The information here is currently relevant to TI Android ICS 4.0.3 DevKit 3.0.0 for AM37x and TI Android ICS
4.0.3 DevKit 3.0.1 for AM335x.
Note: Detailed porting information in the different technical areas is dependent on the respective h/w architecture.
WLAN
Introduction
This section of guide provides a step by step explanation of what's involved in adding a new WiFi driver and making
WiFi work in a custom Android build like Rowboat.
Features Overview
• WLAN (802.11 b/g/n)
• Core IP pre-tested against WiFi specifications.
• Station mode is fully supported.
• Initial support for SoftAP/WiFi hotspot and WiFi Direct is available
TI-Android-ICS-PortingGuide
2
Android WLAN Sub-System Overview
Diagram explains WLAN event flow from application to h/w with respect to rowboat android source tree.
Application
• Settings/Connection
Manager:<android-src>/packages/apps/Settings/src/com/android/settings/WirelessSettings.java
Application Framework
• WiFi manager:<android-src>/frameworks/base/wifi/java/android/net/wifi
• JNI Implementation:<android-src>/frameworks/base/core/jni/android_net_wifi_Wifi.cpp
Libraries
• libhardware_legacy:<android-src>/hardware/libhardware_legacy/wifi/wifi.c
• wpa_supplicant (Daemon):<android-src>/external/hostap/wpa_supplicant
• Higher level network management is done in <android-src>/frameworks/base/core/java/android/net.
TI-Android-ICS-PortingGuide
3
Driver Configuration
In this Devkit release we are using WL12XX Compat wireless SDK. The drivers and firmwares of WL12XX
Compat release are at hardware/ti/wlan
To enable WLAN support in kernel the following settings need to be enabled:
• First enable Wireless LAN device driver as shown below:
Device Drivers --->
[*] Network device support --->
[*] Wireless LAN --->
• Enable WLAN Networking support as shown below:
[*] Networking support --->
-*- Wireless --->
[*] Wireless extensions sysfs files
This enables the following CONFIG options in kernel and allows WL12xx compat wlan drivers to be built:
CONFIG_WLAN=y
CONFIG_WIRELESS_EXT=y
CONFIG_WEXT_CORE=y
CONFIG_WEXT_PROC=y
CONFIG_WEXT_PRIV=y
• The following additional options need to be enabled in kernel for WLAN to operate
CONFIG_KEYS=y
CONFIG_SECURITY=y
CONFIG_CRYPTO=y
CONFIG_CRYPTO_ARC4=y
CONFIG_CRYPTO_ECB=y
CONFIG_CRYPTO_AES=y
CONFIG_CRYPTO_MICHAEL_MIC=y
CONFIG_CRC7=y
• The relevant initialization and pin-muxing for MMC bus is done in the relevant board file e.g for AM335xevm
arch/arm/mach-omap2/board-am335xevm.c. Do take care of this initialization and pin-muxing if using any
other MMC bus e.g. MMC3.
See also: ARM Processor Open Source Wireless Connectivity
Android WiFi HAL Configuration
• Enable building of wpa_supplicant 0.8.x in your BoardConfig.mk (e.g. device/ti/am335xevm/BoardConfig.mk
for AM335xevm and device/ti/omap3evm/BoardConfig.mk for AM37xevm)
This is by simply adding following options in BoardConfig.mk:
BOARD_WPA_SUPPLICANT_DRIVER := NL80211
WPA_SUPPLICANT_VERSION := VER_0_8_X
BOARD_WLAN_DEVICE := wl12xx_mac80211
BOARD_SOFTAP_DEVICE := wl12xx_mac80211
BOARD_WPA_SUPPLICANT_PRIVATE_LIB := lib_driver_cmd_wl12xx
TI-Android-ICS-PortingGuide
4
WIFI_DRIVER_MODULE_PATH := "/system/lib/modules/wl12xx_sdio.ko"
WIFI_DRIVER_MODULE_NAME := "wl12xx_sdio"
This will set WPA_BUILD_SUPPLICANT to true in external/wpa_supplicant_8/Android.mk enabling building
of wpa_supplicant 0.8.x with NL80211. At run time wl12xx_sdio will get loaded from
WIFI_DRIVER_MODULE_PATH.
BOARD_SOFTAP_DEVICE := wl12xx_mac80211 needs to be set only if SoftAP/hotspot feature is required.
• Next we need to provide a proper wpa_supplicant.conf for our device. That we will keep in /data/misc/wifi.
• Set the correct permissions and paths created from init.rc
# give system access to wpa_supplicant.conf for backup and restore
mkdir /system/etc/wifi 0770 system wifi
chmod 0770 /system/etc/wifi
chmod 0660 /system/etc/wifi/wpa_supplicant.conf
chown system wifi /system/etc/wifi/wpa_supplicant.conf
mkdir /data/misc/wifi 0770 system wifi
mkdir /data/misc/wifi/sockets 0770 system wifi
chmod 0770 /data/misc/wifi
chmod 0660 /data/misc/wifi/wpa_supplicant.conf
chown wifi wifi /data/misc/wifi
chown wifi wifi /data/misc/wifi/wpa_supplicant.conf
Important We use System user(uid: 1000) to initiate wpa_supplicant service that way are able to enable WiFi over
Android NFS rootfs. Here is the detailed discussion on that WiFi does not work when booting from an NFS file
system
[1]
• Set the wifi interface name in device.mk
PRODUCT_PROPERTY_OVERRIDES := \
wifi.interface=wlan0
• Start wpa_supplicant and dhcpcd from init.rc.
# wpa_supplicant and dhcp daemon
service wpa_supplicant /system/bin/wpa_supplicant -Dnl80211 -iwlan0
class main
socket wpa_wlan0 dgram 660 wifi wifi
disabled
oneshot
service dhcpcd_wlan0 /system/bin/dhcpcd -ABKL
class main
disabled
oneshot
service iprenew_wlan0 /system/bin/dhcpcd -n
class main
disabled
oneshot
The following entries are required to configure SoftAP/hotspot and WiFi Direct functions:
TI-Android-ICS-PortingGuide
5
• Register hostap service for SoftAP/hotspot:
service hostapd_bin /system/bin/hostapd -d /data/misc/wifi/hostapd.conf
socket wpa_wlan1 dgram 660 wifi wifi
disabled
oneshot
• Register dhcp hooks for WiFi Direct:
service dhcpcd_p2p /system/bin/dhcpcd -aABKL
disabled
oneshot
service iprenew_p2p /system/bin/dhcpcd -n
disabled
oneshot
The following commits in device/ti/omap3evm enable WiFi, SoftAP and WiFi Direct support on AM37xevm.
Ensure that similar additions are done to support WiFi on your platform.
• Enable WiFi commit
[2]
• Enable SoftAP commit
[3]
• Enable WiFi Direct commit
[4]
剩余29页未读,继续阅读
资源评论
LOVE___________YOU
- 粉丝: 0
- 资源: 1
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
最新资源
- 计算机毕业设计:python+爬虫+cnki网站爬
- nyakumi-lewd-snack-3-4k_720p.7z.002
- 现在微信小程序能用的mqtt.min.js
- 基于MPC的非线性摆锤系统轨迹跟踪控制matlab仿真,包括程序中文注释,仿真操作步骤
- shell脚本入门-变量、字符串, Shell脚本中变量与字符串的基础操作教程
- 基于MATLAB的ITS信道模型数值模拟仿真,包括程序中文注释,仿真操作步骤
- 基于Java、JavaScript、CSS的电子产品商城设计与实现源码
- 基于Vue 2的zjc项目设计源码,适用于赶项目需求
- 基于跨语言统一的C++头文件设计源码开发方案
- 基于MindSpore 1.3的T-GCNTemporal Graph Convolutional Network设计源码
资源上传下载、课程学习等过程中有任何疑问或建议,欢迎提出宝贵意见哦~我们会及时处理!
点击此处反馈
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功