PHP code example of webservco / icarsoft

1. Go to this page and download the library: Download webservco/icarsoft library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

webservco / icarsoft example snippets


use WebServCo\ICarsoft\Processors\Data\Processor;

// Throws RuntimeException if the file can't be read.
$processor = new Processor($filePath);
// Throws OutOfBoundsException or UnexpectedValueException if the file isn't in the expected format.
$processor->run();

$header = $processor->getHeader();
$title = $processor->getTitle();
$info = $processor->getInfo();
$frames = $processor->getFrames();

[
    'Frame' => [['value' => '1', 'units' => null]],
    // A reading of "812 rpm".
    'Example parameter' => [['value' => '812', 'units' => 'rpm']],
]

use WebServCo\ICarsoft\Processors\Info\Processor;

$processor = new Processor($filePath);
$processor->run();

// ['Example key' => 'value', ...]
$content = $processor->getContent();