QMK/lib/ugfx/drivers/multiple/uGFXnet
2020-03-23 10:48:11 +01:00
..
driver.mk initial upload 2020-03-23 10:48:11 +01:00
gdisp_lld_config.h initial upload 2020-03-23 10:48:11 +01:00
gdisp_lld_uGFXnet.c initial upload 2020-03-23 10:48:11 +01:00
ginput_lld_mouse_config.h initial upload 2020-03-23 10:48:11 +01:00
readme.txt initial upload 2020-03-23 10:48:11 +01:00
uGFXnetProtocol.h initial upload 2020-03-23 10:48:11 +01:00

To use this driver:

This driver is special in that it implements both the gdisp low level driver
and a touchscreen driver.

1. Add in your gfxconf.h:
	a) #define GFX_USE_GDISP		GFXON
	b) Optionally #define GFX_USE_GINPUT			GFXON
					#define GINPUT_USE_MOUSE		GFXON
	c) Any optional high level driver defines (see gdisp.h) eg: GDISP_NEED_MULTITHREAD
	d) Optionally the following (with appropriate values):
		#define GDISP_SCREEN_WIDTH					640			// Virtual display width
		#define GDISP_SCREEN_HEIGHT					480			// Virtual display height
		#define GDISP_GFXNET_UNSAFE_SOCKETS			GFXOFF		// Your socket library is not thread-safe
																//		LWIP automatically sets this to GFXON
		#define GDISP_GFXNET_CUSTOM_LWIP_STARTUP	GFXOFF		// You want a custom Start_LWIP() function (LWIP only)
		#define GDISP_DONT_WAIT_FOR_NET_DISPLAY		GFXOFF		// Don't halt waiting for the first connection
		$define GDISP_GFXNET_PORT					13001		// The TCP port the display sits on

2. To your makefile add the following lines:
	include $(GFXLIB)/gfx.mk
	include $(GFXLIB)/drivers/multiple/uGFXnet/driver.mk

3. Make sure you have networking libraries included in your Makefile.

NOTE: If you are using ChibiOS with LWIP - you will probably need to increase
	the default stack size for the lwip_thread. 512 bytes seems too small. 1024 seems to work.