[GitHub] [nuttx-apps] jturnsek commented on a diff in pull request #1624: Adding sdr group with liquid-dsp library

2023-03-06 Thread via GitHub


jturnsek commented on code in PR #1624:
URL: https://github.com/apache/nuttx-apps/pull/1624#discussion_r1126054975


##
sdr/liquid_dsp/Makefile:
##
@@ -0,0 +1,247 @@
+###
+# apps/sdr/liquid_dsp/Makefile
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.  The
+# ASF licenses this file to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance with the
+# License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
+# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.  See the
+# License for the specific language governing permissions and limitations
+# under the License.
+#
+/
+
+include $(APPDIR)/Make.defs
+
+LIQUID_DSP_VERSION  = 1.4.0
+LIQUID_DSP_UNPACK   = liquid-dsp
+LIQUID_DSP_TARBALL  = v$(LIQUID_DSP_VERSION).tar.gz
+LIQUID_DSP_URL_BASE = https://github.com/jgaeddert/liquid-dsp/archive
+LIQUID_DSP_URL  = $(LIQUID_DSP_URL_BASE)/$(LIQUID_DSP_TARBALL)
+
+$(LIQUID_DSP_TARBALL):
+   $(Q) echo "Downloading $(LIQUID_DSP_TARBALL)"
+   $(Q) curl -O -L $(LIQUID_DSP_URL)
+
+$(LIQUID_DSP_UNPACK): $(LIQUID_DSP_TARBALL)
+   $(Q) echo "Unpacking $(LIQUID_DSP_TARBALL) to $(LIQUID_DSP_UNPACK)"
+   $(Q) tar xzvf $(LIQUID_DSP_TARBALL)
+   $(Q) mv liquid-dsp-$(LIQUID_DSP_VERSION) $(LIQUID_DSP_UNPACK)
+   $(Q) cp config.h $(LIQUID_DSP_UNPACK)/include
+
+$(LIQUID_DSP_UNPACK)/.patch: $(LIQUID_DSP_UNPACK)
+   $(Q) touch $(LIQUID_DSP_UNPACK)/.patch
+
+VPATH += $(LIBUV_UNPACK)/include
+
+DEPPATH += --dep-path $(LIBUV_UNPACK)/include
+
+CFLAGS += -I$(LIQUID_DSP_UNPACK)/include
+CFLAGS += -Wall -std=c99
+CFLAGS += -DM_SQRT1_2=0.7071067811865475244008443621048490
+CFLAGS += -DM_SQRT2=1.4142135623730950488016887242096981
+CFLAGS += -DM_PI=3.1415926535897932384626433832795029
+CFLAGS += -DM_LN2=0.6931471805599453094172321214581765
+CFLAGS += -DM_PI_2=1.5707963267948966192313216916397514
+CFLAGS += -DM_2_PI=0.6366197723675813430755350534900574

Review Comment:
   > Do you have a workable LuaJIT? it's very great if you can upstream the 
porting.
   
   Yes, I have a working version, but not without some changes in NuttX. I 
still need to fix that first. One of problems is a new UNUSED macro in NuttX, 
which is giving me problems with LuaJIT code. The old version of UNUSED macro 
was fine, but then someone changed it. I am planning to release LuaJIT support 
when EdgePro1 campaign will start.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] masayuki2009 commented on pull request #8721: mm_heap: support custom the mm alignment and default to be 8

2023-03-06 Thread via GitHub


masayuki2009 commented on PR #8721:
URL: https://github.com/apache/nuttx/pull/8721#issuecomment-1455651534

   >I still need some time to figure out why stm32f4discovery:kostest ostest 
crash,
   
   @CV-Bowen 
   I found that the following defconfig does not cause the crash.
   I will create a new PR later.
   
   ```
   --- a/boards/arm/stm32/stm32f4discovery/configs/kostest/defconfig
   +++ b/boards/arm/stm32/stm32f4discovery/configs/kostest/defconfig
   @@ -18,9 +18,11 @@ CONFIG_BOARD_LATE_INITIALIZE=y
CONFIG_BOARD_LOOPSPERMSEC=16717
CONFIG_BUILD_PROTECTED=y
CONFIG_CONSOLE_SYSLOG=y
   +CONFIG_DEBUG_FULLOPT=y
   +CONFIG_DEBUG_HARDFAULT_ALERT=y
   +CONFIG_DEBUG_SYMBOLS=y
CONFIG_DISABLE_ENVIRON=y
CONFIG_DISABLE_MOUNTPOINT=y
   -CONFIG_HOST_WINDOWS=y
CONFIG_INIT_ENTRYPOINT="ostest_main"
CONFIG_INTELHEX_BINARY=y
CONFIG_MM_REGIONS=2
   @@ -32,6 +34,7 @@ CONFIG_RAM_START=0x2000
CONFIG_RAW_BINARY=y
CONFIG_RR_INTERVAL=200
CONFIG_SCHED_WAITPID=y
   +CONFIG_STACK_COLORATION=y
CONFIG_START_DAY=22
CONFIG_START_MONTH=3
CONFIG_START_YEAR=2013
   ```


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] no1wudi opened a new pull request, #8732: tools/arm: Add missing -mcpu param for zig

2023-03-06 Thread via GitHub


no1wudi opened a new pull request, #8732:
URL: https://github.com/apache/nuttx/pull/8732

   ## Summary
   Add missing -mcpu param for zig
   ## Impact
   zig only
   ## Testing
   qemu with hello_zig enabled
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx-apps] jturnsek commented on a diff in pull request #1624: Adding sdr group with liquid-dsp library

2023-03-06 Thread via GitHub


jturnsek commented on code in PR #1624:
URL: https://github.com/apache/nuttx-apps/pull/1624#discussion_r1126056748


##
sdr/liquid_dsp/Makefile:
##
@@ -0,0 +1,247 @@
+###
+# apps/sdr/liquid_dsp/Makefile
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.  The
+# ASF licenses this file to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance with the
+# License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
+# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.  See the
+# License for the specific language governing permissions and limitations
+# under the License.
+#
+/
+
+include $(APPDIR)/Make.defs
+
+LIQUID_DSP_VERSION  = 1.4.0
+LIQUID_DSP_UNPACK   = liquid-dsp
+LIQUID_DSP_TARBALL  = v$(LIQUID_DSP_VERSION).tar.gz
+LIQUID_DSP_URL_BASE = https://github.com/jgaeddert/liquid-dsp/archive
+LIQUID_DSP_URL  = $(LIQUID_DSP_URL_BASE)/$(LIQUID_DSP_TARBALL)
+
+$(LIQUID_DSP_TARBALL):
+   $(Q) echo "Downloading $(LIQUID_DSP_TARBALL)"
+   $(Q) curl -O -L $(LIQUID_DSP_URL)
+
+$(LIQUID_DSP_UNPACK): $(LIQUID_DSP_TARBALL)
+   $(Q) echo "Unpacking $(LIQUID_DSP_TARBALL) to $(LIQUID_DSP_UNPACK)"
+   $(Q) tar xzvf $(LIQUID_DSP_TARBALL)
+   $(Q) mv liquid-dsp-$(LIQUID_DSP_VERSION) $(LIQUID_DSP_UNPACK)
+   $(Q) cp config.h $(LIQUID_DSP_UNPACK)/include
+
+$(LIQUID_DSP_UNPACK)/.patch: $(LIQUID_DSP_UNPACK)
+   $(Q) touch $(LIQUID_DSP_UNPACK)/.patch
+
+VPATH += $(LIBUV_UNPACK)/include
+
+DEPPATH += --dep-path $(LIBUV_UNPACK)/include
+
+CFLAGS += -I$(LIQUID_DSP_UNPACK)/include
+CFLAGS += -Wall -std=c99
+CFLAGS += -DM_SQRT1_2=0.7071067811865475244008443621048490
+CFLAGS += -DM_SQRT2=1.4142135623730950488016887242096981
+CFLAGS += -DM_PI=3.1415926535897932384626433832795029
+CFLAGS += -DM_LN2=0.6931471805599453094172321214581765
+CFLAGS += -DM_PI_2=1.5707963267948966192313216916397514
+CFLAGS += -DM_2_PI=0.6366197723675813430755350534900574
+
+
+CSRCS = $(LIQUID_DSP_UNPACK)/src/agc/src/agc_crcf.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/agc/src/agc_rrrf.c
+
+CSRCS += $(LIQUID_DSP_UNPACK)/src/audio/src/cvsd.c
+
+CSRCS += $(LIQUID_DSP_UNPACK)/src/buffer/src/bufferf.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/buffer/src/buffercf.c
+
+CSRCS += $(LIQUID_DSP_UNPACK)/src/channel/src/channel_cccf.c
+
+CSRCS += $(LIQUID_DSP_UNPACK)/src/dotprod/src/dotprod_cccf.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/dotprod/src/dotprod_crcf.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/dotprod/src/dotprod_rrrf.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/dotprod/src/sumsq.c
+
+CSRCS += $(LIQUID_DSP_UNPACK)/src/equalization/src/equalizer_cccf.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/equalization/src/equalizer_rrrf.c
+
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/crc.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec_conv.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec_conv_poly.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec_conv_pmatrix.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec_conv_punctured.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec_golay2412.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec_hamming74.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec_hamming84.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec_hamming128.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec_hamming1511.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec_hamming3126.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec_hamming128_gentab.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec_pass.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec_rep3.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec_rep5.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec_rs.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec_secded2216.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec_secded3932.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec_secded7264.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/interleaver.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/packetizer.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/sumproduct.c
+
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fft/src/fftf.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fft/src/spgramcf.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fft/src/spgramf.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fft/src/fft_utilities.c
+
+CSRCS += $(LIQUID_DSP_UNPACK)/src/filter/src/bessel.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/filter/src/butter.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/filter/src/cheby1.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/filter/src/cheby2.c
+CSRCS += $(LIQUID_DSP_UNPACK)/s

[GitHub] [nuttx] masayuki2009 opened a new pull request, #8733: boards: stm32f4discovery: Update kostest/defconfig to avoid crash

2023-03-06 Thread via GitHub


masayuki2009 opened a new pull request, #8733:
URL: https://github.com/apache/nuttx/pull/8733

   ## Summary
   
   - I noticed that recent mm_heap changes causes a crash with 
stm32f4discovery:kostest
   - This is a tentative solution to avoid the crash
   
   ## Impact
   
   - None
   
   ## Testing
   
   - Tested with stm32f4discovery board
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx-apps] xiaoxiang781216 commented on a diff in pull request #1624: Adding sdr group with liquid-dsp library

2023-03-06 Thread via GitHub


xiaoxiang781216 commented on code in PR #1624:
URL: https://github.com/apache/nuttx-apps/pull/1624#discussion_r1126062573


##
sdr/liquid_dsp/Makefile:
##
@@ -0,0 +1,247 @@
+###
+# apps/sdr/liquid_dsp/Makefile
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.  The
+# ASF licenses this file to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance with the
+# License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
+# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.  See the
+# License for the specific language governing permissions and limitations
+# under the License.
+#
+/
+
+include $(APPDIR)/Make.defs
+
+LIQUID_DSP_VERSION  = 1.4.0
+LIQUID_DSP_UNPACK   = liquid-dsp
+LIQUID_DSP_TARBALL  = v$(LIQUID_DSP_VERSION).tar.gz
+LIQUID_DSP_URL_BASE = https://github.com/jgaeddert/liquid-dsp/archive
+LIQUID_DSP_URL  = $(LIQUID_DSP_URL_BASE)/$(LIQUID_DSP_TARBALL)
+
+$(LIQUID_DSP_TARBALL):
+   $(Q) echo "Downloading $(LIQUID_DSP_TARBALL)"
+   $(Q) curl -O -L $(LIQUID_DSP_URL)
+
+$(LIQUID_DSP_UNPACK): $(LIQUID_DSP_TARBALL)
+   $(Q) echo "Unpacking $(LIQUID_DSP_TARBALL) to $(LIQUID_DSP_UNPACK)"
+   $(Q) tar xzvf $(LIQUID_DSP_TARBALL)
+   $(Q) mv liquid-dsp-$(LIQUID_DSP_VERSION) $(LIQUID_DSP_UNPACK)
+   $(Q) cp config.h $(LIQUID_DSP_UNPACK)/include
+
+$(LIQUID_DSP_UNPACK)/.patch: $(LIQUID_DSP_UNPACK)
+   $(Q) touch $(LIQUID_DSP_UNPACK)/.patch
+
+VPATH += $(LIBUV_UNPACK)/include
+
+DEPPATH += --dep-path $(LIBUV_UNPACK)/include
+
+CFLAGS += -I$(LIQUID_DSP_UNPACK)/include
+CFLAGS += -Wall -std=c99
+CFLAGS += -DM_SQRT1_2=0.7071067811865475244008443621048490
+CFLAGS += -DM_SQRT2=1.4142135623730950488016887242096981
+CFLAGS += -DM_PI=3.1415926535897932384626433832795029
+CFLAGS += -DM_LN2=0.6931471805599453094172321214581765
+CFLAGS += -DM_PI_2=1.5707963267948966192313216916397514
+CFLAGS += -DM_2_PI=0.6366197723675813430755350534900574
+
+
+CSRCS = $(LIQUID_DSP_UNPACK)/src/agc/src/agc_crcf.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/agc/src/agc_rrrf.c
+
+CSRCS += $(LIQUID_DSP_UNPACK)/src/audio/src/cvsd.c
+
+CSRCS += $(LIQUID_DSP_UNPACK)/src/buffer/src/bufferf.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/buffer/src/buffercf.c
+
+CSRCS += $(LIQUID_DSP_UNPACK)/src/channel/src/channel_cccf.c
+
+CSRCS += $(LIQUID_DSP_UNPACK)/src/dotprod/src/dotprod_cccf.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/dotprod/src/dotprod_crcf.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/dotprod/src/dotprod_rrrf.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/dotprod/src/sumsq.c
+
+CSRCS += $(LIQUID_DSP_UNPACK)/src/equalization/src/equalizer_cccf.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/equalization/src/equalizer_rrrf.c
+
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/crc.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec_conv.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec_conv_poly.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec_conv_pmatrix.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec_conv_punctured.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec_golay2412.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec_hamming74.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec_hamming84.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec_hamming128.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec_hamming1511.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec_hamming3126.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec_hamming128_gentab.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec_pass.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec_rep3.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec_rep5.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec_rs.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec_secded2216.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec_secded3932.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec_secded7264.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/interleaver.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/packetizer.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/sumproduct.c
+
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fft/src/fftf.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fft/src/spgramcf.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fft/src/spgramf.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fft/src/fft_utilities.c
+
+CSRCS += $(LIQUID_DSP_UNPACK)/src/filter/src/bessel.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/filter/src/butter.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/filter/src/cheby1.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/filter/src/cheby2.c
+CSRCS += $(LIQUID_DSP_UN

[GitHub] [nuttx] xiaoxiang781216 commented on pull request #8733: boards: stm32f4discovery: Update kostest/defconfig to avoid crash

2023-03-06 Thread via GitHub


xiaoxiang781216 commented on PR #8733:
URL: https://github.com/apache/nuttx/pull/8733#issuecomment-1455679806

   @masayuki2009 which option does really fix the crash?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx-apps] xiaoxiang781216 commented on a diff in pull request #1624: Adding sdr group with liquid-dsp library

2023-03-06 Thread via GitHub


xiaoxiang781216 commented on code in PR #1624:
URL: https://github.com/apache/nuttx-apps/pull/1624#discussion_r1126069412


##
sdr/liquid_dsp/Makefile:
##
@@ -0,0 +1,247 @@
+###
+# apps/sdr/liquid_dsp/Makefile
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.  The
+# ASF licenses this file to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance with the
+# License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
+# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.  See the
+# License for the specific language governing permissions and limitations
+# under the License.
+#
+/
+
+include $(APPDIR)/Make.defs
+
+LIQUID_DSP_VERSION  = 1.4.0
+LIQUID_DSP_UNPACK   = liquid-dsp
+LIQUID_DSP_TARBALL  = v$(LIQUID_DSP_VERSION).tar.gz
+LIQUID_DSP_URL_BASE = https://github.com/jgaeddert/liquid-dsp/archive
+LIQUID_DSP_URL  = $(LIQUID_DSP_URL_BASE)/$(LIQUID_DSP_TARBALL)
+
+$(LIQUID_DSP_TARBALL):
+   $(Q) echo "Downloading $(LIQUID_DSP_TARBALL)"
+   $(Q) curl -O -L $(LIQUID_DSP_URL)
+
+$(LIQUID_DSP_UNPACK): $(LIQUID_DSP_TARBALL)
+   $(Q) echo "Unpacking $(LIQUID_DSP_TARBALL) to $(LIQUID_DSP_UNPACK)"
+   $(Q) tar xzvf $(LIQUID_DSP_TARBALL)
+   $(Q) mv liquid-dsp-$(LIQUID_DSP_VERSION) $(LIQUID_DSP_UNPACK)
+   $(Q) cp config.h $(LIQUID_DSP_UNPACK)/include
+
+$(LIQUID_DSP_UNPACK)/.patch: $(LIQUID_DSP_UNPACK)
+   $(Q) touch $(LIQUID_DSP_UNPACK)/.patch
+
+VPATH += $(LIBUV_UNPACK)/include
+
+DEPPATH += --dep-path $(LIBUV_UNPACK)/include
+
+CFLAGS += -I$(LIQUID_DSP_UNPACK)/include
+CFLAGS += -Wall -std=c99
+CFLAGS += -DM_SQRT1_2=0.7071067811865475244008443621048490
+CFLAGS += -DM_SQRT2=1.4142135623730950488016887242096981
+CFLAGS += -DM_PI=3.1415926535897932384626433832795029
+CFLAGS += -DM_LN2=0.6931471805599453094172321214581765
+CFLAGS += -DM_PI_2=1.5707963267948966192313216916397514
+CFLAGS += -DM_2_PI=0.6366197723675813430755350534900574

Review Comment:
   When does the campaign start?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx-apps] xiaoxiang781216 commented on a diff in pull request #1624: Adding sdr group with liquid-dsp library

2023-03-06 Thread via GitHub


xiaoxiang781216 commented on code in PR #1624:
URL: https://github.com/apache/nuttx-apps/pull/1624#discussion_r1126069412


##
sdr/liquid_dsp/Makefile:
##
@@ -0,0 +1,247 @@
+###
+# apps/sdr/liquid_dsp/Makefile
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.  The
+# ASF licenses this file to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance with the
+# License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
+# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.  See the
+# License for the specific language governing permissions and limitations
+# under the License.
+#
+/
+
+include $(APPDIR)/Make.defs
+
+LIQUID_DSP_VERSION  = 1.4.0
+LIQUID_DSP_UNPACK   = liquid-dsp
+LIQUID_DSP_TARBALL  = v$(LIQUID_DSP_VERSION).tar.gz
+LIQUID_DSP_URL_BASE = https://github.com/jgaeddert/liquid-dsp/archive
+LIQUID_DSP_URL  = $(LIQUID_DSP_URL_BASE)/$(LIQUID_DSP_TARBALL)
+
+$(LIQUID_DSP_TARBALL):
+   $(Q) echo "Downloading $(LIQUID_DSP_TARBALL)"
+   $(Q) curl -O -L $(LIQUID_DSP_URL)
+
+$(LIQUID_DSP_UNPACK): $(LIQUID_DSP_TARBALL)
+   $(Q) echo "Unpacking $(LIQUID_DSP_TARBALL) to $(LIQUID_DSP_UNPACK)"
+   $(Q) tar xzvf $(LIQUID_DSP_TARBALL)
+   $(Q) mv liquid-dsp-$(LIQUID_DSP_VERSION) $(LIQUID_DSP_UNPACK)
+   $(Q) cp config.h $(LIQUID_DSP_UNPACK)/include
+
+$(LIQUID_DSP_UNPACK)/.patch: $(LIQUID_DSP_UNPACK)
+   $(Q) touch $(LIQUID_DSP_UNPACK)/.patch
+
+VPATH += $(LIBUV_UNPACK)/include
+
+DEPPATH += --dep-path $(LIBUV_UNPACK)/include
+
+CFLAGS += -I$(LIQUID_DSP_UNPACK)/include
+CFLAGS += -Wall -std=c99
+CFLAGS += -DM_SQRT1_2=0.7071067811865475244008443621048490
+CFLAGS += -DM_SQRT2=1.4142135623730950488016887242096981
+CFLAGS += -DM_PI=3.1415926535897932384626433832795029
+CFLAGS += -DM_LN2=0.6931471805599453094172321214581765
+CFLAGS += -DM_PI_2=1.5707963267948966192313216916397514
+CFLAGS += -DM_2_PI=0.6366197723675813430755350534900574

Review Comment:
   > > Do you have a workable LuaJIT? it's very great if you can upstream the 
porting.
   > 
   > Yes, I have a working version, but not without some changes in NuttX. I 
still need to fix that first. One of problems is a new UNUSED macro in NuttX, 
which is giving me problems with LuaJIT code. The old version of UNUSED macro 
was fine, but then someone changed it.
   
   Sorry, it's changed by me, let's see how to make it work with LuaJIT.
   
   > I am planning to release LuaJIT support when EdgePro1 campaign will start.
   
   When does the campaign start?
   
   



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx-apps] xiaoxiang781216 commented on a diff in pull request #1624: Adding sdr group with liquid-dsp library

2023-03-06 Thread via GitHub


xiaoxiang781216 commented on code in PR #1624:
URL: https://github.com/apache/nuttx-apps/pull/1624#discussion_r1126069412


##
sdr/liquid_dsp/Makefile:
##
@@ -0,0 +1,247 @@
+###
+# apps/sdr/liquid_dsp/Makefile
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.  The
+# ASF licenses this file to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance with the
+# License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
+# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.  See the
+# License for the specific language governing permissions and limitations
+# under the License.
+#
+/
+
+include $(APPDIR)/Make.defs
+
+LIQUID_DSP_VERSION  = 1.4.0
+LIQUID_DSP_UNPACK   = liquid-dsp
+LIQUID_DSP_TARBALL  = v$(LIQUID_DSP_VERSION).tar.gz
+LIQUID_DSP_URL_BASE = https://github.com/jgaeddert/liquid-dsp/archive
+LIQUID_DSP_URL  = $(LIQUID_DSP_URL_BASE)/$(LIQUID_DSP_TARBALL)
+
+$(LIQUID_DSP_TARBALL):
+   $(Q) echo "Downloading $(LIQUID_DSP_TARBALL)"
+   $(Q) curl -O -L $(LIQUID_DSP_URL)
+
+$(LIQUID_DSP_UNPACK): $(LIQUID_DSP_TARBALL)
+   $(Q) echo "Unpacking $(LIQUID_DSP_TARBALL) to $(LIQUID_DSP_UNPACK)"
+   $(Q) tar xzvf $(LIQUID_DSP_TARBALL)
+   $(Q) mv liquid-dsp-$(LIQUID_DSP_VERSION) $(LIQUID_DSP_UNPACK)
+   $(Q) cp config.h $(LIQUID_DSP_UNPACK)/include
+
+$(LIQUID_DSP_UNPACK)/.patch: $(LIQUID_DSP_UNPACK)
+   $(Q) touch $(LIQUID_DSP_UNPACK)/.patch
+
+VPATH += $(LIBUV_UNPACK)/include
+
+DEPPATH += --dep-path $(LIBUV_UNPACK)/include
+
+CFLAGS += -I$(LIQUID_DSP_UNPACK)/include
+CFLAGS += -Wall -std=c99
+CFLAGS += -DM_SQRT1_2=0.7071067811865475244008443621048490
+CFLAGS += -DM_SQRT2=1.4142135623730950488016887242096981
+CFLAGS += -DM_PI=3.1415926535897932384626433832795029
+CFLAGS += -DM_LN2=0.6931471805599453094172321214581765
+CFLAGS += -DM_PI_2=1.5707963267948966192313216916397514
+CFLAGS += -DM_2_PI=0.6366197723675813430755350534900574

Review Comment:
   > > Do you have a workable LuaJIT? it's very great if you can upstream the 
porting.
   > 
   > Yes, I have a working version, but not without some changes in NuttX. I 
still need to fix that first. One of problems is a new UNUSED macro in NuttX, 
which is giving me problems with LuaJIT code. The old version of UNUSED macro 
was fine, but then someone changed it.
   
   Sorry, it's changed by me, let's see how to make it work with LuaJIT. Once 
we fix the problem, let's enable LuaJIT in CI to catch the potential break 
before merging the patch.
   
   > I am planning to release LuaJIT support when EdgePro1 campaign will start.
   
   When does the campaign start?
   
   



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx-apps] jturnsek commented on a diff in pull request #1624: Adding sdr group with liquid-dsp library

2023-03-06 Thread via GitHub


jturnsek commented on code in PR #1624:
URL: https://github.com/apache/nuttx-apps/pull/1624#discussion_r1126075736


##
sdr/liquid_dsp/Makefile:
##
@@ -0,0 +1,247 @@
+###
+# apps/sdr/liquid_dsp/Makefile
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.  The
+# ASF licenses this file to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance with the
+# License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
+# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.  See the
+# License for the specific language governing permissions and limitations
+# under the License.
+#
+/
+
+include $(APPDIR)/Make.defs
+
+LIQUID_DSP_VERSION  = 1.4.0
+LIQUID_DSP_UNPACK   = liquid-dsp
+LIQUID_DSP_TARBALL  = v$(LIQUID_DSP_VERSION).tar.gz
+LIQUID_DSP_URL_BASE = https://github.com/jgaeddert/liquid-dsp/archive
+LIQUID_DSP_URL  = $(LIQUID_DSP_URL_BASE)/$(LIQUID_DSP_TARBALL)
+
+$(LIQUID_DSP_TARBALL):
+   $(Q) echo "Downloading $(LIQUID_DSP_TARBALL)"
+   $(Q) curl -O -L $(LIQUID_DSP_URL)
+
+$(LIQUID_DSP_UNPACK): $(LIQUID_DSP_TARBALL)
+   $(Q) echo "Unpacking $(LIQUID_DSP_TARBALL) to $(LIQUID_DSP_UNPACK)"
+   $(Q) tar xzvf $(LIQUID_DSP_TARBALL)
+   $(Q) mv liquid-dsp-$(LIQUID_DSP_VERSION) $(LIQUID_DSP_UNPACK)
+   $(Q) cp config.h $(LIQUID_DSP_UNPACK)/include
+
+$(LIQUID_DSP_UNPACK)/.patch: $(LIQUID_DSP_UNPACK)
+   $(Q) touch $(LIQUID_DSP_UNPACK)/.patch
+
+VPATH += $(LIBUV_UNPACK)/include
+
+DEPPATH += --dep-path $(LIBUV_UNPACK)/include
+
+CFLAGS += -I$(LIQUID_DSP_UNPACK)/include
+CFLAGS += -Wall -std=c99
+CFLAGS += -DM_SQRT1_2=0.7071067811865475244008443621048490
+CFLAGS += -DM_SQRT2=1.4142135623730950488016887242096981
+CFLAGS += -DM_PI=3.1415926535897932384626433832795029
+CFLAGS += -DM_LN2=0.6931471805599453094172321214581765
+CFLAGS += -DM_PI_2=1.5707963267948966192313216916397514
+CFLAGS += -DM_2_PI=0.6366197723675813430755350534900574
+
+
+CSRCS = $(LIQUID_DSP_UNPACK)/src/agc/src/agc_crcf.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/agc/src/agc_rrrf.c
+
+CSRCS += $(LIQUID_DSP_UNPACK)/src/audio/src/cvsd.c
+
+CSRCS += $(LIQUID_DSP_UNPACK)/src/buffer/src/bufferf.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/buffer/src/buffercf.c
+
+CSRCS += $(LIQUID_DSP_UNPACK)/src/channel/src/channel_cccf.c
+
+CSRCS += $(LIQUID_DSP_UNPACK)/src/dotprod/src/dotprod_cccf.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/dotprod/src/dotprod_crcf.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/dotprod/src/dotprod_rrrf.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/dotprod/src/sumsq.c
+
+CSRCS += $(LIQUID_DSP_UNPACK)/src/equalization/src/equalizer_cccf.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/equalization/src/equalizer_rrrf.c
+
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/crc.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec_conv.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec_conv_poly.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec_conv_pmatrix.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec_conv_punctured.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec_golay2412.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec_hamming74.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec_hamming84.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec_hamming128.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec_hamming1511.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec_hamming3126.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec_hamming128_gentab.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec_pass.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec_rep3.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec_rep5.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec_rs.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec_secded2216.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec_secded3932.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/fec_secded7264.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/interleaver.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/packetizer.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fec/src/sumproduct.c
+
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fft/src/fftf.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fft/src/spgramcf.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fft/src/spgramf.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/fft/src/fft_utilities.c
+
+CSRCS += $(LIQUID_DSP_UNPACK)/src/filter/src/bessel.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/filter/src/butter.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/filter/src/cheby1.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/filter/src/cheby2.c
+CSRCS += $(LIQUID_DSP_UNPACK)/s

[GitHub] [nuttx] xiaoxiang781216 commented on issue #8731: ESP32C3 risc-v usb-serial not working correctly

2023-03-06 Thread via GitHub


xiaoxiang781216 commented on issue #8731:
URL: https://github.com/apache/nuttx/issues/8731#issuecomment-1455696651

   Can you rebase both nuttx and apps to the last master?  Especially, the 
change come from @no1wudi :
   https://github.com/apache/nuttx/pulls?q=is%3Apr+author%3Ano1wudi
   https://github.com/apache/nuttx-apps/pulls?q=is%3Apr+author%3Ano1wudi
   Some change recently need both side work together.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] CV-Bowen opened a new pull request, #8734: mm_heap: double malloced memory default alignment (4 -> 8, 8 -> 16)

2023-03-06 Thread via GitHub


CV-Bowen opened a new pull request, #8734:
URL: https://github.com/apache/nuttx/pull/8734

   ## Summary
   Base on the gnu libc standard:
   https://www.gnu.org/software/libc/manual/html_node/Aligned-Memory-Blocks.html
   
   Change the default memory aligment to 8 bytes for 32-bit system and 16 bytes 
for 64-bit system.
   
   This PR fix the issue (qemu-intel64:ostest can not boot) mentioned in 
https://github.com/apache/nuttx/pull/8721
   
   ## Impact
   Memory Manager
   
   ## Testing
   qemu-intel64:ostest and sim ostest mm_test pass
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] CV-Bowen commented on pull request #8721: mm_heap: support custom the mm alignment and default to be 8

2023-03-06 Thread via GitHub


CV-Bowen commented on PR #8721:
URL: https://github.com/apache/nuttx/pull/8721#issuecomment-1455699169

   > > Seems related to the default mm alignment, after I change the default 
alignment to 16, qemu-intel64:ostest can boot.
   > 
   > @CV-Bowen Please create a new PR to fix the issue for x86_64.
   
   Done, https://github.com/apache/nuttx/pull/8734


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx-apps] jturnsek commented on a diff in pull request #1624: Adding sdr group with liquid-dsp library

2023-03-06 Thread via GitHub


jturnsek commented on code in PR #1624:
URL: https://github.com/apache/nuttx-apps/pull/1624#discussion_r1126082419


##
sdr/liquid_dsp/Makefile:
##
@@ -0,0 +1,247 @@
+###
+# apps/sdr/liquid_dsp/Makefile
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.  The
+# ASF licenses this file to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance with the
+# License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
+# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.  See the
+# License for the specific language governing permissions and limitations
+# under the License.
+#
+/
+
+include $(APPDIR)/Make.defs
+
+LIQUID_DSP_VERSION  = 1.4.0
+LIQUID_DSP_UNPACK   = liquid-dsp
+LIQUID_DSP_TARBALL  = v$(LIQUID_DSP_VERSION).tar.gz
+LIQUID_DSP_URL_BASE = https://github.com/jgaeddert/liquid-dsp/archive
+LIQUID_DSP_URL  = $(LIQUID_DSP_URL_BASE)/$(LIQUID_DSP_TARBALL)
+
+$(LIQUID_DSP_TARBALL):
+   $(Q) echo "Downloading $(LIQUID_DSP_TARBALL)"
+   $(Q) curl -O -L $(LIQUID_DSP_URL)
+
+$(LIQUID_DSP_UNPACK): $(LIQUID_DSP_TARBALL)
+   $(Q) echo "Unpacking $(LIQUID_DSP_TARBALL) to $(LIQUID_DSP_UNPACK)"
+   $(Q) tar xzvf $(LIQUID_DSP_TARBALL)
+   $(Q) mv liquid-dsp-$(LIQUID_DSP_VERSION) $(LIQUID_DSP_UNPACK)
+   $(Q) cp config.h $(LIQUID_DSP_UNPACK)/include
+
+$(LIQUID_DSP_UNPACK)/.patch: $(LIQUID_DSP_UNPACK)
+   $(Q) touch $(LIQUID_DSP_UNPACK)/.patch
+
+VPATH += $(LIBUV_UNPACK)/include
+
+DEPPATH += --dep-path $(LIBUV_UNPACK)/include
+
+CFLAGS += -I$(LIQUID_DSP_UNPACK)/include
+CFLAGS += -Wall -std=c99
+CFLAGS += -DM_SQRT1_2=0.7071067811865475244008443621048490
+CFLAGS += -DM_SQRT2=1.4142135623730950488016887242096981
+CFLAGS += -DM_PI=3.1415926535897932384626433832795029
+CFLAGS += -DM_LN2=0.6931471805599453094172321214581765
+CFLAGS += -DM_PI_2=1.5707963267948966192313216916397514
+CFLAGS += -DM_2_PI=0.6366197723675813430755350534900574

Review Comment:
   I hope it will start soon. It si quite some administrative work to do before 
launch. Will see if I can release LuaJIT prior to campign launch?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] no1wudi commented on issue #8719: Xtensa_user_panic when trying to ping from nsh console in a telnet session

2023-03-06 Thread via GitHub


no1wudi commented on issue #8719:
URL: https://github.com/apache/nuttx/issues/8719#issuecomment-1455701788

   I meet the same issue from rv-virt:
   ```
   NuttShell (NSH) NuttX-12.0.0
   nsh> [9.85] [CPU1] ubsan_prologue: 

   [9.86] [CPU1] ubsan_prologue: UBSAN: misaligned-access in 
netdev/netdev_ioctl.c:1250:12
   [9.86] [CPU1] handle_misaligned_access: member access within 
misaligned address 0x9 for type 'struct arpreq'
   [9.86] [CPU1] handle_misaligned_access: which requires 2 byte 
alignment
   [9.86] [CPU1] ubsan_epilogue: 

   [9.87] [CPU1] ubsan_prologue: 

   [9.88] [CPU1] ubsan_prologue: UBSAN: misaligned-access in 
netdev/netdev_ioctl.c:1251:26
   [9.88] [CPU1] handle_misaligned_access: member access within 
misaligned address 0x9 for type 'struct arpreq'
   [9.90] [CPU1] handle_misaligned_access: which requires 2 byte 
alignment
   [9.90] [CPU1] ubsan_epilogue: 

   [9.93] [CPU1] riscv_exception: EXCEPTION: Load access fault. MCAUSE: 
0005, EPC: 80045450, MTVAL: 003a
   [9.94] [CPU1] riscv_exception: PANIC!!! Exception = 0005
   [9.94] [CPU1] _assert: Current Version: NuttX  12.0.0 
88cac02e09-dirty Mar  6 2023 16:29:33 risc-v
   [9.95] [CPU1] _assert: Assertion failed panic: at file: 
common/riscv_exception.c:85 task(CPU1): Telnet session 0x8002a9be
   [9.96] [CPU1] up_dump_register: EPC: 80045450
   [9.97] [CPU1] up_dump_register: A0: 0016 A1: 0076 A2: 
800be414 A3: 0053
   [9.98] [CPU1] up_dump_register: A4: 000a A5: ffcf A6: 
a000 A7: a000
   [9.99] [CPU1] up_dump_register: T0:  T1: 1000 T2: 
 T3: 
   [9.99] [CPU1] up_dump_register: T4:  T5:  T6: 

   [   10.00] [CPU1] up_dump_register: S0: 0009 S1: 003a S2: 
0118 S3: 800b2650
   [   10.00] [CPU1] up_dump_register: S4:  S5: 8008b150 S6: 
80017ae6 S7: 
   [   10.02] [CPU1] up_dump_register: S8: 80134824 S9:  S10: 
800b47e8 S11: 800b9564
   [   10.03] [CPU1] up_dump_register: SP: 80134610 FP: 0009 TP: 
 RA: 80045434
   [   10.03] [CPU1] dump_stack: IRQ Stack:
   [   10.04] [CPU1] dump_stack: sp: 0x8010e250
   [   10.04] [CPU1] dump_stack:   base: 0x8010cbc0
   [   10.04] [CPU1] dump_stack:   size: 2048
   [   10.05] [CPU1] dump_stack: ERROR: IRQ Stack pointer is not within the 
stack
   [   10.05] [CPU1] dump_stack: User Stack:
   [   10.06] [CPU1] dump_stack: sp: 0x80134610
   [   10.06] [CPU1] dump_stack:   base: 0x80133d60
   [   10.07] [CPU1] dump_stack:   size: 3008
   ```
   It seems relative to arp (netdev_arp_ioctl), the req is a invalid pointer 
with value (0x9) on riscv.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx-apps] jturnsek commented on a diff in pull request #1624: Adding sdr group with liquid-dsp library

2023-03-06 Thread via GitHub


jturnsek commented on code in PR #1624:
URL: https://github.com/apache/nuttx-apps/pull/1624#discussion_r1126083925


##
sdr/liquid_dsp/Makefile:
##
@@ -0,0 +1,247 @@
+###
+# apps/sdr/liquid_dsp/Makefile
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.  The
+# ASF licenses this file to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance with the
+# License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
+# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.  See the
+# License for the specific language governing permissions and limitations
+# under the License.
+#
+/
+
+include $(APPDIR)/Make.defs
+
+LIQUID_DSP_VERSION  = 1.4.0
+LIQUID_DSP_UNPACK   = liquid-dsp
+LIQUID_DSP_TARBALL  = v$(LIQUID_DSP_VERSION).tar.gz
+LIQUID_DSP_URL_BASE = https://github.com/jgaeddert/liquid-dsp/archive
+LIQUID_DSP_URL  = $(LIQUID_DSP_URL_BASE)/$(LIQUID_DSP_TARBALL)
+
+$(LIQUID_DSP_TARBALL):
+   $(Q) echo "Downloading $(LIQUID_DSP_TARBALL)"
+   $(Q) curl -O -L $(LIQUID_DSP_URL)
+
+$(LIQUID_DSP_UNPACK): $(LIQUID_DSP_TARBALL)
+   $(Q) echo "Unpacking $(LIQUID_DSP_TARBALL) to $(LIQUID_DSP_UNPACK)"
+   $(Q) tar xzvf $(LIQUID_DSP_TARBALL)
+   $(Q) mv liquid-dsp-$(LIQUID_DSP_VERSION) $(LIQUID_DSP_UNPACK)
+   $(Q) cp config.h $(LIQUID_DSP_UNPACK)/include
+
+$(LIQUID_DSP_UNPACK)/.patch: $(LIQUID_DSP_UNPACK)
+   $(Q) touch $(LIQUID_DSP_UNPACK)/.patch
+
+VPATH += $(LIBUV_UNPACK)/include
+
+DEPPATH += --dep-path $(LIBUV_UNPACK)/include
+
+CFLAGS += -I$(LIQUID_DSP_UNPACK)/include
+CFLAGS += -Wall -std=c99
+CFLAGS += -DM_SQRT1_2=0.7071067811865475244008443621048490
+CFLAGS += -DM_SQRT2=1.4142135623730950488016887242096981
+CFLAGS += -DM_PI=3.1415926535897932384626433832795029
+CFLAGS += -DM_LN2=0.6931471805599453094172321214581765
+CFLAGS += -DM_PI_2=1.5707963267948966192313216916397514
+CFLAGS += -DM_2_PI=0.6366197723675813430755350534900574

Review Comment:
   > so these macro doesn't exist in toolchain's libm?
   
   They should be, but if I remove the definitions from my Makefile, i am 
getting those undefined errors. Maybe you can take a look at it?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx-apps] jturnsek commented on a diff in pull request #1624: Adding sdr group with liquid-dsp library

2023-03-06 Thread via GitHub


jturnsek commented on code in PR #1624:
URL: https://github.com/apache/nuttx-apps/pull/1624#discussion_r1126086235


##
sdr/liquid_dsp/Makefile:
##
@@ -0,0 +1,247 @@
+###
+# apps/sdr/liquid_dsp/Makefile
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.  The
+# ASF licenses this file to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance with the
+# License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
+# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.  See the
+# License for the specific language governing permissions and limitations
+# under the License.
+#
+/
+
+include $(APPDIR)/Make.defs
+
+LIQUID_DSP_VERSION  = 1.4.0
+LIQUID_DSP_UNPACK   = liquid-dsp
+LIQUID_DSP_TARBALL  = v$(LIQUID_DSP_VERSION).tar.gz
+LIQUID_DSP_URL_BASE = https://github.com/jgaeddert/liquid-dsp/archive
+LIQUID_DSP_URL  = $(LIQUID_DSP_URL_BASE)/$(LIQUID_DSP_TARBALL)
+
+$(LIQUID_DSP_TARBALL):
+   $(Q) echo "Downloading $(LIQUID_DSP_TARBALL)"
+   $(Q) curl -O -L $(LIQUID_DSP_URL)
+
+$(LIQUID_DSP_UNPACK): $(LIQUID_DSP_TARBALL)
+   $(Q) echo "Unpacking $(LIQUID_DSP_TARBALL) to $(LIQUID_DSP_UNPACK)"
+   $(Q) tar xzvf $(LIQUID_DSP_TARBALL)
+   $(Q) mv liquid-dsp-$(LIQUID_DSP_VERSION) $(LIQUID_DSP_UNPACK)
+   $(Q) cp config.h $(LIQUID_DSP_UNPACK)/include
+
+$(LIQUID_DSP_UNPACK)/.patch: $(LIQUID_DSP_UNPACK)
+   $(Q) touch $(LIQUID_DSP_UNPACK)/.patch
+
+VPATH += $(LIBUV_UNPACK)/include
+
+DEPPATH += --dep-path $(LIBUV_UNPACK)/include
+
+CFLAGS += -I$(LIQUID_DSP_UNPACK)/include
+CFLAGS += -Wall -std=c99
+CFLAGS += -DM_SQRT1_2=0.7071067811865475244008443621048490
+CFLAGS += -DM_SQRT2=1.4142135623730950488016887242096981
+CFLAGS += -DM_PI=3.1415926535897932384626433832795029
+CFLAGS += -DM_LN2=0.6931471805599453094172321214581765
+CFLAGS += -DM_PI_2=1.5707963267948966192313216916397514
+CFLAGS += -DM_2_PI=0.6366197723675813430755350534900574

Review Comment:
   > Sorry, it's changed by me, let's see how to make it work with LuaJIT. Once 
we fix the problem, let's enable LuaJIT in CI to catch the potential break 
before merging the patch.
   
   Let me open PR in the near future and maybe we can work together to bring 
LuaJIT to life. I am also relying on some archiutecture specific stuff in my 
port, i.e. ITCM memory heap for JIT traces, because I am running LuaJIT on i.MX 
RT1064.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx-apps] jturnsek commented on a diff in pull request #1624: Adding sdr group with liquid-dsp library

2023-03-06 Thread via GitHub


jturnsek commented on code in PR #1624:
URL: https://github.com/apache/nuttx-apps/pull/1624#discussion_r1126086235


##
sdr/liquid_dsp/Makefile:
##
@@ -0,0 +1,247 @@
+###
+# apps/sdr/liquid_dsp/Makefile
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.  The
+# ASF licenses this file to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance with the
+# License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
+# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.  See the
+# License for the specific language governing permissions and limitations
+# under the License.
+#
+/
+
+include $(APPDIR)/Make.defs
+
+LIQUID_DSP_VERSION  = 1.4.0
+LIQUID_DSP_UNPACK   = liquid-dsp
+LIQUID_DSP_TARBALL  = v$(LIQUID_DSP_VERSION).tar.gz
+LIQUID_DSP_URL_BASE = https://github.com/jgaeddert/liquid-dsp/archive
+LIQUID_DSP_URL  = $(LIQUID_DSP_URL_BASE)/$(LIQUID_DSP_TARBALL)
+
+$(LIQUID_DSP_TARBALL):
+   $(Q) echo "Downloading $(LIQUID_DSP_TARBALL)"
+   $(Q) curl -O -L $(LIQUID_DSP_URL)
+
+$(LIQUID_DSP_UNPACK): $(LIQUID_DSP_TARBALL)
+   $(Q) echo "Unpacking $(LIQUID_DSP_TARBALL) to $(LIQUID_DSP_UNPACK)"
+   $(Q) tar xzvf $(LIQUID_DSP_TARBALL)
+   $(Q) mv liquid-dsp-$(LIQUID_DSP_VERSION) $(LIQUID_DSP_UNPACK)
+   $(Q) cp config.h $(LIQUID_DSP_UNPACK)/include
+
+$(LIQUID_DSP_UNPACK)/.patch: $(LIQUID_DSP_UNPACK)
+   $(Q) touch $(LIQUID_DSP_UNPACK)/.patch
+
+VPATH += $(LIBUV_UNPACK)/include
+
+DEPPATH += --dep-path $(LIBUV_UNPACK)/include
+
+CFLAGS += -I$(LIQUID_DSP_UNPACK)/include
+CFLAGS += -Wall -std=c99
+CFLAGS += -DM_SQRT1_2=0.7071067811865475244008443621048490
+CFLAGS += -DM_SQRT2=1.4142135623730950488016887242096981
+CFLAGS += -DM_PI=3.1415926535897932384626433832795029
+CFLAGS += -DM_LN2=0.6931471805599453094172321214581765
+CFLAGS += -DM_PI_2=1.5707963267948966192313216916397514
+CFLAGS += -DM_2_PI=0.6366197723675813430755350534900574

Review Comment:
   > Sorry, it's changed by me, let's see how to make it work with LuaJIT. Once 
we fix the problem, let's enable LuaJIT in CI to catch the potential break 
before merging the patch.
   
   Let me open PR in the near future and maybe we can work together to bring 
LuaJIT to life. I am also relying on some archiutecture specific stuff in my 
port, i.e. ITCM memory heap for JIT traces, because I am running LuaJIT on i.MX 
RT1064. I am afraid that Cortex M7 is a must.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx-apps] xiaoxiang781216 commented on a diff in pull request #1624: Adding sdr group with liquid-dsp library

2023-03-06 Thread via GitHub


xiaoxiang781216 commented on code in PR #1624:
URL: https://github.com/apache/nuttx-apps/pull/1624#discussion_r1126094153


##
sdr/liquid_dsp/Makefile:
##
@@ -0,0 +1,247 @@
+###
+# apps/sdr/liquid_dsp/Makefile
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.  The
+# ASF licenses this file to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance with the
+# License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
+# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.  See the
+# License for the specific language governing permissions and limitations
+# under the License.
+#
+/
+
+include $(APPDIR)/Make.defs
+
+LIQUID_DSP_VERSION  = 1.4.0
+LIQUID_DSP_UNPACK   = liquid-dsp
+LIQUID_DSP_TARBALL  = v$(LIQUID_DSP_VERSION).tar.gz
+LIQUID_DSP_URL_BASE = https://github.com/jgaeddert/liquid-dsp/archive
+LIQUID_DSP_URL  = $(LIQUID_DSP_URL_BASE)/$(LIQUID_DSP_TARBALL)
+
+$(LIQUID_DSP_TARBALL):
+   $(Q) echo "Downloading $(LIQUID_DSP_TARBALL)"
+   $(Q) curl -O -L $(LIQUID_DSP_URL)
+
+$(LIQUID_DSP_UNPACK): $(LIQUID_DSP_TARBALL)
+   $(Q) echo "Unpacking $(LIQUID_DSP_TARBALL) to $(LIQUID_DSP_UNPACK)"
+   $(Q) tar xzvf $(LIQUID_DSP_TARBALL)
+   $(Q) mv liquid-dsp-$(LIQUID_DSP_VERSION) $(LIQUID_DSP_UNPACK)
+   $(Q) cp config.h $(LIQUID_DSP_UNPACK)/include
+
+$(LIQUID_DSP_UNPACK)/.patch: $(LIQUID_DSP_UNPACK)
+   $(Q) touch $(LIQUID_DSP_UNPACK)/.patch
+
+VPATH += $(LIBUV_UNPACK)/include
+
+DEPPATH += --dep-path $(LIBUV_UNPACK)/include
+
+CFLAGS += -I$(LIQUID_DSP_UNPACK)/include
+CFLAGS += -Wall -std=c99
+CFLAGS += -DM_SQRT1_2=0.7071067811865475244008443621048490
+CFLAGS += -DM_SQRT2=1.4142135623730950488016887242096981
+CFLAGS += -DM_PI=3.1415926535897932384626433832795029
+CFLAGS += -DM_LN2=0.6931471805599453094172321214581765
+CFLAGS += -DM_PI_2=1.5707963267948966192313216916397514
+CFLAGS += -DM_2_PI=0.6366197723675813430755350534900574

Review Comment:
   Sure.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx-apps] xiaoxiang781216 commented on a diff in pull request #1624: Adding sdr group with liquid-dsp library

2023-03-06 Thread via GitHub


xiaoxiang781216 commented on code in PR #1624:
URL: https://github.com/apache/nuttx-apps/pull/1624#discussion_r1126094153


##
sdr/liquid_dsp/Makefile:
##
@@ -0,0 +1,247 @@
+###
+# apps/sdr/liquid_dsp/Makefile
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.  The
+# ASF licenses this file to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance with the
+# License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
+# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.  See the
+# License for the specific language governing permissions and limitations
+# under the License.
+#
+/
+
+include $(APPDIR)/Make.defs
+
+LIQUID_DSP_VERSION  = 1.4.0
+LIQUID_DSP_UNPACK   = liquid-dsp
+LIQUID_DSP_TARBALL  = v$(LIQUID_DSP_VERSION).tar.gz
+LIQUID_DSP_URL_BASE = https://github.com/jgaeddert/liquid-dsp/archive
+LIQUID_DSP_URL  = $(LIQUID_DSP_URL_BASE)/$(LIQUID_DSP_TARBALL)
+
+$(LIQUID_DSP_TARBALL):
+   $(Q) echo "Downloading $(LIQUID_DSP_TARBALL)"
+   $(Q) curl -O -L $(LIQUID_DSP_URL)
+
+$(LIQUID_DSP_UNPACK): $(LIQUID_DSP_TARBALL)
+   $(Q) echo "Unpacking $(LIQUID_DSP_TARBALL) to $(LIQUID_DSP_UNPACK)"
+   $(Q) tar xzvf $(LIQUID_DSP_TARBALL)
+   $(Q) mv liquid-dsp-$(LIQUID_DSP_VERSION) $(LIQUID_DSP_UNPACK)
+   $(Q) cp config.h $(LIQUID_DSP_UNPACK)/include
+
+$(LIQUID_DSP_UNPACK)/.patch: $(LIQUID_DSP_UNPACK)
+   $(Q) touch $(LIQUID_DSP_UNPACK)/.patch
+
+VPATH += $(LIBUV_UNPACK)/include
+
+DEPPATH += --dep-path $(LIBUV_UNPACK)/include
+
+CFLAGS += -I$(LIQUID_DSP_UNPACK)/include
+CFLAGS += -Wall -std=c99
+CFLAGS += -DM_SQRT1_2=0.7071067811865475244008443621048490
+CFLAGS += -DM_SQRT2=1.4142135623730950488016887242096981
+CFLAGS += -DM_PI=3.1415926535897932384626433832795029
+CFLAGS += -DM_LN2=0.6931471805599453094172321214581765
+CFLAGS += -DM_PI_2=1.5707963267948966192313216916397514
+CFLAGS += -DM_2_PI=0.6366197723675813430755350534900574

Review Comment:
   > > so these macro doesn't exist in toolchain's libm?
   > 
   > They should be, but if I remove the definitions from my Makefile, i am 
getting those undefined errors. Maybe you can take a look at it?
   
   Let's merge it first, I will try it later.
   
   > > Sorry, it's changed by me, let's see how to make it work with LuaJIT. 
Once we fix the problem, let's enable LuaJIT in CI to catch the potential break 
before merging the patch.
   > 
   > Let me open PR in the near future and maybe we can work together to bring 
LuaJIT to life. I am also relying on some archiutecture specific stuff in my 
port, i.e. ITCM memory heap for JIT traces, because I am running LuaJIT on i.MX 
RT1064. I am afraid that Cortex M7 is a must.
   
   Sure.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] masayuki2009 commented on pull request #8733: boards: stm32f4discovery: Update kostest/defconfig to avoid crash

2023-03-06 Thread via GitHub


masayuki2009 commented on PR #8733:
URL: https://github.com/apache/nuttx/pull/8733#issuecomment-1455718505

   >@masayuki2009 which option does really fix the crash?
   
   I still can not identify which option fixes the crash.
   
   First, I added to `CONFIG_DEBUG_HARDFAULT_ALERT=y` to show more detailed 
info but the crash did not happen.
   Then I added the other configs and the crash still does not happen.
   
   Furthermore, if I remove `CONFIG_DEBUG_HARDFAULT_ALERT=y` from the commit, 
it still works.
   So I think the crash might relate to text/data layout.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] xiaoxiang781216 opened a new pull request, #8735: net: Remove the dummy file_sendfile from sock_intf_s

2023-03-06 Thread via GitHub


xiaoxiang781216 opened a new pull request, #8735:
URL: https://github.com/apache/nuttx/pull/8735

   ## Summary
   
   - net: Make si_bind callback optional
   - net: Make si_getsockname callback optional
   - net: Remove the empty si_getpeername implementation
   - net: Make si_listen callback optional 
   - net: Make si_connect callback optional 
   - net: Make si_accept callback optional 
   - net: Make si_poll callback optional
   
   ## Impact
   
   Code refactor only
   
   ## Testing
   
   CI


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx-apps] jturnsek commented on a diff in pull request #1624: Adding sdr group with liquid-dsp library

2023-03-06 Thread via GitHub


jturnsek commented on code in PR #1624:
URL: https://github.com/apache/nuttx-apps/pull/1624#discussion_r1126102883


##
sdr/liquid_dsp/Makefile:
##
@@ -0,0 +1,243 @@
+###
+# apps/sdr/liquid_dsp/Makefile
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.  The
+# ASF licenses this file to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance with the
+# License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
+# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.  See the
+# License for the specific language governing permissions and limitations
+# under the License.
+#
+/
+
+include $(APPDIR)/Make.defs
+
+LIQUID_DSP_VERSION  = 1.4.0
+LIQUID_DSP_UNPACK   = liquid-dsp
+LIQUID_DSP_TARBALL  = v$(LIQUID_DSP_VERSION).tar.gz
+LIQUID_DSP_URL_BASE = https://github.com/jgaeddert/liquid-dsp/archive
+LIQUID_DSP_URL  = $(LIQUID_DSP_URL_BASE)/$(LIQUID_DSP_TARBALL)
+
+$(LIQUID_DSP_TARBALL):
+   $(Q) echo "Downloading $(LIQUID_DSP_TARBALL)"
+   $(Q) curl -O -L $(LIQUID_DSP_URL)
+
+$(LIQUID_DSP_UNPACK): $(LIQUID_DSP_TARBALL)
+   $(Q) echo "Unpacking $(LIQUID_DSP_TARBALL) to $(LIQUID_DSP_UNPACK)"
+   $(Q) tar xzvf $(LIQUID_DSP_TARBALL)
+   $(Q) mv liquid-dsp-$(LIQUID_DSP_VERSION) $(LIQUID_DSP_UNPACK)
+   $(Q) cp config.h $(LIQUID_DSP_UNPACK)/include

Review Comment:
   Do you have a suggestion?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] pkarashchenko commented on a diff in pull request #8730: cache: add up_get_xcache_linesize() support

2023-03-06 Thread via GitHub


pkarashchenko commented on code in PR #8730:
URL: https://github.com/apache/nuttx/pull/8730#discussion_r1126100984


##
arch/arm/src/armv7-a/l2cc.h:
##
@@ -70,6 +70,22 @@ extern "C"
 void arm_l2ccinitialize(void);
 #endif
 
+/
+ * Name: l2cc_get_linesize
+ *
+ * Description:
+ *Get L2CC-P310 L2 cache linesize
+ *
+ * Input Parameters:
+ *None
+ *
+ * Returned Value:
+ *L2 cache linesize
+ *
+ /
+
+uint32_t l2cc_get_linesize(void);

Review Comment:
   Maybe this can be a define instead of function?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx-apps] jturnsek commented on a diff in pull request #1624: Adding sdr group with liquid-dsp library

2023-03-06 Thread via GitHub


jturnsek commented on code in PR #1624:
URL: https://github.com/apache/nuttx-apps/pull/1624#discussion_r1126107770


##
sdr/liquid_dsp/Makefile:
##
@@ -0,0 +1,243 @@
+###
+# apps/sdr/liquid_dsp/Makefile
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.  The
+# ASF licenses this file to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance with the
+# License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
+# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.  See the
+# License for the specific language governing permissions and limitations
+# under the License.
+#
+/
+
+include $(APPDIR)/Make.defs
+
+LIQUID_DSP_VERSION  = 1.4.0
+LIQUID_DSP_UNPACK   = liquid-dsp
+LIQUID_DSP_TARBALL  = v$(LIQUID_DSP_VERSION).tar.gz
+LIQUID_DSP_URL_BASE = https://github.com/jgaeddert/liquid-dsp/archive
+LIQUID_DSP_URL  = $(LIQUID_DSP_URL_BASE)/$(LIQUID_DSP_TARBALL)
+
+$(LIQUID_DSP_TARBALL):
+   $(Q) echo "Downloading $(LIQUID_DSP_TARBALL)"
+   $(Q) curl -O -L $(LIQUID_DSP_URL)
+
+$(LIQUID_DSP_UNPACK): $(LIQUID_DSP_TARBALL)
+   $(Q) echo "Unpacking $(LIQUID_DSP_TARBALL) to $(LIQUID_DSP_UNPACK)"
+   $(Q) tar xzvf $(LIQUID_DSP_TARBALL)
+   $(Q) mv liquid-dsp-$(LIQUID_DSP_VERSION) $(LIQUID_DSP_UNPACK)
+   $(Q) cp config.h $(LIQUID_DSP_UNPACK)/include

Review Comment:
   Adding CFLAGS += ${shell $(INCDIR) "$(CC)" $(APPDIR)/sdr/liquid_dsp} to 
Makefile seems to work?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx-apps] jturnsek commented on a diff in pull request #1624: Adding sdr group with liquid-dsp library

2023-03-06 Thread via GitHub


jturnsek commented on code in PR #1624:
URL: https://github.com/apache/nuttx-apps/pull/1624#discussion_r1126107770


##
sdr/liquid_dsp/Makefile:
##
@@ -0,0 +1,243 @@
+###
+# apps/sdr/liquid_dsp/Makefile
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.  The
+# ASF licenses this file to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance with the
+# License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
+# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.  See the
+# License for the specific language governing permissions and limitations
+# under the License.
+#
+/
+
+include $(APPDIR)/Make.defs
+
+LIQUID_DSP_VERSION  = 1.4.0
+LIQUID_DSP_UNPACK   = liquid-dsp
+LIQUID_DSP_TARBALL  = v$(LIQUID_DSP_VERSION).tar.gz
+LIQUID_DSP_URL_BASE = https://github.com/jgaeddert/liquid-dsp/archive
+LIQUID_DSP_URL  = $(LIQUID_DSP_URL_BASE)/$(LIQUID_DSP_TARBALL)
+
+$(LIQUID_DSP_TARBALL):
+   $(Q) echo "Downloading $(LIQUID_DSP_TARBALL)"
+   $(Q) curl -O -L $(LIQUID_DSP_URL)
+
+$(LIQUID_DSP_UNPACK): $(LIQUID_DSP_TARBALL)
+   $(Q) echo "Unpacking $(LIQUID_DSP_TARBALL) to $(LIQUID_DSP_UNPACK)"
+   $(Q) tar xzvf $(LIQUID_DSP_TARBALL)
+   $(Q) mv liquid-dsp-$(LIQUID_DSP_VERSION) $(LIQUID_DSP_UNPACK)
+   $(Q) cp config.h $(LIQUID_DSP_UNPACK)/include

Review Comment:
   Adding "CFLAGS += ${shell $(INCDIR) "$(CC)" $(APPDIR)/sdr/liquid_dsp}" to 
Makefile seems to work?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] pkarashchenko commented on pull request #8733: boards: stm32f4discovery: Update kostest/defconfig to avoid crash

2023-03-06 Thread via GitHub


pkarashchenko commented on PR #8733:
URL: https://github.com/apache/nuttx/pull/8733#issuecomment-1455769385

   Maybe something related to stack alignment change. There is a special 
requirement for the exception stack to be 8 byte aligned, but default alignment 
of 8 should cover that. No other ideas for now


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] no1wudi opened a new pull request, #8736: ubsan: Implement __ubsan_handle_invalid_builtin

2023-03-06 Thread via GitHub


no1wudi opened a new pull request, #8736:
URL: https://github.com/apache/nuttx/pull/8736

   ## Summary
   ubsan: Implement __ubsan_handle_invalid_builtin
   ## Impact
   ubsan
   ## Testing
   QEMU
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] xiaoxiang781216 commented on pull request #8735: net: Remove the dummy implementation from sock_intf_s

2023-03-06 Thread via GitHub


xiaoxiang781216 commented on PR #8735:
URL: https://github.com/apache/nuttx/pull/8735#issuecomment-1455793860

   > Please remove extra whitespace on blank lines
   
   Done.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] anchao opened a new pull request, #8737: arm/armv8-m: add missing zig flags

2023-03-06 Thread via GitHub


anchao opened a new pull request, #8737:
URL: https://github.com/apache/nuttx/pull/8737

   ## Summary
   
   arm/armv8-m: add missing zig flags
   
   ## Impact
   
   N/A
   
   ## Testing
   
   ci-check


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] anchao commented on pull request #8737: arm/armv8-m: add missing zig flags

2023-03-06 Thread via GitHub


anchao commented on PR #8737:
URL: https://github.com/apache/nuttx/pull/8737#issuecomment-1455812115

   @no1wudi Please help to verify if this option can work as expect.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] jturnsek opened a new pull request, #8738: Adding support for LS027B7DH01A display and MEMLCD_EXTCOMIN_MODE_HW

2023-03-06 Thread via GitHub


jturnsek opened a new pull request, #8738:
URL: https://github.com/apache/nuttx/pull/8738

   ## Summary
   
   Adding new Sharp Memory LS027B7DH01A to the driver and support for 
MEMLCD_EXTCOMIN_MODE_HW. Later doesn't need IO pin to toggle VCOM. VCOM 
toggling is done by sending special command to the display.
   
   ## Impact
   
   Sharp MEMLCD driver
   
   ## Testing
   
   Tested on EdgeProMX keyboard.
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx-apps] xiaoxiang781216 commented on a diff in pull request #1624: Adding sdr group with liquid-dsp library

2023-03-06 Thread via GitHub


xiaoxiang781216 commented on code in PR #1624:
URL: https://github.com/apache/nuttx-apps/pull/1624#discussion_r1126179524


##
sdr/liquid_dsp/Makefile:
##
@@ -0,0 +1,244 @@
+###
+# apps/sdr/liquid_dsp/Makefile
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.  The
+# ASF licenses this file to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance with the
+# License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
+# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.  See the
+# License for the specific language governing permissions and limitations
+# under the License.
+#
+/
+
+include $(APPDIR)/Make.defs
+
+LIQUID_DSP_VERSION  = 1.4.0
+LIQUID_DSP_UNPACK   = liquid-dsp
+LIQUID_DSP_TARBALL  = v$(LIQUID_DSP_VERSION).tar.gz
+LIQUID_DSP_URL_BASE = https://github.com/jgaeddert/liquid-dsp/archive
+LIQUID_DSP_URL  = $(LIQUID_DSP_URL_BASE)/$(LIQUID_DSP_TARBALL)
+
+$(LIQUID_DSP_TARBALL):
+   $(Q) echo "Downloading $(LIQUID_DSP_TARBALL)"
+   $(Q) curl -O -L $(LIQUID_DSP_URL)
+
+$(LIQUID_DSP_UNPACK): $(LIQUID_DSP_TARBALL)
+   $(Q) echo "Unpacking $(LIQUID_DSP_TARBALL) to $(LIQUID_DSP_UNPACK)"
+   $(Q) tar xzvf $(LIQUID_DSP_TARBALL)
+   $(Q) mv liquid-dsp-$(LIQUID_DSP_VERSION) $(LIQUID_DSP_UNPACK)
+
+$(LIQUID_DSP_UNPACK)/.patch: $(LIQUID_DSP_UNPACK)
+   $(Q) touch $(LIQUID_DSP_UNPACK)/.patch
+
+CFLAGS += -std=c99
+CFLAGS += ${shell $(INCDIR) "$(CC)" $(APPDIR)/sdr/liquid_dsp}
+CFLAGS += -DM_SQRT1_2=0.7071067811865475244008443621048490
+CFLAGS += -DM_SQRT2=1.4142135623730950488016887242096981
+CFLAGS += -DM_PI=3.1415926535897932384626433832795029
+CFLAGS += -DM_LN2=0.6931471805599453094172321214581765
+CFLAGS += -DM_PI_2=1.5707963267948966192313216916397514
+CFLAGS += -DM_2_PI=0.6366197723675813430755350534900574
+
+
+CSRCS = $(LIQUID_DSP_UNPACK)/src/agc/src/agc_crcf.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/agc/src/agc_rrrf.c
+
+CSRCS += $(LIQUID_DSP_UNPACK)/src/audio/src/cvsd.c
+
+CSRCS += $(LIQUID_DSP_UNPACK)/src/buffer/src/bufferf.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/buffer/src/buffercf.c

Review Comment:
   let's sort the source file in order



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx-apps] xiaoxiang781216 commented on a diff in pull request #1624: Adding sdr group with liquid-dsp library

2023-03-06 Thread via GitHub


xiaoxiang781216 commented on code in PR #1624:
URL: https://github.com/apache/nuttx-apps/pull/1624#discussion_r1126179524


##
sdr/liquid_dsp/Makefile:
##
@@ -0,0 +1,244 @@
+###
+# apps/sdr/liquid_dsp/Makefile
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.  The
+# ASF licenses this file to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance with the
+# License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
+# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.  See the
+# License for the specific language governing permissions and limitations
+# under the License.
+#
+/
+
+include $(APPDIR)/Make.defs
+
+LIQUID_DSP_VERSION  = 1.4.0
+LIQUID_DSP_UNPACK   = liquid-dsp
+LIQUID_DSP_TARBALL  = v$(LIQUID_DSP_VERSION).tar.gz
+LIQUID_DSP_URL_BASE = https://github.com/jgaeddert/liquid-dsp/archive
+LIQUID_DSP_URL  = $(LIQUID_DSP_URL_BASE)/$(LIQUID_DSP_TARBALL)
+
+$(LIQUID_DSP_TARBALL):
+   $(Q) echo "Downloading $(LIQUID_DSP_TARBALL)"
+   $(Q) curl -O -L $(LIQUID_DSP_URL)
+
+$(LIQUID_DSP_UNPACK): $(LIQUID_DSP_TARBALL)
+   $(Q) echo "Unpacking $(LIQUID_DSP_TARBALL) to $(LIQUID_DSP_UNPACK)"
+   $(Q) tar xzvf $(LIQUID_DSP_TARBALL)
+   $(Q) mv liquid-dsp-$(LIQUID_DSP_VERSION) $(LIQUID_DSP_UNPACK)
+
+$(LIQUID_DSP_UNPACK)/.patch: $(LIQUID_DSP_UNPACK)
+   $(Q) touch $(LIQUID_DSP_UNPACK)/.patch
+
+CFLAGS += -std=c99
+CFLAGS += ${shell $(INCDIR) "$(CC)" $(APPDIR)/sdr/liquid_dsp}
+CFLAGS += -DM_SQRT1_2=0.7071067811865475244008443621048490
+CFLAGS += -DM_SQRT2=1.4142135623730950488016887242096981
+CFLAGS += -DM_PI=3.1415926535897932384626433832795029
+CFLAGS += -DM_LN2=0.6931471805599453094172321214581765
+CFLAGS += -DM_PI_2=1.5707963267948966192313216916397514
+CFLAGS += -DM_2_PI=0.6366197723675813430755350534900574
+
+
+CSRCS = $(LIQUID_DSP_UNPACK)/src/agc/src/agc_crcf.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/agc/src/agc_rrrf.c
+
+CSRCS += $(LIQUID_DSP_UNPACK)/src/audio/src/cvsd.c
+
+CSRCS += $(LIQUID_DSP_UNPACK)/src/buffer/src/bufferf.c
+CSRCS += $(LIQUID_DSP_UNPACK)/src/buffer/src/buffercf.c

Review Comment:
   let's sort all source files in order



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx-apps] xiaoxiang781216 commented on a diff in pull request #1625: Initial load for nng library

2023-03-06 Thread via GitHub


xiaoxiang781216 commented on code in PR #1625:
URL: https://github.com/apache/nuttx-apps/pull/1625#discussion_r1126180498


##
netutils/nng/Makefile:
##
@@ -0,0 +1,152 @@
+
+# apps/netutils/nng/Makefile
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.  The
+# ASF licenses this file to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance with the
+# License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
+# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.  See the
+# License for the specific language governing permissions and limitations
+# under the License.
+#
+
+
+include $(APPDIR)/Make.defs
+
+NNG_VERSION := $(patsubst "%",%,$(CONFIG_NETUTILS_NNG_VERSION))
+NNG_TARBALL  = v$(NNG_VERSION).tar.gz
+NNG_UNPACK   = nng
+NNG_SRCDIR   = $(NNG_UNPACK)$(DELIM)src
+
+CFLAGS += -I$(NNG_UNPACK)/src
+CFLAGS += -DNNG_PLATFORM_POSIX
+CFLAGS += -DNNG_HAVE_GETRANDOM
+CFLAGS += -DNNG_TRANSPORT_INPROC
+CFLAGS += -DNNG_TRANSPORT_IPC
+CFLAGS += -DNNG_TRANSPORT_TCP
+CFLAGS += -DNNG_TRANSPORT_TLS
+CFLAGS += -DNNG_TRANSPORT_WS
+CFLAGS += -DNNG_TRANSPORT_WSS
+
+CFLAGS += -DNNG_USE_EVENTFD
+CFLAGS += -DNNG_HAVE_EPOLL
+CFLAGS += -DNNG_HAVE_EPOLL_CREATE1
+
+DEPPATH += --dep-path $(NNG_SRCDIR)
+VPATH   += :$(NNG_SRCDIR)
+
+
+CSRCS  = $(NNG_SRCDIR)/nng.c 
+CSRCS += $(NNG_SRCDIR)/nng_legacy.c
+CSRCS += $(NNG_SRCDIR)/core/aio.c
+CSRCS += $(NNG_SRCDIR)/core/device.c
+CSRCS += $(NNG_SRCDIR)/core/dialer.c
+CSRCS += $(NNG_SRCDIR)/core/file.c
+CSRCS += $(NNG_SRCDIR)/core/idhash.c
+CSRCS += $(NNG_SRCDIR)/core/init.c
+CSRCS += $(NNG_SRCDIR)/core/list.c

Review Comment:
   let's order all source files in order.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] wengzhe opened a new pull request, #8739: net/arp: Only parse ioctl request for valid cmd.

2023-03-06 Thread via GitHub


wengzhe opened a new pull request, #8739:
URL: https://github.com/apache/nuttx/pull/8739

   ## Summary
   net/arp: Only parse ioctl request for valid cmd.
   Try to fix https://github.com/apache/nuttx/issues/8719
   
   ## Impact
   Don't access req for invalid cmd.
   
   ## Testing
   CI & manually
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] pkarashchenko commented on a diff in pull request #8738: Adding support for LS027B7DH01A display and MEMLCD_EXTCOMIN_MODE_HW

2023-03-06 Thread via GitHub


pkarashchenko commented on code in PR #8738:
URL: https://github.com/apache/nuttx/pull/8738#discussion_r1126182257


##
drivers/lcd/memlcd.c:
##
@@ -103,6 +109,13 @@
 #define LS_BIT   (1 << 0)
 #define MS_BIT   (1 << 7)
 
+#define MEMLCD_WORK_PERIOD   MSEC2TICK(500)
+
+#define TOGGLE_VCOM  \
+  do {   \
+_sharpmem_vcom = _sharpmem_vcom ? 0x00 : MEMLCD_CMD_VCOM;\
+  } while (0);

Review Comment:
   ```
   do
 {
   ...
 }
   while (0)
   ```



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx-apps] xiaoxiang781216 commented on a diff in pull request #1625: Initial load for nng library

2023-03-06 Thread via GitHub


xiaoxiang781216 commented on code in PR #1625:
URL: https://github.com/apache/nuttx-apps/pull/1625#discussion_r1126191703


##
netutils/nng/Make.defs:
##
@@ -0,0 +1,29 @@
+
+# apps/netutils/nng/Make.defs
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.  The
+# ASF licenses this file to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance with the
+# License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
+# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.  See the
+# License for the specific language governing permissions and limitations
+# under the License.
+#
+
+
+ifneq ($(CONFIG_NETUTILS_NNG),)
+CONFIGURED_APPS += $(APPDIR)/netutils/nng
+
+CFLAGS += ${shell $(INCDIR) $(INCDIROPT) "$(CC)" \
+   $(APPDIR)/netutils/nng/nng/include}
+CXXFLAGS += ${shell $(INCDIR) $(INCDIROPT) "$(CC)" \

Review Comment:
   ```suggestion
   CXXFLAGS += ${INCDIR_PREFIX}$(APPDIR)/netutils/nng/nng/include
   ```



##
netutils/nng/Make.defs:
##
@@ -0,0 +1,29 @@
+
+# apps/netutils/nng/Make.defs
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.  The
+# ASF licenses this file to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance with the
+# License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
+# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.  See the
+# License for the specific language governing permissions and limitations
+# under the License.
+#
+
+
+ifneq ($(CONFIG_NETUTILS_NNG),)
+CONFIGURED_APPS += $(APPDIR)/netutils/nng
+
+CFLAGS += ${shell $(INCDIR) $(INCDIROPT) "$(CC)" \

Review Comment:
   ```suggestion
   CFLAGS += ${INCDIR_PREFIX}$(APPDIR)/netutils/nng/nng/include
   ```



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] jturnsek commented on a diff in pull request #8738: Adding support for LS027B7DH01A display and MEMLCD_EXTCOMIN_MODE_HW

2023-03-06 Thread via GitHub


jturnsek commented on code in PR #8738:
URL: https://github.com/apache/nuttx/pull/8738#discussion_r1126192231


##
drivers/lcd/memlcd.c:
##
@@ -103,6 +109,13 @@
 #define LS_BIT   (1 << 0)
 #define MS_BIT   (1 << 7)
 
+#define MEMLCD_WORK_PERIOD   MSEC2TICK(500)
+
+#define TOGGLE_VCOM  \
+  do {   \
+_sharpmem_vcom = _sharpmem_vcom ? 0x00 : MEMLCD_CMD_VCOM;\
+  } while (0);

Review Comment:
   Thanks. Missed it.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] wengzhe commented on issue #8719: Xtensa_user_panic when trying to ping from nsh console in a telnet session

2023-03-06 Thread via GitHub


wengzhe commented on issue #8719:
URL: https://github.com/apache/nuttx/issues/8719#issuecomment-1455843304

   Hi, @onyx99 could you help us verify if this patch 
(https://github.com/apache/nuttx/pull/8739) solves the problem? 


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] jerpelea merged pull request #8734: mm_heap: double malloced memory default alignment (4 -> 8, 8 -> 16)

2023-03-06 Thread via GitHub


jerpelea merged PR #8734:
URL: https://github.com/apache/nuttx/pull/8734


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[nuttx] branch master updated: mm_heap: double malloced memory default alignment (4 -> 8, 8 -> 16)

2023-03-06 Thread jerpelea
This is an automated email from the ASF dual-hosted git repository.

jerpelea pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx.git


The following commit(s) were added to refs/heads/master by this push:
 new 3e971d2e6d mm_heap: double malloced memory default alignment (4 -> 8, 
8 -> 16)
3e971d2e6d is described below

commit 3e971d2e6d753519985a3e044d4dd21026ec1d12
Author: wangbowen6 
AuthorDate: Mon Mar 6 16:10:31 2023 +0800

mm_heap: double malloced memory default alignment (4 -> 8, 8 -> 16)

Base on the gnu libc standard:

https://www.gnu.org/software/libc/manual/html_node/Aligned-Memory-Blocks.html

Change the default memory aligment to 8 bytes for 32-bit system and
16 bytes for 64-bit system.

Signed-off-by: wangbowen6 
---
 mm/Kconfig  | 2 +-
 mm/mm_heap/mm.h | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/mm/Kconfig b/mm/Kconfig
index 71a95c80fa..6d702f7629 100644
--- a/mm/Kconfig
+++ b/mm/Kconfig
@@ -63,7 +63,7 @@ config MM_KERNEL_HEAPSIZE
 
 config MM_DFAULT_ALIGNMENT
int "Memory default alignment in bytes"
-   default 8
+   default 0
range 0 64
---help---
The memory default alignment in bytes, if this value is 0, the 
real
diff --git a/mm/mm_heap/mm.h b/mm/mm_heap/mm.h
index adc6f24d28..c787ace6af 100644
--- a/mm/mm_heap/mm.h
+++ b/mm/mm_heap/mm.h
@@ -111,7 +111,7 @@
 #define MM_NNODES(MM_MAX_SHIFT - MM_MIN_SHIFT + 1)
 
 #if CONFIG_MM_DFAULT_ALIGNMENT == 0
-#  define MM_ALIGN   sizeof(uintptr_t)
+#  define MM_ALIGN   (2 * sizeof(uintptr_t))
 #else
 #  define MM_ALIGN   CONFIG_MM_DFAULT_ALIGNMENT
 #endif



[GitHub] [nuttx] pussuw commented on pull request #8605: signal/sig_dispatch: Fix case where signal action is sent twice

2023-03-06 Thread via GitHub


pussuw commented on PR #8605:
URL: https://github.com/apache/nuttx/pull/8605#issuecomment-1455871376

   The solution seems to be quite simple.
   
   Like I said the signal delivery was not broken, but scheduling the signal 
*action* did not work, when executing a system call. The solution seems to be 
to just simply add the signal action to the signal queue, not to the pending 
queue.
   
   I will provide a patch in a moment.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] jerpelea merged pull request #8732: tools/arm: Add missing -mcpu param for zig

2023-03-06 Thread via GitHub


jerpelea merged PR #8732:
URL: https://github.com/apache/nuttx/pull/8732


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[nuttx] branch master updated: tools/arm: Add missing -mcpu param for zig

2023-03-06 Thread jerpelea
This is an automated email from the ASF dual-hosted git repository.

jerpelea pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx.git


The following commit(s) were added to refs/heads/master by this push:
 new bcf5700e8a tools/arm: Add missing -mcpu param for zig
bcf5700e8a is described below

commit bcf5700e8a7d012f0b9bbe2519ff97e8a03d8cc5
Author: Huang Qi 
AuthorDate: Mon Mar 6 15:57:02 2023 +0800

tools/arm: Add missing -mcpu param for zig

Signed-off-by: Huang Qi 
---
 arch/arm/src/common/Toolchain.defs | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/arm/src/common/Toolchain.defs 
b/arch/arm/src/common/Toolchain.defs
index 34eaf1c34b..96892ca6fb 100644
--- a/arch/arm/src/common/Toolchain.defs
+++ b/arch/arm/src/common/Toolchain.defs
@@ -285,7 +285,7 @@ else
   ZEABI := gnueabi
 endif
 
-ZIGFLAGS = -target $(ZARCH)-freestanding-$(ZEABI)
+ZIGFLAGS = -target $(ZARCH)-freestanding-$(ZEABI) $(ZARCHCPUFLAGS)
 
 # Optimization of unused sections
 



[GitHub] [nuttx] jerpelea merged pull request #8733: boards: stm32f4discovery: Update kostest/defconfig to avoid crash

2023-03-06 Thread via GitHub


jerpelea merged PR #8733:
URL: https://github.com/apache/nuttx/pull/8733


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[nuttx] branch master updated: boards: stm32f4discovery: Update kostest/defconfig to avoid crash

2023-03-06 Thread jerpelea
This is an automated email from the ASF dual-hosted git repository.

jerpelea pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx.git


The following commit(s) were added to refs/heads/master by this push:
 new 1917870cca boards: stm32f4discovery: Update kostest/defconfig to avoid 
crash
1917870cca is described below

commit 1917870ccac1d993e1f66f240b49bcdc30d26333
Author: Masayuki Ishikawa 
AuthorDate: Mon Mar 6 17:03:22 2023 +0900

boards: stm32f4discovery: Update kostest/defconfig to avoid crash

Summary:
- I noticed that recent mm_heap changes causes a crash with
  stm32f4discovery:kostest
- This is a tentative solution to avoid the crash

Impact:
- None

Testing:
- Tested with stm32f4discovery board

Signed-off-by: Masayuki Ishikawa 
---
 boards/arm/stm32/stm32f4discovery/configs/kostest/defconfig | 5 -
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/boards/arm/stm32/stm32f4discovery/configs/kostest/defconfig 
b/boards/arm/stm32/stm32f4discovery/configs/kostest/defconfig
index d827f8123b..c5ee7e18d9 100644
--- a/boards/arm/stm32/stm32f4discovery/configs/kostest/defconfig
+++ b/boards/arm/stm32/stm32f4discovery/configs/kostest/defconfig
@@ -18,9 +18,11 @@ CONFIG_BOARD_LATE_INITIALIZE=y
 CONFIG_BOARD_LOOPSPERMSEC=16717
 CONFIG_BUILD_PROTECTED=y
 CONFIG_CONSOLE_SYSLOG=y
+CONFIG_DEBUG_FULLOPT=y
+CONFIG_DEBUG_HARDFAULT_ALERT=y
+CONFIG_DEBUG_SYMBOLS=y
 CONFIG_DISABLE_ENVIRON=y
 CONFIG_DISABLE_MOUNTPOINT=y
-CONFIG_HOST_WINDOWS=y
 CONFIG_INIT_ENTRYPOINT="ostest_main"
 CONFIG_INTELHEX_BINARY=y
 CONFIG_MM_REGIONS=2
@@ -32,6 +34,7 @@ CONFIG_RAM_START=0x2000
 CONFIG_RAW_BINARY=y
 CONFIG_RR_INTERVAL=200
 CONFIG_SCHED_WAITPID=y
+CONFIG_STACK_COLORATION=y
 CONFIG_START_DAY=22
 CONFIG_START_MONTH=3
 CONFIG_START_YEAR=2013



[GitHub] [nuttx] xiaoxiang781216 commented on a diff in pull request #8738: Adding support for LS027B7DH01A display and MEMLCD_EXTCOMIN_MODE_HW

2023-03-06 Thread via GitHub


xiaoxiang781216 commented on code in PR #8738:
URL: https://github.com/apache/nuttx/pull/8738#discussion_r1126227237


##
drivers/lcd/memlcd.c:
##
@@ -165,6 +182,7 @@ static int memlcd_setcontrast(struct lcd_dev_s *dev, 
unsigned int contrast);
  * Private Data
  /
 
+static uint8_t _sharpmem_vcom;
 static uint8_t g_runbuffer[MEMLCD_BPP * MEMLCD_XRES / 8];

Review Comment:
   let's move the global variables into memlcd_dev_s



##
drivers/lcd/memlcd.c:
##
@@ -365,13 +418,10 @@ static inline void memlcd_clear(FAR struct memlcd_dev_s 
*mlcd)
 
 static int memlcd_extcominisr(int irq, FAR void *context, void *arg)
 {
-  static bool pol = 0;
-  struct memlcd_dev_s *mlcd = &g_memlcddev;
 #ifdef CONFIG_MEMLCD_EXTCOMIN_MODE_HW
-#  error "CONFIG_MEMLCD_EXTCOMIN_MODE_HW unsupported yet!"
   /* Start a worker thread, do it in bottom half? */
-
 #else
+  static bool pol = 0;

Review Comment:
   move pol to memlcd_dev_s too



##
drivers/lcd/memlcd.c:
##
@@ -365,13 +418,10 @@ static inline void memlcd_clear(FAR struct memlcd_dev_s 
*mlcd)
 
 static int memlcd_extcominisr(int irq, FAR void *context, void *arg)
 {
-  static bool pol = 0;
-  struct memlcd_dev_s *mlcd = &g_memlcddev;
 #ifdef CONFIG_MEMLCD_EXTCOMIN_MODE_HW

Review Comment:
   ```suggestion
   #ifndef CONFIG_MEMLCD_EXTCOMIN_MODE_HW
   ```



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] pussuw opened a new pull request, #8740: signal/sig_dispatch: Fix sending the same signal twice

2023-03-06 Thread via GitHub


pussuw opened a new pull request, #8740:
URL: https://github.com/apache/nuttx/pull/8740

   ## Summary
   This fixes regression found in  #8605. Only the signal action should be 
queued when in system call, the signal should not be sent and pended which 
results in the user app receiving it twice.
   ## Impact
   Fix regression from #8605
   ## Testing
   icicle:nsh / pnsh + ostest and 
https://github.com/linux-test-project/ltp/blob/master/testcases/open_posix_testsuite/conformance/interfaces/timer_settime/9-2.c
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] pkarashchenko commented on a diff in pull request #8739: net/arp: Only parse ioctl request for valid cmd.

2023-03-06 Thread via GitHub


pkarashchenko commented on code in PR #8739:
URL: https://github.com/apache/nuttx/pull/8739#discussion_r1126264765


##
net/netdev/netdev_ioctl.c:
##
@@ -1219,6 +1219,40 @@ static int netdev_imsf_ioctl(FAR struct socket *psock, 
int cmd,
 }
 #endif
 
+/
+ * Name: ioctl_arpreq_parse
+ *
+ * Description:
+ *   Parse arpreq into netdev and sockaddr.
+ *
+ * Input Parameters:
+ *   reqThe argument of the ioctl cmd
+ *   devThe pointer to get ethernet driver device structure
+ *   addr   The pointer to get address in the request
+ *
+ * Returned Value:
+ *   true on success and false on failure.
+ *
+ /
+
+#ifdef CONFIG_NET_ARP
+static bool ioctl_arpreq_parse(FAR struct arpreq *req,
+   FAR struct net_driver_s **dev,
+   FAR struct sockaddr_in **addr)
+{
+  if (req != NULL)
+{
+  *addr = (FAR struct sockaddr_in *)&req->arp_pa;
+  *dev  = req->arp_dev[0] ?

Review Comment:
   ```suggestion
 *dev  = req->arp_dev[0] != '\0' ?
   ```



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] pkarashchenko commented on a diff in pull request #8735: net: Remove the dummy implementation from sock_intf_s

2023-03-06 Thread via GitHub


pkarashchenko commented on code in PR #8735:
URL: https://github.com/apache/nuttx/pull/8735#discussion_r1126267607


##
net/socket/listen.c:
##
@@ -82,7 +82,12 @@ int psock_listen(FAR struct socket *psock, int backlog)
 
   /* Let the address family's listen() method handle the operation */
 
-  DEBUGASSERT(psock->s_sockif != NULL && psock->s_sockif->si_listen != NULL);
+  DEBUGASSERT(psock->s_sockif != NULL)

Review Comment:
   ```suggestion
 DEBUGASSERT(psock->s_sockif != NULL);
   ```



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] pkarashchenko merged pull request #8729: vfs/poll: Remove the unused ptr field from pollfd

2023-03-06 Thread via GitHub


pkarashchenko merged PR #8729:
URL: https://github.com/apache/nuttx/pull/8729


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[nuttx] branch master updated (1917870cca -> 9308a72419)

2023-03-06 Thread pkarashchenko
This is an automated email from the ASF dual-hosted git repository.

pkarashchenko pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx.git


from 1917870cca boards: stm32f4discovery: Update kostest/defconfig to avoid 
crash
 add 9308a72419 vfs/poll: Remove the unused ptr field from pollfd

No new revisions were added by this update.

Summary of changes:
 include/sys/poll.h | 1 -
 1 file changed, 1 deletion(-)



[GitHub] [nuttx] jturnsek commented on a diff in pull request #8738: Adding support for LS027B7DH01A display and MEMLCD_EXTCOMIN_MODE_HW

2023-03-06 Thread via GitHub


jturnsek commented on code in PR #8738:
URL: https://github.com/apache/nuttx/pull/8738#discussion_r1126270898


##
drivers/lcd/memlcd.c:
##
@@ -165,6 +182,7 @@ static int memlcd_setcontrast(struct lcd_dev_s *dev, 
unsigned int contrast);
  * Private Data
  /
 
+static uint8_t _sharpmem_vcom;
 static uint8_t g_runbuffer[MEMLCD_BPP * MEMLCD_XRES / 8];

Review Comment:
   g_runbuffer could not be moved to memlcd_dev_s, because it is used in 
planeinfo structure



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx-apps] pkarashchenko merged pull request #1609: interpreters/wamr: add compile role of WebAssembly

2023-03-06 Thread via GitHub


pkarashchenko merged PR #1609:
URL: https://github.com/apache/nuttx-apps/pull/1609


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[nuttx-apps] branch master updated: interpreters/wamr: add compile role of WebAssembly

2023-03-06 Thread pkarashchenko
This is an automated email from the ASF dual-hosted git repository.

pkarashchenko pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx-apps.git


The following commit(s) were added to refs/heads/master by this push:
 new 4f11f38c3 interpreters/wamr: add compile role of WebAssembly
4f11f38c3 is described below

commit 4f11f38c384f5fafde7da954ddb2e3342b1a1d9d
Author: chao an 
AuthorDate: Thu Mar 2 11:46:37 2023 +0800

interpreters/wamr: add compile role of WebAssembly

Add compilation rules to support WebAssembly(WASM/WAMR):

1. Compile Toolchain
 1> Download WASI sdk and export the WASI_SDK_PATH path:

$ wget 
https://github.com/WebAssembly/wasi-sdk/releases/download/wasi-sdk-19/wasi-sdk-19.0-linux.tar.gz
$ tar xf wasi-sdk-19.0-linux.tar.gz
Put wasi-sdk-19.0 to your host WASI_SDK_PATH environment variable, like:
$ export WASI_SDK_PATH=`pwd`/wasi-sdk-19.0

 2> Download Wamr "wamrc" AOT compiler and export to the PATH:
$ mkdir wamrc
$ wget 
https://github.com/bytecodealliance/wasm-micro-runtime/releases/download/WAMR-1.1.2/wamrc-1.1.2-x86_64-ubuntu-20.04.tar.gz
$ tar xf wamrc-1.1.2-x86_64-ubuntu-20.04.tar.gz
$ export PATH=$PATH:$PWD

2. Configuring and running

 1> Configuring sim/wamr and compile:

nuttx$ ./tools/configure.sh  sim/wamr
nuttx$ make
...
Wamrc Generate AoT: /home/archer/code/nuttx/n5/apps/wasm/hello.aot
Wamrc Generate AoT: /home/archer/code/nuttx/n5/apps/wasm/coremark.aot
LD:  nuttx

 2> Copy the generated wasm file(Interpreter/AoT)

nuttx$ cp ../apps/wasm/hello.aot .
nuttx$ cp ../apps/wasm/hello.wasm .
nuttx$ cp ../apps/wasm/coremark.wasm .

 3> Run iwasm

nuttx$ ./nuttx
NuttShell (NSH) NuttX-10.4.0
nsh> iwasm /data/hello.wasm
Hello, World!!
nsh> iwasm /data/hello.aot
Hello, World!!
nsh> iwasm /data/coremark.wasm
2K performance run parameters for coremark.
CoreMark Size: 666
Total ticks  : 12000
Total time (secs): 12.00
Iterations/Sec   : 5.00
Iterations   : 60
Compiler version : Clang 15.0.7
Compiler flags   : Using NuttX compilation options
Memory location  : Defined by the NuttX configuration
seedcrc  : 0xe9f5
[0]crclist   : 0xe714
[0]crcmatrix : 0x1fd7
[0]crcstate  : 0x8e3a
[0]crcfinal  : 0xa14c
Correct operation validated. See README.md for run and reporting rules.
CoreMark 1.0 : 5.00 / Clang 15.0.7 Using NuttX compilation options / 
Defined by the NuttX configuration

Co-Authored-By: Huang Qi 
Signed-off-by: chao an 
---
 .gitignore   |   2 +
 Application.mk   |   6 ++
 Make.defs|  19 -
 Makefile |  11 +++
 benchmarks/coremark/Makefile |   4 ++
 examples/hello/Makefile  |   8 +++
 interpreters/Wasm.mk |  68 ++
 interpreters/wamr/Toolchain.defs | 149 +++
 8 files changed, 266 insertions(+), 1 deletion(-)

diff --git a/.gitignore b/.gitignore
index 23bd48c86..794f52e36 100644
--- a/.gitignore
+++ b/.gitignore
@@ -11,6 +11,7 @@
 *.lib
 *.lst
 *.o
+*.wo
 *.obj
 *.rel
 *.src
@@ -28,6 +29,7 @@
 /romfs.img
 /staging
 /symtab_apps.c
+/wasm
 cscope.out
 Make.dep
 .context
diff --git a/Application.mk b/Application.mk
index cd196b740..c54829a13 100644
--- a/Application.mk
+++ b/Application.mk
@@ -262,3 +262,9 @@ distclean:: clean
$(call DELFILE, .depend)
 
 -include Make.dep
+
+ifeq ($(WASM_BUILD),y)
+  ifneq ($(CONFIG_INTERPRETERS_WAMR)$(CONFIG_INTERPRETERS_WAMR3),)
+include $(APPDIR)$(DELIM)interpreters$(DELIM)Wasm.mk
+  endif # CONFIG_INTERPRETERS_WAMR || CONFIG_INTERPRETERS_WAMR3
+endif # WASM_BUILD
diff --git a/Make.defs b/Make.defs
index f1f66f4c4..d87cd0072 100644
--- a/Make.defs
+++ b/Make.defs
@@ -65,7 +65,8 @@ BINDIR ?= $(APPDIR)$(DELIM)bin
 
 # The final build target
 
-BIN ?= $(APPDIR)$(DELIM)libapps$(LIBEXT)
+BIN  ?= $(APPDIR)$(DELIM)libapps$(LIBEXT)
+WBIN ?= $(APPDIR)$(DELIM)wasm$(DELIM)libwasm$(LIBEXT)
 
 # Tools
 
@@ -105,3 +106,19 @@ CFLAGS   += ${INCDIR_PREFIX}"$(APPDIR)$(DELIM)include"
 CXXFLAGS += ${INCDIR_PREFIX}"$(APPDIR)$(DELIM)include"
 
 NUTTXLIB ?= $(call CONVERT_PATH,$(TOPDIR)$(DELIM)staging)
+
+# Function to get entry index
+
+define GETINDEX
+   $(eval i=1)
+   $(eval entry=)
+   $(foreach e,$(2), \
+ $(if $(filter $(notdir $(1)),$(notdir $(e))), \
+   $(eval entry=$(1)), \
+   $(if $(entry), \
+ ,$(eval i=$(shell expr $(i) + 1)) \
+   ) \
+ ) \
+   )
+   $(i)
+endef
diff --git a/Makefile b/Makefile
index 28a3b0c77..e21ddd09e 100644
--- a/Makefile
+++ b/Makefile
@@ -21,6 +21,10 @@
 export APPDIR = $(CURDIR)
 include $(APPDIR)/Make.defs
 
+ifeq ($(CONFIG_INTERPRETERS_WAMR),y)
+  include $(APPD

[GitHub] [nuttx-apps] simbit18 opened a new pull request, #1626: nuttx-apps/examples/qencoder: Fix mistakes in comments

2023-03-06 Thread via GitHub


simbit18 opened a new pull request, #1626:
URL: https://github.com/apache/nuttx-apps/pull/1626

   ## Summary
   Fix mistakes in comments
   ## Impact
   none
   ## Testing
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx-apps] pkarashchenko commented on a diff in pull request #1624: Adding sdr group with liquid-dsp library

2023-03-06 Thread via GitHub


pkarashchenko commented on code in PR #1624:
URL: https://github.com/apache/nuttx-apps/pull/1624#discussion_r1126281678


##
sdr/liquid_dsp/config.h:
##
@@ -0,0 +1,326 @@
+/
+ * apps/sdr/liquid_dsp/config.h
+ *
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.  The
+ * ASF licenses this file to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance with the
+ * License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
+ * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.  See the
+ * License for the specific language governing permissions and limitations
+ * under the License.
+ *
+ /
+
+#ifndef __LIQUID_CONFIG_H__
+#define __LIQUID_CONFIG_H__

Review Comment:
   ```suggestion
   #ifndef __APPS_SRC_LIQUID_DSP_CONFIG_H
   #define __APPS_SRC_LIQUID_DSP_CONFIG_H
   ```



##
sdr/liquid_dsp/config.h:
##
@@ -0,0 +1,326 @@
+/
+ * apps/sdr/liquid_dsp/config.h
+ *
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.  The
+ * ASF licenses this file to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance with the
+ * License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
+ * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.  See the
+ * License for the specific language governing permissions and limitations
+ * under the License.
+ *
+ /
+
+#ifndef __LIQUID_CONFIG_H__
+#define __LIQUID_CONFIG_H__
+
+/* Support AVX (Advanced Vector Extensions) instructions */
+
+#define HAVE_AVX 0
+
+/* Define to 1 if you have the `cargf' function. */
+
+#define HAVE_CARGF 1
+
+/* Define to 1 if you have the `cexpf' function. */
+
+#define HAVE_CEXPF 1
+
+/* Define to 1 if you have the `cimagf' function. */
+
+#define HAVE_CIMAGF 1
+
+/* Define to 1 if you have the  header file. */
+
+#define HAVE_COMPLEX_H 1
+
+/* Define to 1 if you have the `cosf' function. */
+
+#define HAVE_COSF 1
+
+/* Define to 1 if you have the `crealf' function. */
+
+#define HAVE_CREALF 1
+
+/* Define to 1 if you have the  header file. */
+
+#define HAVE_EMMINTRIN_H 0
+
+/* Define to 1 if you have the `expf' function. */
+
+#define HAVE_EXPF 1
+
+/* Define to 1 if you have the  header file. */
+
+/* #undef HAVE_FEC_H */
+
+/* Define to 1 if you have the  header file. */
+
+/* #undef HAVE_FFTW3_H */
+
+/* Define to 1 if you have the  header file. */
+
+#define HAVE_FLOAT_H 1
+
+/* Define to 1 if you have the `free' function. */
+
+#define HAVE_FREE 1
+
+/* Define to 1 if you have the  header file. */
+
+#define HAVE_GETOPT_H 1
+
+/* Define to 1 if you have the  header file. */
+
+#define HAVE_IMMINTRIN_H 0
+
+/* Define to 1 if you have the  header file. */
+
+#define HAVE_INTTYPES_H 1
+
+/* Define to 1 if you have the `c' library (-lc). */
+
+#define HAVE_LIBC 1
+
+/* Define to 1 if you have the `fec' library (-lfec). */
+
+/* #undef HAVE_LIBFEC */
+
+/* Define to 1 if you have the `fftw3f' library (-lfftw3f). */
+
+/* #undef HAVE_LIBFFTW3F */
+
+/* Define to 1 if you have the `m' library (-lm). */
+
+#define HAVE_LIBM 1
+
+/* Define to 1 if you have the  header file. */
+
+#define HAVE_LIMITS_H 1
+
+/* Define to 1 if you have the `malloc' function. */
+
+#define HAVE_MALLOC 1
+
+/* Define to 1 if you have the `memmove' function. */
+
+#define HAVE_MEMMOVE 1
+
+/* Define to 1 if you have the  header file. */
+
+#define HAVE_MEMORY_H 1
+
+/* Define to 1 if you have the `memset' function. */
+
+#define HAVE_MEMSET 1
+
+/* Define to 1 if you have the  header file. */
+
+#define HAVE_MMINTRIN_H 0
+
+/* Support MMX instructions */
+
+#define HAVE_MMX 0
+
+/* Define to 1 if you have the  header file. */
+
+#define HAVE_PMMINTRIN_H 0
+
+/* Define to 1 if you have the `realloc' function. */
+
+#define HAVE_REALLOC 1
+
+/* Define to 1 if you have the `sinf' function. */
+
+#define HAVE_SINF 1
+
+/* Define to 1 if you have the  header file. */
+
+#define HAVE_SMMINTRIN_H 0
+
+/* D

[GitHub] [nuttx] wengzhe commented on a diff in pull request #8739: net/arp: Only parse ioctl request for valid cmd.

2023-03-06 Thread via GitHub


wengzhe commented on code in PR #8739:
URL: https://github.com/apache/nuttx/pull/8739#discussion_r1126290034


##
net/netdev/netdev_ioctl.c:
##
@@ -1219,6 +1219,40 @@ static int netdev_imsf_ioctl(FAR struct socket *psock, 
int cmd,
 }
 #endif
 
+/
+ * Name: ioctl_arpreq_parse
+ *
+ * Description:
+ *   Parse arpreq into netdev and sockaddr.
+ *
+ * Input Parameters:
+ *   reqThe argument of the ioctl cmd
+ *   devThe pointer to get ethernet driver device structure
+ *   addr   The pointer to get address in the request
+ *
+ * Returned Value:
+ *   true on success and false on failure.
+ *
+ /
+
+#ifdef CONFIG_NET_ARP
+static bool ioctl_arpreq_parse(FAR struct arpreq *req,
+   FAR struct net_driver_s **dev,
+   FAR struct sockaddr_in **addr)
+{
+  if (req != NULL)
+{
+  *addr = (FAR struct sockaddr_in *)&req->arp_pa;
+  *dev  = req->arp_dev[0] ?

Review Comment:
   Done.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] anchao commented on issue #8533: Assertion fails while freeing IOBs.

2023-03-06 Thread via GitHub


anchao commented on issue #8533:
URL: https://github.com/apache/nuttx/issues/8533#issuecomment-1455979986

   > @anchao Did you have and progress on this?
   > 
   > Or maybe, can you share any thoughts so I can help troubleshooting this 
more effectively? You may suggest any more `ASSERT()`'s to be placed, so I can 
test and help pin-point the issue?
   
   I've added some debug info but can't seem to reproduce the issue 
successfully, can you enable some debug info to reproduce the issue?
   
   ```bash
   CONFIG_DEBUG_INFO=y
   CONFIG_DEBUG_WARN=y
   CONFIG_IOB_DEBUG=y
   ```
   
   and add printing of ipv4 proto:
   ```bash
   diff --git a/net/devif/ipv4_input.c b/net/devif/ipv4_input.c
   index 7a04d96dc2..3defcdd4e4 100644
   --- a/net/devif/ipv4_input.c
   +++ b/net/devif/ipv4_input.c
   @@ -398,6 +398,8 @@ static int ipv4_in(FAR struct net_driver_s *dev)

  /* Now process the incoming packet according to the protocol. */

   +  syslog(1, "ipv4 input proto: %d\n", ipv4->proto);
   +
  switch (ipv4->proto)
{
#ifdef NET_TCP_HAVE_STACK
   ```
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] pkarashchenko merged pull request #8736: ubsan: Implement __ubsan_handle_invalid_builtin

2023-03-06 Thread via GitHub


pkarashchenko merged PR #8736:
URL: https://github.com/apache/nuttx/pull/8736


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[nuttx] branch master updated (9308a72419 -> aba0a25524)

2023-03-06 Thread pkarashchenko
This is an automated email from the ASF dual-hosted git repository.

pkarashchenko pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx.git


from 9308a72419 vfs/poll: Remove the unused ptr field from pollfd
 add aba0a25524 ubsan: Implement __ubsan_handle_invalid_builtin

No new revisions were added by this update.

Summary of changes:
 mm/ubsan/ubsan.c | 5 +
 1 file changed, 5 insertions(+)



[GitHub] [nuttx] michallenc opened a new pull request, #8741: pwm: add config option to support dead time delay + add dead time support to SAMv7 MCU

2023-03-06 Thread via GitHub


michallenc opened a new pull request, #8741:
URL: https://github.com/apache/nuttx/pull/8741

   ## Summary
   PWM drivers usually supports dead time generators that automatically insert 
output activation delay for complementary PWM outputs. This is useful for some 
control purposes as control of H bridge for example.
   
   The first commit adds an application to driver interface that can be used to 
set up those delays (if supported by the selected architecture) directly from 
the application. The set up remains the same as for duty cycle value.
   
   The second commit adds dead time delay support for SAMv7 MCU.
   
   ## Impact
   
   SAMv7 and generic PWM driver (dead time remains under by default disabled 
configuration option and therefore should not have any impact on current state 
of the driver or already implemented applications).
   
   ## Testing
   
   Tested on same70-xplained board.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx-apps] pkarashchenko commented on a diff in pull request #1625: Initial load for nng library

2023-03-06 Thread via GitHub


pkarashchenko commented on code in PR #1625:
URL: https://github.com/apache/nuttx-apps/pull/1625#discussion_r1126309646


##
examples/nng_test/pubsub.c:
##
@@ -0,0 +1,136 @@
+/
+ * apps/examples/nng_test/pubsub.c
+ *
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.  The
+ * ASF licenses this file to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance with the
+ * License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
+ * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.  See the
+ * License for the specific language governing permissions and limitations
+ * under the License.
+ *
+ /
+
+/
+ * Included Files
+ /
+
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+
+#include 
+#include 
+#include 
+
+/
+ * Public Functions
+ /
+
+void
+fatal(const char *func, int rv)
+{
+  fprintf(stderr, "%s: %s\n", func, nng_strerror(rv));
+}
+
+char *
+date(void)

Review Comment:
   ```suggestion
   FAR char *date(void)
   ```



##
examples/nng_test/pubsub.c:
##
@@ -0,0 +1,136 @@
+/
+ * apps/examples/nng_test/pubsub.c
+ *
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.  The
+ * ASF licenses this file to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance with the
+ * License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
+ * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.  See the
+ * License for the specific language governing permissions and limitations
+ * under the License.
+ *
+ /
+
+/
+ * Included Files
+ /
+
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+
+#include 
+#include 
+#include 
+
+/
+ * Public Functions
+ /
+
+void
+fatal(const char *func, int rv)
+{
+  fprintf(stderr, "%s: %s\n", func, nng_strerror(rv));
+}
+
+char *
+date(void)
+{
+  time_t now = time(&now);
+  struct tm *info = localtime(&now);
+  char *text = asctime(info);
+  text[strlen(text) - 1] = '\0';
+  return (text);

Review Comment:
   ```suggestion
 return text;
   ```



##
examples/nng_test/pubsub.c:
##
@@ -0,0 +1,136 @@
+/
+ * apps/examples/nng_test/pubsub.c
+ *
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.  The
+ * ASF licenses this file to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance with the
+ * License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
+ * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.  See the
+ * License for the specific language governing permissions and limitations
+ * under the License.
+ *
+ /
+
+/
+ * Included Files
+ *

[GitHub] [nuttx] pkarashchenko commented on a diff in pull request #8741: pwm: add config option to support dead time delay + add dead time support to SAMv7 MCU

2023-03-06 Thread via GitHub


pkarashchenko commented on code in PR #8741:
URL: https://github.com/apache/nuttx/pull/8741#discussion_r1126331253


##
arch/arm/src/samv7/sam_pwm.c:
##
@@ -326,6 +326,11 @@ static void pwm_set_output(struct pwm_lowerhalf_s *dev, 
uint8_t channel,
 static void pwm_set_freq(struct pwm_lowerhalf_s *dev, uint8_t channel,
  uint32_t frequency);
 static void pwm_set_comparison(struct pwm_lowerhalf_s *dev);
+#ifdef CONFIG_PWM_DEADTIME
+static void pwm_set_deadtime(struct pwm_lowerhalf_s *dev, uint8_t channel,
+   ub16_t dead_time_a, ub16_t dead_time_b,
+   ub16_t duty);

Review Comment:
   ```suggestion
   static void pwm_set_deadtime(struct pwm_lowerhalf_s *dev, uint8_t channel,
ub16_t dead_time_a, ub16_t dead_time_b,
ub16_t duty);
   ```



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] pkarashchenko commented on a diff in pull request #8726: Replace the unsafe function(strcat, sprintf) with the safe one(strlcat, snprintf)

2023-03-06 Thread via GitHub


pkarashchenko commented on code in PR #8726:
URL: https://github.com/apache/nuttx/pull/8726#discussion_r1126337438


##
drivers/wireless/ieee80211/bcm43xxx/bcmf_utils.c:
##
@@ -62,9 +62,10 @@ void bcmf_hexdump(FAR uint8_t *data, unsigned int len, 
unsigned long offset)
   char_count = 0;
 }
 
-  sprintf(hex_line + 3 * char_count, "%02x ", data[i]);
-  sprintf(char_line + char_count, "%c",
-  data[i] < 0x20 || data[i] >= 0x7f? '.': data[i]);
+  snprintf(hex_line + 3 * char_count, sizeof(hex_line) - 3 * char_count,
+   "%02x ", data[i]);
+  snprintf(char_line + char_count, sizeof(char_line) - char_count,
+   "%c", data[i] < 0x20 || data[i] >= 0x7f? '.': data[i]);

Review Comment:
   ```suggestion
  "%c", data[i] < 0x20 || data[i] >= 0x7f ? '.' : data[i]);
   ```



##
arch/arm/src/phy62xx/uart.h:
##
@@ -165,7 +165,11 @@ int hal_uart_set_tx_buf(UART_INDEX_e uart_index, uint8_t 
*buf,
 uint16_t size);
 int hal_uart_get_tx_ready(UART_INDEX_e uart_index);
 int hal_uart_send_buff(UART_INDEX_e uart_index, uint8_t *buff, uint16_t len);
-#define logx(...) {char tmp_str[128]; sprintf(tmp_str, __VA_ARGS__); 
hal_uart_send_buff(0, &tmp_str, strlen(tmp_str) + 1);}
+#define logx(...) { \
+  char tmp_str[128]; \
+  snprintf(tmp_str, sizeof(tmp_str), __VA_ARGS__); \
+  hal_uart_send_buff(0, &tmp_str, strlen(tmp_str) + 1); \
+  }

Review Comment:
   `do {} while (0)`?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx-apps] pkarashchenko commented on a diff in pull request #1625: Initial load for nng library

2023-03-06 Thread via GitHub


pkarashchenko commented on code in PR #1625:
URL: https://github.com/apache/nuttx-apps/pull/1625#discussion_r1126340402


##
examples/nng_test/pubsub.c:
##
@@ -0,0 +1,141 @@
+/
+ * apps/examples/nng_test/pubsub.c
+ *
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.  The
+ * ASF licenses this file to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance with the
+ * License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
+ * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.  See the
+ * License for the specific language governing permissions and limitations
+ * under the License.
+ *
+ /
+
+/
+ * Included Files
+ /
+
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+
+#include 
+#include 
+#include 
+
+/
+ * Public Functions
+ /
+
+void fatal(FAR const char *func, int rv)
+{
+  fprintf(stderr, "%s: %s\n", func, nng_strerror(rv));
+}
+
+FAR char *date(void)
+{
+  time_t now = time(&now);
+  FAR struct tm *info = localtime(&now);
+  FAR char *text = asctime(info);
+  text[strlen(text) - 1] = '\0';
+  return text;
+}
+
+FAR void *client_thread(pthread_addr_t pvarg)
+{
+  nng_socket sock;
+  int rv;
+
+  sleep(2);
+
+  if ((rv = nng_sub0_open(&sock)) != 0)
+{
+  fatal("nng_sub0_open", rv);
+  return NULL;
+}
+
+  /* subscribe to everything (empty means all topics) */
+
+  if ((rv = nng_setopt(sock, NNG_OPT_SUB_SUBSCRIBE, "", 0)) != 0)
+{
+  fatal("nng_setopt", rv);
+  return NULL;

Review Comment:
   should we call `nng_sub0_close` or anything similar on failure path here and 
other places?



##
netutils/nng/.gitignore:
##
@@ -0,0 +1,2 @@
+

Review Comment:
   ```suggestion
   ```



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx-apps] anjiahao1 opened a new pull request, #1627: support ymodem protocal and sb rb application

2023-03-06 Thread via GitHub


anjiahao1 opened a new pull request, #1627:
URL: https://github.com/apache/nuttx-apps/pull/1627

   ## Summary
   support ymodem, can use `sb` `rb` to send file and receive file
   ## Impact
   Noting
   ## Testing
   
   i test sb and rb in armv8-m borad, that run ok.
   Compared with zmodem, ymodem is less prone to errors and has lower 
requirements on hardware.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx-apps] jturnsek commented on a diff in pull request #1625: Initial load for nng library

2023-03-06 Thread via GitHub


jturnsek commented on code in PR #1625:
URL: https://github.com/apache/nuttx-apps/pull/1625#discussion_r1126349097


##
examples/nng_test/pubsub.c:
##
@@ -0,0 +1,141 @@
+/
+ * apps/examples/nng_test/pubsub.c
+ *
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.  The
+ * ASF licenses this file to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance with the
+ * License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
+ * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.  See the
+ * License for the specific language governing permissions and limitations
+ * under the License.
+ *
+ /
+
+/
+ * Included Files
+ /
+
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+
+#include 
+#include 
+#include 
+
+/
+ * Public Functions
+ /
+
+void fatal(FAR const char *func, int rv)
+{
+  fprintf(stderr, "%s: %s\n", func, nng_strerror(rv));
+}
+
+FAR char *date(void)
+{
+  time_t now = time(&now);
+  FAR struct tm *info = localtime(&now);
+  FAR char *text = asctime(info);
+  text[strlen(text) - 1] = '\0';
+  return text;
+}
+
+FAR void *client_thread(pthread_addr_t pvarg)
+{
+  nng_socket sock;
+  int rv;
+
+  sleep(2);
+
+  if ((rv = nng_sub0_open(&sock)) != 0)
+{
+  fatal("nng_sub0_open", rv);
+  return NULL;
+}
+
+  /* subscribe to everything (empty means all topics) */
+
+  if ((rv = nng_setopt(sock, NNG_OPT_SUB_SUBSCRIBE, "", 0)) != 0)
+{
+  fatal("nng_setopt", rv);
+  return NULL;

Review Comment:
   I've took this example directly from nng, where there is no return 
statements in case of failure. Also I can not find close function. Beeing only 
an example I do not see it as a problem, althoug in some mission critical code, 
one must take all the precautions.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] TimJTi opened a new pull request, #8742: ACT8945A: Correct DEBUGASSERT code error, plus tidy ups

2023-03-06 Thread via GitHub


TimJTi opened a new pull request, #8742:
URL: https://github.com/apache/nuttx/pull/8742

   ## Summary
   
   Found a silly DEBUGASSERT logical error.
   
   Whilst correcting this spotted a _err formatting warning; fixed and slightly 
amended it to fix the warning. Also attempted to fix a previously raised 
concern about C89 compatibility.
   
   ## Impact
   
   None, unless you have DEBUGASSERTS enabled in which case it will no longer 
assert because of the error.
   
   ## Testing
   Custome board: SAMA5D27C-D1M with act8945a regulator
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] pkarashchenko commented on a diff in pull request #8742: ACT8945A: Correct DEBUGASSERT code error, plus tidy ups

2023-03-06 Thread via GitHub


pkarashchenko commented on code in PR #8742:
URL: https://github.com/apache/nuttx/pull/8742#discussion_r1126382056


##
drivers/power/supply/act8945a.c:
##
@@ -258,23 +258,32 @@
 #  define ACT8945A_LDO4_PULLDOWN 0
 #endif
 
-#define ACT8945A_REG(_id, _vsel)  \
+/* Ramp times are fixed for this regulator */
+
+#define ETIME_0   0
+#define ETIME_400 400
+#define ETIME_800 800
+
+#define ACT8945A_REG(_id, _vsel, _etime)  \
   [ACT8945A_##_id] =  \
   {   \
-.name  = CONFIG_ACT8945A_##_id##_NAME,\
-.id= ACT8945A_##_id,  \
 .n_voltages= ACT8945A_NUM_VOLTAGES,   \
 .vsel_reg  = ACT8945A_##_id##_##_vsel,\
 .vsel_mask = ACT8945A_VSET_MASK,  \
+.name  = CONFIG_ACT8945A_##_id##_NAME,\
+.id= ACT8945A_##_id,  \
 .enable_reg= ACT8945A_##_id##_CONTROL,\
 .enable_mask   = ACT8945A_EN_MASK,\
-.boot_on   = ACT8945A_##_id##_BOOT_ON,\
+.enable_time   = _etime,  \

Review Comment:
   ```suggestion
   .enable_time   = (_etime),\
   ```



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] TimJTi commented on a diff in pull request #8088: Add ACT8945A power driver

2023-03-06 Thread via GitHub


TimJTi commented on code in PR #8088:
URL: https://github.com/apache/nuttx/pull/8088#discussion_r1126387513


##
drivers/power/supply/act8945a.c:
##
@@ -0,0 +1,1081 @@
+/
+ * drivers/power/supply/act8945a.c
+ *
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.  The
+ * ASF licenses this file to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance with the
+ * License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
+ * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.  See the
+ * License for the specific language governing permissions and limitations
+ * under the License.
+ *
+ /
+
+/
+ * Included Files
+ /
+
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+
+#if defined(CONFIG_I2C) && defined(CONFIG_REGULATOR_ACT8945A)
+
+/
+ * Pre-processor Definitions
+ /
+#define ACT8945A_BUS_SPEED30
+#define ACT8945A_SLAVE_ADDRESS0x5b
+
+#ifdef CONFIG_DEBUG_POWER_ERROR
+#  define act8945a_err(x, ...)_err(x, ##__VA_ARGS__)
+#else
+#  define act8945a_err(x, ...)uerr(x, ##__VA_ARGS__)
+#endif
+#ifdef CONFIG_DEBUG_POWER_WARN
+#  define act8945a_warn(x, ...)   _warn(x, ##__VA_ARGS__)
+#else
+#  define act8945a_warn(x, ...)   uwarn(x, ##__VA_ARGS__)
+#endif
+#ifdef CONFIG_DEBUG_POWER_INFO
+#  define act8945a_info(x, ...)   _info(x, ##__VA_ARGS__)
+#else
+#  define act8945a_info(x, ...)   uinfo(x, ##__VA_ARGS__)
+#endif
+
+#define ACT8945A_NUM_VOLTAGES 64
+
+#define ACT8945A_SYS0 (0x00)
+#define ACT8945A_SYS1 (0x01)
+
+#define ACT8945A_DCDC1_VSET0  (0x20)
+#define ACT8945A_DCDC1_VSET1  (0x21)
+#define ACT8945A_DCDC1_CONTROL(0x22)
+#define ACT8945A_DCDC2_VSET0  (0x30)
+#define ACT8945A_DCDC2_VSET1  (0x31)
+#define ACT8945A_DCDC2_CONTROL(0x32)
+#define ACT8945A_DCDC3_VSET0  (0x40)
+#define ACT8945A_DCDC3_VSET1  (0x41)
+#define ACT8945A_DCDC3_CONTROL(0x42)
+#define ACT8945A_LDO1_VSET(0x50)
+#define ACT8945A_LDO1_CONTROL (0x51)
+#define ACT8945A_LDO2_VSET(0x54)
+#define ACT8945A_LDO2_CONTROL (0x55)
+#define ACT8945A_LDO3_VSET(0x60)
+#define ACT8945A_LDO3_CONTROL (0x61)
+#define ACT8945A_LDO4_VSET(0x64)
+#define ACT8945A_LDO4_CONTROL (0x65)
+
+#define ACT8945A_SYSTRST_MASK (0x80)
+#define ACT8945A_SYSMODE_MASK (0x40)
+#define ACT8945A_SYSLEV_MASK  (0x0f)
+
+#define ACT8945A_VSET_MASK(0x3f)
+#define ACT8945A_EN_MASK  (0x80)
+
+#define ACT8945A_SCRATCH_MASK (0x0f)
+#define SCRATCH_TEST_VAL  (0x05)
+
+#define ACT8945A_PULLDOWN_MASK(0x40)
+
+#ifdef CONFIG_ACT8945A_TRST_64
+#  define ACT8945A_TRST   (0x80) /* 64ms*/
+#else
+#  define ACT8945A_TRST   (0)/* 260ms */
+#endif
+
+#ifdef CONFIG_ACT8945A_SYSLEV_MODE_INTERRUPT
+#  define ACT8945A_SYSLEV_MODE(0x40) /* Interrupt */
+#else
+#  define ACT8945A_SYSLEV_MODE(0)/* Shutdown */
+#endif
+
+#if defined(CONFIG_ACT8945A_SYSLEV_2300)
+#  define ACT8945A_SYSLEV 0
+#elif defined(CONFIG_ACT8945A_SYSLEV_2400)
+#  define ACT8945A_SYSLEV 1
+#elif defined(CONFIG_ACT8945A_SYSLEV_2500)
+#  define ACT8945A_SYSLEV 2
+#elif defined(CONFIG_ACT8945A_SYSLEV_2600)
+#  define ACT8945A_SYSLEV 3
+#elif defined(CONFIG_ACT8945A_SYSLEV_2700)
+#  define ACT8945A_SYSLEV 4
+#elif defined(CONFIG_ACT8945A_SYSLEV_2800)
+#  define ACT8945A_SYSLEV 5
+#elif defined(CONFIG_ACT8945A_SYSLEV_2900)
+#  define ACT8945A_SYSLEV 6
+#elif defi

[GitHub] [nuttx] pkarashchenko commented on pull request #8742: ACT8945A: Correct DEBUGASSERT code error, plus tidy ups

2023-03-06 Thread via GitHub


pkarashchenko commented on PR #8742:
URL: https://github.com/apache/nuttx/pull/8742#issuecomment-1456097805

   Please squash commits


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx-apps] davids5 merged pull request #1626: nuttx-apps/examples/qencoder: Fix mistakes in comments

2023-03-06 Thread via GitHub


davids5 merged PR #1626:
URL: https://github.com/apache/nuttx-apps/pull/1626


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[nuttx-apps] 02/02: qe.h: fix nxstyle

2023-03-06 Thread davids5
This is an automated email from the ASF dual-hosted git repository.

davids5 pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx-apps.git

commit 02d293d4b7bca6a51ad88e9a8214789e8c4d0397
Author: simbit18 <101105604+simbi...@users.noreply.github.com>
AuthorDate: Mon Mar 6 12:21:05 2023 +0100

qe.h: fix nxstyle

fix error: Relative file path does not match actual file
---
 examples/qencoder/qe.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/examples/qencoder/qe.h b/examples/qencoder/qe.h
index 2c001ba33..ab243c6d8 100644
--- a/examples/qencoder/qe.h
+++ b/examples/qencoder/qe.h
@@ -1,5 +1,5 @@
 /
- * apps/examples/examples/qe/qe.h
+ * apps/examples/qencoder/qe.h
  *
  * Licensed to the Apache Software Foundation (ASF) under one or more
  * contributor license agreements.  See the NOTICE file distributed with



[nuttx-apps] 01/02: apps/examples/qencoder/Makefile: Fix mistakes in comments

2023-03-06 Thread davids5
This is an automated email from the ASF dual-hosted git repository.

davids5 pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx-apps.git

commit baf15a1a893c6e5611bd32dd64ab6633f9347579
Author: simbit18 <101105604+simbi...@users.noreply.github.com>
AuthorDate: Mon Mar 6 12:14:03 2023 +0100

apps/examples/qencoder/Makefile: Fix mistakes in comments

Fix mistakes in comments
---
 examples/qencoder/Makefile | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/examples/qencoder/Makefile b/examples/qencoder/Makefile
index 354c8ee2f..fe6b71cf6 100644
--- a/examples/qencoder/Makefile
+++ b/examples/qencoder/Makefile
@@ -1,5 +1,5 @@
 
-# apps/examples/qe/Makefile
+# apps/examples/qencoder/Makefile
 #
 # Licensed to the Apache Software Foundation (ASF) under one or more
 # contributor license agreements.  See the NOTICE file distributed with
@@ -20,7 +20,7 @@
 
 include $(APPDIR)/Make.defs
 
-# NuttX NX Graphics Example.
+# Quadrature Encoder example.
 
 MAINSRC = qe_main.c
 



[nuttx-apps] branch master updated (4f11f38c3 -> 02d293d4b)

2023-03-06 Thread davids5
This is an automated email from the ASF dual-hosted git repository.

davids5 pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx-apps.git


from 4f11f38c3 interpreters/wamr: add compile role of WebAssembly
 new baf15a1a8 apps/examples/qencoder/Makefile: Fix mistakes in comments
 new 02d293d4b qe.h: fix nxstyle

The 2 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 examples/qencoder/Makefile | 4 ++--
 examples/qencoder/qe.h | 2 +-
 2 files changed, 3 insertions(+), 3 deletions(-)



[GitHub] [nuttx-apps] simbit18 opened a new pull request, #1628: apps/testing: Fix mistakes in comments

2023-03-06 Thread via GitHub


simbit18 opened a new pull request, #1628:
URL: https://github.com/apache/nuttx-apps/pull/1628

   ## Summary
   Fix mistakes in comments
   ## Impact
   none
   ## Testing
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] acassis commented on a diff in pull request #8741: pwm: add config option to support dead time delay + add dead time support to SAMv7 MCU

2023-03-06 Thread via GitHub


acassis commented on code in PR #8741:
URL: https://github.com/apache/nuttx/pull/8741#discussion_r1126438448


##
drivers/timers/Kconfig:
##
@@ -46,6 +50,20 @@ config PWM_OVERWRITE
controlled from an application level the same way duty cycle or
frequency is modified.
 
+config PWM_DEADTIME
+   bool "PWM Deadtime Support"
+   default n
+   depends on ARCH_HAVE_PWM_DEADTIME
+   ---help---
+   Some hardware will support deadtime generators that 
automatically
+   instert output activation delay for complementary PWM outputs. 
This
+   is usefull for H-bridge motor control for example. The deadtime
+   values are set from application level via the same IOCTL that 
sets
+   up duty cycle and freqeuncy.

Review Comment:
   ```suggestion
up duty cycle and frequency.



##
drivers/timers/Kconfig:
##
@@ -46,6 +50,20 @@ config PWM_OVERWRITE
controlled from an application level the same way duty cycle or
frequency is modified.
 
+config PWM_DEADTIME
+   bool "PWM Deadtime Support"
+   default n
+   depends on ARCH_HAVE_PWM_DEADTIME
+   ---help---
+   Some hardware will support deadtime generators that 
automatically
+   instert output activation delay for complementary PWM outputs. 
This

Review Comment:
   ```suggestion
insert output activation delay for complementary PWM outputs. 
This



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] zyfeier opened a new pull request, #8743: Pthread mutex: modify pthread to use nxmutex

2023-03-06 Thread via GitHub


zyfeier opened a new pull request, #8743:
URL: https://github.com/apache/nuttx/pull/8743

   ## Summary
   
   1. Merge nxmutex and nxrmutex;
   2. Modify pthread to use nxmutex;
   
   ## Impact
   
   mutex
   
   ## Testing
   
   ostest
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] acassis merged pull request #8739: net/arp: Only parse ioctl request for valid cmd.

2023-03-06 Thread via GitHub


acassis merged PR #8739:
URL: https://github.com/apache/nuttx/pull/8739


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[nuttx] branch master updated (aba0a25524 -> 7111d23ae4)

2023-03-06 Thread acassis
This is an automated email from the ASF dual-hosted git repository.

acassis pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx.git


from aba0a25524 ubsan: Implement __ubsan_handle_invalid_builtin
 add 7111d23ae4 net/arp: Only parse ioctl request for valid cmd.

No new revisions were added by this update.

Summary of changes:
 net/netdev/netdev_ioctl.c | 54 +++
 1 file changed, 41 insertions(+), 13 deletions(-)



[GitHub] [nuttx] acassis closed issue #8719: Xtensa_user_panic when trying to ping from nsh console in a telnet session

2023-03-06 Thread via GitHub


acassis closed issue #8719: Xtensa_user_panic when trying to ping from nsh 
console in a telnet session
URL: https://github.com/apache/nuttx/issues/8719


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] acassis merged pull request #8737: arm/armv8-m: add missing zig flags

2023-03-06 Thread via GitHub


acassis merged PR #8737:
URL: https://github.com/apache/nuttx/pull/8737


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[nuttx] branch master updated (7111d23ae4 -> 34a032b486)

2023-03-06 Thread acassis
This is an automated email from the ASF dual-hosted git repository.

acassis pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx.git


from 7111d23ae4 net/arp: Only parse ioctl request for valid cmd.
 add 34a032b486 arm/armv8-m: add missing zig flags

No new revisions were added by this update.

Summary of changes:
 arch/arm/src/armv8-m/Toolchain.defs | 1 +
 1 file changed, 1 insertion(+)



[GitHub] [nuttx] davids5 commented on issue #7435: Assertion fails within STM32 MAC driver.

2023-03-06 Thread via GitHub


davids5 commented on issue #7435:
URL: https://github.com/apache/nuttx/issues/7435#issuecomment-1456190213

   @fjpanag I do not have a setup at the moment. Has the usage of dev->d_len, 
changed in resent Network changes? Is the assert still valid? If it is and we 
are not resetting dev->d_len = 0 on a drop could that be the cause?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] pkarashchenko commented on pull request #8742: ACT8945A: Correct DEBUGASSERT code error, plus tidy ups

2023-03-06 Thread via GitHub


pkarashchenko commented on PR #8742:
URL: https://github.com/apache/nuttx/pull/8742#issuecomment-1456228708

   The C89 issue is not fixed. Anyway I can try to get back compatibility later


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[nuttx] branch master updated: Adding support for LS027B7DH01A display and MEMLCD_EXTCOMIN_MODE_HW

2023-03-06 Thread pkarashchenko
This is an automated email from the ASF dual-hosted git repository.

pkarashchenko pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx.git


The following commit(s) were added to refs/heads/master by this push:
 new 4c2edece50 Adding support for LS027B7DH01A display and 
MEMLCD_EXTCOMIN_MODE_HW
4c2edece50 is described below

commit 4c2edece50a65ffb21325e8922b793d549f21a9f
Author: jturnsek 
AuthorDate: Mon Mar 6 10:34:32 2023 +0100

Adding support for LS027B7DH01A display and MEMLCD_EXTCOMIN_MODE_HW
---
 drivers/lcd/Kconfig  |  5 +++
 drivers/lcd/memlcd.c | 89 ++--
 2 files changed, 77 insertions(+), 17 deletions(-)

diff --git a/drivers/lcd/Kconfig b/drivers/lcd/Kconfig
index 860a1d97f4..80be5c59a2 100644
--- a/drivers/lcd/Kconfig
+++ b/drivers/lcd/Kconfig
@@ -1039,6 +1039,11 @@ config MEMLCD_LS013B7DH03
---help---
Selects the LS013B7DH03 model
 
+config MEMLCD_LS027B7DH01A
+   bool "LS027B7DH01A"
+   ---help---
+   Selects the LS027B7DH01A model
+
 endchoice
 
 config MEMLCD_NINTERFACES
diff --git a/drivers/lcd/memlcd.c b/drivers/lcd/memlcd.c
index f30e98857f..06dd88c464 100644
--- a/drivers/lcd/memlcd.c
+++ b/drivers/lcd/memlcd.c
@@ -33,6 +33,8 @@
 #include 
 
 #include 
+#include 
+#include 
 #include 
 #include 
 #include 
@@ -63,6 +65,9 @@
 #elif defined CONFIG_MEMLCD_LS013B7DH03
 #  define MEMLCD_XRES128
 #  define MEMLCD_YRES128
+#elif defined CONFIG_MEMLCD_LS027B7DH01A
+#  define MEMLCD_XRES400
+#  define MEMLCD_YRES240
 #else
 #  error "This Memory LCD model is not supported yet."
 #endif
@@ -70,6 +75,7 @@
 /* lcd command */
 
 #define MEMLCD_CMD_UPDATE(0x01)
+#define MEMLCD_CMD_VCOM  (0x02)
 #define MEMLCD_CMD_ALL_CLEAR (0x04)
 #define MEMLCD_CONTROL_BYTES (0)
 
@@ -103,6 +109,15 @@
 #define LS_BIT   (1 << 0)
 #define MS_BIT   (1 << 7)
 
+#define MEMLCD_WORK_PERIOD   MSEC2TICK(500)
+
+#define TOGGLE_VCOM(dev) \
+  do \
+{\
+  dev->vcom = dev->vcom ? 0x00 : MEMLCD_CMD_VCOM;\
+}\
+  while (0);
+
 /
  * Private Type Definition
  /
@@ -119,7 +134,12 @@ struct memlcd_dev_s
   FAR struct memlcd_priv_s *priv; /* Board specific structure */
   uint8_t contrast;   /* Current contrast setting */
   uint8_t power;  /* Current power setting */
-
+#ifdef CONFIG_MEMLCD_EXTCOMIN_MODE_HW
+  struct work_s work;
+  uint8_t vcom;
+#else
+  bool pol;   /* Polarity  for extcomisr */
+#endif
   /* The memlcds does not support reading the display memory in SPI mode.
* Since there is 1 BPP and is byte access, it is necessary to keep a
* shadow copy of the framebuffer. At 128x128, it amounts to 2KB.
@@ -249,6 +269,41 @@ static inline int __test_bit(int nr, const volatile 
uint8_t * addr)
   return 1 & (addr[BIT_BYTE(nr)] >> (nr & (BITS_PER_BYTE - 1)));
 }
 
+/
+ * Name: memlcd_worker
+ *
+ * Description:
+ *   Toggle VCOM bit
+ *
+ * Input Parameters:
+ *   arg  - Reference to the memlcd_dev_s structure
+ *
+ * Returned Value:
+ *   None
+ *
+ /
+#ifdef CONFIG_MEMLCD_EXTCOMIN_MODE_HW
+static void memlcd_worker(FAR void *arg)
+{
+  FAR struct memlcd_dev_s *mlcd = arg;
+  uint16_t cmd = (uint16_t)mlcd->vcom;
+
+  TOGGLE_VCOM(mlcd);
+
+  memlcd_select(mlcd->spi);
+
+  up_udelay(2);
+
+  SPI_SNDBLOCK(mlcd->spi, &cmd, 2);
+
+  up_udelay(1);
+
+  memlcd_deselect(mlcd->spi);
+
+  work_queue(LPWORK, &mlcd->work, memlcd_worker, mlcd, MEMLCD_WORK_PERIOD);
+}
+#endif
+
 /
  * Name: memlcd_select
  *
@@ -329,16 +384,16 @@ static void memlcd_deselect(FAR struct spi_dev_s *spi)
 
 static inline void memlcd_clear(FAR struct memlcd_dev_s *mlcd)
 {
-  uint16_t cmd = MEMLCD_CMD_ALL_CLEAR;
+  uint16_t cmd = MEMLCD_CMD_VCOM | MEMLCD_CMD_ALL_CLEAR;
 
   lcdinfo("Clear display\n");
   memlcd_select(mlcd->spi);
 
-  /* XXX Ensure 2us here */
+  up_udelay(2);
 
   SPI_SNDBLOCK(mlcd->spi, &cmd, 2);
 
-  /* XXX Ensure 6us here */
+  up_udelay(1);
 
   memlcd_deselect(mlcd->spi);
 }
@@ -365,15 +420,10 @@ static inline void memlcd_clear(FAR struct memlcd_dev_s 
*mlcd)
 
 static int memlcd_extcominisr(int irq, FAR void *context, void *arg)
 {
-  static bool pol = 0;
-  struct memlcd_dev_s *mlcd = &g_memlcddev;
-#ifdef CONFIG_M

[GitHub] [nuttx] pkarashchenko merged pull request #8738: Adding support for LS027B7DH01A display and MEMLCD_EXTCOMIN_MODE_HW

2023-03-06 Thread via GitHub


pkarashchenko merged PR #8738:
URL: https://github.com/apache/nuttx/pull/8738


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] TimJTi commented on pull request #8742: ACT8945A: Correct DEBUGASSERT code error, plus tidy ups

2023-03-06 Thread via GitHub


TimJTi commented on PR #8742:
URL: https://github.com/apache/nuttx/pull/8742#issuecomment-1456234373


   
   
   
   > The C89 issue is not fixed. Anyway I can try to get back compatibility 
later
   
   I was trying to force the build to enforce strict c89 but have not worked 
out how to do that? Arm gcc, Linux.
   
   What is not compliant still - I am happy to fix once I understand :)


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx-apps] gustavonihei opened a new pull request, #1629: Include missing headers

2023-03-06 Thread via GitHub


gustavonihei opened a new pull request, #1629:
URL: https://github.com/apache/nuttx-apps/pull/1629

   ## Summary
   This PR intends to add missing headers to files from `nshlib` and 
`system/nsh` .
   These were being transitively included by the `userspace.h` header from 
`kmalloc.h`, which will be removed for not being required at the current point 
of inclusion.
   
   ## Impact
   No functional change, should have no impact.
   
   ## Testing
   CI build pass.
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] gustavonihei opened a new pull request, #8744: [ESP32-S3] Fix build of WebAssembly applications

2023-03-06 Thread via GitHub


gustavonihei opened a new pull request, #8744:
URL: https://github.com/apache/nuttx/pull/8744

   ## Summary
   This PR intends to fix the build of WebAssembly applications for the 
**ESP32-S3**, which currently fails due to the following error:
   ```
   /opt/wasi-sdk-19.0//bin/clang -pipe -I 
/home/nihei/Projects/NuttX/apps/benchmarks/coremark/coremark -I 
/home/nihei/Projects/NuttX/apps/benchmarks/coremark/coremark/posix -I 
/home/nihei/Projects/NuttX/apps/interpreters/wamr/wamr/core/iwasm/include -I 
"/home/nihei/Projects/NuttX/apps/include" -Wno-undef -DUSE_PTHREAD 
-DPERFORMANCE_RUN=1 -DMULTITHREAD=1 -DFLAGS_STR="\"Using NuttX compilation 
options\"" -DMEM_LOCATION=\""Defined by the NuttX configuration"\" 
--sysroot=/home/nihei/Projects/NuttX/nuttx -nostdlib -D__NuttX__ -c 
coremark/core_main.c -o core_main.wo
   In file included from coremark/core_main.c:23:
   In file included from 
/home/nihei/Projects/NuttX/apps/benchmarks/coremark/coremark/coremark.h:41:
   In file included from /home/nihei/Projects/NuttX/nuttx/include/stdio.h:35:
   In file included from 
/home/nihei/Projects/NuttX/nuttx/include/nuttx/lib/lib.h:31:
   In file included from 
/home/nihei/Projects/NuttX/nuttx/include/nuttx/kmalloc.h:36:
   In file included from 
/home/nihei/Projects/NuttX/nuttx/include/nuttx/userspace.h:35:
   In file included from 
/home/nihei/Projects/NuttX/nuttx/include/nuttx/arch.h:87:
   In file included from 
/home/nihei/Projects/NuttX/nuttx/include/nuttx/sched.h:39:
   In file included from 
/home/nihei/Projects/NuttX/nuttx/include/nuttx/irq.h:37:
   /home/nihei/Projects/NuttX/nuttx/include/arch/irq.h:336:11: error: unknown 
register name 'a2' in asm
   : : : "a2"
 ^
   1 error generated.
   make[3]: *** [/home/nihei/Projects/NuttX/apps/interpreters/Wasm.mk:50: 
core_main.wo] Error 1
   ```
   The proposed fix is to remove an unused include of `userspace.h` from 
`kmalloc.h`, which ends up including the arch-specific `nuttx/irq.h` that 
contains inline assembly instructions.
   
   ## Impact
   No functional changes, should have no impact.
   
   ## Testing
   Custom defconfig based on `esp32s3-devkit:nsh` for enabling WAMR support.
   CI build pass.
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx-apps] Cynerd opened a new pull request, #1630: treewide: silent download, unpack and others

2023-03-06 Thread via GitHub


Cynerd opened a new pull request, #1630:
URL: https://github.com/apache/nuttx-apps/pull/1630

   This introduces changes from NuttX commit
   03b164f59ce40a3f5677b0588af2aee8d9697bf6.
   
   The only left out is 'Register:' as that provides pretty handly list of 
applications in the firmware.
   
   The download is unified to handle it always the same way.
   
   Follow up on https://github.com/apache/nuttx-apps/pull/1588#event-8649968171.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] Cynerd opened a new pull request, #8745: samv7: switch from printing numbers as signed to unsigned in QSPI

2023-03-06 Thread via GitHub


Cynerd opened a new pull request, #8745:
URL: https://github.com/apache/nuttx/pull/8745

   This switches from PRId32 to PRIu32. Those variables have unsigned type and 
thus we should print them as such.
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] janantos commented on issue #8731: ESP32C3 risc-v usb-serial not working correctly

2023-03-06 Thread via GitHub


janantos commented on issue #8731:
URL: https://github.com/apache/nuttx/issues/8731#issuecomment-1456286417

   rebased to latest master and no change. 
   tried with `tools/configure.sh -m esp32c3-devkit:usbconsole` with only 
change `ESP32-C3-MINI-1=y`
   and it does misbehave the same way. enabling `NSH_CLE=y` couses complete 
freeze of console after boot.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] xiaoxiang781216 commented on a diff in pull request #8717: arch/armv8-m: DSP extension is optional

2023-03-06 Thread via GitHub


xiaoxiang781216 commented on code in PR #8717:
URL: https://github.com/apache/nuttx/pull/8717#discussion_r1126540795


##
arch/arm/Kconfig:
##
@@ -481,6 +481,7 @@ config ARCH_CHIP_STM32L5
bool "STMicro STM32 L5"
select ARCH_CORTEXM33
select ARCH_HAVE_MPU
+   select ARCH_HAVE_DSP

Review Comment:
   ARCH_HAVE_DSP->ARM_HAVE_DSP



##
arch/arm/Kconfig:
##
@@ -495,6 +496,7 @@ config ARCH_CHIP_STM32U5
bool "STMicro STM32 U5"
select ARCH_CORTEXM33
select ARCH_HAVE_MPU
+   select ARCH_HAVE_DSP

Review Comment:
   ARCH_HAVE_DSP->ARM_HAVE_DSP



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] xiaoxiang781216 commented on issue #8731: ESP32C3 risc-v usb-serial not working correctly

2023-03-06 Thread via GitHub


xiaoxiang781216 commented on issue #8731:
URL: https://github.com/apache/nuttx/issues/8731#issuecomment-1456290557

   @no1wudi could you look at this?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] janantos commented on issue #8731: ESP32C3 risc-v usb-serial not working correctly

2023-03-06 Thread via GitHub


janantos commented on issue #8731:
URL: https://github.com/apache/nuttx/issues/8731#issuecomment-1456293605

   also I realized now that NSH_CLE=y does not work in revision db69196 
neither, but it works perfectly in release/12.0
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] anchao opened a new pull request, #8746: arch/arm: correct ARCH_HAVE_DSP to ARM_HAVE_DSP

2023-03-06 Thread via GitHub


anchao opened a new pull request, #8746:
URL: https://github.com/apache/nuttx/pull/8746

   ## Summary
   
   arch/arm: correct ARCH_HAVE_DSP to ARM_HAVE_DSP
   
   
   ## Impact
   
   N/A
   
   ## Testing
   
   ci-check


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



  1   2   3   >