Commit Graph

4017 Commits

Author SHA1 Message Date
SPRESENSE
139f1f1548 drivers/modem/altair: Fix behavior when a reset packet conflicts with a send packet
Even in the case of a conflict between a reset packet
and a send packet, the send size is compared and the
larger size is sent as the payload.
2021-05-19 12:15:59 +02:00
SPRESENSE
4b1fddec8a drivers/mtd/smart.c: Recover the missing link of directory entry
When creating the next chain of directory entries, (1) add the position
of next entry to the current sector, and then (2) update the sector of
next entry. If the power is turned off between (1) and (2), the next
entry will not be found, and the chain of directory entries will break.
It causes the SmartFS file system corruption, and we will not be able
to add files.

To avoid this issue, in checking the filesystem by smart_fsck_directory,
if the sector of next entry does not exist, update the sector of
directory entry to invalidate the field of next entry.
2021-05-19 11:02:50 +02:00
Xiang Xiao
5f7c98b6e1 drivers/syslog: Remove emergstream implementation and caller
since emergstream always call syslog_force, but syslog_force is designed
for the interrupt context, and then doesn't mean any emergency thing.
On the other hand, emergstream has other bad side effect:
1.Can't output to file or dev channel
2.Can't work well with the interrupt buffer

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-05-18 09:26:28 -03:00
Alan C. Assis
4c74f46afe Add basic support for MCP23017 I/O Expander 2021-05-16 12:48:52 -05:00
Jiuzhu Dong
73cc1f8884 driver/rtc: add config CONFIG_RTC_RPMSG_SERVER to
N/A
select rtc rpmsg role.

Change-Id: I7f9053b070593573caa5d988c6a2e13593da6bc5
Signed-off-by: Jiuzhu Dong <dongjiuzhu1@xiaomi.com>
2021-05-15 14:33:52 -03:00
Jiuzhu Dong
f082893b9a driver/rtc: add config RTC_RPMSG_SERVER_NAME to
specified the name of remote proc(rpmsg server)

Change-Id: I0086bb43727a2bbb5e68f88907b5e4608182ef9c
Signed-off-by: Jiuzhu Dong <dongjiuzhu1@xiaomi.com>
2021-05-15 14:33:52 -03:00
Jiuzhu Dong
018cf26605 lirc: fix bug about lirc_raw_event
N/A

Change-Id: If00d0a7e4e4f9a0d9119b6a170cffd993f23f71a
Signed-off-by: Jiuzhu Dong <dongjiuzhu1@xiaomi.com>
2021-05-15 09:47:28 -07:00
Jiuzhu Dong
ff567124d3 driver/syslog: add config SYSLOG_RPMSG_SERVER_NAME to
N/A

specified the name of remote proc(rpmsg server)

Change-Id: Ie270d651071e87a40a80ab489597ae18db9814f0
Signed-off-by: Jiuzhu Dong <dongjiuzhu1@xiaomi.com>
2021-05-15 09:39:57 -03:00
Xiang Xiao
7169c7c5f8 drivers/rptun: Adapter to openamp 2020.10.0 release
change the callback implementation from mmap to get_mem

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-05-13 18:43:19 +01:00
Xiang Xiao
276fa2ff1c drivers/serial: Change the default value of SERIAL_NPOLLWAITERS to 4
since the console is normally opened three time as stdin, stdout and
stderr and remove the dependence on STANDARD_SERIAL because other type
of serial drivers also support the poll through the same codebase.

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: Ie68322c4647cc838b295491329969869d6ba310b
2021-05-11 16:45:22 +01:00
Diego Herranz
a1c4ba379f drivers/sensors/hdc1008: add missing break
It was not possible to use the HDC1008_MEAS_T_AND_RH
operation mode since it was running the default case too.
2021-05-07 21:19:14 -03:00
Julian Oes
644a0cd525 drivers/serial: fix Rx interrupt enable for cdcacm
This is addressing an issue where Rx interrupts were not restored for
cdcacm after the buffer had been filled (in a burst).
The Rx interrupts were only restored after the watchdog timeout of 200ms
fired.

This happened because CONFIG_SERIAL_RXDMA was set, however, for the
cdcacm driver this does not actually matter as it is relying on
uart_enablerxint to be called via the ops table.

This patch makes sure that uart_enablerxint and uart_disablerxint are
always called, independent of CONFIG_SERIAL_RXDMA, relying on the ops
table to be correct for the case where it should be only a no-op.
2021-05-06 06:49:07 -07:00
raiden00pl
a74ea51aae drivers/timers/pwm.c: fix compilation warnings 2021-05-05 09:32:58 -03:00
raiden00pl
3fb78a8299 drivers: move the generic upper-half motor driver from drivers/power to drivers/motor 2021-05-05 09:00:22 +02:00
Brennan Ashton
2c91805d8f boards/stm32f7: Add i2c and mpu60x0 support to nucleo-144 2021-05-04 10:17:44 -03:00
Brennan Ashton
e155af891a sensor: Fix bad bit mask macro in mpu60x0 2021-05-04 10:17:44 -03:00
David Sidrane
8f8befaa25 mtd:ramtron Use inttypes in printing macros 2021-05-03 16:58:47 -04:00
Nathan Hartman
8efec13ab0 drivers/motor - Fix CFLAGS path
* drivers/motor/Make.defs b/drivers/motor/Make.defs:
  Fix typo in MOTOR_CFLAGS path (motr -> motor)
2021-05-03 12:23:54 -07:00
Masayuki Ishikawa
97e6d35c3a drivers: wireless: Fix AT command response handling in gs2200m.c
Summary:
- When sending an AT command during receiving a bulk packet,
  the bulk packet might be put in the AT command response.
- To handle such the case, gs2200m_send_cmd2() is newly
  introduced instead of using gs2200m_send_cmd(dev, cmd, NULL)

Impact:
- All use cases that send an AT command in gs2200m.c

Testing:
- Tested with renew and nxplayer with spresense:wifi

Reported-by: Masatoshi Ueno <Masatoshi.Ueno@sony.com>
Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>
2021-04-15 21:28:25 -05:00
Marco Krahl
05b889457e 1wire: Removes duplicate device information
Removes the family identifier from the device configuration, since the device
family is already part of the rom code and the underlying logic does know how
to extract this information.

include/nuttx/1wire drivers/sensors

stm32f103-minimim

Signed-off-by: Marco Krahl <ocram.lhark@gmail.com>
2021-04-15 02:28:42 -05:00
Marco Krahl
9f9d266f68 drivers/sensors: Adds new driver for ds18b20 sensore module
Signed-off-by: Marco Krahl <ocram.lhark@gmail.com>
2021-04-14 02:49:28 -05:00
Marco Krahl
624a60f456 drivers/1wire: Adds some improvents
The following changes where added.
- Removes dependency to slave structure. Selecting a device on the bus only
  requires the unique romcode.

- Make search operation mutual exclusive on the bus. This is necessary to
  prevent another driver instance from making a transition on the bus at
  the same time.

- Skip also rom when only 1 slave is expected on the bus. Physical
  connected devuce should be indicated by the maxslave paramter during
  initializing, not the reigstered slaves.

- Fixes some compiler warnings in existing ds28e17 driver.

Signed-off-by: Marco Krahl <ocram.lhark@gmail.com>
2021-04-14 02:49:28 -05:00
Marco Krahl
8456f3615e drivers/1wire: Moves header and adjusts include paths
Moves header to 1wire include sub directory.
Moves over common crc definitions to new interface.

Signed-off-by: Marco Krahl <ocram.lhark@gmail.com>
2021-04-14 02:49:28 -05:00
Marco Krahl
c726dac605 nuttx/1wire: Adds 1wire master interface
This implements a new master interface to handle the 1-wire transition in an
atomic sense.

Signed-off-by: Marco Krahl <ocram.lhark@gmail.com>
2021-04-14 02:49:28 -05:00
Anthony Merlino
9c8c2b0db2 Separate CLOCK_TIMEKEEPING and SCHED_TICKLESS. 2021-04-13 11:42:31 -05:00
Masayuki Ishikawa
fa5daea3d9 drivers: wireless: Fix to receive a UDP packet partially in gs2200m.c
Summary:
- When receiving a UDP packet partially, the rest of the packet
  must be discarded.

Impact:
- None

Testing:
- Tested with a UDP sample program

Reported-by: Masatoshi Ueno <Masatoshi.Ueno@sony.com>
Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>
2021-04-13 10:37:15 -05:00
Xiang Xiao
3f9908f7d1 Remove the unnecessary math.h inclusion
or move from header file to source file since math.h doesn't always exist

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-04-12 22:58:23 -04:00
jturnsek
f57ff30545 Removing FLexSPI NOR driver 2021-04-12 17:22:14 -03:00
jturnsek
7453e76d98 FlexSPI NOR driver 2021-04-12 11:35:44 -03:00
Fotis Panagiotopoulos
3543ac95bf syslog_device: Device is re-opened in case of failure. 2021-04-10 06:47:44 -05:00
Alin Jerpelea
231b8518b7 NuttX: Ken Pettit: update licenses to Apache
Ken Pettit has submitted the ICLA and we can migrate the licenses
 to Apache.

Sebastien Lorquet has submitted the ICLA and we can migrate the licenses
 to Apache.

Gregory Nutt has submitted the SGA and we can migrate the licenses
 to Apache.

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-04-10 06:42:19 -05:00
Michal Lenc
3f43a34d11 drivers/lcd/ili9225: fix nxstyle
Signed-off-by: Michal Lenc <michallenc@seznam.cz>
2021-04-09 22:41:56 -03:00
Michal Lenc
cf7cfa682b drivers: added support for ili9225 controller
Signed-off-by: Michal Lenc <michallenc@seznam.cz>
2021-04-09 22:41:56 -03:00
Fotis Panagiotopoulos
ee7276e7a7 syslog: syslog_device ops are handled internally by the driver. 2021-04-09 08:02:38 -05:00
Gustavo Henrique Nihei
ada84cacda drivers/input: Rename AJOYSTICK configs to INPUT_AJOYSTICK 2021-04-08 14:41:22 -03:00
Gustavo Henrique Nihei
3054237d2e drivers/input: Rename DJOYSTICK configs to INPUT_DJOYSTICK 2021-04-08 14:41:22 -03:00
Gustavo Henrique Nihei
2efae6928d drivers/input: Rename BUTTONS configs to INPUT_BUTTONS 2021-04-08 14:41:22 -03:00
Gustavo Henrique Nihei
5719dab8ec drivers/input: Rename MOUSE configs to INPUT_MOUSE 2021-04-08 14:41:22 -03:00
Gustavo Henrique Nihei
00e68bb38d drivers/input: Add TOUCHSCREEN config for touchscreen input devices 2021-04-08 09:17:58 -07:00
Marco Krahl
7e8424903a drivers/sensors: Adds driver for hyt271 sensore module
This adds a sensor driver for the hyt271, hyt221, and hyt939 sensor module from
vendor iST (Innovative Sensor Technology). This sensor type is connected via i2c
bus and allows the measurement of relative humidity and temperature.

Each driver instance supports two different character device for each type
(/dev/sensor/tempX and /dev/sensor/humiX).

This driver also supports changing the i2c address of one connected sensor on
the bus. This requires a callback to the platform-specific board logic which
must ensure a power-on reset.

Optional the driver allows setting up a read interval for fetching sensor data.
This is done by a worker thread and can be useful when watching several sensors
via poll() by the userspace application.

Signed-off-by: Marco Krahl <ocram.lhark@gmail.com>
2021-04-07 21:29:51 -05:00
Fotis Panagiotopoulos
ac7feda1bc syslog: Proper uninit of syslog_device. 2021-04-07 08:38:53 -05:00
Xiang Xiao
f1e821833b mtd/ftl: Don't call ferr if return value equals -ENOTTY
MIRTOS4BES-22

since -ENOTTY is an expected code to indicate IOCTL isn't supported

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: I62cf58c514be696327ad769ab2f35099154bcb42
2021-04-06 22:36:09 +01:00
Alin Jerpelea
72041911ce NuttX: Marco Krahl: update licenses to Apache
Marco Krahl has submitted the ICLA and we can migrate the licenses
 to Apache.

Gregory Nutt, S.A has submitted the SGA and we can migrate the licenses
 to Apache.

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-04-06 12:50:41 -05:00
Fotis Panagiotopoulos
c4a9a35fb9 syslog: Fix in syslog_intbuffer flushing. 2021-04-06 10:26:55 -05:00
Fotis Panagiotopoulos
1dee243e29 syslog: Added multi device support in syslog_device. 2021-04-06 07:32:23 -05:00
Anthony Merlino
b21cb3308a Fixes race condition in event wait logic of SDMMC driver.
This change makes it so that the timeout is set as part of the SDIO_WAITENABLE call instead of the SDIO_EVENTWAIT call. By doing so, you eliminate all opportunity for a race condition.

stm32h7:sdmmc Check if busy ended early
2021-04-05 23:08:45 -05:00
Alin Jerpelea
e1d361eddf drivers: nxstyle fixes
Fixes for errors reported by nxstyle

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-04-05 07:31:45 -05:00
Alin Jerpelea
0fc329d814 driver: Ales Verbic: update licenses to Apache
Ales Verbic has submitted the ICLA and we can migrate the licenses
 to Apache.

Uros Platise has submitted the ICLA and we can migrate the licenses
 to Apache.

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-04-05 06:13:17 -05:00
Xiang Xiao
5f3a98b5a8 libc/assert: Reference the expression in all case
to avoid the warning "defined but not used"

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: I55b7c092d0f2e5882fc1784987657c10cdf2d90b
2021-04-03 21:00:41 +01:00
Alin Jerpelea
5f5fae6b57 drivers: DS Automotion GmbH: update licenses to Apache
DS Automotion GmbH has submitted the SGA and we can migrate the licenses
 to Apache.

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-04-03 09:36:43 -05:00