Commit Graph

5437 Commits

Author SHA1 Message Date
Xiang Xiao
1140bebfc0 Fix nxstyle warning
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-06-03 13:56:27 +09:00
Xiang Xiao
602ff0cd76 Include assert.h in necessary place
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-06-03 13:56:27 +09:00
Xiang Xiao
8e06d060c2 nsh/date: Support -u option
user can use both UTC and local time now

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-06-02 11:10:31 +01:00
Xiang Xiao
719b37cfdc Include assert.h in necessary place
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-06-02 17:03:04 +09:00
RoCorbera
42f4565129 nsh kill cmd can be executed with no signal option.
SIGTERM is the default signal, as in unix kill command.
nsh> kill [-<signal>] <pid>
2021-06-01 15:57:13 -03:00
RoCorbera
61ddfeba17 add SIGTERM handling in leds example
following the idea of having a kill \<pid\> that will send SIGTERM default signal to the task,
this example of a "daemon leds" will handle SIGTERM in order to gracefully terminate itself.
It allows to restart this daemon after correctly terminating it.
2021-06-01 15:56:55 -03:00
Abdelatif Guettouche
99ec1bec61 examples/lvgl & graphics/lvgl: Use the usual Q variable for quiet instead of @.
Signed-off-by: Abdelatif Guettouche <abdelatif.guettouche@espressif.com>
2021-06-01 09:07:31 -05:00
Abdelatif Guettouche
4a72b8d132 examples/lvgldemo: LVGL examples are now called lv_demos and not
lv_examples.

Signed-off-by: Abdelatif Guettouche <abdelatif.guettouche@espressif.com>
2021-06-01 09:07:31 -05:00
Xiang Xiao
d6d458c60b Include assert.h in necessary place
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-06-01 14:11:16 +09:00
Xiang Xiao
58293abb8e Follow up task_spawn change from kernel side
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-06-01 12:45:26 +09:00
Xiang Xiao
e9104dbbef Include assert.h in necessary place
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-06-01 06:36:44 +09:00
raiden00pl
be14592e84 examples/pwm: fix printf format warnings 2021-05-31 08:32:06 -05:00
raiden00pl
10ab78b028 examples/foc/foc_float_thr.c: fix incorect variable type 2021-05-31 08:31:45 -05:00
Xiang Xiao
ebb4ade95e interpreters/bas: Fix the nxstyle warning
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-05-31 08:51:22 +02:00
Xiang Xiao
213e60232f Include assert.h in necessary place
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-05-31 08:51:22 +02:00
Sara Souza
b203d14c7b examples/termios: Adds option to disable HW flow control 2021-05-30 22:32:29 -05:00
Sara Souza
7a7ef0db59 examples/alarm: fix typo and coding style issues 2021-05-29 23:05:23 +01:00
Masayuki Ishikawa
f6f4de1ca2 interpreters: wamr: Add touch in Makefile to avoid unnecessary mv
Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>
2021-05-27 08:20:43 +02:00
Masayuki Ishikawa
a077598b6d interpreters: wamr: Change the default version to "04-15-2021"
Summary:
- This commit changes the default version to "04-15-2021"
  to fix a compile error for Cortex-M target

Impact:
- WASM micro runtime (WAMR)
- NOTE: There are still compile warnings in the WAMR which
  should be fixed later

Testing:
- Tested with spresense (NOTE: need to add -lm)
- Tested with esp32-devkitc

Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>
2021-05-27 08:20:43 +02:00
Gustavo Henrique Nihei
b843486386 readline: Reset offset when top command is issued repeateadly 2021-05-24 22:01:21 -05:00
Xiang Xiao
82ed7bf5b1 Include debug.h for xerr/xinfo/xwarn caller
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-05-24 19:52:54 +09:00
Xiang Xiao
98de0d6a68 nsh: Add debug.h inclusion in nsh_command.c
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-05-24 16:05:07 +09:00
Xiang Xiao
1ee948e0c8 Include assert.h for DEBUGASSERT caller
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-05-24 12:34:37 +09:00
Xiang Xiao
d3f8f423d5 Include debug.h for xerr/xinfo/xwarn caller
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-05-24 12:33:17 +09:00
Xiang Xiao
6e15af3786 graphics/twm4nx: Fix error: 'sleep' was not declared in this scope
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-05-24 08:33:58 +09:00
Michał Łyszczek
19e2ffe37e system/psmq: update to v0.2.1
This release breaks API and ABI by making use of library way
easier and more safe. No app in a nuttx tree uses psmq, so
nothing in-tree will be broken by this change.

Updated license files to Apache 2.0.

Tested on nucleo-f091

Signed-off-by: Michał Łyszczek <michal.lyszczek@bofc.pl>
2021-05-23 23:57:25 +01:00
Sara Souza
b8817e2a6d examples/termios: Small fix on a print message 2021-05-23 12:21:12 -05:00
Alexander Lunev
5f05678e7d examples/nxflat: fixed an issue with the symbol table creation (#3737#issuecomment-844574935) 2021-05-22 14:04:16 -05:00
Xiang Xiao
34a042aa49 nimble: Update version to cd8ab38c3da91b71dd428979153a408f38d3b02e
which contain the following fix:
commit cd8ab38c3da91b71dd428979153a408f38d3b02e
Author: Xiang Xiao <xiaoxiang@xiaomi.com>
Date:   Thu May 20 15:43:50 2021 +0800

nuttx: fix error: use of undeclared identifier 'ENOMEM'

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: Idd832450d98306750ece8307ec7eef5c0c367a48
2021-05-22 12:02:58 -03:00
jturnsek
6b53a1959b Arrow keys not working when in INSERT mode 2021-05-20 04:23:10 -05:00
Xiang Xiao
6ff7e42e01 include debug.h for xerr/xinfo/xwarn caller
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-05-20 08:43:17 +01:00
Xiang Xiao
7ef50558ab system/system: Include errno.h
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-05-20 08:42:05 +01:00
Tanushree Baindur
bff92219cd Check CONFIG_BOARDCTL_ROMDISK is set
CONFIG_BOARDCTL_ROMDISK must be set to enable boardctl(BOARDIOC_ROMDISK)
    in these 2 files:
    examples/nxflat/nxflat_main.c
    examples/thttpd/thttpd_main.c
2021-05-19 20:42:24 -05:00
Xiang Xiao
a6ca97d733 ostest: Include errno.h in timedmutex.c
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-05-18 12:42:02 +01:00
Tanushree Baindur
ab41d23d7c Apps Issue #246:Replace romdisk_register() with boardctl(BOARDIOC_ROMDISK)
files changed: examples/nxflat/nxflat_main.c
               examples/thttpd/thttpd_main.c

examples/thttpd: Fix error: unused variable 'desc'
2021-05-17 07:13:51 -05:00
Xiang Xiao
b7e9c43489 ci: change sim01 and sim02 to sim-01 and sim-02
follow up the kernel side chnage:
commit 09a0ed111c0c193a57b2a538e23c2b6a6e9cdf26
Author: Xiang Xiao <xiaoxiang@xiaomi.com>
Date:   Thu May 13 21:28:43 2021 +0800

tools/ci: Rename sim0x.dat to sim-0x.dat to align with arm-xx.dat

To avoid the build break sim0x.dat will remove in the upcoming patch

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-05-16 19:44:46 +01:00
YAMAMOTO Takashi
95c9007668 webclient: Fix buffer overrun in wget_parsestatus
Similarly to the fix in wget_parseheaders.
But simply always bail out as i guess it's very rare to see
that long status line.

Tested with an aritifically small CONFIG_WEBCLIENT_MAXHTTPLINE=20,
which is smaller than "HTTP/1.1 301 Moved Permanently".
2021-05-16 11:32:47 -03:00
YAMAMOTO Takashi
b53375074b webclient.c: Fix buffer overrun in HTTP header parsing
* Detect a long header line which doesn't fit the buffer.

* If the header line in question doesn't seem important for us,
  just ignore it.

* Otherwise, bail out with -E2BIG.

The overrun was found by LLVM UBSan on macOS.

The following is an example of a long header line,
which doesn't fit the default CONFIG_WEBCLIENT_MAXHTTPLINE=200.
```
pacetanuki% curl -v https://www.midokura.com
:
:
< HTTP/2 200
< server: nginx
< date: Fri, 14 May 2021 02:16:24 GMT
< content-type: text/html; charset=UTF-8
< content-length: 131313
< x-powered-by: PHP/7.4.18
< link: <https://www.midokura.com/wp-json/>; rel="https://api.w.org/", <https://www.midokura.com/wp-json/wp/v2/pages/7>; rel="alternate"; type="application/json", <https://www.midokura.com/>; rel=shortlink
< x-powered-by: PleskLin
<
```
2021-05-16 11:32:47 -03:00
YAMAMOTO Takashi
eb1a99fdd6 webclient.c: Don't parse the status line as the first header line 2021-05-16 11:32:47 -03:00
YAMAMOTO Takashi
f17af21f9c webclient: Add a few ninfo in header parsing 2021-05-16 11:32:47 -03:00
Diego Herranz
d74ac654a9 hdc1008_demo: set intial measurement mode
No mode was set before the first read by the app.
The first time the app was run, it worked properly, reading
temperature and humidity on the first read(). But subsequent reads
returned humidity only since that was last mode set up.
Also, the ioctl read was returning invalid results.
2021-05-16 11:31:31 -03:00
Michał Łyszczek
ccc8ddaf5d system/embedlog: update to v0.6.0
Changes from v0.4.0
- add thread safety code
- add option to print function info (name) in logs
- abi/api stabilization
- bug fixes + increased reliability

Signed-off-by: Michał Łyszczek <michal.lyszczek@bofc.pl>

---
v1 -> v2 [suggested by Brennan Ashton]
 - fix path to embedlog_main.c in header comment
 - change license from bsd3 to apache2.0
2021-05-16 11:30:29 -03:00
Xiang Xiao
e352bdca4f examples/module: Fix error: unused variable 'desc'
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-05-13 04:54:28 -05:00
Xiang Xiao
e25a303a73 examples/elf: Fix error: unused variable 'desc' [-Werror=unused-variable]
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-05-12 19:23:02 -07:00
Tanushree Baindur
f0c044adb1 Apps Issue #246: Replace romdisk_register() with boardctl(BOARDIOC_ROMDISK)
C file changes:
   examples/bastest/bastest_main.c
   examples/elf/elf_main.c
   examples/module/module_main.c
   examples/posix_spawn/spawn_main.c
   examples/romfs/romfs_main.c
   examples/sotest/sotest_main.c
   examples/unionfs/unionfs_main.c

Update examples/elf/elf_main.c

Co-authored-by: Xiang Xiao <xiaoxiang781216@gmail.com>

Update examples/unionfs/unionfs_main.c

Co-authored-by: Xiang Xiao <xiaoxiang781216@gmail.com>

Update examples/unionfs/unionfs_main.c

Co-authored-by: Xiang Xiao <xiaoxiang781216@gmail.com>

Update examples/posix_spawn/spawn_main.c

Co-authored-by: Xiang Xiao <xiaoxiang781216@gmail.com>

Update examples/elf/elf_main.c

Co-authored-by: Xiang Xiao <xiaoxiang781216@gmail.com>

Update examples/elf/elf_main.c

Co-authored-by: Xiang Xiao <xiaoxiang781216@gmail.com>
2021-05-12 04:41:51 -07:00
Xiang Xiao
bb1e93cb67 netutils/wakeonlan: Remove the tab from the blank line in Kconfig
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-05-12 10:48:44 +01:00
Simon Piriou
842f149c78 netutils: add Wake-on-LAN util 2021-05-09 10:25:20 -03:00
Diego Herranz
b52de67f6e examples/hdc1008_demo: fix header path
As recommended by the nxstyle CI check.
2021-05-08 23:09:30 -07:00
Diego Herranz
453d5f2866 examples/hdc1008_demo: fix wrong printf parameter
An extra "%d" that shouldn't be there
2021-05-08 23:09:30 -07:00
Simon Piriou
e4db4df673 system: adb: fix shell service
Fix wrong dup2 return value check after:
fs: file_dup2 shouldn't hold the file list lock
1e5bfa623aa93b918566e8dc0e2f9c1a1037f45e

Fix issue in adb shell introduced in:
nsh: Pass the correct command lines to nsh_consolemain
6aca60133c
2021-05-08 22:51:25 -07:00