CTS-SAT-1-OBC-Firmware
Loading...
Searching...
No Matches
heatshrink_helpers.c File Reference
#include "compression/heatshrink_helpers.h"
#include "littlefs/lfs.h"
#include "compression/heatshrink_lib/heatshrink_encoder.h"
#include "log/log.h"
#include <stdlib.h>
#include <string.h>
Include dependency graph for heatshrink_helpers.c:

Functions

int8_t LFS_compress_lfs_file_with_heatshrink (lfs_t *lfs, const char *input_path, const char *output_path, uint8_t window_sz2, uint8_t lookahead_sz2)
 Compress a file with Heatshrink, similar to the CLI.

Function Documentation

◆ LFS_compress_lfs_file_with_heatshrink()

int8_t LFS_compress_lfs_file_with_heatshrink ( lfs_t * lfs,
const char * input_path,
const char * output_path,
uint8_t window_sz2,
uint8_t lookahead_sz2 )

Compress a file with Heatshrink, similar to the CLI.

Parameters
lfspointer to LittleFS instance
input_pathinput file path
output_pathoutput file path
window_sz2log2 sliding window size (like CLI arg -w)
lookahead_sz2number of bits for backref length (like CLI arg -l)
Returns
0 success, negative LittleFS error, positive Heatshrink error.
Here is the call graph for this function:
Here is the caller graph for this function: