Commit Graph

66 Commits

Author SHA1 Message Date
me-no-dev
e81d4d3f72 Fix SD Card not mounting on boot
The card seems to need a bit of a nudge at boot to properly mount
sometimes.
Fixes: https://github.com/espressif/arduino-esp32/issues/272
2017-03-20 00:50:27 +02:00
me-no-dev
a70954111b Fix compilation issues is certain situations. 2017-03-19 11:27:58 +02:00
me-no-dev
01b2ef780a Set proper default pins for SPI
Some boards have different default pins for SPI

Thanks @ladyada
2017-03-19 11:14:38 +02:00
copercini
2b24603aab SD library explanation (#262)
It's look more a practical guide "how to use SD lib"
2017-03-14 14:53:59 +01:00
me-no-dev
64ccef75fb Do not use inline functions for mkdir and rename 2017-03-11 09:16:34 +02:00
Me No Dev
fa1716e73e Add Ota and mdns (#257)
* Add Sketch Update Library

* Add MDNS Library

* Add Arduino OTA Library

* add missing library file

* Add library files for Update

* Add missing headers

* fix ota command

* Add espota binary

* remove bad example

* PlatformIO does not auto forward declare methods like Arduino Builder
2017-03-11 07:15:44 +01:00
me-no-dev
2f5efed220 Add pin mapping for SD and SD_MMC examples 2017-03-10 17:35:42 +02:00
copercini
e30447449f WiFiSecureClient fixes and improvements (#255)
* Add CA certificate in example

SHA1 fingerprint is broken now: more info: https://shattered.io

* Best error handling

When occur an error in WiFiClientSecure library just return the error message
and clean the context avoiding crash - fix for https://github.com/espressif/arduino-esp32/issues/211

Translate MbedTLS error codes in messages for best understanding

* Declarate certificates as const

mbedtls_pk_parse_key needs a const unsigned char * certificate. In old implementation the certificate was declarated as char * so first it converts to unsigned and after to const.

When we convert signed to unsigned it may result in a +1 larger output.

Fix issue https://github.com/espressif/arduino-esp32/issues/223
2017-03-10 15:52:50 +01:00
Me No Dev
e625b3b08e Add FS, SD and SD_MMC (#256) 2017-03-10 15:25:38 +01:00
me-no-dev
8fb8478431 Flush client with single call to available 2017-03-03 14:56:18 +02:00
me-no-dev
946e52da98 Break on any error when flushing a client 2017-03-02 12:32:32 +02:00
me-no-dev
6fc96b977f Add WiFiClient flush to clear all non-read data in RX
fixes: https://github.com/espressif/arduino-esp32/issues/119
2017-03-02 02:49:53 +02:00
David Schroeder
f0fc28f0e3 Rework WiFiClient (#238)
* Rework WiFiClient

Rework WiFiClient to correct error where making a copy of a WiFiClient object resulted in the socket being closed prematurely.

Added loop and select to write to handle/prevent EAGAIN errors.

* Rework WiFiClient to use shared_ptr

Rework changes to utilize shared_ptr rather than manually maintaining reference count. 

Revert changes to write

* Incorporate comments from review

Move WiFiClientSocketHandle and fd() into WiFiClient.cpp
2017-03-02 00:47:16 +02:00
David Schroeder
770830aa01 Revise WiFiClient::Write to handle EAGAIN (#240)
The send call may return EAGAIN. This indicates a recoverable error and a retry should be attempted. The current implementation treats this as a fatal error. Further, the current implementation strips the error code, setting it to 0, which prevents the caller from handling it directly. 
This change utilizes select to verify the socket is available prior to calling send and will retry on an EAGAIN condition.
2017-03-01 00:37:00 +02:00
me-no-dev
bcd6dcf5f6 Fix compile error with IDF and mbedtls debug off 2017-02-28 23:18:06 +02:00
me-no-dev
1d759380a6 Major IDF and Arduino Update
WiFi and BlueTooth can now be started and stopped at will.
basic functions added to esp32-hal to start and stop the BT radio
SimpleBLE class added to show the most basic functionality
Example to show how to switch between BT, WiFi or Both
2017-02-23 01:11:57 +02:00
me-no-dev
b5ac95b274 Update RepeatTimer example
Implement semaphore and mutex to safeguard the ISR.
This is the proper way to handle hardware Interrupts with FreeRTOS. The
more regular approach may/will lead to exceptions
2017-02-20 15:08:11 +02:00
Martin Sloup
a83dd5f2b5 Add RepeatTimer example (#216) 2017-02-17 15:55:07 +02:00
wami
95cb54cede [fix] return add --- error: no return statement in function returning non-void (#205) 2017-02-17 00:43:59 +02:00
me-no-dev
3cbc405edf Add helper for sending 16bit color buffers 2017-02-14 11:58:04 +02:00
me-no-dev
d0232d126a SPI implement transaction locking
Use transactions to skip mutex locks for reads and writes
2017-02-14 04:15:38 +02:00
Martin Sloup
a36ef2aea8 Added LEDC Software Fade example (#202)
* Added LEDC Fade exmaple

* Renamed LEDCFade example to LEDCSoftwareFade

Added valueMax parameter for ledcAnalogWrite

* Remove usage of LED_BUILTIN constant to solve CI errors
2017-02-12 17:30:12 +02:00
Martin Sloup
f9ba8e9ccf Refactoring EPS32NVS library to Preferences library (#199)
* Refactoring EPS32NVS library to Preferences library

* Renaming all set* functions to put
* Added functions for float, double and bool

* Small redesign of Preferences API

* added type to put* function names
* for (u)int64_t used functions name with *(U)Long64
* added functions for long and unsigned long (same like int a unsigned int)
2017-02-12 00:08:22 +02:00
copercini
8ab3231e31 Add WiFiClient secure lib (#184)
* Provide SSL/TLS functions to ESP32 with Arduino IDE

* Generate a new random number in case of reconnection
2017-02-11 00:20:24 +02:00
Martin Sloup
0fb5e5ca11 Improves in ESP32NVS library (#196)
* Improved ESP32NVS default value support for read* functions

Fixed uninitialized NVS flash storage. Added example code.

* Add methods for String and remove unnecessary nvs_flash_init() in ESP32NVS class

+ other minor declaration fixes

* ESP32NVS function name renaming

* read* -> get*
* write* -> set*
* erase -> clear / remove
2017-02-11 00:18:57 +02:00
Me No Dev
fb8fe671d6 New partitions (#192)
* Add new partition scheme

* Init NVS early, so it can be used without BT or WiFi
2017-02-10 14:11:24 +02:00
me-no-dev
1f0df1ef97 Fix wrong return values for WiFi::softAPConfig
fixes: https://github.com/espressif/arduino-esp32/issues/191
2017-02-10 13:49:43 +02:00
me-no-dev
0101564219 fix compilation error if debug level is above debug and less or equal to warn 2017-02-10 04:27:48 +02:00
me-no-dev
8df22cac80 Store WiFi settings in flash
Fixes: https://github.com/espressif/arduino-esp32/issues/173
2017-02-10 02:01:16 +02:00
me-no-dev
6a058275e7 Remove unimplemented methods from SPI 2017-02-09 20:40:56 +02:00
Martin Sloup
3e87dcf748 beginPacket can be used without listening on socket (#185)
Currently there is bug in WiFiUDP library when you want to use beginPacket(...) without listening on socket (without calling begin(...) first). You can't send any data because socket is not open and also tx_buffer is not allocated which cause crash while writing data to tx_buffer.
2017-02-08 23:10:16 +02:00
me-no-dev
bfa979a900 Add initial NVS Arduino implementation 2017-02-08 23:09:42 +02:00
me-no-dev
fdc4f53eb6 fix WiFi disconnect reason index 2017-02-08 20:20:00 +02:00
Ion
cea41d965a Add Touchread example (#175)
* Add Touchread example

* Rename libraries/ESP32/examples/Touch/TouchRead.ino to libraries/ESP32/examples/Touch/TouchRead/TouchRead.ino

* Update TouchRead.ino
2017-02-07 03:42:43 +02:00
Me No Dev
d02c1c786e Update IDF, fix SS definition, add custom partitions and debug level selection (#174)
* Add build time partitions compilation

* Fix wrong definition of SS pin

* Add support for core debug level selection

* update idf libs
2017-02-06 15:17:11 +02:00
me-no-dev
ee8149e207 add better debug messages for WiFi status 2017-02-05 23:59:44 +02:00
Ion
c66b54a9eb Add touch example 2017-02-05 18:03:04 +02:00
Jan Hendrik Berlin
bbf48a5d54 Add (ported) SimpleWiFiServer (#158) 2017-02-05 17:21:51 +02:00
me-no-dev
a80b2b24a4 Add ESP32 examples folder and sigma-delta example 2017-02-05 16:14:43 +02:00
Joren Six
97e9a120bd Added a basic WiFi UDP client example (#114)
* Added a basic WiFi UDP client example: a sketch that sends random bytes over udp.

* Updated udp example and included Python and Ruby UDP servers.
2017-02-03 16:31:41 +02:00
me-no-dev
de017a8a1b Optimize SPI transfers to take one lock and do not return until completed 2017-02-01 02:14:36 +02:00
me-no-dev
6dfbdbca29 fix WiFi.config not being applied
fixes: https://github.com/espressif/arduino-esp32/issues/143
2017-01-24 01:08:48 +02:00
me-no-dev
3c7d0e9905 add RSSI return and fix SSID and BSSID methods
fixes: https://github.com/espressif/arduino-esp32/issues/144
2017-01-24 00:56:12 +02:00
Seop Yoon
57dbc9ab77 Add smartConfig support (#136)
* smartConfig support

* fixed bug, added example

* added _smartConfigDone = ture

* changed example name, added explanation
2017-01-20 12:39:51 +02:00
me-no-dev
9e6e3249b6 update windows toolchain and platform.txt 2017-01-19 03:24:21 +02:00
Me No Dev
be7871677f Update WiFiUdp.cpp
Change return value of UDP::endPacket() to match specifications

Ref: https://github.com/espressif/arduino-esp32/issues/138
2017-01-19 02:03:37 +02:00
me-no-dev
7cef2e2954 Add initial IPv6 Support 2017-01-06 00:54:50 +02:00
me-no-dev
f49ac391b2 replace wrong calls to cbuf->size in UDP 2017-01-02 09:46:13 +02:00
me-no-dev
e383a11291 Add Server and UDP and fix WiFi.hostByName 2016-12-30 02:44:45 +02:00
me-no-dev
c19fc061b0 Hopefully fix I2C/Wire
Tested with (all at the same time):
- MPU9250
- HTU21
- TMP102
- BMP180
- AM2320
- SSD1306
2016-12-14 02:41:22 +02:00