ra8-firmware 0.1.0
Bare-metal firmware for the Renesas RA8 family (RA8D2 / RA8P1)
Loading...
Searching...
No Matches
book_library.h
Go to the documentation of this file.
1
14#pragma once
15
16#include <stdint.h>
17
23typedef struct {
24 const char* title;
25 const char* author;
26 const char* filename;
27 uint32_t file_size;
28 uint32_t inflated_size;
30
36typedef enum : uint16_t {
39
46typedef enum : uint32_t {
49
51// NOLINTBEGIN(readability-magic-numbers) -- Generated book measurements are payload data, not control constants.
53 {"A Dolls House", "Henrik Ibsen", "A Doll's House - Henrik Ibsen.rabook", 228132U, 1115917U},
54 {"A Princess of Mars",
55 "Edgar Rice Burroughs",
56 "A Princess of Mars - Edgar Rice Burroughs.rabook",
57 323679U,
58 1013451U},
59 {"A Tale of Two Cities",
60 "Charles Dickens",
61 "A Tale of Two Cities - Charles Dickens.rabook",
62 513566U,
63 1636583U},
64 {"Alices Adventures in Wonderland",
65 "Lewis Carroll",
66 "Alice's Adventures in Wonderland - Lewis Carroll.rabook",
67 335719U,
68 14952337U},
69 {"Anna Karenina", "Leo Tolstoy", "Anna Karenina - Leo Tolstoy.rabook", 954866U, 3260597U},
70 {"Anne of Green Gables",
71 "L. M. Montgomery",
72 "Anne of Green Gables - L M Montgomery.rabook",
73 476776U,
74 1335904U},
75 {"Crime and Punishment",
76 "Fyodor Dostoevsky",
77 "Crime and Punishment - Fyodor Dostoevsky.rabook",
78 680425U,
79 2151864U},
80 {"Don Quixote",
81 "Miguel de Cervantes Saavedra",
82 "Don Quixote - Miguel de Cervantes.rabook",
83 1256904U,
84 4162468U},
85 {"Dracula", "Bram Stoker", "Dracula - Bram Stoker.rabook", 458137U, 1620367U},
86 {"Dubliners", "James Joyce", "Dubliners - James Joyce.rabook", 364562U, 1091576U},
87 {"Frankenstein", "Mary Shelley", "Frankenstein - Mary Shelley.rabook", 347622U, 1042189U},
88 {"Great Expectations",
89 "Charles Dickens",
90 "Great Expectations - Charles Dickens.rabook",
91 604997U,
92 1946672U},
93 {"Gullivers Travels",
94 "Jonathan Swift",
95 "Gulliver's Travels - Jonathan Swift.rabook",
96 364636U,
97 1226649U},
98 {"Hamlet", "William Shakespeare", "Hamlet - William Shakespeare.rabook", 355767U, 1367791U},
99 {"Heart of Darkness",
100 "Joseph Conrad",
101 "Heart of Darkness - Joseph Conrad.rabook",
102 315470U,
103 788750U},
104 {"Jane Eyre", "Charlotte Bronte", "Jane Eyre - Charlotte Bronte.rabook", 629660U, 1988661U},
105 {"Journey to the Center of the Earth",
106 "Jules Verne",
107 "Journey to the Center of the Earth - Jules Verne.rabook",
108 360748U,
109 1336381U},
110 {"King Solomons Mines",
111 "H. Rider Haggard",
112 "King Solomon's Mines - H Rider Haggard.rabook",
113 355540U,
114 1336275U},
115 {"Leaves of Grass", "Walt Whitman", "Leaves of Grass - Walt Whitman.rabook", 698216U, 2921367U},
116 {"Les Miserables", "Victor Hugo", "Les Miserables - Victor Hugo.rabook", 1801722U, 5520494U},
117 {"Macbeth", "William Shakespeare", "Macbeth - William Shakespeare.rabook", 259853U, 1091918U},
118 {"Madame Bovary",
119 "Gustave Flaubert",
120 "Madame Bovary - Gustave Flaubert.rabook",
121 434740U,
122 1502836U},
123 {"Meditations", "Marcus Aurelius", "Meditations - Marcus Aurelius.rabook", 330182U, 1005552U},
124 {"Moby Dick", "Herman Melville", "Moby-Dick - Herman Melville.rabook", 756969U, 2112708U},
125 {"Narrative of the Life of Frederick Douglass",
126 "Frederick Douglass",
127 "Narrative of the Life of Frederick Douglass - Frederick Douglass.rabook",
128 167051U,
129 872630U},
130 {"The Origin of Species",
131 "Charles Darwin",
132 "On the Origin of Species - Charles Darwin.rabook",
133 574873U,
134 2126482U},
135 {"Paradise Lost", "John Milton", "Paradise Lost - John Milton.rabook", 559778U, 2275874U},
136 {"Pride and Prejudice",
137 "Jane Austen",
138 "Pride and Prejudice - Jane Austen.rabook",
139 495104U,
140 1534461U},
141 {"Pygmalion", "George Bernard Shaw", "Pygmalion - George Bernard Shaw.rabook", 271951U, 1056378U},
142 {"Tao Te Ching", "Laozi", "Tao Te Ching - Lao Tzu.rabook", 353390U, 1111095U},
143 {"Tarzan of the Apes",
144 "Edgar Rice Burroughs",
145 "Tarzan of the Apes - Edgar Rice Burroughs.rabook",
146 390267U,
147 1269661U},
148 {"The Adventures of Huckleberry Finn",
149 "Mark Twain",
150 "The Adventures of Huckleberry Finn - Mark Twain.rabook",
151 408951U,
152 1376195U},
153 {"The Adventures of Sherlock Holmes",
154 "Arthur Conan Doyle",
155 "The Adventures of Sherlock Holmes - Arthur Conan Doyle.rabook",
156 378981U,
157 1359243U},
158 {"The Art of War", "Sun Tzu", "The Art of War - Sun Tzu.rabook", 464359U, 2012634U},
159 {"The Brothers Karamazov",
160 "Fyodor Dostoevsky",
161 "The Brothers Karamazov - Fyodor Dostoevsky.rabook",
162 959539U,
163 3162936U},
164 {"The Call of the Wild",
165 "Jack London",
166 "The Call of the Wild - Jack London.rabook",
167 194890U,
168 758317U},
169 {"The Castle of Otranto",
170 "Horace Walpole",
171 "The Castle of Otranto - Horace Walpole.rabook",
172 224538U,
173 831009U},
174 {"The Count of Monte Cristo",
175 "Alexandre Dumas",
176 "The Count of Monte Cristo - Alexandre Dumas.rabook",
177 1334758U,
178 4565691U},
179 {"The Great Gatsby",
180 "F. Scott Fitzgerald",
181 "The Great Gatsby - F Scott Fitzgerald.rabook",
182 215960U,
183 937495U},
184 {"Histories", "Herodotus", "The Histories - Herodotus.rabook", 955216U, 3385662U},
185 {"The History of the Decline and Fall of the Roman Empire",
186 "Edward Gibbon",
187 "The History of the Decline and Fall of the Roman Empire - Edward Gibbon.rabook",
188 5621584U,
189 20360476U},
190 {"The Hound of the Baskervilles",
191 "Arthur Conan Doyle",
192 "The Hound of the Baskervilles - Arthur Conan Doyle.rabook",
193 262196U,
194 1012387U},
195 {"The Importance of Being Earnest",
196 "Oscar Wilde",
197 "The Importance of Being Earnest - Oscar Wilde.rabook",
198 187347U,
199 934963U},
200 {"The Innocence of Father Brown",
201 "G. K. Chesterton",
202 "The Innocence of Father Brown - G K Chesterton.rabook",
203 403137U,
204 1123960U},
205 {"The Jungle Book",
206 "Rudyard Kipling",
207 "The Jungle Book - Rudyard Kipling.rabook",
208 274410U,
209 917056U},
210 {"The Moonstone", "Wilkie Collins", "The Moonstone - Wilkie Collins.rabook", 643888U, 2069231U},
211 {"The Mysterious Affair at Styles",
212 "Agatha Christie",
213 "The Mysterious Affair at Styles - Agatha Christie.rabook",
214 272444U,
215 2445851U},
216 {"The Picture of Dorian Gray",
217 "Oscar Wilde",
218 "The Picture of Dorian Gray - Oscar Wilde.rabook",
219 327838U,
220 1119388U},
221 {"The Prince",
222 "Niccolo Machiavelli",
223 "The Prince - Niccolo Machiavelli.rabook",
224 184239U,
225 888034U},
226 {"The Secret Garden",
227 "Frances Hodgson Burnett",
228 "The Secret Garden - Frances Hodgson Burnett.rabook",
229 339666U,
230 1180323U},
231 {"The Strange Case of Dr. Jekyll and Mr. Hyde",
232 "Robert Louis Stevenson",
233 "The Strange Case of Dr Jekyll and Mr Hyde - Robert Louis Stevenson.rabook",
234 197287U,
235 772775U},
236 {"The Three Musketeers",
237 "Alexandre Dumas",
238 "The Three Musketeers - Alexandre Dumas.rabook",
239 758794U,
240 2679816U},
241 {"The Time Machine", "H. G. Wells", "The Time Machine - H G Wells.rabook", 240808U, 723420U},
242 {"The Turn of the Screw",
243 "Henry James",
244 "The Turn of the Screw - Henry James.rabook",
245 282208U,
246 874283U},
247 {"The Voyage of the Beagle",
248 "Charles Darwin",
249 "The Voyage of the Beagle - Charles Darwin.rabook",
250 780817U,
251 5974213U},
252 {"The War of the Worlds",
253 "H. G. Wells",
254 "The War of the Worlds - H G Wells.rabook",
255 346860U,
256 975945U},
257 {"The Wind in the Willows",
258 "Kenneth Grahame",
259 "The Wind in the Willows - Kenneth Grahame.rabook",
260 364687U,
261 987224U},
262 {"The Woman in White",
263 "Wilkie Collins",
264 "The Woman in White - Wilkie Collins.rabook",
265 760828U,
266 2380652U},
267 {"The Wonderful Wizard of Oz",
268 "L. Frank Baum",
269 "The Wonderful Wizard of Oz - L Frank Baum.rabook",
270 236746U,
271 855203U},
272 {"Treasure Island",
273 "Robert Louis Stevenson",
274 "Treasure Island - Robert Louis Stevenson.rabook",
275 346980U,
276 1026332U},
277 {"Ulysses", "James Joyce", "Ulysses - James Joyce.rabook", 1007940U, 3977130U},
278 {"Walden", "Henry David Thoreau", "Walden - Henry David Thoreau.rabook", 485054U, 1201164U},
279 {"White Fang", "Jack London", "White Fang - Jack London.rabook", 240984U, 1007231U},
280 {"Wuthering Heights",
281 "Emily Bronte",
282 "Wuthering Heights - Emily Bronte.rabook",
283 469346U,
284 1412025U},
285};
286// NOLINTEND(readability-magic-numbers)
static const book_library_entry_t g_book_library[k_book_library_count]
The bundled book index.
book_library_scratch_t
Largest inflate scratch any bundled book needs, bytes.
@ k_book_library_max_inflated
Worst-case inflated size.
book_library_count_t
Number of books in g_book_library.
@ k_book_library_count
Bundled book count.
One bundled book: display metadata plus storage/inflate sizes.
const char * author
Author (transliterated to ASCII).
const char * title
Book title (transliterated to ASCII).
uint32_t inflated_size
Scratch bytes book_open() needs.
uint32_t file_size
Compressed size on disk, bytes.
const char * filename
.rabook file name on storage.