fs_write failed #70341
Replies: 6 comments
-
Somebody correct me if I am wrong, but the ofstream, indirectly, is supported in Zephyr by Posix subsys, which seems to not implement the sync. Also, I have searched for fs_sync callers in Zephyr and SDK and did not found anything that looks like std implementation to call the function. |
Beta Was this translation helpful? Give feedback.
-
It seems I found an issue.
In /zephyr/drivers/flash/flash_simulator.c file in the function Now let's look in my device tree again
When I decrease PS. |
Beta Was this translation helpful? Give feedback.
-
@AydinyanNarek your second partition is to large to fit in the specified 64kB of the simulator, reduce the size of the second partition or increase the simulator size. |
Beta Was this translation helpful? Give feedback.
-
@Laczen what do you mean saying |
Beta Was this translation helpful? Give feedback.
-
lfsram_partition1 starts at 32kB and is 64kB, so this needs 96kB. |
Beta Was this translation helpful? Give feedback.
-
Thanks, it works now. Should I open an issue related to |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Discussed in #70163
Originally posted by AydinyanNarek March 13, 2024
Hello,
Introdcution
I am using
STM32
microcontroller andZephyr
3.6.0.My application logger logs data to the Ram-FS, instead of flash memory. (Flash memory has a fixed count of write operations).
I have created
Ram-FS(/etc and /tmp)
using FALSH_SIMULATOR.It looks like this.
Notes.
/opt
is using flash0 memory. (just skip this)Problems.
I am writing logs to
/tmp
directory usingstd::ofstream
fs_write
returns error code-22
which isINVALID ARGUMENT ERROR
and printing errno returnsThe Socket is not available
.Does someone have an idea about this ?
Beta Was this translation helpful? Give feedback.
All reactions