Commit b387ba93 authored by devsaurus's avatar devsaurus
Browse files

introduce u8g_config.h

parent 7b160da1
#ifndef __U8G_CONFIG_H__
#define __U8G_CONFIG_H__
// Configure U8glib fonts
// add a U8G_FONT_TABLE_ENTRY for each font you want to compile into the image
#define U8G_FONT_TABLE_ENTRY(font)
#define U8G_FONT_TABLE \
U8G_FONT_TABLE_ENTRY(font_6x10) \
U8G_FONT_TABLE_ENTRY(font_chikita)
#undef U8G_FONT_TABLE_ENTRY
#endif /* __U8G_CONFIG_H__ */
...@@ -65,12 +65,4 @@ ...@@ -65,12 +65,4 @@
#define LED_LOW_COUNT_DEFAULT 0 #define LED_LOW_COUNT_DEFAULT 0
#endif #endif
// Configure U8glib fonts
// add a U8G_FONT_TABLE_ENTRY for each font you want to compile into the image
#define U8G_FONT_TABLE_ENTRY(font)
#define U8G_FONT_TABLE \
U8G_FONT_TABLE_ENTRY(font_6x10) \
U8G_FONT_TABLE_ENTRY(font_chikita)
#undef U8G_FONT_TABLE_ENTRY
#endif /* __USER_CONFIG_H__ */ #endif /* __USER_CONFIG_H__ */
// Module for U8glib // Module for U8glib
//#include "lua.h"
#include "lualib.h" #include "lualib.h"
#include "lauxlib.h" #include "lauxlib.h"
#include "platform.h" #include "platform.h"
...@@ -12,6 +11,8 @@ ...@@ -12,6 +11,8 @@
#include "u8g.h" #include "u8g.h"
#include "u8g_config.h"
struct _lu8g_userdata_t struct _lu8g_userdata_t
{ {
u8g_t u8g; u8g_t u8g;
...@@ -25,16 +26,6 @@ typedef struct _lu8g_userdata_t lu8g_userdata_t; ...@@ -25,16 +26,6 @@ typedef struct _lu8g_userdata_t lu8g_userdata_t;
#define LU8G (&(lud->u8g)) #define LU8G (&(lud->u8g))
// Font look-up array
//static const u8g_fntpgm_uint8_t *font_array[] =
//{
//#undef U8G_FONT_TABLE_ENTRY
//#define U8G_FONT_TABLE_ENTRY(font) u8g_ ## font ,
// U8G_FONT_TABLE
// NULL
//};
// function to read 4-byte aligned from program memory AKA irom0 // function to read 4-byte aligned from program memory AKA irom0
u8g_pgm_uint8_t ICACHE_FLASH_ATTR u8g_pgm_read(const u8g_pgm_uint8_t *adr) u8g_pgm_uint8_t ICACHE_FLASH_ATTR u8g_pgm_read(const u8g_pgm_uint8_t *adr)
{ {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment