I2C SPI USB CAN eSPI Cable Testing View All Quick Start Guides User Manuals Software Downloads Knowledge Base Videos Case Studies App Notes White Papers Sales Support About Us
Products Blog Sales Support Contact Search
How Do I Transfer SPI Data Captured by the Beagle I2S/SPI Protocol Analyzer as Plain Text to a Hard Drive
Rena Ayeras

Image of keyboarding a new program for data transfer

Image by Gerd Altmann from Pixabay

 

Question from the Customer:

I have a question about the Beagle I2C/SPI Protocol Analyzer, which I am using with Data Center Software. I have a lot of SPI data to capture and review. I need to save the raw data as plain text on a hard drive. How can I do that?

Response from Technical Support:

Thanks for your question! This can be done with our Beagle Software API. We have an example script that continues to save data to the hard drive until you press a key on the keyboard. You can modify this program as needed.

Overview of Saving Data to a Hard Drive

Several functional scripts are provided with Beagle Software API. The script that we are using for your setup is capture_i2c_disklogs.c.  The following are steps to modify the program, which refer to the numbered lines of code in that script.

You will need a text editor and Microsoft Visual Studio for building the file. The executable file will be run in a command window.

  1. Download Beagle DLL and place it in a PATH environmental variable, or in the location of .c file of execution and location of the built executable.
  2. The default location for saving log files is C:/Beagle_Logs/capture_i2c.txt. To change the location, open c and edit the location in line no. 287.
  3. In line no. 328, edit the location in the printf statement.
  4. Use Microsoft Visual Studio to build the file.
  5. Run the program. Navigate to the location of the executable, open a command window, and execute the following command:

>>  <project name which contains capture_i2c_disklogs.c> <max_packet_len> <num_events>

    • For example: Capture_i2c 100 20
    • Note, to capture indefinitely, set num_events=0.

  1. The Beagle I2C/SPI analyzer will start capturing data, which is logged in the specified file. Here is an example of what you will see in the command window.
  2. To stop the capture, press any key during command line execution. The capture will be stopped abruptly. End time will be displayed.

This is a basic setup. You can continue to modify the script for exactly what you need.

We hope this answers your question. Additional resources that you may find helpful include the following:

If you want more information, feel free to contact us with your questions, or request a demo that applies to your application.