Add experimental localized content structure
This commit is contained in:
parent
c44b95a693
commit
7eac090aa3
|
@ -0,0 +1,6 @@
|
|||
# NodeMCU Dokumentation
|
||||
|
||||
NodeMCU ist eine [eLua](http://www.eluaproject.net/)-basierende firmware für den [ESP8266 WiFi SOC von Espressif](http://espressif.com/en/products/esp8266/). Dies ist ein Partnerprojekt für die beliebten [NodeMCU dev kits](https://github.com/nodemcu/nodemcu-devkit-v1.0) - open source NodeMCU boards mit ESP8266-12E chips.
|
||||
|
||||
Diese firmware nutzt das Espressif SDK v1.4, das Dateisystem basiert auf [spiffs](https://github.com/pellepl/spiffs).
|
||||
|
|
@ -1,6 +1,6 @@
|
|||
There are essentially three ways to build your NodeMCU firmware: cloud build service, Docker image, dedicated Linux environment (possibly VM).
|
||||
|
||||
## Cloud build serivce
|
||||
## Cloud build service
|
||||
NodeMCU "application developers" just need a ready-made firmware. There's a [cloud build service](http://nodemcu-build.com/) with a nice UI and configuration options for them.
|
||||
|
||||
## Docker image
|
|
@ -24,6 +24,3 @@ Run the following command to flash an *aggregated* binary as is produced for exa
|
|||
Source: [https://github.com/nodemcu/nodemcu-flasher](https://github.com/nodemcu/nodemcu-flasher)
|
||||
|
||||
Supported platforms: Windows
|
||||
|
||||
## ...
|
||||
more
|
|
@ -0,0 +1,12 @@
|
|||
# NodeMCU Documentation
|
||||
|
||||
NodeMCU is an [eLua](http://www.eluaproject.net/) based firmware for the [ESP8266 WiFi SOC from Espressif](http://espressif.com/en/products/esp8266/). This is a companion project to the popular [NodeMCU dev kits](https://github.com/nodemcu/nodemcu-devkit-v1.0), ready-made open source development boards with ESP8266-12E chips.
|
||||
|
||||
The firmware is based on the Espressif SDK v1.4 and uses a file system based on [spiffs](https://github.com/pellepl/spiffs).
|
||||
|
||||
## Getting started
|
||||
- [Build the firmeware](build.md) with the modules you need.
|
||||
- [Flash the firmware](flash.md) to the chip.
|
||||
- Load your code into the firmware.
|
||||
|
||||
|
|
@ -0,0 +1,57 @@
|
|||
# node Module
|
||||
## node.restart()
|
||||
|
||||
Restarts the chip.
|
||||
|
||||
####Syntax
|
||||
`node.restart()`
|
||||
|
||||
####Parameters
|
||||
`nil`
|
||||
|
||||
####Returns
|
||||
`nil`
|
||||
|
||||
####Example
|
||||
|
||||
```lua
|
||||
node.restart();
|
||||
```
|
||||
___
|
||||
## node.dsleep()
|
||||
|
||||
Enter deep sleep mode, wake up when timed out.
|
||||
|
||||
####Syntax
|
||||
`node.dsleep(us, option)`
|
||||
|
||||
**Note:** This function can only be used in the condition that esp8266 PIN32(RST) and PIN8(XPD_DCDC aka GPIO16) are connected together. Using sleep(0) will set no wake up timer, connect a GPIO to pin RST, the chip will wake up by a falling-edge on pin RST.<br />
|
||||
option=0, init data byte 108 is valuable;<br />
|
||||
option>0, init data byte 108 is valueless.<br />
|
||||
More details as follows:<br />
|
||||
0, RF_CAL or not after deep-sleep wake up, depends on init data byte 108.<br />
|
||||
1, RF_CAL after deep-sleep wake up, there will belarge current.<br />
|
||||
2, no RF_CAL after deep-sleep wake up, there will only be small current.<br />
|
||||
4, disable RF after deep-sleep wake up, just like modem sleep, there will be the smallest current.
|
||||
|
||||
####Parameters
|
||||
- `us`: number(Integer) or nil, sleep time in micro second. If us = 0, it will sleep forever. If us = nil, will not set sleep time.
|
||||
|
||||
- `option`: number(Integer) or nil. If option = nil, it will use last alive setting as default option.
|
||||
|
||||
####Returns
|
||||
`nil`
|
||||
|
||||
####Example
|
||||
|
||||
```lua
|
||||
--do nothing
|
||||
node.dsleep()
|
||||
--sleep μs
|
||||
node.dsleep(1000000)
|
||||
--set sleep option, then sleep μs
|
||||
node.dsleep(1000000, 4)
|
||||
--set sleep option only
|
||||
node.dsleep(nil,4)
|
||||
```
|
||||
___
|
|
@ -7,3 +7,8 @@ blockquote {
|
|||
.rst-content blockquote {
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
/*shifts the nested subnav label to the left to align it with the regular nav item labels*/
|
||||
ul.subnav ul.subnav span {
|
||||
padding-left: 1.3em;
|
||||
}
|
|
@ -4,9 +4,7 @@ NodeMCU is an [eLua](http://www.eluaproject.net/) based firmware for the [ESP826
|
|||
|
||||
The firmware is based on the Espressif SDK v1.4 and uses a file system based on [spiffs](https://github.com/pellepl/spiffs).
|
||||
|
||||
## Getting started
|
||||
- [Build the firmeware](build.md) with the modules you need.
|
||||
- [Flash the firmware](flash.md) to the chip.
|
||||
- Load your code into the firmware.
|
||||
[English](EN/index.md)
|
||||
|
||||
[Deutsch](DE/index.md)
|
||||
|
||||
|
|
|
@ -0,0 +1,43 @@
|
|||
var nodemcu = nodemcu || {};
|
||||
(function () {
|
||||
'use strict';
|
||||
var languageCodeToNameMap = {EN: 'English', DE: 'Deutsch'};
|
||||
var languageNames = values(languageCodeToNameMap);
|
||||
var defaultLanguageCode = 'EN';
|
||||
|
||||
$(document).ready(function () {
|
||||
hideNavigationForAllButSelectedLanguage();
|
||||
});
|
||||
|
||||
function hideNavigationForAllButSelectedLanguage() {
|
||||
// URL is like http://host/EN/build/ -> extract 'EN'
|
||||
var selectedLanguageCode = window.location.pathname.substr(1, 2);
|
||||
if (!selectedLanguageCode) {
|
||||
selectedLanguageCode = defaultLanguageCode;
|
||||
}
|
||||
var selectedLanguageName = languageCodeToNameMap[selectedLanguageCode];
|
||||
// Finds all subnav elements and hides them if they're /language/ subnavs. Hence, all 'Modules' subnav elements
|
||||
// won't be hidden.
|
||||
// <ul class="subnav">
|
||||
// <li><span>Modules</span></li>
|
||||
// <li class="toctree-l1 ">
|
||||
// <a class="" href="EN/modules/node/">node</a>
|
||||
// </li>
|
||||
$('.subnav li span').not(':contains(' + selectedLanguageName + ')').each(function (index) {
|
||||
var spanElement = $(this);
|
||||
if ($.inArray(spanElement.text(), languageNames) > -1) {
|
||||
spanElement.parent().parent().hide();
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
function values(associativeArray) {
|
||||
var values = [];
|
||||
for (var key in associativeArray) {
|
||||
if (associativeArray.hasOwnProperty(key)) {
|
||||
values.push(associativeArray[key]);
|
||||
}
|
||||
}
|
||||
return values;
|
||||
}
|
||||
}());
|
18
mkdocs.yml
18
mkdocs.yml
|
@ -12,10 +12,14 @@ markdown_extensions:
|
|||
permalink: True
|
||||
|
||||
pages:
|
||||
- Home: 'index.md'
|
||||
- Building the firmware: 'build.md'
|
||||
- Flashing the firmware: 'flash.md'
|
||||
- FAQ: 'faq.md'
|
||||
- Support: 'support.md'
|
||||
- Modules:
|
||||
- 'node': 'modules/node.md'
|
||||
- Overview: 'index.md'
|
||||
- English:
|
||||
- Home: 'EN/index.md'
|
||||
- Building the firmware: 'EN/build.md'
|
||||
- Flashing the firmware: 'EN/flash.md'
|
||||
- FAQ: 'EN/faq.md'
|
||||
- Support: 'EN/support.md'
|
||||
- Modules:
|
||||
- 'node': 'EN/modules/node.md'
|
||||
- Deutsch:
|
||||
- Home: 'DE/index.md'
|
Loading…
Reference in New Issue