Hello,
I am using fprintf() to output some data to a file. This file is located on
an SD card.
As I realised, fprintf() never returns an error.
I tried to completely remove the SD card from the system, and fprintf
happily succeeds,
returning the number of bytes that it would have written, if the
On Thu, Jul 20, 2023 at 3:02 PM Fotis Panagiotopoulos
wrote:
> Hello,
>
> I am using fprintf() to output some data to a file. This file is located on
> an SD card.
>
> As I realised, fprintf() never returns an error.
>
> I tried to completely remove the SD card from the system, and fprintf
> happ
Hi,
I'm new to NuttX and to the pico-sdk, (and RTOSs in general). I have an
Adafruit Feather RP2040 that I was using to experiment with NuttX and I
haven't been able to get either the nsh or usbnsh apps to work, (and I
haven't really tried anything else).
I have the Feather RP2040 connected
On Thu, Jul 20, 2023 at 3:28 PM Richard Fox wrote:
> Hi,
>
> I'm new to NuttX and to the pico-sdk, (and RTOSs in general). I have an
> Adafruit Feather RP2040 that I was using to experiment with NuttX and I
> haven't been able to get either the nsh or usbnsh apps to work, (and I
> haven't really
Hello Nathan,
Indeed, I should have mentioned that I have selected
CONFIG_STDIO_DISABLE_BUFFERING.
So, at least in my case, no buffering is taking place.
But in the case of buffered output, I think that I agree that fprintf() may
return success for buffered (but not written) data.
On Thu, Jul 20
Thanks Fotis,
I haven't had a chance to look at the code for stream_putc (i'm away from
my computer and on my phone) but based on your description, it sounds like
stream_putc should check and propagate errors. Even if the write to disk
won't happen until later, any errors that are caught shouldn't