dji_srt_parser
Advanced tools
Comparing version 1.0.29 to 1.0.30
{ | ||
"name": "dji_srt_parser", | ||
"version": "1.0.29", | ||
"version": "1.0.30", | ||
"description": "Parses and interprets DJI's drones SRT metadata", | ||
"main": "index.js", | ||
"scripts": { | ||
"test": "echo \"Error: no test specified\" && exit 1" | ||
"test": "jest" | ||
}, | ||
@@ -38,3 +38,6 @@ "repository": { | ||
"homepage": "https://github.com/JuanIrache/DJI_SRT_Parser#readme", | ||
"dependencies": {} | ||
"dependencies": {}, | ||
"devDependencies": { | ||
"jest": "^24.8.0" | ||
} | ||
} |
@@ -12,2 +12,3 @@ # DJI_SRT_Parser | ||
Using npm: | ||
```shell | ||
@@ -18,2 +19,3 @@ $ npm install dji_srt_parser | ||
## Usage | ||
```js | ||
@@ -24,3 +26,3 @@ //Load module | ||
//Specify data source name | ||
let fileName = "filePath"; | ||
let fileName = 'filePath'; | ||
@@ -31,3 +33,3 @@ //And load the data in a string (with your preferred method) | ||
//You can create multiple instances, one for reading each SRT file. Specify data as a string and filename for future reference | ||
let DJIData = DJISRTParser(dataString,fileName); | ||
let DJIData = DJISRTParser(dataString, fileName); | ||
@@ -51,4 +53,4 @@ //toGeoJSON() exports the current interpretation of data to a CSV spreadsheet format. The optional value raw exports the raw data instead. You can then use tokml or togpx modules to convert to those formats | ||
let csvData = DJIData.toCSV(); | ||
//Now you can also load a GeoJSON (or JSON) file directly into the rawMetadata field. This can be useful if you want to import data from other sources into the syste, | ||
let DJIData = DJISRTParser(JSONDataString,JSONfileName,true); | ||
//Now you can also load a GeoJSON (or JSON) file directly into the rawMetadata field. This can be useful if you want to import data from other sources into the system, | ||
let DJIData = DJISRTParser(JSONDataString, JSONfileName, true); | ||
//These data must follow the same structure as rawMetadata() usually has: | ||
@@ -72,9 +74,10 @@ // { | ||
// } | ||
``` | ||
``` | ||
Smoothing is applied when interpreting the data because the GPS values provided by DJI are not accurate enough. They don't have enough digits. We average them with the surrounding values to create more pleasant paths and to be able to compute somewhat meaningful speeds. The interpreted values are not necessarily more accurate. | ||
## Units of interpreted data | ||
(As far as we know) | ||
- Timecode: HH:MM:SS,FFF | ||
@@ -88,4 +91,1 @@ - GPS: degrees (and meters for third value, altitude) | ||
- ISO, shutter and EV (not always present) | ||
## TODO | ||
- Fix date in KML and JSON |
No tests
QualityPackage does not have any tests. This is a strong signal of a poorly maintained or low quality package.
Found 1 instance in 1 package
327654
11
722
0
1
2