Rapid ioT and USB key

cancel
Showing results for 
Search instead for 
Did you mean: 

Rapid ioT and USB key

1,108 Views
jpl
Contributor II

Is it possible to store sensor's outputs on the Rapid ioT device and read it as an USB key?

Labels (2)
Tags (1)
10 Replies

470 Views
theophileleroy
NXP Employee
NXP Employee

Jean-Philippe Lelievre,

You will find attached to this post an example project to be imported into MCUXpresso and a binary file to be flashed into K64F.

This example takes a chunk of temperature measurements and stores the result in a text file (RAPIDIOT.TXT).

The parameters can be easily modified via some define in the code (source/app_usb.c):

/* Number of measurement to take */
#define x 100

/* Delay between measurements, (in ms)*/
#define DELAY 50

First, compile and debug the application from MCUXpresso and then terminate the debug session. When all measurements are done (display on Rapid-IoT screen), plug in the Rapid-IoT into a host PC using USB mini cable. You should see the device as a removable disk with inside the data file. Reset Rapid-IoT to start again the demo.

pastedImage_1.png

pastedImage_2.png

pastedImage_3.png

From there, by modifying the code you can develop your own USB application.

Regards,

Theophile

470 Views
lesek_franek
Contributor I

Hi,

USB mass storage example published above uses fatfs in RAM memory which is limited to 47,5kB. Is it possible to export more than 47,5kB of data?

0 Kudos

470 Views
jpl
Contributor II

Bonjour,

Merci, nous allons tester

--

Jean-Philippe Lelièvre mercredi, 28 novembre 2018, 02:24AM +09:00 de theophileleroy admin@community.nxp.com :

>NXP Community

>Re:  Rapid ioT and USB key

>reply from Theophile Leroy in Rapid IoT - View the full discussion

0 Kudos

470 Views
theophileleroy
NXP Employee
NXP Employee

Jean-Philippe Lelievre

To fill your need, an example where Rapid-IoT is used as a Mass Storage Device is under development. It will store data from sensors and could be read in a text file via a PC.

We will get back to you when available.

Regards,

Theophile

470 Views
jpl
Contributor II

Thank you, looking forward seeing it.

470 Views
frq05186
NXP Employee
NXP Employee

Hi, 

On a technical side it is feasible to turn the kit into a USB key. We have a micro controler inside, a 16MB memory and the right connector.

We did not anticipate such a use case and we have no code example available for this at this moment.

Also, as there is only 1 USB port which is currently used for programming the chips into the kit, if we convert it fully as a standard USB drive, you will have to figure out how you will fall back to the USB used for programming. (This would be possible by defining a combination of push buttons to select to USB port function).

This means this is quite advanced programming of the kit and I would first advise to consider other ways of extracting the data from the kit:

- As mentionned by Jay, you can store data on the cloud and download a CSV file

- You could store your data in the NTAG memomry and get them via NFC

- You could also send them over BLE or THREAD

- You can get them out via I²C or UART

- You could use a UART to USB click element : USB UART 4 click - USB-to-UART interface module | MikroElektronika .(Storing the data in the NOR memory and reading it back). This element is not supported yet in Rapid IoT Studio, but developping associated code/driver is much simpler than turning your kit into a USB drive.

-...

Eric

470 Views
jpl
Contributor II

Thank you for your explanations

- As mentionned by Jay, you can store data on the cloud and download a CSV file : this imply that the BLE link between the device and the app is working. For us unfortunately your app doesn't see the Rapid IoT

- You could store your data in the NTAG memomry and get them via NFC : how big is the memory?

- You could also send them over BLE or THREAD : what is the transmission protocol in BLE?

- You can get them out via I²C or UART : with which connector?

- You could use a UART to USB click element : USB UART 4 click - USB-to-UART interface module | MikroElektronika .(Storing the data in the NOR memory and reading it back). This element is not supported yet in Rapid IoT Studio, but developping associated code/driver is much simpler than turning your kit into a USB drive.

Could be, but having an additional element when the Rapid IoT is already  working in USB is weird.

470 Views
frq05186
NXP Employee
NXP Employee

Hi,

  • I would like to investigate why BLE link between kit and app is not working in your case. Not all phone models were tested, but most recent ones (SAMSUNG, iPhones, Xiaomi, Huawei) were tested and ok. Can you send me a private message with your exact configuration ?

  • I am not fully sure about your exact question on 'the transmission protocol in BLE'. The protocol is described fully there, but I feel you have a more precise question: (Starting slide 31)

https://community.nxp.com/docs/DOC-334499 

  • NFC tag embedded has 2kb of EEPROM:

https://www.nxp.com/docs/en/data-sheet/NT3H2111_2211.pdf 

  • Connector at the back of the kit can be used (via docking station or by wiring/soldering) to use communication buses to get data out of the kit. See last page of the schematics. Using a docking station greatly helps to remove the burden associated with wiring... The connector at the back of the Rapid IoT is fully compatible with it

https://www.nxp.com/downloads/en/schematics/SCH-29943.pdf 

We can have a private conversation about your specific use case so we can advise on the best way to build your solutions. Using the existing USB plug to get data out is totally possible, but as mentionned would require precise understanding of how it is currently use so the kit can be reverted in its default state when needed

470 Views
jaycanteenwala
NXP Employee
NXP Employee

Hi Jean Phillipe, Sorry about the delay we have a number of folks flying back form overseas. The sensor values  are automatically stored in the Cloud under Rapid IoT Studio ( there is a limit to the amount of free storage, but that's the easiest way to store data. . We';; get back to you on whether certain values can be stored on Rapid IoT itself ( I don't believe so) 

470 Views
javierasolorzan
NXP Employee
NXP Employee

Hi Jean, 

   Thank you for your questions. We are working on a response and will get back to you as soon as possible.