|
SimAVR
AVR Simulator
|
Data Structures | |
| struct | ihex_chunk_t |
| A .hex file chunk (base address + size) More... | |
Typedefs | |
| typedef struct ihex_chunk_t | ihex_chunk_t |
| A .hex file chunk (base address + size) More... | |
| typedef struct ihex_chunk_t * | ihex_chunk_p |
Functions | |
| int | read_hex_string (const char *src, uint8_t *buffer, int maxlen) |
| Parses a hex text string 'src' of at max 'maxlen' characters, decodes it into 'buffer'. More... | |
| int | read_ihex_chunks (const char *fname, ihex_chunk_p *chunks) |
| Read a .hex file, detects the various different chunks in it from their starting addresses and allocate an array of ihex_chunk_t returned in 'chunks'. More... | |
| uint8_t * | read_ihex_file (const char *fname, uint32_t *dsize, uint32_t *start) |
| Reads IHEX file 'fname', puts it's decoded size in *'dsize' and returns a newly allocated buffer with the binary data (or NULL, if error) More... | |
| void | hdump (const char *w, uint8_t *b, size_t l) |
| Hex dump from pointer 'b' for 'l' bytes with string prefix 'w'. More... | |
| typedef struct ihex_chunk_t * ihex_chunk_p |
| typedef struct ihex_chunk_t ihex_chunk_t |
A .hex file chunk (base address + size)
| void hdump | ( | const char * | w, |
| uint8_t * | b, | ||
| size_t | l | ||
| ) |
Hex dump from pointer 'b' for 'l' bytes with string prefix 'w'.
| int read_hex_string | ( | const char * | src, |
| uint8_t * | buffer, | ||
| int | maxlen | ||
| ) |
Parses a hex text string 'src' of at max 'maxlen' characters, decodes it into 'buffer'.

| int read_ihex_chunks | ( | const char * | fname, |
| ihex_chunk_p * | chunks | ||
| ) |
Read a .hex file, detects the various different chunks in it from their starting addresses and allocate an array of ihex_chunk_t returned in 'chunks'.
Returns the number of chunks found, or -1 if an error occurs.


| uint8_t* read_ihex_file | ( | const char * | fname, |
| uint32_t * | dsize, | ||
| uint32_t * | start | ||
| ) |
Reads IHEX file 'fname', puts it's decoded size in *'dsize' and returns a newly allocated buffer with the binary data (or NULL, if error)
