Bluetooth Low-Power BLE: Controls GPIO to light LEDs and blegpio
This section describes the simplest and most basic things. The ios operation of the CC2540 uses the PORT as the GPIO. If you don't talk much about it, let's look at it.
1. Hardware Circuit
The most simple hardware circuit is to use a GPIO to control the L
Transferred from: http://blog.csdn.net/mirkerson/article/details/8464290An overviewThe Gpio in the Linux kernel is the simplest, most common resource (and interrupt, Dma,timer) driver, the application is able to use the corresponding interface using Gpio,gpio to use the integer ID between 0~max_int, can not use negative numbers,
Through the Sysfs control Gpio, first access to the/sys/class/gpio directory, the export file to write the Gpio number, so that the Gpio operation interface from the kernel space exposed to the user space, Gpio operating interface including direction and value, etc. The dire
by Sysfs control Gpio, first access the/sys/class/gpio directory, write the GPIO number to the export file, so that the Gpio operation interface from the kernel space exposed to the user space, The GPIO's operating interface includes direction and value, and direction controls the
I. Overview
Through the SYSFS mode control GPIO, first access to the/sys/class/gpio directory, write GPIO number to the export file, so that the GPIO operating interface from the kernel space exposure to user space, GPIO operating interface, including direction and value And
Raspberry Pi advanced GPIO library, wiringpi2 for python Use note (3) GPIO operations, gpiowiringpi2
The core function of the GPIO library is to operate GPIO. GPIO is the "general input/output" interface, such as lighting up an LED or relay, or using iic spi 1-wire and other
Gpio Library core function, of course, is the operation of Gpio, Gpio is the "general input/Output" interface, such as lighting a LED, relays, or through the IIC SPI 1-wire and other protocols, read, write data, this is the use of Gpio, can say no gpio, Raspberry Pi can only
Bluetooth 1.2 vs 1.1:
1. Adaptive Frequency Hopping (AFH ):Adaptive Frequency Hopping TechnologyThe main function is to reduce interference problems between Bluetooth products and other wireless communication devices.
2. Extended synchronous connection-oriented links (ESCO ):Extended synchronous link-oriented channel technologyIt is used to provide audio transmission with high QoS, and can further meet the
Implement your own RPi. GPIO (1)-Python C Extension, rpi. gpio-python
Raspberry Pi has a Python module of RPi. GPIO. After import, you can directly use Python to operate the GPIO hardware module of the ARM chip. I think this is very interesting, so I want to implement this module on my own DM8148 platform.
DM8148 is a
sleep, or to WAKE upPulled low bt_wake:bt can sleep, sleep isn't sleep to BTHOST each time before going to send data pulled Bt_wakeBT sleep'll is pulled Bt_rts to prevent HOST data.III) BLUESLEEP.C OverviewBluesleep_init:create a node, bluesleep_probe:application gpio/int/wake_lock, resources, start the timer monitoring Host to send data (time-out can is pulled low bt_wake), open the interruption to monitor the state of the Host_wake Bluesl eep_outgo
Document directory
References
The previous two Articles respectively described how to use Windows Embedded Source Tools for Bluetooth and 32feet. NET for Bluetooth development under. NET Compact Framework. The links are as follows:Windows Embedded Source Tools for Bluetooth development under. NET Compact Framework32feet. NET for
external electromagnetic interference, a resistor is used to connect the pin to a high level so that it is fixed to a high level, such resistance is called a pull-up resistance .)
Additional reading:
1The gpio is initialized in the file gpio_drv.c. You can use the tool provided by MTK to configure it or use code to directly operate in the program. The two options should be determined by whether the macro _ cust_new __
2Pay attenti
From http://www.cnblogs.com/xiaobo-Linux/p/8969324.html command line control LED lightecho >/sys/class/gpio/export Write outputcd/sys/class/gpio/gpio12/Enter this portThe main 2 files Direction/valueDirection control output echo out > Direction/control input echo in > directionValue control high and low level 1, 0 low echo 1 > Value lit/echo 0 > value offRead high and low level cat valueUse Python to light
How to Use Android Bluetooth (Bluetooth details) and Android bluetoothI. Communication between bluetooth devices consists of four processes.
Configure a bluetooth device to search for devices that may match in the LAN to connect to data transmission between devices.
Ii. completion of detailed programming
1. Activate
If the local Bluetooth device can be found by other nearby bluetooth devices, you can use the following method with comments in the code.
Of course, you need to set up your Bluetooth device to be detected by nearby bluetooth devices (usually 2 minutes)
In settings-Bluetooth-
an overview
Linux kernel Gpio is the simplest, most commonly used resource (and interrupt, Dma,timer) driver, applications can use the corresponding interface Gpio,gpio use the integer ID between 0~max_int, can not use negative numbers, Gpio is closely related to the hardware system, but Linux has a framework for
1. Modify the visibility of the local Bluetooth device
2. Scan the available Bluetooth devices around
Eg:
I. configuration file adroidmanifest. xml:
Ii. layout file: Main. xml:
3. mainactivity:
Import android. app. activity; import android. bluetooth. export thadapter; import android. bluetooth. export thdevice;
(1) If you want to use the Bluetooth Android phone, you need to add Bluetooth access to the Androidmanifest file.Note: Permissions should be added to the Androidmanifest file (2) to determine if there is a Bluetooth device that can be used, if there is to determine whether the Bluetooth device is turned on, if not open
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.