Difference between revisions of "USB Recorder"
From Diustou Wiki
Yousimaier17 (talk | contribs) (Created page with "{{Product |images=400px |categories= {{Category|USB}} |brand=Diustou |features= * USB Recorder |interfaces= {{Category|USB}} |related= * ...") |
Yousimaier17 (talk | contribs) |
||
Line 32: | Line 32: | ||
== Product Illustration == | == Product Illustration == | ||
− | *[[File:USB Recorder_产品说明.png| | + | *[[File:USB Recorder_产品说明.png|1000px]] |
== Usage Instructions == | == Usage Instructions == |
Latest revision as of 17:51, 6 February 2025
| ||||||||||||||||||||||
| ||||||||||||||||||||||
| ||||||||||||||||||||||
|
Contents
Product Overview
- This module is an intelligent storage module that can store data received via the USB interface in TXT format onto an SD card, achieving the purpose of recording serial port data. It is suitable for environmental monitoring, flow data logging, drone data recording, and various sensor data logging scenarios. It can also be paired with microcontroller devices such as Arduino, Raspberry Pi, STM32, etc., for development, debugging, and product testing.
Product Description
- Power Supply Voltage: 5V. Powered via Type-C interface.
- Equipped with two Type-C interfaces:
- Enter USB drive mode through the Type-C interface near the button.
- Transfer data through the other Type-C interface.
- Onboard control button for switching the module to USB drive mode and RTC time setting mode.
- Dual LED indicators to display the system's working status.
- Onboard Micro SD card slot, supporting FAT32 and EXFAT formats, with a maximum capacity of 128GB.
- Onboard CR1220 coin cell battery holder, supporting RTC for real-time data collection time recording.
- Supported baud rates: 56000bps – 2Mbps, with a default of 115200.
- Files on the TF card can be read and saved to a specified directory on the computer without the need for a USB card reader.
- Capable of storing files in other formats such as video and audio.
- Product dimensions: 44mm*37mm
Product Illustration
Usage Instructions
- When the board is powered on for the first time (i.e., there is no ulog_config.txt on the SD card) or if the file format is incorrect, a new ulog_config.txt configuration file will be automatically created upon power-up.
Contents of ulog_config.txt:(Do not change the order, do not add spaces afterward, do not alter the preceding characters; except for the baud rate, other settings can be modified with the values specified in parentheses.) [ulog_fw]:220620A # Current version number [write_raw(0,1)]:0 # Whether to write RAW data to the SD card, i.e., whether to generate a .bin file. Set to 0 to not save, default is 0. [write_time(0,1)]:1 # Whether to write time-stamped data to the SD card, i.e., whether to generate a .txt file. Set to 1 to save, default is 1. [uart_baud]:1500000 # Baud rate [uart_dataLength(8,9)]:8 # Data length [uart_Direction(MSB,LSB)]:LSB # Least Significant Bit first or Most Significant Bit first [uart_Parity(None,Even,Odd)]:None # Parity bit [uart_stopBit(1,2)]:1 # Stop bit
- Each time the board powers on and enters ULOG printing mode, a new uart_log00000.txt file will be automatically created on the SD card to receive data from the serial port. The number 00000 will increment upwards.
ULOG Printing Mode
- Insert an SD card while the device is powered off, and connect the Type-C port (on the side away from the control buttons) of the USB Recorder module to a computer using a Type-C data cable. Do not press the control buttons before powering on; powering on will directly enter ULOG printing mode. At this point, the red light will flash once, and the blue light will flash quickly. If the SD card is not inserted when powering on, both the red and blue lights will remain constantly lit.
- Open the serial port debugging assistant, select the corresponding COM port, and configure it according to the settings in the configuration file (follow the diagram below for the first power-on). After configuring, open the serial port, click send, and each successful data transmission will be indicated by a flash of the red light on the USB Recorder (the blue light may also flash synchronously). If the flashing is abnormal, please check the configuration.
RAW Function
- Open the ulog_config.txt file and modify: [write_raw(0,1)]:0 -> [write_raw(0,1)]:1. After successful modification, in addition to storing the received data in the uart_log0000x.txt file, the module will also create a uart_log0000x.bin file on the SD card, which contains only the raw received data without timestamps.
- Testing: Save the modified ulog_config.txt file, power on to enter ULOG printing mode. Set the corresponding values in the serial port assistant, open the serial port (the same as in the configuration file), click to open a file, select the file/image to be transmitted (.txt or .jpg format, other formats are also acceptable), and then send the file. After sending, enter USB drive mode. At this point, you will notice that a .bin file has been added to the USB drive. You can copy it to the desktop, change the file extension to match the transmitted file, and open the modified file to check if the content matches the transmitted file.
USB Drive Mode
- Insert an SD card while the device is powered off, press and hold the control button, insert the Type-C data cable into the Type-C port of the USB Recorder module (on the side close to the control button), release the button after the board is powered on to enter USB drive mode. At this point, the red light will enter a breathing light state, and the blue light will flash quickly. After the blue light goes out, the USB drive will appear on the PC.
- After entering USB drive mode, you can view the contents of the SD card through "My Computer" -> USB drive, without the need for a USB card reader or inserting/removing the SD card.
RTC Time Setting Mode
- Insert an SD card and a button cell battery while the device is powered off, and connect the Type-C data cable to the Type-C port on the side away from the control buttons of the USB Recorder module. Press and hold the control button while powering on, and release the button after power-on. Enter RTC time setting mode, at which point the red light will enter a breathing light state, and the blue light will be off.
- Open the serial port debugging assistant and send the AT+22+07+27+11+59+00 command to set the time with a configuration of baud rate 115200, 8 data bits, 1 stop bit, no parity bit. This command sets the time to 11:59:00 on July 27, 2022. A successful configuration will return "Set Time OK: [2022-07-27 11:59:00-xxx]".
Related Software
Precautions
- When there is printing or during power-on, the blue light will flash, and when the red light is constantly lit, do not remove the card or disconnect the power, as this may damage some data.
- Inserting or removing the SD card should be done while the module is powered off.
- The RTC settings of the module can only be configured by sending commands through the Type-C port used for data communication.
- To enter USB drive mode, the Type-C cable must be inserted into the Type-C port close to the control button.
- To maintain the RTC clock after power loss, an RTC battery must be installed, with a battery voltage of approximately 3V.
FAQ
|