tuanpmt / React Native Smartconfig
A React Native module for ESP8266 Smartconfig
Stars: ✭ 109
Labels
Projects that are alternatives of or similar to React Native Smartconfig
Esp8266 Oled Ssd1306
Driver for the SSD1306 and SH1106 based 128x64, 128x32, 64x48 pixel OLED display running on ESP8266/ESP32
Stars: ✭ 1,590 (+1358.72%)
Mutual labels: esp32, esp8266
Pagebuilder
An arduino library to create html string in the sketch for ESP8266/ESP32 WebServer.
Stars: ✭ 104 (-4.59%)
Mutual labels: esp32, esp8266
Blinker Library
An IoT Solution,Blinker library for embedded hardware. Works with Arduino, ESP8266, ESP32.
Stars: ✭ 1,095 (+904.59%)
Mutual labels: esp32, esp8266
Perswifimanager
Persistent WiFiManager Arduino library for ESP8266
Stars: ✭ 106 (-2.75%)
Mutual labels: esp32, esp8266
App Release
An IoT Solution,this is the android release app | download ios app in app store
Stars: ✭ 104 (-4.59%)
Mutual labels: esp32, esp8266
Aunit
Unit testing framework for Arduino platforms inspired by ArduinoUnit and Google Test. Used with AUniter or EpoxyDuino for continuous builds.
Stars: ✭ 73 (-33.03%)
Mutual labels: esp32, esp8266
Sx126x Arduino
Arduino library to use Semtech SX126x LoRa chips and modules to communicate
Stars: ✭ 55 (-49.54%)
Mutual labels: esp32, esp8266
Wled Wemos Shield
Wemos D1 Mini (ESP8266) or Wemos ESP32 D1 Mini (ESP32) based shield for WLED firmware
Stars: ✭ 105 (-3.67%)
Mutual labels: esp32, esp8266
Tft espi
Arduino and PlatformIO IDE compatible TFT library optimised for the STM32, ESP8266 and ESP32 that supports different driver chips
Stars: ✭ 1,215 (+1014.68%)
Mutual labels: esp32, esp8266
Micropython Rotary
MicroPython module to read a rotary encoder.
Stars: ✭ 62 (-43.12%)
Mutual labels: esp32, esp8266
Deepsleepscheduler
DeepSleepScheduler is a lightweight, cooperative task scheduler library with configurable sleep and task supervision.
Stars: ✭ 59 (-45.87%)
Mutual labels: esp32, esp8266
Stickwatch
A DIY smart watch based on M5Stick of ESP32
Stars: ✭ 68 (-37.61%)
Mutual labels: esp32, esp8266
Bleeper
Library to manage your firmware configurations written in C++
Stars: ✭ 54 (-50.46%)
Mutual labels: esp32, esp8266
Tinygsm
A small Arduino library for GSM modules, that just works
Stars: ✭ 1,186 (+988.07%)
Mutual labels: esp32, esp8266
Wifiespnow
ESP-NOW Arduino library for ESP8266 and ESP32
Stars: ✭ 90 (-17.43%)
Mutual labels: esp32, esp8266
Description
react-native module for ESP8266 ESPTOUCH Smart config
Featues
- Support both IOS and Android
- React Native Promise support
- Fast way to do configure wifi network for IOT device
Getting started
Mostly automatic install
npm install rnpm --global
npm install [email protected] --save
rnpm link react-native-smartconfig
Manual install
iOS
npm install [email protected] --save
- In XCode, in the project navigator, right click
Libraries
➜Add Files to [your project's name]
- Go to
node_modules
➜react-native-smartconfig
and addRCTSmartconfig.xcodeproj
- In XCode, in the project navigator, select your project. Add
libRCTSmartconfig.a
to your project'sBuild Phases
➜Link Binary With Libraries
- Click
RCTSmartconfig.xcodeproj
in the project navigator and go theBuild Settings
tab. Make sure 'All' is toggled on (instead of 'Basic'). In theSearch Paths
section, look forHeader Search Paths
and make sure it contains both$(SRCROOT)/../../react-native/React
- mark asrecursive
. - Run your project (
Cmd+R
)
Android
npm install [email protected] --save
- For older version. Modify the ReactInstanceManager.builder() calls chain in
android/app/main/java/.../MainActivity.java
to include:
import com.tuanpm.RCTSmartconfig; // import for older version
.addPackage(new RCTSmartconfigPackage()) //for older version
- For newest version. Modify the ReactInstanceManager.builder() calls chain in
android/app/main/java/.../MainApplication.java
to include:
import com.tuanpm.RCTSmartconfig.RCTSmartconfigPackage; // import for newest version of react-native
new RCTSmartconfigPackage() // for newest version of react-native
- Append the following lines to
android/settings.gradle
beforeinclude ':app'
:
include ':react-native-smartconfig'
project(':react-native-smartconfig').projectDir = new File(rootProject.projectDir, '../node_modules/react-native-smartconfig/android')
- Insert the following lines inside the dependencies block in
android/app/build.gradle
, dont missingapply plugin:'java'
on top:
compile project(':react-native-smartconfig')
Notes:
dependencies {
compile project(':react-native-smartconfig')
}
Usage
import Smartconfig from 'react-native-smartconfig';
Smartconfig.start({
type: 'esptouch', //or airkiss, now doesn't not effect
ssid: 'wifi-network-ssid',
bssid: 'filter-device', //"" if not need to filter (don't use null)
password: 'wifi-password',
timeout: 50000 //now doesn't not effect
}).then(function(results){
//Array of device success do smartconfig
console.log(results);
/*[
{
'bssid': 'device-bssi1', //device bssid
'ipv4': '192.168.1.11' //local ip address
},
{
'bssid': 'device-bssi2', //device bssid
'ipv4': '192.168.1.12' //local ip address
},
...
]*/
}).catch(function(error) {
});
Smartconfig.stop(); //interrupt task
Todo
- [ ] Support automatic get current wifi network ssid
- [ ] Set timeout effect
- [ ] Support airkiss
LICENSE
The MIT License (MIT)
Copyright (c) 2015 <TuanPM> https://twitter.com/tuanpmt
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
Note that the project description data, including the texts, logos, images, and/or trademarks,
for each open source project belongs to its rightful owner.
If you wish to add or remove any projects, please contact us at [email protected].