Beware that this post is related to an SDK in maintenance mode
More Info: Consider nRF Connect SDK for new designs
This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

How to create a .txt file with nRF52840 and send it through USB to computer

Hi everyone,

I use nrf52840 DK with Segger embedded studio. I have created a project where I read several sensors data and send these data to mobile through BLE UART.

I also have an external 512MB flash memory chip  where I save all the sampled data, in case I don't have my mobile connected. Since I do not use a file system with

the flash memory chip ( I just save raw data to it and read them back), I need to encapsulate those data in a .txt file after I retrieve them from the flash memory chip

  and then send them through the USB cable to my computer.

How can this .txt encapsulation be done?

  I tried to write to a Hello_World.txt  a simple string but the file is not created. Is it possible to do it with FILE structure somehow?

Thank you

Parents Reply Children
Related