Prusa MINI Firmware overview
binary_protocol.h File Reference

Go to the source code of this file.

Classes

class  SDFileTransferProtocol
 
struct  SDFileTransferProtocol::Packet::Open
 
class  BinaryStream
 
struct  BinaryStream::Packet
 
union  BinaryStream::Packet::Header
 
union  BinaryStream::Packet::Footer
 

Macros

#define BINARY_STREAM_COMPRESSION
 

Functions

bool bs_serial_data_available (const uint8_t index)
 
int bs_read_serial (const uint8_t index)
 

Variables

static heatshrink_decoder hsd
 
static uint8_t decode_buffer [512] = {}
 
BinaryStream binaryStream [NUM_SERIAL]
 

Macro Definition Documentation

◆ BINARY_STREAM_COMPRESSION

#define BINARY_STREAM_COMPRESSION

Marlin 3D Printer Firmware Copyright (c) 2019 MarlinFirmware [https://github.com/MarlinFirmware/Marlin]

Based on Sprinter and grbl. Copyright (c) 2011 Camiel Gubbels / Erik van der Zalm

This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with this program. If not, see http://www.gnu.org/licenses/.

Function Documentation

◆ bs_serial_data_available()

bool bs_serial_data_available ( const uint8_t  index)
32  {
33  switch (index) {
34  case 0: return MYSERIAL0.available();
35  #if NUM_SERIAL > 1
36  case 1: return MYSERIAL1.available();
37  #endif
38  }
39  return false;
40 }
Here is the caller graph for this function:

◆ bs_read_serial()

int bs_read_serial ( const uint8_t  index)
42  {
43  switch (index) {
44  case 0: return MYSERIAL0.read();
45  #if NUM_SERIAL > 1
46  case 1: return MYSERIAL1.read();
47  #endif
48  }
49  return -1;
50 }
Here is the caller graph for this function:

Variable Documentation

◆ hsd

heatshrink_decoder hsd
static

◆ decode_buffer

uint8_t decode_buffer[512] = {}
static

◆ binaryStream

BinaryStream binaryStream[NUM_SERIAL]
MYSERIAL0
#define MYSERIAL0
Definition: HAL.h:89