Commit Graph

521 Commits

Author SHA1 Message Date
Petro Karashchenko
9480c0ec12 include: fix double include pre-processor guards
Signed-off-by: Petro Karashchenko <petro.karashchenko@gmail.com>
2022-01-16 17:36:21 +08:00
Fotis Panagiotopoulos
bc5d8034f1 Typo fixes. 2022-01-06 10:30:41 +08:00
Xiang Xiao
66dbaa4539 Replace self defined macros with NET_SOCK_[FAMILY|TYPE|PROTOCOL]
NET_SOCK_* is defined by nuttx/net/netconfig.h and then can be shared

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-12-20 16:04:29 -03:00
Xiang Xiao
58586f86e3 system/cle: Make it work without CONFIG_FILE_STREAM
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-11-30 22:06:03 -06:00
Xiang Xiao
c8439368ac system/readline: Make it work without CONFIG_FILE_STREAM
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-11-30 22:06:03 -06:00
songlinzhang
e0fc53b23c netutils/dhcpc: add non-blocking interface
Signed-off-by: songlinzhang <songlinzhang@xiaomi.com>
2021-11-29 02:04:49 -06:00
raiden00pl
54c0b9a9d8 industry/foc/foc_align: add support for sensor index search 2021-11-07 03:46:17 -06:00
Gustavo Henrique Nihei
fbdfb0ef96 crypto/mbedtls: Bump Mbed TLS to version 3.0.0
Signed-off-by: Gustavo Henrique Nihei <gustavo.nihei@espressif.com>
2021-11-04 23:19:58 -05:00
Brennan Ashton
c2057d77b2 crypto: Initial support for mbedtls
Signed-off-by: Brennan Ashton <bashton@brennanashton.com>
2021-11-04 15:20:14 -03:00
raiden00pl
4001d27571 industry/foc: add support for Hall sensor 2021-10-30 10:17:07 -05:00
raiden00pl
5b52247625 industry/foc: add support for qenco 2021-10-30 10:17:07 -05:00
raiden00pl
515a25fbb8 industry/foc/*/foc_velocity.c: add methods to set the zero velocity and direction of the velocity 2021-10-30 10:17:07 -05:00
raiden00pl
6cafdae44a industry/foc/*/foc_angle.c: add methods to set the zero angle and direction of the angle 2021-10-30 10:17:07 -05:00
raiden00pl
2e61b3e310 industry/foc/*/foc_velocity.c: run method should return int 2021-10-30 10:17:07 -05:00
raiden00pl
cb78f6d0df industry/foc/*/foc_angle.c: run method should return int 2021-10-30 10:17:07 -05:00
raiden00pl
27c282a58a include/industry/foc/*/foc_angle.h: add a field with angle type 2021-10-30 10:17:07 -05:00
raiden00pl
9362fe760d include/industry/foc/*/foc_handler.h: remove useless FAR 2021-10-30 01:19:43 -05:00
raiden00pl
f009d68a91 industry/foc: add motor identification routine 2021-10-30 01:18:12 -05:00
raiden00pl
f2fc2af8e3 industry/foc: add sensor alignment routine 2021-10-30 01:18:12 -05:00
raiden00pl
084cfa4e5e industry/foc: add general FOC routine handler 2021-10-30 01:18:12 -05:00
Jiuzhu Dong
5c1626c764 netutils: add NETLIB_SOCK_TYPE for AF_RPMSG
Signed-off-by: Jiuzhu Dong <dongjiuzhu1@xiaomi.com>
2021-09-12 11:37:53 +08:00
Erdem Meydanli
c222043ed1 system/termcurses: Add terminate operation into the termcurses_ops_s interface
The existing implementation of the termcurses_deinitterm calls
termcurses_setcolors with some hard-coded values, leading to different
terminal emulators' behavior. Instead, a reset call needs to be made to
the implementation to roll back changes.

A new operation (terminate) has been added to the termcurses_ops interface
to achieve this functionality.

The vt100's terminate implementation ensures that default foreground and
background colors are applied portably across different terminals emulators.
2021-08-28 21:12:40 +08:00
Juha Niskanen
b283289986 apps: fix miscellaneous typos
Signed-off-by: Juha Niskanen <juha.niskanen@haltian.com>
2021-08-26 11:39:28 -07:00
YAMAMOTO Takashi
66650f223b netlib: Change the type of url_s:port to uint16_t
uint16_t is what's used in netlib and webclient in most of places.
There is a static analizer complaining on the type mismatch.
(It's actually harmless as far as I understand though.)
2021-08-12 04:33:44 -07:00
YAMAMOTO Takashi
f6c194944c netlib.h: Fix an nxstyle error 2021-08-12 04:33:44 -07:00
YAMAMOTO Takashi
b8fd862965 webclient: Add some assertions on webclient_context state 2021-08-08 22:34:26 -07:00
YAMAMOTO Takashi
cb1f7c9dfe webclient.h: Document webclient_client lifetime 2021-08-08 22:34:26 -07:00
YAMAMOTO Takashi
0bae950b63 webclient: Implement non-blocking I/O
* webclient_perform
    * Add a new flag to use non-blocking mode (WEBCLIENT_FLAG_NON_BLOCKING)
    * Implement restarting

* Add a few associated API functions
    * webclient_get_poll_info: get the descriptor info for poll/select
    * webclient_abort: abort the operation (instead of restarting)
2021-08-08 22:34:26 -07:00
raiden00pl
a0fbd104fa industry/foc: add support for CORDIC 2021-07-28 14:24:08 -03:00
Gustavo Henrique Nihei
a1026c9f23 netutils/webclient: Notify HTTP header data via dedicated callback
Signed-off-by: Gustavo Henrique Nihei <gustavo.nihei@espressif.com>
2021-07-23 11:28:26 -07:00
Xiang Xiao
ca70e585b1 system/nxlooper: Fix the following compiler warning
nxlooper.c: In function 'nxlooper_opendevice':
Error: nxlooper.c:126:15: error: unused variable 'x' [-Werror=unused-variable]
  126 |       uint8_t x;
      |               ^
Error: nxlooper.c:125:15: error: unused variable 'supported' [-Werror=unused-variable]
  125 |       uint8_t supported = true;
      |               ^~~~~~~~~
In file included from nxlooper.c:40:
nxlooper.c: In function 'nxlooper_loopthread':
Error: nxlooper.c:482:15: error: format '%d' expects argument of type 'int', but argument 3 has type 'ssize_t' {aka 'long int'} [-Werror=format=]
  482 |       audinfo("message received size %d id%d\n", size, msg.msg_id);
      |               ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~  ~~~~
      |                                                  |
      |                                                  ssize_t {aka long int}
nxlooper.c:482:39: note: format string is defined here
  482 |       audinfo("message received size %d id%d\n", size, msg.msg_id);
      |                                      ~^
      |                                       |
      |                                       int
      |                                      %ld
cc1: all warnings being treated as errors
make[3]: *** [/github/workspace/sources/apps/Application.mk:133: nxlooper.c.github.workspace.sources.apps.system.nxlooper.o] Error 1
nxlooper_main.c: In function 'nxlooper_cmd_loopback':
Error: nxlooper_main.c:209:9: error: implicit declaration of function 'nxlooper_loopraw'; did you mean 'nxlooper_stop'? [-Werror=implicit-function-declaration]
  209 |   ret = nxlooper_loopraw(plooper, channels, bpsamp,
      |         ^~~~~~~~~~~~~~~~
      |         nxlooper_stop

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-07-10 07:45:42 -03:00
chao.an
c89e9330cc system/ping[6]: correct the ping return value
MIRTOS-421

Change-Id: I68d8328ead736cd557d6142f611fae0540f74c1b
Signed-off-by: chao.an <anchao@xiaomi.com>
2021-06-22 10:28:21 -03:00
Alin Jerpelea
15c6c91b8a include: fix relative path CI error
error: Path relative to repository other than nuttx must begin with the root directory
Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-06-16 09:03:06 -05:00
YAMAMOTO Takashi
ce2b9519a7 webclient: Add a way to specify timeout 2021-06-15 05:18:14 -05:00
Alin Jerpelea
adc3c9fae9 include: nxstyle fixes
fixes for nxstyle errors reported by nxstyle tool

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-06-11 08:53:57 -05:00
Alin Jerpelea
324155cd1e include: update licenses to Apache
Gregory Nutt is has submitted the SGA

Uros Platise has submitted the ICLA

Ken Pettit has submitted the ICLA

Sebastien Lorquet has submitted the ICLA

Pierre-Noel Bouteville has submitted the ICLA

as a result we can migrate the licenses to Apache.

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-06-11 05:05:27 -05:00
Alin Jerpelea
2e7e221f07 industry: abnt_codi: update licenses to Apache
Gregory Nutt is has submitted the SGA

Alan Carvalho de Assis has submitted the ICLA

as a result we can migrate the licenses to Apache.

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-06-08 08:43:15 -05:00
Alin Jerpelea
dc888ba70f canutils: update licenses to Apache
Alan Carvalho de Assis has submitted the ICLA

as a result we can migrate the licenses to Apache.

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-06-08 08:43:15 -05:00
chenwen
39c5fa812d wireless/wapi: Fix issue of getting the operating frequency 2021-04-12 03:56:11 -05:00
raiden00pl
d75d6b7af0 Add FOC library
Supported features:
- float and fixed16 operations
- helper interface to interact with the kernel-side FOC device
- general interface for FOC controller
- PI current/voltage controller
- 3-phase space vector modulation
- general interface for FOC model
- PMSM model
- general interface for phase angle data
- open-loop handler
- general interface for phase velocity data
- general interface for ramp (eg. velocity ramp, torque ramp)
- (WIP) CORDIC interface for hardware acceleration
2021-04-10 00:39:09 -05:00
Alan C. Assis
f9e487ae1d modbus: Fix compilation issue and advice users about termios 2021-04-05 08:39:52 -05:00
Matias N
d548803d38 httpd: expose http_send_headers to be used in CGI handlers 2021-03-30 22:27:49 -05:00
Jiuzhu Dong
4c6ded2661 app: delete NFILE_DESCRIPTORS limits
Change-Id: I3ced2b2b7440a2c79a712cfc97b4cd15d2bddd4c
Signed-off-by: Jiuzhu Dong <dongjiuzhu1@xiaomi.com>
2021-03-12 21:12:07 -08:00
YAMAMOTO Takashi
8ae1267054 ntpclient: Add ntpcstatus() api to query ntpc status programatically
For now, just provide the latest samples.
2021-02-20 01:30:55 -08:00
chao.an
623a668baa wapi: Extend "WAPI_ESSID_DELAY_ON" flag to support customized connection behavior
The current essid setting(SIOCSIWESSID) are not satisfactory in case
of specified bssid connection, if there are multiple essids with same name,
we need additional bssid information to connect to the specified softap.
The extended flag "WAPI_ESSID_DELAY_ON" instructs the driver to delay the
connection behavior of essid, so that which can accept more accurate
information before generating a connection.

About flow of wapi command, drivers that support WAPI_ESSID_DELAY_ON semantics
will have the following behavior changes:

1. Station mode without bssid set:

$ ifup wlan0
$ wapi mode wlan0 2
$ wapi psk wlan0 12345678 3
$ wapi essid wlan0 archer 1
$ renew wlan0

2. Station mode with bssid set:

$ ifup wlan0
$ wapi mode wlan0 2
$ wapi psk wlan0 12345678 3
$ wapi essid wlan0 archer 2       <----- WAPI_ESSID_DELAY_ON will indicate the driver delay
$                                        the connection event late to bssid set (SIOCSIWAP).
$ wapi ap wlan0 ec:41:18:e0:76:7e
$ renew wlan0

Signed-off-by: chao.an <anchao@xiaomi.com>
2021-01-30 20:19:10 -08:00
Juha Niskanen
3b21cd9ceb netutils/ntpclient: add more features
Allow multiple NTP servers, also with runtime configurable list
Add validation of received NTP packets
NTPv4 support with 'Kiss o' Death' message handling
IPv6 support
Collect multiple NTP samples and filter outsiders
Check if system clock has been altered during NTP (if CONFIG_CLOCK_MONOTONIC)

Signed-off-by: Juha Niskanen <juha.niskanen@haltian.com>
2021-01-26 03:23:27 -08:00
Juha Niskanen
c4bcd8254a include/system/prun.h: remove leftover file 2021-01-22 17:50:13 +01:00
YAMAMOTO Takashi
1131cbe14d webclient: Implement AF_LOCAL 2021-01-17 18:44:17 -08:00
Juha Niskanen
35535655c5 ntpclient: change sinfo to ninfo
Signed-off-by: Juha Niskanen <juha.niskanen@haltian.com>
2021-01-14 11:07:58 -06:00
chao.an
bd9174a3b6 wireless/wapi: add set country code support
Signed-off-by: chao.an <anchao@xiaomi.com>
2021-01-05 08:00:29 +01:00