Prusa-MMU-Private
PrusaMultiMaterialUpgradev3firmwareforMK3SMK4
Functions
hal::progmem Namespace Reference

AVR PROGMEM handling. More...

Functions

static uint16_t read_word (const uint16_t *addr)
 read a 16bit word from PROGMEM
 
static uint8_t read_byte (const uint8_t *addr)
 read a 8bit byte from PROGMEM
 
template<typename RT >
static RT read_ptr (const void *addr)
 

Detailed Description

AVR PROGMEM handling.

Function Documentation

◆ read_ptr()

template<typename RT >
static RT hal::progmem::read_ptr ( const void *  addr)
inlinestatic

read a ptr from PROGMEM Introduced mainly for compatibility reasons with the unit tests and to hide the ugly reinterpret_casts. Returns a correctly typed pointer: a 16-bit on AVR, but a 64bit address on x86_64