Xiang Xiao
0d2ef47192
nshlib: Rename CONFIG_SYSTEM_NSH_SYMTAB to CONFIG_NSH_SYMTAB
...
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-10-18 22:18:38 +02:00
Xiang Xiao
b659f0fbdf
Remove the unnecessary cast for main_t, NULL and argv
...
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-10-18 18:40:23 +02:00
Xiang Xiao
8e460e7e19
nshlib: Move symbol table initialization from nsh_main to nsh_initialize
...
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-10-16 15:39:10 -04:00
Xiang Xiao
0d210c3227
nshlib: Move commoin initialization from console_main to nsh_initialize
...
to avoid the code duplication
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-10-16 15:39:10 -04:00
Xiang Xiao
964747dd36
nshlib: Call nsh_telnetstart in nsh_initialize to avoid the dupliation
...
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-10-16 15:39:10 -04:00
Xiang Xiao
893387b2c5
Fix the minor style issue
...
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-10-16 19:07:16 +02:00
Xiang Xiao
4941182cc6
Make.defs: Change "ifeq ($(XXX),y)" to "ifneq ($(XXX),)
...
to support the tristate option correctly and unify the usage
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-10-16 14:59:08 +02:00
crafcat7
2ad6dc37d8
system/cachespeed:Average time to add
2022-10-15 03:15:30 +08:00
Xiang Xiao
9291d07a87
Fix the coding style issue
...
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-10-06 12:20:32 +02:00
crafcat
98a9d2c749
system/ramspeed: Add system interrupt switch.
...
system/ramspeed: Add system interrupt switch.
2022-10-03 21:07:17 +02:00
crafcat
744ecf2b01
system/ramspeed: Add system interrupt switch.
2022-10-03 21:07:17 +02:00
crafcat
0e0ac0656b
system/cachespeed:Tools for testing cache-related speed.
...
Signed-off-by: crafcat <110923103+crafcat7@users.noreply.github.com>
2022-10-01 11:41:40 +08:00
yinshengkai
1b99543e8d
system/gcov: add show usage
...
Signed-off-by: yinshengkai <yinshengkai@xiaomi.com>
2022-09-27 19:39:31 +08:00
yinshengkai
d9ec9ca868
system/trace: expand dump string
...
Signed-off-by: yinshengkai <yinshengkai@xiaomi.com>
2022-09-27 19:39:22 +08:00
Huang Qi
2e2630e838
Don't download tarballs if a local git repo found
...
Signed-off-by: Huang Qi <huangqi3@xiaomi.com>
2022-08-28 17:20:47 +08:00
Fotis Panagiotopoulos
0cdb2cfa48
Fixed compiler warnings.
2022-08-23 01:39:59 +08:00
yinshengkai
1e66c39066
system/input: update input device name
...
Signed-off-by: yinshengkai <yinshengkai@xiaomi.com>
2022-08-16 14:59:34 +08:00
jihandong
6afc226350
nxlooper nxplayer nxrecorder: fix coverity bug
...
readline might return EOF.
Signed-off-by: jihandong <jihandong@xiaomi.com>
2022-08-16 14:59:19 +08:00
Xiang Xiao
de26582775
system/uorb: Pass NULL to task_create directly
...
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-08-16 09:47:17 +03:00
yinshengkai
6895da98e3
system/input: add input tools keyboard support
...
Signed-off-by: yinshengkai <yinshengkai@xiaomi.com>
2022-08-15 11:12:21 +03:00
zhouliang3
ec4f97623a
libuv/tests: Fix libuv extension tests compilation error
...
Signed-off-by: zhouliang3 <zhouliang3@xiaomi.com>
2022-08-15 10:51:10 +03:00
Xiang Xiao
b515a00fea
zmodem: Move crc16.h and crc32.h from host to host/nuttx
...
to avoid the conflict with the 3rd party library
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-08-13 13:28:30 +03:00
Masayuki Ishikawa
41fe4f177a
system:nsh : Apply CONFIG_NSH_DISABLE_TELNETSTART to nsh_main.c
...
Summary:
- This commit applies CONFIG_NSH_DISABLE_TELNETSTART to nsh_main.c
Impact:
- None
Testing:
- Tested with sabre-6quad:netknsh (will be updated later)
Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>
2022-08-09 23:17:25 +08:00
Masayuki Ishikawa
a86315050d
system: telnetd: Add telnetd app
...
Summary:
- This commit adds telnetd app
Impact:
- None
Testing:
- Tested with sabre-6quad:netknsh (will be updated later)
Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>
2022-08-09 23:17:25 +08:00
Jiuzhu Dong
e04333c986
driver/sensor: rename /dev/sensor -> /dev/uorb
...
because this directory contains all topics by uorb using, not just sensors.
Signed-off-by: Jiuzhu Dong <dongjiuzhu1@xiaomi.com>
2022-08-08 23:11:37 +08:00
Petro Karashchenko
6d730e3c25
system/cfgdata: add "format" command to description
...
Signed-off-by: Petro Karashchenko <petro.karashchenko@gmail.com>
2022-08-05 13:57:21 +08:00
ligd
79a137495a
cu: fix cu hang when meet ctrl + C
...
We can't do sem_wait in sigaction
hang backtrace:
[<0x2c5a6958>] arm_switchcontext+0xc/0x10
[<0x2c579eba>] nxsem_wait+0x6e/0xa8
[<0x3c9a8cb5>] pb_field_iter_find+0xffde8cb/0xd3635c15
[<0x2c58d164>] uart_tcdrain.constprop.0+0x10/0xf8
[<0x2c58d5c6>] uart_close+0x10e/0x180
[<0x2c579f38>] nxsem_wait_uninterruptible+0x44/0xb8
[<0x2c95f87a>] file_close+0x12/0x44
[<0x2c95e5a8>] close+0x80/0xb4
[<0x2c5c6396>] sigint+0x1a/0x28
[<0x2c57b1b0>] nxsig_deliver+0x54/0xb8
[<0x2c5a549a>] arm_sigdeliver+0x1a/0x44
[<0x2c579eb6>] nxsem_wait+0x6a/0xa8
[<0x2c579eb6>] nxsem_wait+0x6a/0xa8
[<0x2c579eb6>] nxsem_wait+0x6a/0xa8
[<0x2c58aa1a>] pm_lock+0x1a/0x28
[<0x2c58a656>] pm_stay+0xa/0x60
[<0x2c58bb14>] rptun_notify+0x4c/0x58
[<0x2c97b8fc>] virtqueue_kick+0x54/0x7c
[<0x2c97ac82>] rpmsg_virtio_send_offchannel_nocopy+0x9a/0xcc
[<0x2c58df7c>] uart_rpmsg_dmasend+0x8c/0xe0
[<0x2c5771be>] leave_critical_section+0x2e/0x54
[<0x2c58d124>] uart_write+0x11c/0x14c
[<0x2c9620c6>] write+0x32/0x50
[<0x2c5c665e>] cu_main+0x2ba/0x484
[<0x2c5957be>] nxtask_startup+0x12/0x24
[<0x2c57b9d2>] nxtask_start+0x46/0x60
Signed-off-by: ligd <liguiding1@xiaomi.com>
2022-07-29 19:21:52 +03:00
ligd
8081711e22
nxlooper: nxlooper should wait call buffer returned before close
...
Signed-off-by: ligd <liguiding1@xiaomi.com>
2022-07-29 19:18:34 +03:00
Masayuki Ishikawa
147a796a7a
system: popen: Fix to build with CONFIG_BUILD_KERNEL=y
...
Summary:
- This commit fixes to build with CONFIG_BUILD_KERNEL=y
Impact:
- None
Testing:
- Tested with sabre-6quad:knsh (not merged yet)
Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>
2022-07-29 10:20:19 +08:00
jihandong
74af9a8065
app/system/uorb: fix error, memset() wrong size.
...
Signed-off-by: jihandong <jihandong@xiaomi.com>
2022-07-23 16:57:58 -03:00
Jiuzhu Dong
131e4dc69d
system/uorb: simply orb_check by SNIOC_UPDATED
...
Signed-off-by: Jiuzhu Dong <dongjiuzhu1@xiaomi.com>
2022-07-23 16:57:58 -03:00
jihandong
3f865c4f9e
uorb/listener: ignore first get_state failed.
...
Signed-off-by: jihandong <jihandong@xiaomi.com>
Signed-off-by: Jiuzhu Dong <dongjiuzhu1@xiaomi.com>
2022-07-23 16:57:58 -03:00
jihandong
2b8bfc5be7
app/system/uorb: modify unit test to support data persist
...
Signed-off-by: jihandong <jihandong@xiaomi.com>
2022-07-23 16:57:58 -03:00
jihandong
874ed7654d
app/system/uorb: fix listener run_once not work.
...
And remove dead code.
Signed-off-by: Jiuzhu Dong <dongjiuzhu1@xiaomi.com>
2022-07-23 16:57:58 -03:00
Jiuzhu Dong
f02c5a5d7e
system/uorb: support new api
...
orb_advertise_multi_queue_persist
Signed-off-by: Jiuzhu Dong <dongjiuzhu1@xiaomi.com>
2022-07-23 16:57:58 -03:00
ligd
37f1e453b1
uorb: use another writing method to avoid compiler bug
...
int func(int b)
{
int a;
while (1) {
...;
if (b != 0)
a = 1000 / b;
...;
}
}
if b == 0, then system crash in Xtensa arch, clang compiler
Signed-off-by: ligd <liguiding1@xiaomi.com>
2022-07-23 16:57:58 -03:00
Jiuzhu Dong
8558e63772
uorb_listener: support set batch latency
...
Signed-off-by: Jiuzhu Dong <dongjiuzhu1@xiaomi.com>
2022-07-23 16:57:58 -03:00
Jiuzhu Dong
3a8f4b53fc
apps/uorb: fix compile break
...
Signed-off-by: Jiuzhu Dong <dongjiuzhu1@xiaomi.com>
2022-07-23 16:57:58 -03:00
jihandong
384c05beb2
app/system/uorb: alloc on heap instead of stack.
...
Signed-off-by: jihandong <jihandong@xiaomi.com>
2022-07-23 16:57:58 -03:00
Jiuzhu Dong
e97b1a79d6
uorb_listener: support subscribe physical sensor before node register
...
Signed-off-by: Jiuzhu Dong <dongjiuzhu1@xiaomi.com>
2022-07-23 16:57:58 -03:00
Jiuzhu Dong
5bb4e14aad
system/uorb: always let orb_advertise, orb_advertise_queue for instance 0
...
1.orb_advertise, orb_advertise_queue for instance 0
2.orb_advertise_multi, orb_advertise__multi_queue for specified instance
3.If orb_advertise_multi_queue with instance is NULL, auto increase
instance from existing base.
Signed-off-by: Jiuzhu Dong <dongjiuzhu1@xiaomi.com>
2022-07-23 16:57:58 -03:00
Jiuzhu Dong
53ee04ba3c
uorb/listener: add new api: orb_open and orb_close
...
don't using subscriber to get state to avoid rpmsg access
Signed-off-by: Jiuzhu Dong <dongjiuzhu1@xiaomi.com>
2022-07-23 16:57:58 -03:00
Jiuzhu Dong
d44dd1c426
uorb_unit_test: optimize stack used
...
Signed-off-by: Jiuzhu Dong <dongjiuzhu1@xiaomi.com>
2022-07-23 16:57:58 -03:00
Jiuzhu Dong
6fceb913a2
system/uorb: optimize stack used
...
Signed-off-by: Jiuzhu Dong <dongjiuzhu1@xiaomi.com>
2022-07-23 16:57:58 -03:00
jihandong
9f6d322186
system/uorb: listener, has 'top' command.
...
Listener can scan device under ORB_SENSOR_PATH, subscribe them and
cotinue printing messages by call their cb.
'-T' can Continuously print updating objects, '-l' means only
print once.
Signed-off-by: jihandong <jihandong@xiaomi.com>
Signed-off-by: Jiuzhu Dong <dongjiuzhu1@xiaomi.com>
2022-07-23 16:57:58 -03:00
Jiuzhu Dong
4ec3f70f1d
apps/system/uorb: support orb_get_meta by name string
...
Signed-off-by: Jiuzhu Dong <dongjiuzhu1@xiaomi.com>
2022-07-23 16:57:58 -03:00
Jiuzhu Dong
46c98420b7
system/uorb: add builtin sensor topics
...
Signed-off-by: Jiuzhu Dong <dongjiuzhu1@xiaomi.com>
2022-07-23 16:57:58 -03:00
jihandong
d8d1e1e761
apps/system/uorb: c unit testcases
...
testcases:
1. test_single(): single instance, advertise then subscribe.
2. test_multi_inst10(): 10 instance, each 1 subscriber.
3. test_multi(): 2 instances, 2 advertisers, 2 subscribers.
4. test_multi_reversed(): same as test_multi(), but subsribe before
advertise.
5. test_unadvertise(): unadvertise upper 4 advertisers.
6. test_multi2(): same as tset_multi(). but multi-thread.
7, test_queue(): topic queue_size = 16.
Signed-off-by: jihandong <jihandong@xiaomi.com>
Signed-off-by: Jiuzhu Dong <dongjiuzhu1@xiaomi.com>
2022-07-23 16:57:58 -03:00
jihandong
3528b5515f
apps/system/uorb: c interfaces.
...
refer to: https://docs.px4.io/v1.12/en/middleware/uorb.html
- orb_open: do real work for advertise() and subscribe(), if thre is
no user, register topic first, then save meta in driver;
only first user can successfully set buffer number.
- orb_exists: check topic state, if topic only has subscribers,
return "not exists".
Signed-off-by: jihandong <jihandong@xiaomi.com>
2022-07-23 16:57:58 -03:00
Xiang Xiao
c252ec1481
Add printflike to all printf like functions
...
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-07-18 14:09:10 +03:00