summaryrefslogtreecommitdiff
path: root/firmware
diff options
context:
space:
mode:
authorCamil Staps2015-08-20 22:37:23 +0200
committerCamil Staps2015-08-20 22:46:47 +0200
commit3056e083d78b6edec6bab1ebac3fa9e3708644d7 (patch)
tree80dd8334e7a598d4d5080778ed5dcf3b5769392e /firmware
Initial commit
Diffstat (limited to 'firmware')
-rw-r--r--firmware/CText.X/Makefile113
-rw-r--r--firmware/CText.X/nbproject/Makefile-default.mk321
-rw-r--r--firmware/CText.X/nbproject/Makefile-genesis.properties9
-rw-r--r--firmware/CText.X/nbproject/Makefile-impl.mk69
-rw-r--r--firmware/CText.X/nbproject/Makefile-local-default.mk36
-rw-r--r--firmware/CText.X/nbproject/Makefile-variables.mk13
-rw-r--r--firmware/CText.X/nbproject/Package-default.bash73
-rw-r--r--firmware/CText.X/nbproject/configurations.xml416
-rw-r--r--firmware/CText.X/nbproject/project.properties0
-rw-r--r--firmware/CText.X/nbproject/project.xml18
-rw-r--r--firmware/PIC32MZ_harmony_tryout.hconfig55
m---------firmware/src/T6963C_PIC0
-rw-r--r--firmware/src/app.c78
-rw-r--r--firmware/src/app.h115
-rw-r--r--firmware/src/editor.c87
-rw-r--r--firmware/src/editor.h50
-rw-r--r--firmware/src/main.c92
-rw-r--r--firmware/src/screen.c38
-rw-r--r--firmware/src/screen.h34
-rw-r--r--firmware/src/system_config/default/configuration.xml113
-rw-r--r--firmware/src/system_config/default/default.mhc433
-rw-r--r--firmware/src/system_config/default/framework/system/clk/src/sys_clk_static.c283
-rw-r--r--firmware/src/system_config/default/framework/system/clk/sys_clk_static.h65
-rw-r--r--firmware/src/system_config/default/framework/system/ports/src/sys_ports_static.c130
-rw-r--r--firmware/src/system_config/default/system_config.h165
-rw-r--r--firmware/src/system_config/default/system_definitions.h119
-rw-r--r--firmware/src/system_config/default/system_exceptions.c143
-rw-r--r--firmware/src/system_config/default/system_init.c210
-rw-r--r--firmware/src/system_config/default/system_interrupt.c77
-rw-r--r--firmware/src/system_config/default/system_tasks.c91
-rw-r--r--firmware/src/t6963c_specific.c40
-rw-r--r--firmware/src/t6963c_specific.h68
32 files changed, 3554 insertions, 0 deletions
diff --git a/firmware/CText.X/Makefile b/firmware/CText.X/Makefile
new file mode 100644
index 0000000..fca8e2c
--- /dev/null
+++ b/firmware/CText.X/Makefile
@@ -0,0 +1,113 @@
+#
+# There exist several targets which are by default empty and which can be
+# used for execution of your targets. These targets are usually executed
+# before and after some main targets. They are:
+#
+# .build-pre: called before 'build' target
+# .build-post: called after 'build' target
+# .clean-pre: called before 'clean' target
+# .clean-post: called after 'clean' target
+# .clobber-pre: called before 'clobber' target
+# .clobber-post: called after 'clobber' target
+# .all-pre: called before 'all' target
+# .all-post: called after 'all' target
+# .help-pre: called before 'help' target
+# .help-post: called after 'help' target
+#
+# Targets beginning with '.' are not intended to be called on their own.
+#
+# Main targets can be executed directly, and they are:
+#
+# build build a specific configuration
+# clean remove built files from a configuration
+# clobber remove all built files
+# all build all configurations
+# help print help mesage
+#
+# Targets .build-impl, .clean-impl, .clobber-impl, .all-impl, and
+# .help-impl are implemented in nbproject/makefile-impl.mk.
+#
+# Available make variables:
+#
+# CND_BASEDIR base directory for relative paths
+# CND_DISTDIR default top distribution directory (build artifacts)
+# CND_BUILDDIR default top build directory (object files, ...)
+# CONF name of current configuration
+# CND_ARTIFACT_DIR_${CONF} directory of build artifact (current configuration)
+# CND_ARTIFACT_NAME_${CONF} name of build artifact (current configuration)
+# CND_ARTIFACT_PATH_${CONF} path to build artifact (current configuration)
+# CND_PACKAGE_DIR_${CONF} directory of package (current configuration)
+# CND_PACKAGE_NAME_${CONF} name of package (current configuration)
+# CND_PACKAGE_PATH_${CONF} path to package (current configuration)
+#
+# NOCDDL
+
+
+# Environment
+MKDIR=mkdir
+CP=cp
+CCADMIN=CCadmin
+RANLIB=ranlib
+
+
+# build
+build: .build-post
+
+.build-pre:
+# Add your pre 'build' code here...
+
+.build-post: .build-impl
+# Add your post 'build' code here...
+
+
+# clean
+clean: .clean-post
+
+.clean-pre:
+# Add your pre 'clean' code here...
+# WARNING: the IDE does not call this target since it takes a long time to
+# simply run make. Instead, the IDE removes the configuration directories
+# under build and dist directly without calling make.
+# This target is left here so people can do a clean when running a clean
+# outside the IDE.
+
+.clean-post: .clean-impl
+# Add your post 'clean' code here...
+
+
+# clobber
+clobber: .clobber-post
+
+.clobber-pre:
+# Add your pre 'clobber' code here...
+
+.clobber-post: .clobber-impl
+# Add your post 'clobber' code here...
+
+
+# all
+all: .all-post
+
+.all-pre:
+# Add your pre 'all' code here...
+
+.all-post: .all-impl
+# Add your post 'all' code here...
+
+
+# help
+help: .help-post
+
+.help-pre:
+# Add your pre 'help' code here...
+
+.help-post: .help-impl
+# Add your post 'help' code here...
+
+
+
+# include project implementation makefile
+include nbproject/Makefile-impl.mk
+
+# include project make variables
+include nbproject/Makefile-variables.mk
diff --git a/firmware/CText.X/nbproject/Makefile-default.mk b/firmware/CText.X/nbproject/Makefile-default.mk
new file mode 100644
index 0000000..fd6f08b
--- /dev/null
+++ b/firmware/CText.X/nbproject/Makefile-default.mk
@@ -0,0 +1,321 @@
+#
+# Generated Makefile - do not edit!
+#
+# Edit the Makefile in the project folder instead (../Makefile). Each target
+# has a -pre and a -post target defined where you can add customized code.
+#
+# This makefile implements configuration specific macros and targets.
+
+
+# Include project Makefile
+ifeq "${IGNORE_LOCAL}" "TRUE"
+# do not include local makefile. User is passing all local related variables already
+else
+include Makefile
+# Include makefile containing local settings
+ifeq "$(wildcard nbproject/Makefile-local-default.mk)" "nbproject/Makefile-local-default.mk"
+include nbproject/Makefile-local-default.mk
+endif
+endif
+
+# Environment
+MKDIR=mkdir -p
+RM=rm -f
+MV=mv
+CP=cp
+
+# Macros
+CND_CONF=default
+ifeq ($(TYPE_IMAGE), DEBUG_RUN)
+IMAGE_TYPE=debug
+OUTPUT_SUFFIX=elf
+DEBUGGABLE_SUFFIX=elf
+FINAL_IMAGE=dist/${CND_CONF}/${IMAGE_TYPE}/CText.X.${IMAGE_TYPE}.${OUTPUT_SUFFIX}
+else
+IMAGE_TYPE=production
+OUTPUT_SUFFIX=hex
+DEBUGGABLE_SUFFIX=elf
+FINAL_IMAGE=dist/${CND_CONF}/${IMAGE_TYPE}/CText.X.${IMAGE_TYPE}.${OUTPUT_SUFFIX}
+endif
+
+# Object Directory
+OBJECTDIR=build/${CND_CONF}/${IMAGE_TYPE}
+
+# Distribution Directory
+DISTDIR=dist/${CND_CONF}/${IMAGE_TYPE}
+
+# Source Files Quoted if spaced
+SOURCEFILES_QUOTED_IF_SPACED=../src/system_config/default/framework/system/clk/src/sys_clk_static.c ../src/system_config/default/framework/system/ports/src/sys_ports_static.c ../src/system_config/default/system_init.c ../src/system_config/default/system_interrupt.c ../src/system_config/default/system_exceptions.c ../src/system_config/default/system_tasks.c ../src/app.c ../src/main.c ../src/screen.c ../../../../../../opt/microchip/harmony/v1_06/framework/system/devcon/src/sys_devcon.c ../../../../../../opt/microchip/harmony/v1_06/framework/system/devcon/src/sys_devcon_pic32mz.c ../../../../../../opt/microchip/harmony/v1_06/framework/system/devcon/src/sys_devcon_cache_pic32mz.S ../../../../../../opt/microchip/harmony/v1_06/framework/system/ports/src/sys_ports.c ../src/T6963C_PIC/t6963c.c ../src/T6963C_PIC/terminal.c
+
+# Object Files Quoted if spaced
+OBJECTFILES_QUOTED_IF_SPACED=${OBJECTDIR}/_ext/639803181/sys_clk_static.o ${OBJECTDIR}/_ext/822048611/sys_ports_static.o ${OBJECTDIR}/_ext/1688732426/system_init.o ${OBJECTDIR}/_ext/1688732426/system_interrupt.o ${OBJECTDIR}/_ext/1688732426/system_exceptions.o ${OBJECTDIR}/_ext/1688732426/system_tasks.o ${OBJECTDIR}/_ext/1360937237/app.o ${OBJECTDIR}/_ext/1360937237/main.o ${OBJECTDIR}/_ext/1360937237/screen.o ${OBJECTDIR}/_ext/133027496/sys_devcon.o ${OBJECTDIR}/_ext/133027496/sys_devcon_pic32mz.o ${OBJECTDIR}/_ext/133027496/sys_devcon_cache_pic32mz.o ${OBJECTDIR}/_ext/1964175649/sys_ports.o ${OBJECTDIR}/_ext/1781646828/t6963c.o ${OBJECTDIR}/_ext/1781646828/terminal.o
+POSSIBLE_DEPFILES=${OBJECTDIR}/_ext/639803181/sys_clk_static.o.d ${OBJECTDIR}/_ext/822048611/sys_ports_static.o.d ${OBJECTDIR}/_ext/1688732426/system_init.o.d ${OBJECTDIR}/_ext/1688732426/system_interrupt.o.d ${OBJECTDIR}/_ext/1688732426/system_exceptions.o.d ${OBJECTDIR}/_ext/1688732426/system_tasks.o.d ${OBJECTDIR}/_ext/1360937237/app.o.d ${OBJECTDIR}/_ext/1360937237/main.o.d ${OBJECTDIR}/_ext/1360937237/screen.o.d ${OBJECTDIR}/_ext/133027496/sys_devcon.o.d ${OBJECTDIR}/_ext/133027496/sys_devcon_pic32mz.o.d ${OBJECTDIR}/_ext/133027496/sys_devcon_cache_pic32mz.o.d ${OBJECTDIR}/_ext/1964175649/sys_ports.o.d ${OBJECTDIR}/_ext/1781646828/t6963c.o.d ${OBJECTDIR}/_ext/1781646828/terminal.o.d
+
+# Object Files
+OBJECTFILES=${OBJECTDIR}/_ext/639803181/sys_clk_static.o ${OBJECTDIR}/_ext/822048611/sys_ports_static.o ${OBJECTDIR}/_ext/1688732426/system_init.o ${OBJECTDIR}/_ext/1688732426/system_interrupt.o ${OBJECTDIR}/_ext/1688732426/system_exceptions.o ${OBJECTDIR}/_ext/1688732426/system_tasks.o ${OBJECTDIR}/_ext/1360937237/app.o ${OBJECTDIR}/_ext/1360937237/main.o ${OBJECTDIR}/_ext/1360937237/screen.o ${OBJECTDIR}/_ext/133027496/sys_devcon.o ${OBJECTDIR}/_ext/133027496/sys_devcon_pic32mz.o ${OBJECTDIR}/_ext/133027496/sys_devcon_cache_pic32mz.o ${OBJECTDIR}/_ext/1964175649/sys_ports.o ${OBJECTDIR}/_ext/1781646828/t6963c.o ${OBJECTDIR}/_ext/1781646828/terminal.o
+
+# Source Files
+SOURCEFILES=../src/system_config/default/framework/system/clk/src/sys_clk_static.c ../src/system_config/default/framework/system/ports/src/sys_ports_static.c ../src/system_config/default/system_init.c ../src/system_config/default/system_interrupt.c ../src/system_config/default/system_exceptions.c ../src/system_config/default/system_tasks.c ../src/app.c ../src/main.c ../src/screen.c ../../../../../../opt/microchip/harmony/v1_06/framework/system/devcon/src/sys_devcon.c ../../../../../../opt/microchip/harmony/v1_06/framework/system/devcon/src/sys_devcon_pic32mz.c ../../../../../../opt/microchip/harmony/v1_06/framework/system/devcon/src/sys_devcon_cache_pic32mz.S ../../../../../../opt/microchip/harmony/v1_06/framework/system/ports/src/sys_ports.c ../src/T6963C_PIC/t6963c.c ../src/T6963C_PIC/terminal.c
+
+
+CFLAGS=
+ASFLAGS=
+LDLIBSOPTIONS=
+
+############# Tool locations ##########################################
+# If you copy a project from one host to another, the path where the #
+# compiler is installed may be different. #
+# If you open this project with MPLAB X in the new host, this #
+# makefile will be regenerated and the paths will be corrected. #
+#######################################################################
+# fixDeps replaces a bunch of sed/cat/printf statements that slow down the build
+FIXDEPS=fixDeps
+
+.build-conf: ${BUILD_SUBPROJECTS}
+ifneq ($(INFORMATION_MESSAGE), )
+ @echo $(INFORMATION_MESSAGE)
+endif
+ ${MAKE} -f nbproject/Makefile-default.mk dist/${CND_CONF}/${IMAGE_TYPE}/CText.X.${IMAGE_TYPE}.${OUTPUT_SUFFIX}
+
+MP_PROCESSOR_OPTION=32MZ2048ECG064
+MP_LINKER_FILE_OPTION=
+# ------------------------------------------------------------------------------------
+# Rules for buildStep: assemble
+ifeq ($(TYPE_IMAGE), DEBUG_RUN)
+else
+endif
+
+# ------------------------------------------------------------------------------------
+# Rules for buildStep: assembleWithPreprocess
+ifeq ($(TYPE_IMAGE), DEBUG_RUN)
+${OBJECTDIR}/_ext/133027496/sys_devcon_cache_pic32mz.o: ../../../../../../opt/microchip/harmony/v1_06/framework/system/devcon/src/sys_devcon_cache_pic32mz.S nbproject/Makefile-${CND_CONF}.mk
+ @${MKDIR} "${OBJECTDIR}/_ext/133027496"
+ @${RM} ${OBJECTDIR}/_ext/133027496/sys_devcon_cache_pic32mz.o.d
+ @${RM} ${OBJECTDIR}/_ext/133027496/sys_devcon_cache_pic32mz.o
+ @${RM} ${OBJECTDIR}/_ext/133027496/sys_devcon_cache_pic32mz.o.ok ${OBJECTDIR}/_ext/133027496/sys_devcon_cache_pic32mz.o.err
+ @${FIXDEPS} "${OBJECTDIR}/_ext/133027496/sys_devcon_cache_pic32mz.o.d" "${OBJECTDIR}/_ext/133027496/sys_devcon_cache_pic32mz.o.asm.d" -t $(SILENT) -rsi ${MP_CC_DIR}../ -c ${MP_CC} $(MP_EXTRA_AS_PRE) -D__DEBUG -D__MPLAB_DEBUGGER_ICD3=1 -c -mprocessor=$(MP_PROCESSOR_OPTION) -MMD -MF "${OBJECTDIR}/_ext/133027496/sys_devcon_cache_pic32mz.o.d" -o ${OBJECTDIR}/_ext/133027496/sys_devcon_cache_pic32mz.o ../../../../../../opt/microchip/harmony/v1_06/framework/system/devcon/src/sys_devcon_cache_pic32mz.S -save-temps=obj -Wa,--defsym=__MPLAB_BUILD=1$(MP_EXTRA_AS_POST),-MD="${OBJECTDIR}/_ext/133027496/sys_devcon_cache_pic32mz.o.asm.d",--defsym=__ICD2RAM=1,--defsym=__MPLAB_DEBUG=1,--gdwarf-2,--defsym=__DEBUG=1,--defsym=__MPLAB_DEBUGGER_ICD3=1
+
+else
+${OBJECTDIR}/_ext/133027496/sys_devcon_cache_pic32mz.o: ../../../../../../opt/microchip/harmony/v1_06/framework/system/devcon/src/sys_devcon_cache_pic32mz.S nbproject/Makefile-${CND_CONF}.mk
+ @${MKDIR} "${OBJECTDIR}/_ext/133027496"
+ @${RM} ${OBJECTDIR}/_ext/133027496/sys_devcon_cache_pic32mz.o.d
+ @${RM} ${OBJECTDIR}/_ext/133027496/sys_devcon_cache_pic32mz.o
+ @${RM} ${OBJECTDIR}/_ext/133027496/sys_devcon_cache_pic32mz.o.ok ${OBJECTDIR}/_ext/133027496/sys_devcon_cache_pic32mz.o.err
+ @${FIXDEPS} "${OBJECTDIR}/_ext/133027496/sys_devcon_cache_pic32mz.o.d" "${OBJECTDIR}/_ext/133027496/sys_devcon_cache_pic32mz.o.asm.d" -t $(SILENT) -rsi ${MP_CC_DIR}../ -c ${MP_CC} $(MP_EXTRA_AS_PRE) -c -mprocessor=$(MP_PROCESSOR_OPTION) -MMD -MF "${OBJECTDIR}/_ext/133027496/sys_devcon_cache_pic32mz.o.d" -o ${OBJECTDIR}/_ext/133027496/sys_devcon_cache_pic32mz.o ../../../../../../opt/microchip/harmony/v1_06/framework/system/devcon/src/sys_devcon_cache_pic32mz.S -save-temps=obj -Wa,--defsym=__MPLAB_BUILD=1$(MP_EXTRA_AS_POST),-MD="${OBJECTDIR}/_ext/133027496/sys_devcon_cache_pic32mz.o.asm.d",--gdwarf-2
+
+endif
+
+# ------------------------------------------------------------------------------------
+# Rules for buildStep: compile
+ifeq ($(TYPE_IMAGE), DEBUG_RUN)
+${OBJECTDIR}/_ext/639803181/sys_clk_static.o: ../src/system_config/default/framework/system/clk/src/sys_clk_static.c nbproject/Makefile-${CND_CONF}.mk
+ @${MKDIR} "${OBJECTDIR}/_ext/639803181"
+ @${RM} ${OBJECTDIR}/_ext/639803181/sys_clk_static.o.d
+ @${RM} ${OBJECTDIR}/_ext/639803181/sys_clk_static.o
+ @${FIXDEPS} "${OBJECTDIR}/_ext/639803181/sys_clk_static.o.d" $(SILENT) -rsi ${MP_CC_DIR}../ -c ${MP_CC} $(MP_EXTRA_CC_PRE) -g -D__DEBUG -D__MPLAB_DEBUGGER_ICD3=1 -fframe-base-loclist -x c -c -mprocessor=$(MP_PROCESSOR_OPTION) -ffunction-sections -O1 -I"../src" -I"../src/system_config/default" -I"../../../../../../opt/microchip/harmony/v1_06/framework" -I"../src/system_config/default/framework" -MMD -MF "${OBJECTDIR}/_ext/639803181/sys_clk_static.o.d" -o ${OBJECTDIR}/_ext/639803181/sys_clk_static.o ../src/system_config/default/framework/system/clk/src/sys_clk_static.c -save-temps=obj
+
+${OBJECTDIR}/_ext/822048611/sys_ports_static.o: ../src/system_config/default/framework/system/ports/src/sys_ports_static.c nbproject/Makefile-${CND_CONF}.mk
+ @${MKDIR} "${OBJECTDIR}/_ext/822048611"
+ @${RM} ${OBJECTDIR}/_ext/822048611/sys_ports_static.o.d
+ @${RM} ${OBJECTDIR}/_ext/822048611/sys_ports_static.o
+ @${FIXDEPS} "${OBJECTDIR}/_ext/822048611/sys_ports_static.o.d" $(SILENT) -rsi ${MP_CC_DIR}../ -c ${MP_CC} $(MP_EXTRA_CC_PRE) -g -D__DEBUG -D__MPLAB_DEBUGGER_ICD3=1 -fframe-base-loclist -x c -c -mprocessor=$(MP_PROCESSOR_OPTION) -ffunction-sections -O1 -I"../src" -I"../src/system_config/default" -I"../../../../../../opt/microchip/harmony/v1_06/framework" -I"../src/system_config/default/framework" -MMD -MF "${OBJECTDIR}/_ext/822048611/sys_ports_static.o.d" -o ${OBJECTDIR}/_ext/822048611/sys_ports_static.o ../src/system_config/default/framework/system/ports/src/sys_ports_static.c -save-temps=obj
+
+${OBJECTDIR}/_ext/1688732426/system_init.o: ../src/system_config/default/system_init.c nbproject/Makefile-${CND_CONF}.mk
+ @${MKDIR} "${OBJECTDIR}/_ext/1688732426"
+ @${RM} ${OBJECTDIR}/_ext/1688732426/system_init.o.d
+ @${RM} ${OBJECTDIR}/_ext/1688732426/system_init.o
+ @${FIXDEPS} "${OBJECTDIR}/_ext/1688732426/system_init.o.d" $(SILENT) -rsi ${MP_CC_DIR}../ -c ${MP_CC} $(MP_EXTRA_CC_PRE) -g -D__DEBUG -D__MPLAB_DEBUGGER_ICD3=1 -fframe-base-loclist -x c -c -mprocessor=$(MP_PROCESSOR_OPTION) -ffunction-sections -O1 -I"../src" -I"../src/system_config/default" -I"../../../../../../opt/microchip/harmony/v1_06/framework" -I"../src/system_config/default/framework" -MMD -MF "${OBJECTDIR}/_ext/1688732426/system_init.o.d" -o ${OBJECTDIR}/_ext/1688732426/system_init.o ../src/system_config/default/system_init.c -save-temps=obj
+
+${OBJECTDIR}/_ext/1688732426/system_interrupt.o: ../src/system_config/default/system_interrupt.c nbproject/Makefile-${CND_CONF}.mk
+ @${MKDIR} "${OBJECTDIR}/_ext/1688732426"
+ @${RM} ${OBJECTDIR}/_ext/1688732426/system_interrupt.o.d
+ @${RM} ${OBJECTDIR}/_ext/1688732426/system_interrupt.o
+ @${FIXDEPS} "${OBJECTDIR}/_ext/1688732426/system_interrupt.o.d" $(SILENT) -rsi ${MP_CC_DIR}../ -c ${MP_CC} $(MP_EXTRA_CC_PRE) -g -D__DEBUG -D__MPLAB_DEBUGGER_ICD3=1 -fframe-base-loclist -x c -c -mprocessor=$(MP_PROCESSOR_OPTION) -ffunction-sections -O1 -I"../src" -I"../src/system_config/default" -I"../../../../../../opt/microchip/harmony/v1_06/framework" -I"../src/system_config/default/framework" -MMD -MF "${OBJECTDIR}/_ext/1688732426/system_interrupt.o.d" -o ${OBJECTDIR}/_ext/1688732426/system_interrupt.o ../src/system_config/default/system_interrupt.c -save-temps=obj
+
+${OBJECTDIR}/_ext/1688732426/system_exceptions.o: ../src/system_config/default/system_exceptions.c nbproject/Makefile-${CND_CONF}.mk
+ @${MKDIR} "${OBJECTDIR}/_ext/1688732426"
+ @${RM} ${OBJECTDIR}/_ext/1688732426/system_exceptions.o.d
+ @${RM} ${OBJECTDIR}/_ext/1688732426/system_exceptions.o
+ @${FIXDEPS} "${OBJECTDIR}/_ext/1688732426/system_exceptions.o.d" $(SILENT) -rsi ${MP_CC_DIR}../ -c ${MP_CC} $(MP_EXTRA_CC_PRE) -g -D__DEBUG -D__MPLAB_DEBUGGER_ICD3=1 -fframe-base-loclist -x c -c -mprocessor=$(MP_PROCESSOR_OPTION) -ffunction-sections -O1 -I"../src" -I"../src/system_config/default" -I"../../../../../../opt/microchip/harmony/v1_06/framework" -I"../src/system_config/default/framework" -MMD -MF "${OBJECTDIR}/_ext/1688732426/system_exceptions.o.d" -o ${OBJECTDIR}/_ext/1688732426/system_exceptions.o ../src/system_config/default/system_exceptions.c -save-temps=obj
+
+${OBJECTDIR}/_ext/1688732426/system_tasks.o: ../src/system_config/default/system_tasks.c nbproject/Makefile-${CND_CONF}.mk
+ @${MKDIR} "${OBJECTDIR}/_ext/1688732426"
+ @${RM} ${OBJECTDIR}/_ext/1688732426/system_tasks.o.d
+ @${RM} ${OBJECTDIR}/_ext/1688732426/system_tasks.o
+ @${FIXDEPS} "${OBJECTDIR}/_ext/1688732426/system_tasks.o.d" $(SILENT) -rsi ${MP_CC_DIR}../ -c ${MP_CC} $(MP_EXTRA_CC_PRE) -g -D__DEBUG -D__MPLAB_DEBUGGER_ICD3=1 -fframe-base-loclist -x c -c -mprocessor=$(MP_PROCESSOR_OPTION) -ffunction-sections -O1 -I"../src" -I"../src/system_config/default" -I"../../../../../../opt/microchip/harmony/v1_06/framework" -I"../src/system_config/default/framework" -MMD -MF "${OBJECTDIR}/_ext/1688732426/system_tasks.o.d" -o ${OBJECTDIR}/_ext/1688732426/system_tasks.o ../src/system_config/default/system_tasks.c -save-temps=obj
+
+${OBJECTDIR}/_ext/1360937237/app.o: ../src/app.c nbproject/Makefile-${CND_CONF}.mk
+ @${MKDIR} "${OBJECTDIR}/_ext/1360937237"
+ @${RM} ${OBJECTDIR}/_ext/1360937237/app.o.d
+ @${RM} ${OBJECTDIR}/_ext/1360937237/app.o
+ @${FIXDEPS} "${OBJECTDIR}/_ext/1360937237/app.o.d" $(SILENT) -rsi ${MP_CC_DIR}../ -c ${MP_CC} $(MP_EXTRA_CC_PRE) -g -D__DEBUG -D__MPLAB_DEBUGGER_ICD3=1 -fframe-base-loclist -x c -c -mprocessor=$(MP_PROCESSOR_OPTION) -ffunction-sections -O1 -I"../src" -I"../src/system_config/default" -I"../../../../../../opt/microchip/harmony/v1_06/framework" -I"../src/system_config/default/framework" -MMD -MF "${OBJECTDIR}/_ext/1360937237/app.o.d" -o ${OBJECTDIR}/_ext/1360937237/app.o ../src/app.c -save-temps=obj
+
+${OBJECTDIR}/_ext/1360937237/main.o: ../src/main.c nbproject/Makefile-${CND_CONF}.mk
+ @${MKDIR} "${OBJECTDIR}/_ext/1360937237"
+ @${RM} ${OBJECTDIR}/_ext/1360937237/main.o.d
+ @${RM} ${OBJECTDIR}/_ext/1360937237/main.o
+ @${FIXDEPS} "${OBJECTDIR}/_ext/1360937237/main.o.d" $(SILENT) -rsi ${MP_CC_DIR}../ -c ${MP_CC} $(MP_EXTRA_CC_PRE) -g -D__DEBUG -D__MPLAB_DEBUGGER_ICD3=1 -fframe-base-loclist -x c -c -mprocessor=$(MP_PROCESSOR_OPTION) -ffunction-sections -O1 -I"../src" -I"../src/system_config/default" -I"../../../../../../opt/microchip/harmony/v1_06/framework" -I"../src/system_config/default/framework" -MMD -MF "${OBJECTDIR}/_ext/1360937237/main.o.d" -o ${OBJECTDIR}/_ext/1360937237/main.o ../src/main.c -save-temps=obj
+
+${OBJECTDIR}/_ext/1360937237/screen.o: ../src/screen.c nbproject/Makefile-${CND_CONF}.mk
+ @${MKDIR} "${OBJECTDIR}/_ext/1360937237"
+ @${RM} ${OBJECTDIR}/_ext/1360937237/screen.o.d
+ @${RM} ${OBJECTDIR}/_ext/1360937237/screen.o
+ @${FIXDEPS} "${OBJECTDIR}/_ext/1360937237/screen.o.d" $(SILENT) -rsi ${MP_CC_DIR}../ -c ${MP_CC} $(MP_EXTRA_CC_PRE) -g -D__DEBUG -D__MPLAB_DEBUGGER_ICD3=1 -fframe-base-loclist -x c -c -mprocessor=$(MP_PROCESSOR_OPTION) -ffunction-sections -O1 -I"../src" -I"../src/system_config/default" -I"../../../../../../opt/microchip/harmony/v1_06/framework" -I"../src/system_config/default/framework" -MMD -MF "${OBJECTDIR}/_ext/1360937237/screen.o.d" -o ${OBJECTDIR}/_ext/1360937237/screen.o ../src/screen.c -save-temps=obj
+
+${OBJECTDIR}/_ext/133027496/sys_devcon.o: ../../../../../../opt/microchip/harmony/v1_06/framework/system/devcon/src/sys_devcon.c nbproject/Makefile-${CND_CONF}.mk
+ @${MKDIR} "${OBJECTDIR}/_ext/133027496"
+ @${RM} ${OBJECTDIR}/_ext/133027496/sys_devcon.o.d
+ @${RM} ${OBJECTDIR}/_ext/133027496/sys_devcon.o
+ @${FIXDEPS} "${OBJECTDIR}/_ext/133027496/sys_devcon.o.d" $(SILENT) -rsi ${MP_CC_DIR}../ -c ${MP_CC} $(MP_EXTRA_CC_PRE) -g -D__DEBUG -D__MPLAB_DEBUGGER_ICD3=1 -fframe-base-loclist -x c -c -mprocessor=$(MP_PROCESSOR_OPTION) -ffunction-sections -O1 -I"../src" -I"../src/system_config/default" -I"../../../../../../opt/microchip/harmony/v1_06/framework" -I"../src/system_config/default/framework" -MMD -MF "${OBJECTDIR}/_ext/133027496/sys_devcon.o.d" -o ${OBJECTDIR}/_ext/133027496/sys_devcon.o ../../../../../../opt/microchip/harmony/v1_06/framework/system/devcon/src/sys_devcon.c -save-temps=obj
+
+${OBJECTDIR}/_ext/133027496/sys_devcon_pic32mz.o: ../../../../../../opt/microchip/harmony/v1_06/framework/system/devcon/src/sys_devcon_pic32mz.c nbproject/Makefile-${CND_CONF}.mk
+ @${MKDIR} "${OBJECTDIR}/_ext/133027496"
+ @${RM} ${OBJECTDIR}/_ext/133027496/sys_devcon_pic32mz.o.d
+ @${RM} ${OBJECTDIR}/_ext/133027496/sys_devcon_pic32mz.o
+ @${FIXDEPS} "${OBJECTDIR}/_ext/133027496/sys_devcon_pic32mz.o.d" $(SILENT) -rsi ${MP_CC_DIR}../ -c ${MP_CC} $(MP_EXTRA_CC_PRE) -g -D__DEBUG -D__MPLAB_DEBUGGER_ICD3=1 -fframe-base-loclist -x c -c -mprocessor=$(MP_PROCESSOR_OPTION) -ffunction-sections -O1 -I"../src" -I"../src/system_config/default" -I"../../../../../../opt/microchip/harmony/v1_06/framework" -I"../src/system_config/default/framework" -MMD -MF "${OBJECTDIR}/_ext/133027496/sys_devcon_pic32mz.o.d" -o ${OBJECTDIR}/_ext/133027496/sys_devcon_pic32mz.o ../../../../../../opt/microchip/harmony/v1_06/framework/system/devcon/src/sys_devcon_pic32mz.c -save-temps=obj
+
+${OBJECTDIR}/_ext/1964175649/sys_ports.o: ../../../../../../opt/microchip/harmony/v1_06/framework/system/ports/src/sys_ports.c nbproject/Makefile-${CND_CONF}.mk
+ @${MKDIR} "${OBJECTDIR}/_ext/1964175649"
+ @${RM} ${OBJECTDIR}/_ext/1964175649/sys_ports.o.d
+ @${RM} ${OBJECTDIR}/_ext/1964175649/sys_ports.o
+ @${FIXDEPS} "${OBJECTDIR}/_ext/1964175649/sys_ports.o.d" $(SILENT) -rsi ${MP_CC_DIR}../ -c ${MP_CC} $(MP_EXTRA_CC_PRE) -g -D__DEBUG -D__MPLAB_DEBUGGER_ICD3=1 -fframe-base-loclist -x c -c -mprocessor=$(MP_PROCESSOR_OPTION) -ffunction-sections -O1 -I"../src" -I"../src/system_config/default" -I"../../../../../../opt/microchip/harmony/v1_06/framework" -I"../src/system_config/default/framework" -MMD -MF "${OBJECTDIR}/_ext/1964175649/sys_ports.o.d" -o ${OBJECTDIR}/_ext/1964175649/sys_ports.o ../../../../../../opt/microchip/harmony/v1_06/framework/system/ports/src/sys_ports.c -save-temps=obj
+
+${OBJECTDIR}/_ext/1781646828/t6963c.o: ../src/T6963C_PIC/t6963c.c nbproject/Makefile-${CND_CONF}.mk
+ @${MKDIR} "${OBJECTDIR}/_ext/1781646828"
+ @${RM} ${OBJECTDIR}/_ext/1781646828/t6963c.o.d
+ @${RM} ${OBJECTDIR}/_ext/1781646828/t6963c.o
+ @${FIXDEPS} "${OBJECTDIR}/_ext/1781646828/t6963c.o.d" $(SILENT) -rsi ${MP_CC_DIR}../ -c ${MP_CC} $(MP_EXTRA_CC_PRE) -g -D__DEBUG -D__MPLAB_DEBUGGER_ICD3=1 -fframe-base-loclist -x c -c -mprocessor=$(MP_PROCESSOR_OPTION) -ffunction-sections -O1 -I"../src" -I"../src/system_config/default" -I"../../../../../../opt/microchip/harmony/v1_06/framework" -I"../src/system_config/default/framework" -MMD -MF "${OBJECTDIR}/_ext/1781646828/t6963c.o.d" -o ${OBJECTDIR}/_ext/1781646828/t6963c.o ../src/T6963C_PIC/t6963c.c -save-temps=obj
+
+${OBJECTDIR}/_ext/1781646828/terminal.o: ../src/T6963C_PIC/terminal.c nbproject/Makefile-${CND_CONF}.mk
+ @${MKDIR} "${OBJECTDIR}/_ext/1781646828"
+ @${RM} ${OBJECTDIR}/_ext/1781646828/terminal.o.d
+ @${RM} ${OBJECTDIR}/_ext/1781646828/terminal.o
+ @${FIXDEPS} "${OBJECTDIR}/_ext/1781646828/terminal.o.d" $(SILENT) -rsi ${MP_CC_DIR}../ -c ${MP_CC} $(MP_EXTRA_CC_PRE) -g -D__DEBUG -D__MPLAB_DEBUGGER_ICD3=1 -fframe-base-loclist -x c -c -mprocessor=$(MP_PROCESSOR_OPTION) -ffunction-sections -O1 -I"../src" -I"../src/system_config/default" -I"../../../../../../opt/microchip/harmony/v1_06/framework" -I"../src/system_config/default/framework" -MMD -MF "${OBJECTDIR}/_ext/1781646828/terminal.o.d" -o ${OBJECTDIR}/_ext/1781646828/terminal.o ../src/T6963C_PIC/terminal.c -save-temps=obj
+
+else
+${OBJECTDIR}/_ext/639803181/sys_clk_static.o: ../src/system_config/default/framework/system/clk/src/sys_clk_static.c nbproject/Makefile-${CND_CONF}.mk
+ @${MKDIR} "${OBJECTDIR}/_ext/639803181"
+ @${RM} ${OBJECTDIR}/_ext/639803181/sys_clk_static.o.d
+ @${RM} ${OBJECTDIR}/_ext/639803181/sys_clk_static.o
+ @${FIXDEPS} "${OBJECTDIR}/_ext/639803181/sys_clk_static.o.d" $(SILENT) -rsi ${MP_CC_DIR}../ -c ${MP_CC} $(MP_EXTRA_CC_PRE) -g -x c -c -mprocessor=$(MP_PROCESSOR_OPTION) -ffunction-sections -O1 -I"../src" -I"../src/system_config/default" -I"../../../../../../opt/microchip/harmony/v1_06/framework" -I"../src/system_config/default/framework" -MMD -MF "${OBJECTDIR}/_ext/639803181/sys_clk_static.o.d" -o ${OBJECTDIR}/_ext/639803181/sys_clk_static.o ../src/system_config/default/framework/system/clk/src/sys_clk_static.c -save-temps=obj
+
+${OBJECTDIR}/_ext/822048611/sys_ports_static.o: ../src/system_config/default/framework/system/ports/src/sys_ports_static.c nbproject/Makefile-${CND_CONF}.mk
+ @${MKDIR} "${OBJECTDIR}/_ext/822048611"
+ @${RM} ${OBJECTDIR}/_ext/822048611/sys_ports_static.o.d
+ @${RM} ${OBJECTDIR}/_ext/822048611/sys_ports_static.o
+ @${FIXDEPS} "${OBJECTDIR}/_ext/822048611/sys_ports_static.o.d" $(SILENT) -rsi ${MP_CC_DIR}../ -c ${MP_CC} $(MP_EXTRA_CC_PRE) -g -x c -c -mprocessor=$(MP_PROCESSOR_OPTION) -ffunction-sections -O1 -I"../src" -I"../src/system_config/default" -I"../../../../../../opt/microchip/harmony/v1_06/framework" -I"../src/system_config/default/framework" -MMD -MF "${OBJECTDIR}/_ext/822048611/sys_ports_static.o.d" -o ${OBJECTDIR}/_ext/822048611/sys_ports_static.o ../src/system_config/default/framework/system/ports/src/sys_ports_static.c -save-temps=obj
+
+${OBJECTDIR}/_ext/1688732426/system_init.o: ../src/system_config/default/system_init.c nbproject/Makefile-${CND_CONF}.mk
+ @${MKDIR} "${OBJECTDIR}/_ext/1688732426"
+ @${RM} ${OBJECTDIR}/_ext/1688732426/system_init.o.d
+ @${RM} ${OBJECTDIR}/_ext/1688732426/system_init.o
+ @${FIXDEPS} "${OBJECTDIR}/_ext/1688732426/system_init.o.d" $(SILENT) -rsi ${MP_CC_DIR}../ -c ${MP_CC} $(MP_EXTRA_CC_PRE) -g -x c -c -mprocessor=$(MP_PROCESSOR_OPTION) -ffunction-sections -O1 -I"../src" -I"../src/system_config/default" -I"../../../../../../opt/microchip/harmony/v1_06/framework" -I"../src/system_config/default/framework" -MMD -MF "${OBJECTDIR}/_ext/1688732426/system_init.o.d" -o ${OBJECTDIR}/_ext/1688732426/system_init.o ../src/system_config/default/system_init.c -save-temps=obj
+
+${OBJECTDIR}/_ext/1688732426/system_interrupt.o: ../src/system_config/default/system_interrupt.c nbproject/Makefile-${CND_CONF}.mk
+ @${MKDIR} "${OBJECTDIR}/_ext/1688732426"
+ @${RM} ${OBJECTDIR}/_ext/1688732426/system_interrupt.o.d
+ @${RM} ${OBJECTDIR}/_ext/1688732426/system_interrupt.o
+ @${FIXDEPS} "${OBJECTDIR}/_ext/1688732426/system_interrupt.o.d" $(SILENT) -rsi ${MP_CC_DIR}../ -c ${MP_CC} $(MP_EXTRA_CC_PRE) -g -x c -c -mprocessor=$(MP_PROCESSOR_OPTION) -ffunction-sections -O1 -I"../src" -I"../src/system_config/default" -I"../../../../../../opt/microchip/harmony/v1_06/framework" -I"../src/system_config/default/framework" -MMD -MF "${OBJECTDIR}/_ext/1688732426/system_interrupt.o.d" -o ${OBJECTDIR}/_ext/1688732426/system_interrupt.o ../src/system_config/default/system_interrupt.c -save-temps=obj
+
+${OBJECTDIR}/_ext/1688732426/system_exceptions.o: ../src/system_config/default/system_exceptions.c nbproject/Makefile-${CND_CONF}.mk
+ @${MKDIR} "${OBJECTDIR}/_ext/1688732426"
+ @${RM} ${OBJECTDIR}/_ext/1688732426/system_exceptions.o.d
+ @${RM} ${OBJECTDIR}/_ext/1688732426/system_exceptions.o
+ @${FIXDEPS} "${OBJECTDIR}/_ext/1688732426/system_exceptions.o.d" $(SILENT) -rsi ${MP_CC_DIR}../ -c ${MP_CC} $(MP_EXTRA_CC_PRE) -g -x c -c -mprocessor=$(MP_PROCESSOR_OPTION) -ffunction-sections -O1 -I"../src" -I"../src/system_config/default" -I"../../../../../../opt/microchip/harmony/v1_06/framework" -I"../src/system_config/default/framework" -MMD -MF "${OBJECTDIR}/_ext/1688732426/system_exceptions.o.d" -o ${OBJECTDIR}/_ext/1688732426/system_exceptions.o ../src/system_config/default/system_exceptions.c -save-temps=obj
+
+${OBJECTDIR}/_ext/1688732426/system_tasks.o: ../src/system_config/default/system_tasks.c nbproject/Makefile-${CND_CONF}.mk
+ @${MKDIR} "${OBJECTDIR}/_ext/1688732426"
+ @${RM} ${OBJECTDIR}/_ext/1688732426/system_tasks.o.d
+ @${RM} ${OBJECTDIR}/_ext/1688732426/system_tasks.o
+ @${FIXDEPS} "${OBJECTDIR}/_ext/1688732426/system_tasks.o.d" $(SILENT) -rsi ${MP_CC_DIR}../ -c ${MP_CC} $(MP_EXTRA_CC_PRE) -g -x c -c -mprocessor=$(MP_PROCESSOR_OPTION) -ffunction-sections -O1 -I"../src" -I"../src/system_config/default" -I"../../../../../../opt/microchip/harmony/v1_06/framework" -I"../src/system_config/default/framework" -MMD -MF "${OBJECTDIR}/_ext/1688732426/system_tasks.o.d" -o ${OBJECTDIR}/_ext/1688732426/system_tasks.o ../src/system_config/default/system_tasks.c -save-temps=obj
+
+${OBJECTDIR}/_ext/1360937237/app.o: ../src/app.c nbproject/Makefile-${CND_CONF}.mk
+ @${MKDIR} "${OBJECTDIR}/_ext/1360937237"
+ @${RM} ${OBJECTDIR}/_ext/1360937237/app.o.d
+ @${RM} ${OBJECTDIR}/_ext/1360937237/app.o
+ @${FIXDEPS} "${OBJECTDIR}/_ext/1360937237/app.o.d" $(SILENT) -rsi ${MP_CC_DIR}../ -c ${MP_CC} $(MP_EXTRA_CC_PRE) -g -x c -c -mprocessor=$(MP_PROCESSOR_OPTION) -ffunction-sections -O1 -I"../src" -I"../src/system_config/default" -I"../../../../../../opt/microchip/harmony/v1_06/framework" -I"../src/system_config/default/framework" -MMD -MF "${OBJECTDIR}/_ext/1360937237/app.o.d" -o ${OBJECTDIR}/_ext/1360937237/app.o ../src/app.c -save-temps=obj
+
+${OBJECTDIR}/_ext/1360937237/main.o: ../src/main.c nbproject/Makefile-${CND_CONF}.mk
+ @${MKDIR} "${OBJECTDIR}/_ext/1360937237"
+ @${RM} ${OBJECTDIR}/_ext/1360937237/main.o.d
+ @${RM} ${OBJECTDIR}/_ext/1360937237/main.o
+ @${FIXDEPS} "${OBJECTDIR}/_ext/1360937237/main.o.d" $(SILENT) -rsi ${MP_CC_DIR}../ -c ${MP_CC} $(MP_EXTRA_CC_PRE) -g -x c -c -mprocessor=$(MP_PROCESSOR_OPTION) -ffunction-sections -O1 -I"../src" -I"../src/system_config/default" -I"../../../../../../opt/microchip/harmony/v1_06/framework" -I"../src/system_config/default/framework" -MMD -MF "${OBJECTDIR}/_ext/1360937237/main.o.d" -o ${OBJECTDIR}/_ext/1360937237/main.o ../src/main.c -save-temps=obj
+
+${OBJECTDIR}/_ext/1360937237/screen.o: ../src/screen.c nbproject/Makefile-${CND_CONF}.mk
+ @${MKDIR} "${OBJECTDIR}/_ext/1360937237"
+ @${RM} ${OBJECTDIR}/_ext/1360937237/screen.o.d
+ @${RM} ${OBJECTDIR}/_ext/1360937237/screen.o
+ @${FIXDEPS} "${OBJECTDIR}/_ext/1360937237/screen.o.d" $(SILENT) -rsi ${MP_CC_DIR}../ -c ${MP_CC} $(MP_EXTRA_CC_PRE) -g -x c -c -mprocessor=$(MP_PROCESSOR_OPTION) -ffunction-sections -O1 -I"../src" -I"../src/system_config/default" -I"../../../../../../opt/microchip/harmony/v1_06/framework" -I"../src/system_config/default/framework" -MMD -MF "${OBJECTDIR}/_ext/1360937237/screen.o.d" -o ${OBJECTDIR}/_ext/1360937237/screen.o ../src/screen.c -save-temps=obj
+
+${OBJECTDIR}/_ext/133027496/sys_devcon.o: ../../../../../../opt/microchip/harmony/v1_06/framework/system/devcon/src/sys_devcon.c nbproject/Makefile-${CND_CONF}.mk
+ @${MKDIR} "${OBJECTDIR}/_ext/133027496"
+ @${RM} ${OBJECTDIR}/_ext/133027496/sys_devcon.o.d
+ @${RM} ${OBJECTDIR}/_ext/133027496/sys_devcon.o
+ @${FIXDEPS} "${OBJECTDIR}/_ext/133027496/sys_devcon.o.d" $(SILENT) -rsi ${MP_CC_DIR}../ -c ${MP_CC} $(MP_EXTRA_CC_PRE) -g -x c -c -mprocessor=$(MP_PROCESSOR_OPTION) -ffunction-sections -O1 -I"../src" -I"../src/system_config/default" -I"../../../../../../opt/microchip/harmony/v1_06/framework" -I"../src/system_config/default/framework" -MMD -MF "${OBJECTDIR}/_ext/133027496/sys_devcon.o.d" -o ${OBJECTDIR}/_ext/133027496/sys_devcon.o ../../../../../../opt/microchip/harmony/v1_06/framework/system/devcon/src/sys_devcon.c -save-temps=obj
+
+${OBJECTDIR}/_ext/133027496/sys_devcon_pic32mz.o: ../../../../../../opt/microchip/harmony/v1_06/framework/system/devcon/src/sys_devcon_pic32mz.c nbproject/Makefile-${CND_CONF}.mk
+ @${MKDIR} "${OBJECTDIR}/_ext/133027496"
+ @${RM} ${OBJECTDIR}/_ext/133027496/sys_devcon_pic32mz.o.d
+ @${RM} ${OBJECTDIR}/_ext/133027496/sys_devcon_pic32mz.o
+ @${FIXDEPS} "${OBJECTDIR}/_ext/133027496/sys_devcon_pic32mz.o.d" $(SILENT) -rsi ${MP_CC_DIR}../ -c ${MP_CC} $(MP_EXTRA_CC_PRE) -g -x c -c -mprocessor=$(MP_PROCESSOR_OPTION) -ffunction-sections -O1 -I"../src" -I"../src/system_config/default" -I"../../../../../../opt/microchip/harmony/v1_06/framework" -I"../src/system_config/default/framework" -MMD -MF "${OBJECTDIR}/_ext/133027496/sys_devcon_pic32mz.o.d" -o ${OBJECTDIR}/_ext/133027496/sys_devcon_pic32mz.o ../../../../../../opt/microchip/harmony/v1_06/framework/system/devcon/src/sys_devcon_pic32mz.c -save-temps=obj
+
+${OBJECTDIR}/_ext/1964175649/sys_ports.o: ../../../../../../opt/microchip/harmony/v1_06/framework/system/ports/src/sys_ports.c nbproject/Makefile-${CND_CONF}.mk
+ @${MKDIR} "${OBJECTDIR}/_ext/1964175649"
+ @${RM} ${OBJECTDIR}/_ext/1964175649/sys_ports.o.d
+ @${RM} ${OBJECTDIR}/_ext/1964175649/sys_ports.o
+ @${FIXDEPS} "${OBJECTDIR}/_ext/1964175649/sys_ports.o.d" $(SILENT) -rsi ${MP_CC_DIR}../ -c ${MP_CC} $(MP_EXTRA_CC_PRE) -g -x c -c -mprocessor=$(MP_PROCESSOR_OPTION) -ffunction-sections -O1 -I"../src" -I"../src/system_config/default" -I"../../../../../../opt/microchip/harmony/v1_06/framework" -I"../src/system_config/default/framework" -MMD -MF "${OBJECTDIR}/_ext/1964175649/sys_ports.o.d" -o ${OBJECTDIR}/_ext/1964175649/sys_ports.o ../../../../../../opt/microchip/harmony/v1_06/framework/system/ports/src/sys_ports.c -save-temps=obj
+
+${OBJECTDIR}/_ext/1781646828/t6963c.o: ../src/T6963C_PIC/t6963c.c nbproject/Makefile-${CND_CONF}.mk
+ @${MKDIR} "${OBJECTDIR}/_ext/1781646828"
+ @${RM} ${OBJECTDIR}/_ext/1781646828/t6963c.o.d
+ @${RM} ${OBJECTDIR}/_ext/1781646828/t6963c.o
+ @${FIXDEPS} "${OBJECTDIR}/_ext/1781646828/t6963c.o.d" $(SILENT) -rsi ${MP_CC_DIR}../ -c ${MP_CC} $(MP_EXTRA_CC_PRE) -g -x c -c -mprocessor=$(MP_PROCESSOR_OPTION) -ffunction-sections -O1 -I"../src" -I"../src/system_config/default" -I"../../../../../../opt/microchip/harmony/v1_06/framework" -I"../src/system_config/default/framework" -MMD -MF "${OBJECTDIR}/_ext/1781646828/t6963c.o.d" -o ${OBJECTDIR}/_ext/1781646828/t6963c.o ../src/T6963C_PIC/t6963c.c -save-temps=obj
+
+${OBJECTDIR}/_ext/1781646828/terminal.o: ../src/T6963C_PIC/terminal.c nbproject/Makefile-${CND_CONF}.mk
+ @${MKDIR} "${OBJECTDIR}/_ext/1781646828"
+ @${RM} ${OBJECTDIR}/_ext/1781646828/terminal.o.d
+ @${RM} ${OBJECTDIR}/_ext/1781646828/terminal.o
+ @${FIXDEPS} "${OBJECTDIR}/_ext/1781646828/terminal.o.d" $(SILENT) -rsi ${MP_CC_DIR}../ -c ${MP_CC} $(MP_EXTRA_CC_PRE) -g -x c -c -mprocessor=$(MP_PROCESSOR_OPTION) -ffunction-sections -O1 -I"../src" -I"../src/system_config/default" -I"../../../../../../opt/microchip/harmony/v1_06/framework" -I"../src/system_config/default/framework" -MMD -MF "${OBJECTDIR}/_ext/1781646828/terminal.o.d" -o ${OBJECTDIR}/_ext/1781646828/terminal.o ../src/T6963C_PIC/terminal.c -save-temps=obj
+
+endif
+
+# ------------------------------------------------------------------------------------
+# Rules for buildStep: compileCPP
+ifeq ($(TYPE_IMAGE), DEBUG_RUN)
+else
+endif
+
+# ------------------------------------------------------------------------------------
+# Rules for buildStep: link
+ifeq ($(TYPE_IMAGE), DEBUG_RUN)
+dist/${CND_CONF}/${IMAGE_TYPE}/CText.X.${IMAGE_TYPE}.${OUTPUT_SUFFIX}: ${OBJECTFILES} nbproject/Makefile-${CND_CONF}.mk ../../../../../../opt/microchip/harmony/v1_06/bin/framework/peripheral/PIC32MZ2048ECG064_peripherals.a
+ @${MKDIR} dist/${CND_CONF}/${IMAGE_TYPE}
+ ${MP_CC} $(MP_EXTRA_LD_PRE) -mdebugger -D__MPLAB_DEBUGGER_ICD3=1 -mprocessor=$(MP_PROCESSOR_OPTION) -o dist/${CND_CONF}/${IMAGE_TYPE}/CText.X.${IMAGE_TYPE}.${OUTPUT_SUFFIX} ${OBJECTFILES_QUOTED_IF_SPACED} ../../../../../../opt/microchip/harmony/v1_06/bin/framework/peripheral/PIC32MZ2048ECG064_peripherals.a -save-temps=obj -mreserve=data@0x0:0x27F -Wl,--defsym=__MPLAB_BUILD=1$(MP_EXTRA_LD_POST)$(MP_LINKER_FILE_OPTION),--defsym=__MPLAB_DEBUG=1,--defsym=__DEBUG=1,--defsym=__MPLAB_DEBUGGER_ICD3=1,--defsym=_min_heap_size=4096,--gc-sections,-Map="${DISTDIR}/${PROJECTNAME}.${IMAGE_TYPE}.map",--memorysummary,dist/${CND_CONF}/${IMAGE_TYPE}/memoryfile.xml
+
+else
+dist/${CND_CONF}/${IMAGE_TYPE}/CText.X.${IMAGE_TYPE}.${OUTPUT_SUFFIX}: ${OBJECTFILES} nbproject/Makefile-${CND_CONF}.mk ../../../../../../opt/microchip/harmony/v1_06/bin/framework/peripheral/PIC32MZ2048ECG064_peripherals.a
+ @${MKDIR} dist/${CND_CONF}/${IMAGE_TYPE}
+ ${MP_CC} $(MP_EXTRA_LD_PRE) -mprocessor=$(MP_PROCESSOR_OPTION) -o dist/${CND_CONF}/${IMAGE_TYPE}/CText.X.${IMAGE_TYPE}.${DEBUGGABLE_SUFFIX} ${OBJECTFILES_QUOTED_IF_SPACED} ../../../../../../opt/microchip/harmony/v1_06/bin/framework/peripheral/PIC32MZ2048ECG064_peripherals.a -save-temps=obj -Wl,--defsym=__MPLAB_BUILD=1$(MP_EXTRA_LD_POST)$(MP_LINKER_FILE_OPTION),--defsym=_min_heap_size=4096,--gc-sections,-Map="${DISTDIR}/${PROJECTNAME}.${IMAGE_TYPE}.map",--memorysummary,dist/${CND_CONF}/${IMAGE_TYPE}/memoryfile.xml
+ ${MP_CC_DIR}/xc32-bin2hex dist/${CND_CONF}/${IMAGE_TYPE}/CText.X.${IMAGE_TYPE}.${DEBUGGABLE_SUFFIX}
+endif
+
+
+# Subprojects
+.build-subprojects:
+
+
+# Subprojects
+.clean-subprojects:
+
+# Clean Targets
+.clean-conf: ${CLEAN_SUBPROJECTS}
+ ${RM} -r build/default
+ ${RM} -r dist/default
+
+# Enable dependency checking
+.dep.inc: .depcheck-impl
+
+DEPFILES=$(shell "${PATH_TO_IDE_BIN}"mplabwildcard ${POSSIBLE_DEPFILES})
+ifneq (${DEPFILES},)
+include ${DEPFILES}
+endif
diff --git a/firmware/CText.X/nbproject/Makefile-genesis.properties b/firmware/CText.X/nbproject/Makefile-genesis.properties
new file mode 100644
index 0000000..c0fcd1d
--- /dev/null
+++ b/firmware/CText.X/nbproject/Makefile-genesis.properties
@@ -0,0 +1,9 @@
+#
+#Thu Aug 20 22:36:04 CEST 2015
+default.com-microchip-mplab-nbide-toolchainXC32-XC32LanguageToolchain.md5=a29d9df60dd9a7849837c8f5ca17a004
+default.languagetoolchain.dir=/opt/microchip/xc32/v1.40/bin
+configurations-xml=9764c5a974d7015cd7c610db0085c53e
+com-microchip-mplab-nbide-embedded-makeproject-MakeProject.md5=47805b5596804b87cda41e61096929be
+default.languagetoolchain.version=1.40
+host.platform=linux
+conf.ids=default
diff --git a/firmware/CText.X/nbproject/Makefile-impl.mk b/firmware/CText.X/nbproject/Makefile-impl.mk
new file mode 100644
index 0000000..c720100
--- /dev/null
+++ b/firmware/CText.X/nbproject/Makefile-impl.mk
@@ -0,0 +1,69 @@
+#
+# Generated Makefile - do not edit!
+#
+# Edit the Makefile in the project folder instead (../Makefile). Each target
+# has a pre- and a post- target defined where you can add customization code.
+#
+# This makefile implements macros and targets common to all configurations.
+#
+# NOCDDL
+
+
+# Building and Cleaning subprojects are done by default, but can be controlled with the SUB
+# macro. If SUB=no, subprojects will not be built or cleaned. The following macro
+# statements set BUILD_SUB-CONF and CLEAN_SUB-CONF to .build-reqprojects-conf
+# and .clean-reqprojects-conf unless SUB has the value 'no'
+SUB_no=NO
+SUBPROJECTS=${SUB_${SUB}}
+BUILD_SUBPROJECTS_=.build-subprojects
+BUILD_SUBPROJECTS_NO=
+BUILD_SUBPROJECTS=${BUILD_SUBPROJECTS_${SUBPROJECTS}}
+CLEAN_SUBPROJECTS_=.clean-subprojects
+CLEAN_SUBPROJECTS_NO=
+CLEAN_SUBPROJECTS=${CLEAN_SUBPROJECTS_${SUBPROJECTS}}
+
+
+# Project Name
+PROJECTNAME=CText.X
+
+# Active Configuration
+DEFAULTCONF=default
+CONF=${DEFAULTCONF}
+
+# All Configurations
+ALLCONFS=default
+
+
+# build
+.build-impl: .build-pre
+ ${MAKE} -f nbproject/Makefile-${CONF}.mk SUBPROJECTS=${SUBPROJECTS} .build-conf
+
+
+# clean
+.clean-impl: .clean-pre
+ ${MAKE} -f nbproject/Makefile-${CONF}.mk SUBPROJECTS=${SUBPROJECTS} .clean-conf
+
+# clobber
+.clobber-impl: .clobber-pre .depcheck-impl
+ ${MAKE} SUBPROJECTS=${SUBPROJECTS} CONF=default clean
+
+
+
+# all
+.all-impl: .all-pre .depcheck-impl
+ ${MAKE} SUBPROJECTS=${SUBPROJECTS} CONF=default build
+
+
+
+# dependency checking support
+.depcheck-impl:
+# @echo "# This code depends on make tool being used" >.dep.inc
+# @if [ -n "${MAKE_VERSION}" ]; then \
+# echo "DEPFILES=\$$(wildcard \$$(addsuffix .d, \$${OBJECTFILES}))" >>.dep.inc; \
+# echo "ifneq (\$${DEPFILES},)" >>.dep.inc; \
+# echo "include \$${DEPFILES}" >>.dep.inc; \
+# echo "endif" >>.dep.inc; \
+# else \
+# echo ".KEEP_STATE:" >>.dep.inc; \
+# echo ".KEEP_STATE_FILE:.make.state.\$${CONF}" >>.dep.inc; \
+# fi
diff --git a/firmware/CText.X/nbproject/Makefile-local-default.mk b/firmware/CText.X/nbproject/Makefile-local-default.mk
new file mode 100644
index 0000000..a6a093e
--- /dev/null
+++ b/firmware/CText.X/nbproject/Makefile-local-default.mk
@@ -0,0 +1,36 @@
+#
+# Generated Makefile - do not edit!
+#
+#
+# This file contains information about the location of compilers and other tools.
+# If you commmit this file into your revision control server, you will be able to
+# to checkout the project and build it from the command line with make. However,
+# if more than one person works on the same project, then this file might show
+# conflicts since different users are bound to have compilers in different places.
+# In that case you might choose to not commit this file and let MPLAB X recreate this file
+# for each user. The disadvantage of not commiting this file is that you must run MPLAB X at
+# least once so the file gets created and the project can be built. Finally, you can also
+# avoid using this file at all if you are only building from the command line with make.
+# You can invoke make with the values of the macros:
+# $ makeMP_CC="/opt/microchip/mplabc30/v3.30c/bin/pic30-gcc" ...
+#
+PATH_TO_IDE_BIN=/opt/microchip/mplabx/v3.05/mplab_ide/mplab_ide/modules/../../bin/
+# Adding MPLAB X bin directory to path.
+PATH:=/opt/microchip/mplabx/v3.05/mplab_ide/mplab_ide/modules/../../bin/:$(PATH)
+# Path to java used to run MPLAB X when this makefile was created
+MP_JAVA_PATH="/opt/microchip/mplabx/v3.05/sys/java/jre1.7.0_67/bin/"
+OS_CURRENT="$(shell uname -s)"
+MP_CC="/opt/microchip/xc32/v1.40/bin/xc32-gcc"
+MP_CPPC="/opt/microchip/xc32/v1.40/bin/xc32-g++"
+# MP_BC is not defined
+MP_AS="/opt/microchip/xc32/v1.40/bin/xc32-as"
+MP_LD="/opt/microchip/xc32/v1.40/bin/xc32-ld"
+MP_AR="/opt/microchip/xc32/v1.40/bin/xc32-ar"
+DEP_GEN=${MP_JAVA_PATH}java -jar "/opt/microchip/mplabx/v3.05/mplab_ide/mplab_ide/modules/../../bin/extractobjectdependencies.jar"
+MP_CC_DIR="/opt/microchip/xc32/v1.40/bin"
+MP_CPPC_DIR="/opt/microchip/xc32/v1.40/bin"
+# MP_BC_DIR is not defined
+MP_AS_DIR="/opt/microchip/xc32/v1.40/bin"
+MP_LD_DIR="/opt/microchip/xc32/v1.40/bin"
+MP_AR_DIR="/opt/microchip/xc32/v1.40/bin"
+# MP_BC_DIR is not defined
diff --git a/firmware/CText.X/nbproject/Makefile-variables.mk b/firmware/CText.X/nbproject/Makefile-variables.mk
new file mode 100644
index 0000000..755b435
--- /dev/null
+++ b/firmware/CText.X/nbproject/Makefile-variables.mk
@@ -0,0 +1,13 @@
+#
+# Generated - do not edit!
+#
+# NOCDDL
+#
+CND_BASEDIR=`pwd`
+# default configuration
+CND_ARTIFACT_DIR_default=dist/default/production
+CND_ARTIFACT_NAME_default=CText.X.production.hex
+CND_ARTIFACT_PATH_default=dist/default/production/CText.X.production.hex
+CND_PACKAGE_DIR_default=${CND_DISTDIR}/default/package
+CND_PACKAGE_NAME_default=ctext.x.tar
+CND_PACKAGE_PATH_default=${CND_DISTDIR}/default/package/ctext.x.tar
diff --git a/firmware/CText.X/nbproject/Package-default.bash b/firmware/CText.X/nbproject/Package-default.bash
new file mode 100644
index 0000000..4fafef2
--- /dev/null
+++ b/firmware/CText.X/nbproject/Package-default.bash
@@ -0,0 +1,73 @@
+#!/bin/bash -x
+
+#
+# Generated - do not edit!
+#
+
+# Macros
+TOP=`pwd`
+CND_CONF=default
+CND_DISTDIR=dist
+TMPDIR=build/${CND_CONF}/${IMAGE_TYPE}/tmp-packaging
+TMPDIRNAME=tmp-packaging
+OUTPUT_PATH=dist/${CND_CONF}/${IMAGE_TYPE}/CText.X.${IMAGE_TYPE}.${OUTPUT_SUFFIX}
+OUTPUT_BASENAME=CText.X.${IMAGE_TYPE}.${OUTPUT_SUFFIX}
+PACKAGE_TOP_DIR=ctext.x/
+
+# Functions
+function checkReturnCode
+{
+ rc=$?
+ if [ $rc != 0 ]
+ then
+ exit $rc
+ fi
+}
+function makeDirectory
+# $1 directory path
+# $2 permission (optional)
+{
+ mkdir -p "$1"
+ checkReturnCode
+ if [ "$2" != "" ]
+ then
+ chmod $2 "$1"
+ checkReturnCode
+ fi
+}
+function copyFileToTmpDir
+# $1 from-file path
+# $2 to-file path
+# $3 permission
+{
+ cp "$1" "$2"
+ checkReturnCode
+ if [ "$3" != "" ]
+ then
+ chmod $3 "$2"
+ checkReturnCode
+ fi
+}
+
+# Setup
+cd "${TOP}"
+mkdir -p ${CND_DISTDIR}/${CND_CONF}/package
+rm -rf ${TMPDIR}
+mkdir -p ${TMPDIR}
+
+# Copy files and create directories and links
+cd "${TOP}"
+makeDirectory ${TMPDIR}/ctext.x/bin
+copyFileToTmpDir "${OUTPUT_PATH}" "${TMPDIR}/${PACKAGE_TOP_DIR}bin/${OUTPUT_BASENAME}" 0755
+
+
+# Generate tar file
+cd "${TOP}"
+rm -f ${CND_DISTDIR}/${CND_CONF}/package/ctext.x.tar
+cd ${TMPDIR}
+tar -vcf ../../../../${CND_DISTDIR}/${CND_CONF}/package/ctext.x.tar *
+checkReturnCode
+
+# Cleanup
+cd "${TOP}"
+rm -rf ${TMPDIR}
diff --git a/firmware/CText.X/nbproject/configurations.xml b/firmware/CText.X/nbproject/configurations.xml
new file mode 100644
index 0000000..8c576b6
--- /dev/null
+++ b/firmware/CText.X/nbproject/configurations.xml
@@ -0,0 +1,416 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<configurationDescriptor version="62">
+ <logicalFolder name="root" displayName="root" projectFiles="true">
+ <logicalFolder name="HeaderFiles"
+ displayName="Header Files"
+ projectFiles="true">
+ <logicalFolder name="f2" displayName="app" projectFiles="true">
+ <logicalFolder name="f1" displayName="system_config" projectFiles="true">
+ <logicalFolder name="f1" displayName="default" projectFiles="true">
+ <logicalFolder name="f1" displayName="framework" projectFiles="true">
+ <logicalFolder name="f1" displayName="system" projectFiles="true">
+ <logicalFolder name="f1" displayName="clk" projectFiles="true">
+ <itemPath>../src/system_config/default/framework/system/clk/sys_clk_static.h</itemPath>
+ </logicalFolder>
+ </logicalFolder>
+ </logicalFolder>
+ <itemPath>../src/system_config/default/system_config.h</itemPath>
+ <itemPath>../src/system_config/default/system_definitions.h</itemPath>
+ </logicalFolder>
+ </logicalFolder>
+ <itemPath>../src/app.h</itemPath>
+ <itemPath>../src/editor.h</itemPath>
+ <itemPath>../src/screen.h</itemPath>
+ <itemPath>../src/t6963c_specific.h</itemPath>
+ </logicalFolder>
+ <logicalFolder name="f1" displayName="framework" projectFiles="true">
+ <logicalFolder name="f1" displayName="system" projectFiles="true">
+ <logicalFolder name="f1" displayName="common" projectFiles="true">
+ <itemPath>../../../../../../opt/microchip/harmony/v1_06/framework/system/common/sys_common.h</itemPath>
+ <itemPath>../../../../../../opt/microchip/harmony/v1_06/framework/system/common/sys_module.h</itemPath>
+ </logicalFolder>
+ <logicalFolder name="f2" displayName="devcon" projectFiles="true">
+ <itemPath>../../../../../../opt/microchip/harmony/v1_06/framework/system/devcon/sys_devcon.h</itemPath>
+ <itemPath>../../../../../../opt/microchip/harmony/v1_06/framework/system/devcon/src/sys_devcon_cache.h</itemPath>
+ </logicalFolder>
+ <logicalFolder name="f3" displayName="ports" projectFiles="true">
+ <itemPath>../../../../../../opt/microchip/harmony/v1_06/framework/system/ports/sys_ports.h</itemPath>
+ </logicalFolder>
+ <itemPath>../../../../../../opt/microchip/harmony/v1_06/framework/system/system.h</itemPath>
+ </logicalFolder>
+ </logicalFolder>
+ <logicalFolder name="T6963C_PIC" displayName="T6963C_PIC" projectFiles="true">
+ <itemPath>../src/T6963C_PIC/terminal.h</itemPath>
+ <itemPath>../src/T6963C_PIC/t6963c.h</itemPath>
+ </logicalFolder>
+ </logicalFolder>
+ <logicalFolder name="LinkerScript"
+ displayName="Linker Files"
+ projectFiles="true">
+ </logicalFolder>
+ <logicalFolder name="SourceFiles"
+ displayName="Source Files"
+ projectFiles="true">
+ <logicalFolder name="f2" displayName="app" projectFiles="true">
+ <logicalFolder name="f1" displayName="system_config" projectFiles="true">
+ <logicalFolder name="f1" displayName="default" projectFiles="true">
+ <logicalFolder name="f1" displayName="framework" projectFiles="true">
+ <logicalFolder name="f1" displayName="system" projectFiles="true">
+ <logicalFolder name="f1" displayName="clk" projectFiles="true">
+ <logicalFolder name="f1" displayName="src" projectFiles="true">
+ <itemPath>../src/system_config/default/framework/system/clk/src/sys_clk_static.c</itemPath>
+ </logicalFolder>
+ </logicalFolder>
+ <logicalFolder name="f2" displayName="ports" projectFiles="true">
+ <logicalFolder name="f1" displayName="src" projectFiles="true">
+ <itemPath>../src/system_config/default/framework/system/ports/src/sys_ports_static.c</itemPath>
+ </logicalFolder>
+ </logicalFolder>
+ </logicalFolder>
+ </logicalFolder>
+ <itemPath>../src/system_config/default/system_init.c</itemPath>
+ <itemPath>../src/system_config/default/system_interrupt.c</itemPath>
+ <itemPath>../src/system_config/default/system_exceptions.c</itemPath>
+ <itemPath>../src/system_config/default/system_tasks.c</itemPath>
+ </logicalFolder>
+ </logicalFolder>
+ <itemPath>../src/app.c</itemPath>
+ <itemPath>../src/main.c</itemPath>
+ <itemPath>../src/screen.c</itemPath>
+ </logicalFolder>
+ <logicalFolder name="f1" displayName="framework" projectFiles="true">
+ <logicalFolder name="f1" displayName="system" projectFiles="true">
+ <logicalFolder name="f1" displayName="devcon" projectFiles="true">
+ <logicalFolder name="f1" displayName="src" projectFiles="true">
+ <itemPath>../../../../../../opt/microchip/harmony/v1_06/framework/system/devcon/src/sys_devcon.c</itemPath>
+ <itemPath>../../../../../../opt/microchip/harmony/v1_06/framework/system/devcon/src/sys_devcon_pic32mz.c</itemPath>
+ <itemPath>../../../../../../opt/microchip/harmony/v1_06/framework/system/devcon/src/sys_devcon_cache_pic32mz.S</itemPath>
+ </logicalFolder>
+ </logicalFolder>
+ <logicalFolder name="f2" displayName="ports" projectFiles="true">
+ <logicalFolder name="f1" displayName="src" projectFiles="true">
+ <itemPath>../../../../../../opt/microchip/harmony/v1_06/framework/system/ports/src/sys_ports.c</itemPath>
+ </logicalFolder>
+ </logicalFolder>
+ </logicalFolder>
+ </logicalFolder>
+ <logicalFolder name="T6963C_PIC" displayName="T6963C_PIC" projectFiles="true">
+ <itemPath>../src/T6963C_PIC/t6963c.c</itemPath>
+ <itemPath>../src/T6963C_PIC/terminal.c</itemPath>
+ </logicalFolder>
+ </logicalFolder>
+ <logicalFolder name="ExternalFiles"
+ displayName="Important Files"
+ projectFiles="false">
+ <itemPath>Makefile</itemPath>
+ </logicalFolder>
+ </logicalFolder>
+ <sourceRootList>
+ <Elem>../src</Elem>
+ <Elem>../../../../opt/microchip/harmony/v1_06</Elem>
+ <Elem>../src/system_config/default</Elem>
+ </sourceRootList>
+ <projectmakefile>Makefile</projectmakefile>
+ <confs>
+ <conf name="default" type="2">
+ <toolsSet>
+ <developmentServer>localhost</developmentServer>
+ <targetDevice>PIC32MZ2048ECG064</targetDevice>
+ <targetHeader></targetHeader>
+ <targetPluginBoard></targetPluginBoard>
+ <platformTool>ICD3PlatformTool</platformTool>
+ <languageToolchain>XC32</languageToolchain>
+ <languageToolchainVersion>1.40</languageToolchainVersion>
+ <platform>2</platform>
+ </toolsSet>
+ <compileType>
+ <linkerTool>
+ <linkerLibItems>
+ <linkerLibFileItem>../../../../../../opt/microchip/harmony/v1_06/bin/framework/peripheral/PIC32MZ2048ECG064_peripherals.a</linkerLibFileItem>
+ </linkerLibItems>
+ </linkerTool>
+ <archiverTool>
+ </archiverTool>
+ <loading>
+ <useAlternateLoadableFile>false</useAlternateLoadableFile>
+ <parseOnProdLoad>true</parseOnProdLoad>
+ <alternateLoadableFile></alternateLoadableFile>
+ </loading>
+ </compileType>
+ <makeCustomizationType>
+ <makeCustomizationPreStepEnabled>false</makeCustomizationPreStepEnabled>
+ <makeCustomizationPreStep></makeCustomizationPreStep>
+ <makeCustomizationPostStepEnabled>false</makeCustomizationPostStepEnabled>
+ <makeCustomizationPostStep></makeCustomizationPostStep>
+ <makeCustomizationPutChecksumInUserID>false</makeCustomizationPutChecksumInUserID>
+ <makeCustomizationEnableLongLines>false</makeCustomizationEnableLongLines>
+ <makeCustomizationNormalizeHexFile>false</makeCustomizationNormalizeHexFile>
+ </makeCustomizationType>
+ <C32>
+ <property key="additional-warnings" value="false"/>
+ <property key="enable-app-io" value="false"/>
+ <property key="enable-omit-frame-pointer" value="false"/>
+ <property key="enable-symbols" value="true"/>
+ <property key="enable-unroll-loops" value="false"/>
+ <property key="exclude-floating-point" value="false"/>
+ <property key="extra-include-directories"
+ value="../src;../src/system_config/default;../../../../../../opt/microchip/harmony/v1_06/framework;../src/system_config/default/framework"/>
+ <property key="generate-16-bit-code" value="false"/>
+ <property key="generate-micro-compressed-code" value="false"/>
+ <property key="isolate-each-function" value="true"/>
+ <property key="make-warnings-into-errors" value="false"/>
+ <property key="optimization-level" value="-O1"/>
+ <property key="place-data-into-section" value="false"/>
+ <property key="post-instruction-scheduling" value="default"/>
+ <property key="pre-instruction-scheduling" value="default"/>
+ <property key="preprocessor-macros" value=""/>
+ <property key="strict-ansi" value="false"/>
+ <property key="support-ansi" value="false"/>
+ <property key="use-cci" value="false"/>
+ <property key="use-iar" value="false"/>
+ <property key="use-indirect-calls" value="false"/>
+ </C32>
+ <C32-AR>
+ <property key="additional-options-chop-files" value="false"/>
+ </C32-AR>
+ <C32-AS>
+ <property key="assembler-symbols" value=""/>
+ <property key="enable-symbols" value="true"/>
+ <property key="exclude-floating-point-library" value="false"/>
+ <property key="expand-macros" value="false"/>
+ <property key="extra-include-directories-for-assembler" value=""/>
+ <property key="extra-include-directories-for-preprocessor" value=""/>
+ <property key="false-conditionals" value="false"/>
+ <property key="keep-locals" value="false"/>
+ <property key="list-assembly" value="false"/>
+ <property key="list-source" value="false"/>
+ <property key="list-symbols" value="false"/>
+ <property key="oXC32asm-list-to-file" value="false"/>
+ <property key="omit-debug-dirs" value="false"/>
+ <property key="omit-forms" value="false"/>
+ <property key="preprocessor-macros" value=""/>
+ <property key="warning-level" value=""/>
+ </C32-AS>
+ <C32-LD>
+ <property key="additional-options-use-response-files" value="false"/>
+ <property key="enable-check-sections" value="false"/>
+ <property key="exclude-floating-point-library" value="false"/>
+ <property key="exclude-standard-libraries" value="false"/>
+ <property key="extra-lib-directories" value=""/>
+ <property key="fill-flash-options-addr" value=""/>
+ <property key="fill-flash-options-const" value=""/>
+ <property key="fill-flash-options-how" value="0"/>
+ <property key="fill-flash-options-inc-const" value="1"/>
+ <property key="fill-flash-options-increment" value=""/>
+ <property key="fill-flash-options-seq" value=""/>
+ <property key="fill-flash-options-what" value="0"/>
+ <property key="generate-16-bit-code" value="false"/>
+ <property key="generate-cross-reference-file" value="false"/>
+ <property key="generate-micro-compressed-code" value="false"/>
+ <property key="heap-size" value="4096"/>
+ <property key="input-libraries" value=""/>
+ <property key="linker-symbols" value=""/>
+ <property key="map-file" value="${DISTDIR}/${PROJECTNAME}.${IMAGE_TYPE}.map"/>
+ <property key="no-startup-files" value="false"/>
+ <property key="oXC32ld-extra-opts" value=""/>
+ <property key="optimization-level" value=""/>
+ <property key="preprocessor-macros" value=""/>
+ <property key="remove-unused-sections" value="true"/>
+ <property key="report-memory-usage" value="false"/>
+ <property key="stack-size" value=""/>
+ <property key="symbol-stripping" value=""/>
+ <property key="trace-symbols" value=""/>
+ <property key="warn-section-align" value="false"/>
+ </C32-LD>
+ <C32CPP>
+ <property key="additional-warnings" value="false"/>
+ <property key="check-new" value="false"/>
+ <property key="eh-specs" value="true"/>
+ <property key="enable-app-io" value="false"/>
+ <property key="enable-omit-frame-pointer" value="false"/>
+ <property key="enable-symbols" value="true"/>
+ <property key="enable-unroll-loops" value="false"/>
+ <property key="exceptions" value="true"/>
+ <property key="exclude-floating-point" value="false"/>
+ <property key="extra-include-directories" value=""/>
+ <property key="generate-16-bit-code" value="false"/>
+ <property key="generate-micro-compressed-code" value="false"/>
+ <property key="isolate-each-function" value="true"/>
+ <property key="make-warnings-into-errors" value="false"/>
+ <property key="optimization-level" value="-O1"/>
+ <property key="place-data-into-section" value="false"/>
+ <property key="post-instruction-scheduling" value="default"/>
+ <property key="pre-instruction-scheduling" value="default"/>
+ <property key="preprocessor-macros" value=""/>
+ <property key="rtti" value="true"/>
+ <property key="strict-ansi" value="false"/>
+ <property key="use-cci" value="false"/>
+ <property key="use-iar" value="false"/>
+ <property key="use-indirect-calls" value="false"/>
+ </C32CPP>
+ <C32Global>
+ <property key="common-include-directories" value=""/>
+ <property key="gp-relative-option" value=""/>
+ <property key="legacy-libc" value="false"/>
+ <property key="relaxed-math" value="false"/>
+ <property key="save-temps" value="true"/>
+ <property key="wpo-lto" value="false"/>
+ </C32Global>
+ <ICD3PlatformTool>
+ <property key="AutoSelectMemRanges" value="auto"/>
+ <property key="CHANGE NOTICE B" value="true"/>
+ <property key="CHANGE NOTICE C" value="true"/>
+ <property key="CHANGE NOTICE D" value="true"/>
+ <property key="CHANGE NOTICE E" value="true"/>
+ <property key="CHANGE NOTICE F" value="true"/>
+ <property key="CHANGE NOTICE G" value="true"/>
+ <property key="COMPARATOR" value="true"/>
+ <property key="DMA" value="true"/>
+ <property key="ETHERNET CONTROLLER" value="true"/>
+ <property key="INPUT CAPTURE 1" value="true"/>
+ <property key="INPUT CAPTURE 2" value="true"/>
+ <property key="INPUT CAPTURE 3" value="true"/>
+ <property key="INPUT CAPTURE 4" value="true"/>
+ <property key="INPUT CAPTURE 5" value="true"/>
+ <property key="INPUT CAPTURE 6" value="true"/>
+ <property key="INPUT CAPTURE 7" value="true"/>
+ <property key="INPUT CAPTURE 8" value="true"/>
+ <property key="INPUT CAPTURE 9" value="true"/>
+ <property key="INTERRUPT CONTROL" value="true"/>
+ <property key="OUTPUT COMPARE 1" value="true"/>
+ <property key="OUTPUT COMPARE 2" value="true"/>
+ <property key="OUTPUT COMPARE 3" value="true"/>
+ <property key="OUTPUT COMPARE 4" value="true"/>
+ <property key="OUTPUT COMPARE 5" value="true"/>
+ <property key="OUTPUT COMPARE 6" value="true"/>
+ <property key="OUTPUT COMPARE 7" value="true"/>
+ <property key="OUTPUT COMPARE 8" value="true"/>
+ <property key="OUTPUT COMPARE 9" value="true"/>
+ <property key="PARALLEL MASTER/SLAVE PORT" value="true"/>
+ <property key="REAL TIME CLOCK" value="true"/>
+ <property key="REFERENCE CLOCK1" value="true"/>
+ <property key="REFERENCE CLOCK2" value="true"/>
+ <property key="REFERENCE CLOCK3" value="true"/>
+ <property key="REFERENCE CLOCK4" value="true"/>
+ <property key="SPI/I2S 1" value="true"/>
+ <property key="SPI/I2S 2" value="true"/>
+ <property key="SPI/I2S 3" value="true"/>
+ <property key="SPI/I2S 4" value="true"/>
+ <property key="SecureSegment.SegmentProgramming" value="FullChipProgramming"/>
+ <property key="TIMER1" value="true"/>
+ <property key="TIMER2" value="true"/>
+ <property key="TIMER3" value="true"/>
+ <property key="TIMER4" value="true"/>
+ <property key="TIMER5" value="true"/>
+ <property key="TIMER6" value="true"/>
+ <property key="TIMER7" value="true"/>
+ <property key="TIMER8" value="true"/>
+ <property key="TIMER9" value="true"/>
+ <property key="ToolFirmwareFilePath"
+ value="Press to browse for a specific firmware version"/>
+ <property key="ToolFirmwareOption.UseLatestFirmware" value="true"/>
+ <property key="UART1" value="true"/>
+ <property key="UART2" value="true"/>
+ <property key="UART3" value="true"/>
+ <property key="UART4" value="true"/>
+ <property key="UART5" value="true"/>
+ <property key="UART6" value="true"/>
+ <property key="debugoptions.useswbreakpoints" value="false"/>
+ <property key="firmware.download.all" value="false"/>
+ <property key="hwtoolclock.frcindebug" value="false"/>
+ <property key="memories.aux" value="false"/>
+ <property key="memories.bootflash" value="false"/>
+ <property key="memories.configurationmemory" value="true"/>
+ <property key="memories.configurationmemory2" value="true"/>
+ <property key="memories.dataflash" value="true"/>
+ <property key="memories.eeprom" value="true"/>
+ <property key="memories.flashdata" value="true"/>
+ <property key="memories.id" value="true"/>
+ <property key="memories.programmemory" value="true"/>
+ <property key="memories.programmemory.end" value="0x1d1fffff"/>
+ <property key="memories.programmemory.partition2" value="true"/>
+ <property key="memories.programmemory.partition2.end"
+ value="${memories.programmemory.partition2.end.value}"/>
+ <property key="memories.programmemory.partition2.start"
+ value="${memories.programmemory.partition2.start.value}"/>
+ <property key="memories.programmemory.start" value="0x1d000000"/>
+ <property key="poweroptions.powerenable" value="false"/>
+ <property key="programoptions.donoteraseauxmem" value="false"/>
+ <property key="programoptions.eraseb4program" value="true"/>
+ <property key="programoptions.preservedataflash" value="false"/>
+ <property key="programoptions.preserveeeprom" value="false"/>
+ <property key="programoptions.preserveprogramrange" value="false"/>
+ <property key="programoptions.preserveprogramrange.end" value="0x1d1fffff"/>
+ <property key="programoptions.preserveprogramrange.start" value="0x1d000000"/>
+ <property key="programoptions.preserveuserid" value="false"/>
+ <property key="programoptions.programcalmem" value="false"/>
+ <property key="programoptions.programuserotp" value="false"/>
+ <property key="programoptions.testmodeentrymethod" value="VDDFirst"/>
+ <property key="programoptions.usehighvoltageonmclr" value="false"/>
+ <property key="programoptions.uselvpprogramming" value="false"/>
+ <property key="voltagevalue" value="3.25"/>
+ </ICD3PlatformTool>
+ <PICkit3PlatformTool>
+ <property key="ADC 1" value="true"/>
+ <property key="AutoSelectMemRanges" value="auto"/>
+ <property key="CHANGE NOTICE" value="true"/>
+ <property key="COMPARATOR" value="true"/>
+ <property key="CTMU" value="true"/>
+ <property key="DMA" value="true"/>
+ <property key="Freeze All Other Peripherals" value="true"/>
+ <property key="I2C1" value="true"/>
+ <property key="I2C2" value="true"/>
+ <property key="INPUT CAPTURE 1" value="true"/>
+ <property key="INPUT CAPTURE 2" value="true"/>
+ <property key="INPUT CAPTURE 3" value="true"/>
+ <property key="INPUT CAPTURE 4" value="true"/>
+ <property key="INPUT CAPTURE 5" value="true"/>
+ <property key="INTERRUPT CONTROL" value="true"/>
+ <property key="OUTPUT COMPARE 1" value="true"/>
+ <property key="OUTPUT COMPARE 2" value="true"/>
+ <property key="OUTPUT COMPARE 3" value="true"/>
+ <property key="OUTPUT COMPARE 4" value="true"/>
+ <property key="OUTPUT COMPARE 5" value="true"/>
+ <property key="PARALLEL MASTER/SLAVE PORT" value="true"/>
+ <property key="REAL TIME CLOCK" value="true"/>
+ <property key="SPI/I2S 1" value="true"/>
+ <property key="SPI/I2S 2" value="true"/>
+ <property key="SecureSegment.SegmentProgramming" value="FullChipProgramming"/>
+ <property key="TIMER1" value="true"/>
+ <property key="TIMER2" value="true"/>
+ <property key="TIMER3" value="true"/>
+ <property key="TIMER4" value="true"/>
+ <property key="TIMER5" value="true"/>
+ <property key="ToolFirmwareFilePath"
+ value="Press to browse for a specific firmware version"/>
+ <property key="ToolFirmwareOption.UseLatestFirmware" value="true"/>
+ <property key="UART1" value="true"/>
+ <property key="UART2" value="true"/>
+ <property key="hwtoolclock.frcindebug" value="false"/>
+ <property key="memories.aux" value="false"/>
+ <property key="memories.bootflash" value="true"/>
+ <property key="memories.configurationmemory" value="true"/>
+ <property key="memories.eeprom" value="true"/>
+ <property key="memories.flashdata" value="true"/>
+ <property key="memories.id" value="true"/>
+ <property key="memories.programmemory" value="true"/>
+ <property key="memories.programmemory.end" value="0x1d003fff"/>
+ <property key="memories.programmemory.start" value="0x1d000000"/>
+ <property key="poweroptions.powerenable" value="false"/>
+ <property key="programmertogo.imagename" value=""/>
+ <property key="programoptions.donoteraseauxmem" value="false"/>
+ <property key="programoptions.eraseb4program" value="true"/>
+ <property key="programoptions.pgmspeed" value="2"/>
+ <property key="programoptions.preserveeeprom" value="false"/>
+ <property key="programoptions.preserveprogramrange" value="false"/>
+ <property key="programoptions.preserveprogramrange.end" value="0x1d003fff"/>
+ <property key="programoptions.preserveprogramrange.start" value="0x1d000000"/>
+ <property key="programoptions.preserveuserid" value="false"/>
+ <property key="programoptions.testmodeentrymethod" value="VPPFirst"/>
+ <property key="programoptions.usehighvoltageonmclr" value="false"/>
+ <property key="programoptions.uselvpprogramming" value="false"/>
+ <property key="voltagevalue" value="3.25"/>
+ </PICkit3PlatformTool>
+ </conf>
+ </confs>
+</configurationDescriptor>
diff --git a/firmware/CText.X/nbproject/project.properties b/firmware/CText.X/nbproject/project.properties
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/firmware/CText.X/nbproject/project.properties
diff --git a/firmware/CText.X/nbproject/project.xml b/firmware/CText.X/nbproject/project.xml
new file mode 100644
index 0000000..a9bc737
--- /dev/null
+++ b/firmware/CText.X/nbproject/project.xml
@@ -0,0 +1,18 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project xmlns="http://www.netbeans.org/ns/project/1">
+ <type>com.microchip.mplab.nbide.embedded.makeproject</type>
+ <configuration>
+ <Harmony xmlns="Harmony" MHC="true"/>
+ <data xmlns="http://www.netbeans.org/ns/make-project/1">
+ <name>CText</name>
+ <creation-uuid>e54023e9-3948-44ef-bf6f-29d8b223e555</creation-uuid>
+ <make-project-type>0</make-project-type>
+ <c-extensions>c</c-extensions>
+ <cpp-extensions/>
+ <header-extensions>h</header-extensions>
+ <asminc-extensions/>
+ <sourceEncoding>ISO-8859-1</sourceEncoding>
+ <make-dep-projects/>
+ </data>
+ </configuration>
+</project>
diff --git a/firmware/PIC32MZ_harmony_tryout.hconfig b/firmware/PIC32MZ_harmony_tryout.hconfig
new file mode 100644
index 0000000..c6e7da7
--- /dev/null
+++ b/firmware/PIC32MZ_harmony_tryout.hconfig
@@ -0,0 +1,55 @@
+#
+# Application configuration file generated by
+# Microchip Harmony Configurator (MHC) from Harmony version: 1.04
+#
+
+mainmenu "MPLAB Harmony & Application Configuration"
+
+menu "Application Configuration"
+
+config APP_INSTANCES
+ int "Number of Applications"
+ default 1
+ range 1 10 # Must limit to 10 or application templates will need to be updated.
+
+source "$HARMONY_VERSION_PATH/utilities/mhc/config/app_name_idx.ftl" 10 instances
+
+menu "Exception Handling"
+
+config USE_EXCEPTION_HANDLER
+ bool "Use MPLAB Harmony Exception Handler Template?"
+ default y
+ ---help---
+ Enter 'Y' if you want to include an exception handler template
+ (system_exceptions.c) in this system configuration. Enter 'N' if
+ you do not.
+ ---endhelp---
+
+config EXCEPTION_USE_SYS_DEBUG
+ bool "Use debug services in exception handler?"
+ depends on USE_EXCEPTION_HANDLER
+ default y
+ ---help---
+ Enter 'Y' if you want the exception handler to use the SYS_DEBUG service to
+ report exception information. Enter 'N' if you do not.
+ ---endhelp---
+
+config EXCEPTION_BREAKPOINT
+ bool "Hit breakpoint when an exception occurs?"
+ depends on USE_EXCEPTION_HANDLER && EXCEPTION_USE_SYS_DEBUG
+ default y
+ ---help---
+ Enter 'Y' if you want the exception handler to hit a breakpoint when
+ an exception occurs. Enter 'N' if you do not.
+ Note: Only works if debugging is enabled.
+ ---endhelp---
+
+endmenu # Exception Handling
+
+#insert application specific configuration here
+
+endmenu # Application Configuration
+
+source "$HARMONY_VERSION_PATH/config/harmony.hconfig"
+
+
diff --git a/firmware/src/T6963C_PIC b/firmware/src/T6963C_PIC
new file mode 160000
+Subproject d5a6e4bd67cdc8e03025c17590d612178b8f84d
diff --git a/firmware/src/app.c b/firmware/src/app.c
new file mode 100644
index 0000000..635c46f
--- /dev/null
+++ b/firmware/src/app.c
@@ -0,0 +1,78 @@
+/*******************************************************************************
+ MPLAB Harmony Application Source File
+
+ File Name:
+ app.c
+
+ Summary:
+ This file contains the source code for the MPLAB Harmony application.
+
+ Description:
+ This file contains the source code for the MPLAB Harmony application. It
+ implements the logic of the application's state machine and it may call
+ API routines of other MPLAB Harmony modules in the system, such as drivers,
+ system services, and middleware. However, it does not call any of the
+ system interfaces (such as the "Initialize" and "Tasks" functions) of any of
+ the modules in the system or make any assumptions about when those functions
+ are called. That is the responsibility of the configuration-specific system
+ files.
+ *******************************************************************************/
+
+#include "app.h"
+#include "T6963C_PIC/t6963c.h"
+#include "t6963c_specific.h"
+#include "T6963C_PIC/terminal.h"
+
+APP_DATA appData;
+static Terminal* term;
+
+void APP_Initialize (void) {
+ t6963c_init();
+ t6963c_clear();
+
+ term = terminal.construct(t6963c_rows * t6963c_columns);
+ term->update = t6963c_update_terminal;
+
+ appData.state = APP_STATE_MAIN;
+}
+
+void APP_Tasks (void) {
+ /* Check the application's current state. */
+ switch (appData.state) {
+ /* Application's main state. */
+ case APP_STATE_MAIN: {
+ if (term != NULL) {
+ unsigned char* string = "me@pic:~$ ls\nme@pic:~$ mkdir docs\nme@pic:~$ cd docs/\nme@pic:~/docs$ ls\nme@pic:~/docs$ touch doc.txt\nme@pic:~/docs$ ls\ndoc.txt\nme@pic:~/docs$ cat doc.txt\nme@pic:~/docs$ echo hello > doc.txt\nme@pic:~/docs$ cat doc.txt\nhello\nme@pic:~/docs$ cd ..\nme@pic:~$ tree -fFi\n.\n./docs/\n./docs/doc.txt\n\n1 directory, 1 file\nme@pic:~$ rm -r docs/\n";
+ unsigned short i, j;
+ unsigned char state = 0; // 0 = quick, 1 = slow
+ for (i = 0; string[i]; i++) {
+ if (!terminal.appendChar(term, string[i])) {
+ terminal.free(term);
+ t6963c_clear();
+ t6963c_set_address(5,5);
+ t6963c_writeString("ERROR");
+ while (1);
+ }
+ if (string[i] == '$') {
+ state = 1;
+ terminal.appendChar(term, string[++i]);
+ for (j = 0; j < 10000; j++)
+ delay_ns(60000);
+ } else if (string[i] == '\n') {
+ state = 0;
+ }
+ if (state)
+ for (j = 0; j < 800; j++)
+ delay_ns(60000);
+ }
+ }
+
+ break;
+ }
+
+ default: {
+ /* TODO: Handle error in application's state machine. */
+ break;
+ }
+ }
+}
diff --git a/firmware/src/app.h b/firmware/src/app.h
new file mode 100644
index 0000000..50db318
--- /dev/null
+++ b/firmware/src/app.h
@@ -0,0 +1,115 @@
+/*******************************************************************************
+ MPLAB Harmony Application Header File
+
+ File Name:
+ app.h
+
+ Summary:
+ This header file provides prototypes and definitions for the application.
+
+ Description:
+ This header file provides function prototypes and data type definitions for
+ the application. Some of these are required by the system (such as the
+ "APP_Initialize" and "APP_Tasks" prototypes) and some of them are only used
+ internally by the application (such as the "APP_STATES" definition). Both
+ are defined here for convenience.
+*******************************************************************************/
+
+#ifndef _APP_H
+#define _APP_H
+
+#include <stdint.h>
+#include <stdbool.h>
+#include <stddef.h>
+#include <stdlib.h>
+#include "system_config.h"
+#include "system_definitions.h"
+
+#ifdef __cplusplus // Provide C++ Compatibility
+
+extern "C" {
+
+#endif
+
+typedef enum
+{
+ APP_STATE_MAIN=0,
+
+} APP_STATES;
+
+
+typedef struct
+{
+ APP_STATES state;
+} APP_DATA;
+
+/*******************************************************************************
+ Function:
+ void APP_Initialize ( void )
+
+ Summary:
+ MPLAB Harmony application initialization routine.
+
+ Description:
+ This function initializes the Harmony application. It places the
+ application in its initial state and prepares it to run so that its
+ APP_Tasks function can be called.
+
+ Precondition:
+ All other system initialization routines should be called before calling
+ this routine (in "SYS_Initialize").
+
+ Parameters:
+ None.
+
+ Returns:
+ None.
+
+ Example:
+ <code>
+ APP_Initialize();
+ </code>
+
+ Remarks:
+ This routine must be called from the SYS_Initialize function.
+*/
+
+void APP_Initialize ( void );
+
+/*******************************************************************************
+ Function:
+ void APP_Tasks ( void )
+
+ Summary:
+ MPLAB Harmony Demo application tasks function
+
+ Description:
+ This routine is the Harmony Demo application's tasks function. It
+ defines the application's state machine and core logic.
+
+ Precondition:
+ The system and application initialization ("SYS_Initialize") should be
+ called before calling this.
+
+ Parameters:
+ None.
+
+ Returns:
+ None.
+
+ Example:
+ <code>
+ APP_Tasks();
+ </code>
+
+ Remarks:
+ This routine must be called from SYS_Tasks() routine.
+ */
+
+void APP_Tasks( void );
+
+#endif /* _APP_H */
+
+#ifdef __cplusplus
+}
+#endif
diff --git a/firmware/src/editor.c b/firmware/src/editor.c
new file mode 100644
index 0000000..7b5eeb1
--- /dev/null
+++ b/firmware/src/editor.c
@@ -0,0 +1,87 @@
+#include "editor.h"
+#include <string.h>
+
+Editor newEditor(unsigned int size) {
+ unsigned char* block = calloc(1, size + 1);
+ if (block == NULL)
+ return NULL;
+
+ Editor editor;
+ editor.front.start = editor.front.end = block;
+ editor.back.start = editor.back.end = block + size;
+
+ return editor;
+}
+
+inline void freeEditor(Editor editor) {
+ free(editor.front.start);
+}
+
+inline unsigned int getFreeSpace(Editor editor) {
+ return editor.back.start - editor.front.end;
+}
+
+inline unsigned isFull(Editor editor) {
+ return getFreeSpace(editor) == NULL;
+}
+
+unsigned char* getNearCursor(Editor editor, signed int start, signed int end) {
+ unsigned char* block = (unsigned char*) calloc(1, end - start + 1);
+ if (block == NULL)
+ return NULL;
+
+ memcpy(block, editor.front.end + start, min(end - start, max(0, 0 - start)));
+ memcpy(block + max(0, 0 - start), editor.back.start + max(0, start), end - max(0, start));
+ return block;
+}
+
+void moveCursor(Editor editor, signed int change) {
+ if (change > 0) {
+ change = max(editor.back.end - editor.back.start, change);
+ memcpy(editor.front.end, editor.back.start, change);
+ editor.front.end += change;
+ editor.back.start += change;
+ } else if (change < 0) {
+ change = max(editor.front.end - editor.front.start, 0 - change);
+ memcpy(editor.back.start - change, editor.front.end - change, change);
+ editor.front.end -= change;
+ editor.back.start -= change;
+ }
+}
+
+inline void writeAtCursor(Editor editor, unsigned char character) {
+ editor.front.end++;
+ *editor.front.end = character;
+}
+
+void writeStringAtCursor(Editor editor, unsigned char* string) {
+ editor.front.end++;
+ memcpy(editor.front.end, string, strlen(string));
+ editor.front.end += strlen(string) - 1;
+}
+
+inline void writeAfterCursor(Editor editor, unsigned char character) {
+ editor.back.start--;
+ *editor.back.start = character;
+}
+
+void writeStringAfterCursor(Editor editor, unsigned char* string) {
+ editor.back.start -= strlen(string);
+ memcpy(editor.back.start, string, strlen(string));
+}
+
+inline void deleteAtCursor(Editor editor) {
+ editor.front.end--;
+}
+
+inline void deleteNAtCursor(Editor editor, unsigned int length) {
+ editor.front.end -= length;
+}
+
+inline void deleteAfterCursor(Editor editor) {
+ editor.back.start++;
+}
+
+inline void deleteNAfterCursor(Editor editor, unsigned int length) {
+ editor.back.start += length;
+}
diff --git a/firmware/src/editor.h b/firmware/src/editor.h
new file mode 100644
index 0000000..4d5cac2
--- /dev/null
+++ b/firmware/src/editor.h
@@ -0,0 +1,50 @@
+/*
+ * File: editor.h
+ * Author: camilstaps
+ *
+ * Created on August 18, 2015, 11:25 PM
+ */
+
+#ifndef EDITOR_H
+#define EDITOR_H
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+
+typedef struct {
+ unsigned char* start;
+ unsigned char* end;
+} EditorArea;
+
+typedef struct {
+ EditorArea front;
+ EditorArea back;
+} Editor;
+
+Editor newEditor(unsigned int size);
+inline void freeEditor(Editor editor);
+
+inline unsigned int getFreeSpace(Editor editor);
+inline unsigned isFull(Editor editor);
+
+unsigned char* getNearCursor(Editor editor, signed int start, signed int end);
+void moveCursor(Editor editor, signed int change);
+
+inline void writeAtCursor(Editor editor, unsigned char character);
+void writeStringAtCursor(Editor editor, unsigned char* string);
+inline void writeAfterCursor(Editor editor, unsigned char character);
+void writeStringAfterCursor(Editor editor, unsigned char* string);
+
+inline void deleteAtCursor(Editor editor);
+inline void deleteNAtCursor(Editor editor, unsigned int length);
+inline void deleteAfterCursor(Editor editor);
+inline void deleteNAfterCursor(Editor editor, unsigned int length);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* EDITOR_H */
+
diff --git a/firmware/src/main.c b/firmware/src/main.c
new file mode 100644
index 0000000..50de2fd
--- /dev/null
+++ b/firmware/src/main.c
@@ -0,0 +1,92 @@
+/*******************************************************************************
+ MPLAB Harmony Project Main Source File
+
+ Company:
+ Microchip Technology Inc.
+
+ File Name:
+ main.c
+
+ Summary:
+ This file contains the "main" function for an MPLAB Harmony project.
+
+ Description:
+ This file contains the "main" function for an MPLAB Harmony project. The
+ "main" function calls the "SYS_Initialize" function to initialize the state
+ machines of all MPLAB Harmony modules in the system and it calls the
+ "SYS_Tasks" function from within a system-wide "super" loop to maintain
+ their correct operation. These two functions are implemented in
+ configuration-specific files (usually "system_init.c" and "system_tasks.c")
+ in a configuration-specific folder under the "src/system_config" folder
+ within this project's top-level folder. An MPLAB Harmony project may have
+ more than one configuration, each contained within it's own folder under
+ the "system_config" folder.
+ *******************************************************************************/
+
+// DOM-IGNORE-BEGIN
+/*******************************************************************************
+Copyright (c) 2013-2014 released Microchip Technology Inc. All rights reserved.
+
+//Microchip licenses to you the right to use, modify, copy and distribute
+Software only when embedded on a Microchip microcontroller or digital signal
+controller that is integrated into your product or third party product
+(pursuant to the sublicense terms in the accompanying license agreement).
+
+You should refer to the license agreement accompanying this Software for
+additional information regarding your rights and obligations.
+
+SOFTWARE AND DOCUMENTATION ARE PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND,
+EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION, ANY WARRANTY OF
+MERCHANTABILITY, TITLE, NON-INFRINGEMENT AND FITNESS FOR A PARTICULAR PURPOSE.
+IN NO EVENT SHALL MICROCHIP OR ITS LICENSORS BE LIABLE OR OBLIGATED UNDER
+CONTRACT, NEGLIGENCE, STRICT LIABILITY, CONTRIBUTION, BREACH OF WARRANTY, OR
+OTHER LEGAL EQUITABLE THEORY ANY DIRECT OR INDIRECT DAMAGES OR EXPENSES
+INCLUDING BUT NOT LIMITED TO ANY INCIDENTAL, SPECIAL, INDIRECT, PUNITIVE OR
+CONSEQUENTIAL DAMAGES, LOST PROFITS OR LOST DATA, COST OF PROCUREMENT OF
+SUBSTITUTE GOODS, TECHNOLOGY, SERVICES, OR ANY CLAIMS BY THIRD PARTIES
+(INCLUDING BUT NOT LIMITED TO ANY DEFENSE THEREOF), OR OTHER SIMILAR COSTS.
+ *******************************************************************************/
+// DOM-IGNORE-END
+
+
+// *****************************************************************************
+// *****************************************************************************
+// Section: Included Files
+// *****************************************************************************
+// *****************************************************************************
+
+#include <stddef.h> // Defines NULL
+#include <stdbool.h> // Defines true
+#include <stdlib.h> // Defines EXIT_FAILURE
+#include "system/common/sys_module.h" // SYS function prototypes
+
+
+// *****************************************************************************
+// *****************************************************************************
+// Section: Main Entry Point
+// *****************************************************************************
+// *****************************************************************************
+
+int main ( void )
+{
+ /* Initialize all MPLAB Harmony modules, including application(s). */
+ SYS_Initialize ( NULL );
+
+
+ while ( true )
+ {
+ /* Maintain state machines of all polled MPLAB Harmony modules. */
+ SYS_Tasks ( );
+
+ }
+
+ /* Execution should not come here during normal operation */
+
+ return ( EXIT_FAILURE );
+}
+
+
+/*******************************************************************************
+ End of File
+*/
+
diff --git a/firmware/src/screen.c b/firmware/src/screen.c
new file mode 100644
index 0000000..06f038c
--- /dev/null
+++ b/firmware/src/screen.c
@@ -0,0 +1,38 @@
+#include "screen.h"
+#include <stddef.h>
+#include <stdlib.h>
+
+Screen* newScreen(unsigned short rows, unsigned short columns, void (*update)(Screen)) {
+ unsigned short i;
+
+ Screen* screen = calloc(1, sizeof(Screen));
+ if (screen == NULL)
+ return NULL;
+
+ screen->data = (unsigned char**) calloc(rows, sizeof(unsigned char*));
+ if (screen->data == NULL)
+ return NULL;
+ for (i = 0; i < rows; i++) {
+ screen->data[i] = (unsigned char*) calloc(columns + 1, sizeof(unsigned char));
+ if (screen->data[i] == NULL) {
+ for (; i >= 0; i--)
+ free(screen->data[i]);
+ free(screen->data);
+ return NULL;
+ }
+ }
+
+ screen->rows = rows;
+ screen->columns = columns;
+ screen->first_visible_row = screen->first_visible_column = NULL;
+ screen->cursor_x = screen->cursor_y = NULL;
+ screen->update = update;
+ return screen;
+}
+
+inline void freeScreen(Screen* screen) {
+ unsigned short i;
+ for (i = 0; i < screen->rows; i++)
+ free(screen->data[i]);
+ free(screen->data);
+}
diff --git a/firmware/src/screen.h b/firmware/src/screen.h
new file mode 100644
index 0000000..b210619
--- /dev/null
+++ b/firmware/src/screen.h
@@ -0,0 +1,34 @@
+/*
+ * File: screen.h
+ * Author: camilstaps
+ *
+ * Created on August 19, 2015, 12:01 AM
+ */
+
+#ifndef SCREEN_H
+#define SCREEN_H
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+typedef struct Screen {
+ unsigned short rows, columns,
+ first_visible_row, first_visible_column,
+ cursor_x, cursor_y;
+ unsigned char** data;
+ void (*update)(struct Screen);
+} Screen;
+
+Screen* newScreen(unsigned short rows, unsigned short columns, void (*update)(Screen));
+inline void freeScreen(Screen* screen);
+
+//void writeOnS
+//void appendToScreen
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* SCREEN_H */
+
diff --git a/firmware/src/system_config/default/configuration.xml b/firmware/src/system_config/default/configuration.xml
new file mode 100644
index 0000000..4606dcc
--- /dev/null
+++ b/firmware/src/system_config/default/configuration.xml
@@ -0,0 +1,113 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<configuration version="1.0.6.12">
+ <General>
+ <HarmonyPath path="../../../../opt/microchip/harmony/v1_06"/>
+ <ForceOptimization flag="false"/>
+ </General>
+ <Manifest>
+ <Files>
+ <File>
+ <Name>sys_devcon_cache_pic32mz.S</Name>
+ <Path>Source Files/framework/system/devcon/src</Path>
+ </File>
+ <File>
+ <Name>sys_module.h</Name>
+ <Path>Header Files/framework/system/common</Path>
+ </File>
+ <File>
+ <Name>sys_devcon.c</Name>
+ <Path>Source Files/framework/system/devcon/src</Path>
+ </File>
+ <File>
+ <Name>sys_devcon_cache.h</Name>
+ <Path>Header Files/framework/system/devcon</Path>
+ </File>
+ <File>
+ <Name>sys_common.h</Name>
+ <Path>Header Files/framework/system/common</Path>
+ </File>
+ <File>
+ <Name>sys_ports.h</Name>
+ <Path>Header Files/framework/system/ports</Path>
+ </File>
+ <File>
+ <Name>system.h</Name>
+ <Path>Header Files/framework/system</Path>
+ </File>
+ <File>
+ <Name>sys_ports.c</Name>
+ <Path>Source Files/framework/system/ports/src</Path>
+ </File>
+ <File>
+ <Name>sys_devcon.h</Name>
+ <Path>Header Files/framework/system/devcon</Path>
+ </File>
+ <File>
+ <Name>sys_devcon_pic32mz.c</Name>
+ <Path>Source Files/framework/system/devcon/src</Path>
+ </File>
+ </Files>
+ <Templates>
+ <Template>
+ <Name>main.c</Name>
+ <Path>Source Files/app</Path>
+ </Template>
+ <Template>
+ <Name>system_exceptions.c</Name>
+ <Path>Source Files/app/system_config/default</Path>
+ <Checksum>C111969CA43D6CEA1E9E33A6164E7AE0</Checksum>
+ </Template>
+ <Template>
+ <Name>app.c</Name>
+ <Path>Source Files/app</Path>
+ </Template>
+ <Template>
+ <Name>system_config.h</Name>
+ <Path>Header Files/app/system_config/default</Path>
+ <Checksum>AACDE55E44291B8ECCFF86EB2C6D3F1B</Checksum>
+ </Template>
+ <Template>
+ <Name>system_init.c</Name>
+ <Path>Source Files/app/system_config/default</Path>
+ <Checksum>A20E6051172F14BA64FD464630B2D979</Checksum>
+ </Template>
+ <Template>
+ <Name>system_interrupt.c</Name>
+ <Path>Source Files/app/system_config/default</Path>
+ <Checksum>9AC33B2960C8DF72C5EB0E3662303FF4</Checksum>
+ </Template>
+ <Template>
+ <Name>sys_ports_static.c</Name>
+ <Path>Source Files/app/system_config/default/framework/system/ports/src</Path>
+ <Checksum>5F2394E93856B6D50B7274ADB5A4FF75</Checksum>
+ </Template>
+ <Template>
+ <Name>sys_clk_static.h</Name>
+ <Path>Header Files/app/system_config/default/framework/system/clk</Path>
+ <Checksum>999179DADE9ECD59953526F5E9F83ACC</Checksum>
+ </Template>
+ <Template>
+ <Name>app.h</Name>
+ <Path>Header Files/app</Path>
+ </Template>
+ <Template>
+ <Name>sys_clk_static.c</Name>
+ <Path>Source Files/app/system_config/default/framework/system/clk/src</Path>
+ <Checksum>58CE0B253D4367C188EB62895C501C46</Checksum>
+ </Template>
+ <Template>
+ <Name>system_tasks.c</Name>
+ <Path>Source Files/app/system_config/default</Path>
+ <Checksum>BE644D0142ACA48D9CA2E6255A02CDBA</Checksum>
+ </Template>
+ <Template>
+ <Name>system_definitions.h</Name>
+ <Path>Header Files/app/system_config/default</Path>
+ <Checksum>08B5EB4F7D9B07DBF06AD124A3AC99C1</Checksum>
+ </Template>
+ </Templates>
+ <Libraries>
+ <Library value="../../../../../../opt/microchip/harmony/v1_06/bin/framework/peripheral/PIC32MZ2048ECG064_peripherals.a"/>
+ </Libraries>
+ </Manifest>
+</configuration>
diff --git a/firmware/src/system_config/default/default.mhc b/firmware/src/system_config/default/default.mhc
new file mode 100644
index 0000000..94fdc77
--- /dev/null
+++ b/firmware/src/system_config/default/default.mhc
@@ -0,0 +1,433 @@
+#
+# Configuration generated by Microchip Harmony Configurator (MHC) v1.0.6.12
+# Project name: PIC32MZ_harmony_tryout
+# Configuration: default
+# Device: PIC32MZ2048ECG064
+# Harmony version: 1.06
+#
+#
+# from $PROJECT_FIRMWARE_DIRECTORY/$PROJECT_NAME.hconfig
+#
+CONFIG_APP_INSTANCES=1
+#
+# from $HARMONY_VERSION_PATH/utilities/mhc/config/app_name_idx.ftl
+#
+CONFIG_APP_MENU_IDX0=y
+CONFIG_APP_NAME_0="app"
+#
+# from $PROJECT_FIRMWARE_DIRECTORY/$PROJECT_NAME.hconfig
+#
+CONFIG_USE_EXCEPTION_HANDLER=y
+CONFIG_EXCEPTION_USE_SYS_DEBUG=y
+CONFIG_EXCEPTION_BREAKPOINT=y
+#
+# from $HARMONY_VERSION_PATH/framework/bluetooth/config/bluetooth.hconfig
+#
+CONFIG_USE_BLUETOOTH_LIBRARIES=n
+#
+# from $HARMONY_VERSION_PATH/framework/bootloader/config/bootloader.hconfig
+#
+CONFIG_USE_BOOTLOADER=n
+#
+# from $HARMONY_VERSION_PATH/framework/crypto/config/crypto.hconfig
+#
+CONFIG_USE_CRYPTO_LIB=n
+#
+# from $HARMONY_VERSION_PATH/framework/driver/adc/config/drv_adc.hconfig
+#
+CONFIG_USE_DRV_ADC=n
+#
+# from $HARMONY_VERSION_PATH/framework/driver/camera/config/drv_camera.hconfig
+#
+CONFIG_USE_DRV_CAMERA=n
+#
+# from $HARMONY_VERSION_PATH/framework/driver/cmp/config/drv_cmp.hconfig
+#
+CONFIG_DRV_CVREF_ENABLE=n
+CONFIG_USE_DRV_CMP=n
+#
+# from $HARMONY_VERSION_PATH/framework/driver/codec/config/drv_codec.hconfig
+#
+CONFIG_SELECT_DRV_AK4384=n
+CONFIG_SELECT_DRV_AK4642=n
+CONFIG_SELECT_DRV_AK4645=n
+CONFIG_SELECT_DRV_AK4953=n
+#
+# from $HARMONY_VERSION_PATH/framework/driver/encx24j600/config/drv_encx24j600.hconfig
+#
+CONFIG_DRV_ENCX24J600_USE_DRIVER=n
+#
+# from $HARMONY_VERSION_PATH/framework/tcpip/config/tcpip_mac.hconfig
+#
+CONFIG_TCPIP_USE_ETH_MAC=n
+#
+# from $HARMONY_VERSION_PATH/framework/driver/gfx/controller/lcc/config/drv_gfx_lcc.hconfig
+#
+CONFIG_USE_DRV_GFX_LCC=n
+#
+# from $HARMONY_VERSION_PATH/framework/driver/gfx/controller/otm2201a/config/drv_gfx_otm2201a.hconfig
+#
+CONFIG_USE_DRV_GFX_OTM2201A=n
+#
+# from $HARMONY_VERSION_PATH/framework/driver/gfx/controller/ssd1926/config/drv_gfx_ssd1926.hconfig
+#
+CONFIG_USE_DRV_GFX_SSD1926=n
+#
+# from $HARMONY_VERSION_PATH/framework/driver/gfx/controller/ssd1289/config/drv_gfx_ssd1289.hconfig
+#
+CONFIG_USE_DRV_GFX_SSD1289=n
+#
+# from $HARMONY_VERSION_PATH/framework/driver/gfx/controller/s1d13517/config/drv_gfx_s1d13517.hconfig
+#
+CONFIG_USE_DRV_GFX_S1D13517=n
+#
+# from $HARMONY_VERSION_PATH/framework/driver/gfx/controller/tft002/config/drv_gfx_tft002.hconfig
+#
+CONFIG_USE_DRV_GFX_TFT002=n
+#
+# from $HARMONY_VERSION_PATH/framework/driver/gfx/display/config/drv_gfx_display.hconfig
+#
+CONFIG_USE_DRV_GFX_DISPLAY=n
+#
+# from $HARMONY_VERSION_PATH/framework/driver/i2c/config/drv_i2c.hconfig
+#
+CONFIG_USE_DRV_I2C=n
+#
+# from $HARMONY_VERSION_PATH/framework/driver/i2s/config/drv_i2s.hconfig
+#
+CONFIG_USE_DRV_I2S=n
+#
+# from $HARMONY_VERSION_PATH/framework/driver/ic/config/drv_ic.hconfig
+#
+CONFIG_USE_DRV_IC=n
+#
+# from $HARMONY_VERSION_PATH/framework/driver/nvm/config/drv_nvm.hconfig
+#
+CONFIG_USE_DRV_NVM=n
+#
+# from $HARMONY_VERSION_PATH/framework/driver/oc/config/drv_oc.hconfig
+#
+CONFIG_USE_DRV_OC=n
+#
+# from $HARMONY_VERSION_PATH/framework/driver/pmp/config/drv_pmp.hconfig
+#
+CONFIG_USE_DRV_PMP=n
+#
+# from $HARMONY_VERSION_PATH/framework/driver/rtcc/config/drv_rtcc.hconfig
+#
+CONFIG_USE_DRV_RTCC=n
+#
+# from $HARMONY_VERSION_PATH/framework/driver/sample/config/drv_sample.hconfig
+#
+CONFIG_USE_DRV_SAMPLE=n
+#
+# from $HARMONY_VERSION_PATH/framework/driver/sdcard/config/drv_sdcard.hconfig
+#
+CONFIG_USE_DRV_SDCARD=n
+#
+# from $HARMONY_VERSION_PATH/framework/driver/spi/config/drv_spi.hconfig
+#
+CONFIG_DRV_SPI_USE_DRIVER=n
+#
+# from $HARMONY_VERSION_PATH/framework/driver/sqi/config/drv_sqi.hconfig
+#
+CONFIG_DRV_SQI_USE_DRIVER=n
+#
+# from $HARMONY_VERSION_PATH/framework/driver/spi_flash/sst25vf016b/config/drv_sst25vf016b.hconfig
+#
+CONFIG_USE_DRV_SST25VF016B=n
+#
+# from $HARMONY_VERSION_PATH/framework/driver/spi_flash/sst25vf020b/config/drv_sst25vf020b.hconfig
+#
+CONFIG_USE_DRV_SST25VF020B=n
+#
+# from $HARMONY_VERSION_PATH/framework/driver/spi_flash/sst25vf064c/config/drv_sst25vf064c.hconfig
+#
+CONFIG_USE_DRV_SST25VF064C=n
+#
+# from $HARMONY_VERSION_PATH/framework/driver/tmr/config/drv_tmr.hconfig
+#
+CONFIG_USE_DRV_TMR=n
+#
+# from $HARMONY_VERSION_PATH/framework/driver/touch/adc10bit/config/drv_adc10bit.hconfig
+#
+CONFIG_USE_DRV_TOUCH_ADC10BIT=n
+#
+# from $HARMONY_VERSION_PATH/framework/driver/touch/ar1020/config/drv_ar1020.hconfig
+#
+CONFIG_USE_DRV_TOUCH_AR1020=n
+#
+# from $HARMONY_VERSION_PATH/framework/driver/touch/mtch6301/config/drv_mtch6301.hconfig
+#
+CONFIG_USE_DRV_TOUCH_MTCH6301=n
+#
+# from $HARMONY_VERSION_PATH/framework/driver/usart/config/drv_usart.hconfig
+#
+CONFIG_USE_DRV_USART=n
+#
+# from $HARMONY_VERSION_PATH/framework/driver/wifi/config/drv_wifi.hconfig
+#
+CONFIG_USE_DRV_WIFI=n
+#
+# from $HARMONY_VERSION_PATH/framework/gfx/config/gfx.hconfig
+#
+CONFIG_USE_GFX_STACK=n
+#
+# from $HARMONY_VERSION_PATH/framework/math/dsp/config/dsp.hconfig
+#
+CONFIG_USE_DSP=n
+#
+# from $HARMONY_VERSION_PATH/framework/math/libq/config/libq.hconfig
+#
+CONFIG_USE_LIBQ=n
+#
+# from $HARMONY_VERSION_PATH/framework/osal/config/osal.hconfig
+#
+CONFIG_USE_OSAL=y
+#
+# from $HARMONY_VERSION_PATH/framework/peripheral/config/peripheral.hconfig
+#
+CONFIG_PERIPHERAL_LIB=y
+#
+# from $HARMONY_VERSION_PATH/framework/system/clk/config/sys_clk.hconfig
+#
+CONFIG_USE_SYS_CLK=y
+CONFIG_SYS_CLK_MODE="STATIC"
+CONFIG_SYS_CLK_PBDIV0_MZ=2
+CONFIG_SYS_CLK_PBCLK1_ENABLE=n
+CONFIG_SYS_CLK_PBCLK2_ENABLE=y
+CONFIG_SYS_CLK_PBDIV2=2
+CONFIG_SYS_CLK_PBCLK3_ENABLE=y
+CONFIG_SYS_CLK_PBDIV3=2
+CONFIG_SYS_CLK_PBCLK4_ENABLE=n
+CONFIG_SYS_CLK_PBCLK6_ENABLE=y
+CONFIG_SYS_CLK_PBDIV6=1
+CONFIG_SYS_CLK_PBCLK7_ENABLE=n
+CONFIG_SYS_CLK_REFCLK0_ENABLE=n
+CONFIG_SYS_CLK_REFCLK1_ENABLE=n
+CONFIG_SYS_CLK_REFCLK2_ENABLE=n
+CONFIG_SYS_CLK_REFCLK3_ENABLE=n
+CONFIG_SYS_CLK_CONFIG_PRIMARY_XTAL="24000000"
+CONFIG_SYS_CLK_CONFIG_SECONDARY_XTAL="32768"
+CONFIG_SYS_CLK_FREQ="80000000"
+CONFIG_SYS_CLK_PBCLK0_FREQ="40000000"
+CONFIG_SYS_CLK_PBCLK2_FREQ="40000000"
+CONFIG_SYS_CLK_PBCLK3_FREQ="40000000"
+CONFIG_SYS_CLK_PBCLK6_FREQ="80000000"
+#
+# from $HARMONY_VERSION_PATH/framework/system/command/config/sys_command.hconfig
+#
+CONFIG_USE_SYS_COMMAND=n
+#
+# from $HARMONY_VERSION_PATH/framework/system/common/config/sys_common.hconfig
+#
+CONFIG_USE_SYS_COMMON=y
+CONFIG_SYS_BUFFER=n
+CONFIG_SYS_QUEUE=n
+#
+# from $HARMONY_VERSION_PATH/framework/system/console/config/sys_console.hconfig
+#
+CONFIG_USE_SYS_CONSOLE=n
+#
+# from $HARMONY_VERSION_PATH/framework/system/debug/config/sys_debug.hconfig
+#
+CONFIG_USE_SYS_DEBUG=n
+#
+# from $HARMONY_VERSION_PATH/framework/system/devcon/config/sys_devcon.hconfig
+#
+CONFIG_USE_SYS_DEVCON=y
+CONFIG_SYS_DEVCON_USE_JTAG=n
+CONFIG_SYS_DEVCON_USE_TRACE=n
+#
+# from $HARMONY_VERSION_PATH/framework/system/dma/config/sys_dma.hconfig
+#
+CONFIG_USE_SYS_DMA=n
+#
+# from $HARMONY_VERSION_PATH/framework/system/fs/config/sys_fs.hconfig
+#
+CONFIG_USE_SYS_FS=n
+#
+# from $HARMONY_VERSION_PATH/framework/system/int/config/sys_int.hconfig
+#
+CONFIG_USE_SYS_INT=n
+CONFIG_USE_EXT_INT=n
+#
+# from $HARMONY_VERSION_PATH/framework/system/msg/config/sys_msg.hconfig
+#
+CONFIG_USE_SYS_MSG=n
+#
+# from $HARMONY_VERSION_PATH/framework/system/ports/config/sys_ports.hconfig
+#
+CONFIG_USE_SYS_PORTS=y
+CONFIG_COMPONENT_PACKAGE="TQFP"
+CONFIG_USE_SYS_PORTS_CN_INTERRUPT=n
+#
+# from $HARMONY_VERSION_PATH/framework/system/ports/config/sys_ports_idx.ftl
+#
+CONFIG_USE_PORT_B=y
+CONFIG_SYS_PORT_B_ANSEL=0x0
+CONFIG_SYS_PORT_B_TRIS=0x0
+CONFIG_SYS_PORT_B_LAT=0x0
+CONFIG_SYS_PORT_B_ODC=0x0
+CONFIG_SYS_PORT_B_CNPU=0x0
+CONFIG_SYS_PORT_B_CNPD=0x0
+CONFIG_SYS_PORT_B_CNEN=0x0
+CONFIG_USE_PORT_C=y
+CONFIG_SYS_PORT_C_ANSEL=0x0
+CONFIG_SYS_PORT_C_TRIS=0xf000
+CONFIG_SYS_PORT_C_LAT=0x0
+CONFIG_SYS_PORT_C_ODC=0x0
+CONFIG_SYS_PORT_C_CNPU=0x0
+CONFIG_SYS_PORT_C_CNPD=0x0
+CONFIG_SYS_PORT_C_CNEN=0x0
+CONFIG_USE_PORT_D=y
+CONFIG_SYS_PORT_D_ANSEL=0x0
+CONFIG_SYS_PORT_D_TRIS=0xe3f
+CONFIG_SYS_PORT_D_LAT=0x0
+CONFIG_SYS_PORT_D_ODC=0x0
+CONFIG_SYS_PORT_D_CNPU=0xe3f
+CONFIG_SYS_PORT_D_CNPD=0x0
+CONFIG_SYS_PORT_D_CNEN=0x0
+CONFIG_USE_PORT_E=y
+CONFIG_SYS_PORT_E_ANSEL=0x0
+CONFIG_SYS_PORT_E_TRIS=0xff
+CONFIG_SYS_PORT_E_LAT=0x0
+CONFIG_SYS_PORT_E_ODC=0x0
+CONFIG_SYS_PORT_E_CNPU=0xff
+CONFIG_SYS_PORT_E_CNPD=0x0
+CONFIG_SYS_PORT_E_CNEN=0x0
+CONFIG_USE_PORT_F=y
+CONFIG_SYS_PORT_F_ANSEL=0x0
+CONFIG_SYS_PORT_F_TRIS=0x3b
+CONFIG_SYS_PORT_F_LAT=0x0
+CONFIG_SYS_PORT_F_ODC=0x0
+CONFIG_SYS_PORT_F_CNPU=0x3b
+CONFIG_SYS_PORT_F_CNPD=0x0
+CONFIG_SYS_PORT_F_CNEN=0x0
+CONFIG_USE_PORT_G=y
+CONFIG_SYS_PORT_G_ANSEL=0x0
+CONFIG_SYS_PORT_G_TRIS=0x1c0
+CONFIG_SYS_PORT_G_LAT=0x0
+CONFIG_SYS_PORT_G_ODC=0x0
+CONFIG_SYS_PORT_G_CNPU=0x0
+CONFIG_SYS_PORT_G_CNPD=0x0
+CONFIG_SYS_PORT_G_CNEN=0x0
+#
+# from $HARMONY_VERSION_PATH/framework/system/random/config/sys_random.hconfig
+#
+CONFIG_USE_SYS_RANDOM=n
+#
+# from $HARMONY_VERSION_PATH/framework/system/reset/config/sys_reset.hconfig
+#
+CONFIG_USE_SYS_RESET=n
+#
+# from $HARMONY_VERSION_PATH/framework/system/touch/config/sys_touch.hconfig
+#
+CONFIG_USE_SYS_TOUCH=n
+#
+# from $HARMONY_VERSION_PATH/framework/system/tmr/config/sys_tmr.hconfig
+#
+CONFIG_USE_SYS_TMR=n
+#
+# from $HARMONY_VERSION_PATH/framework/system/wdt/config/sys_wdt.hconfig
+#
+CONFIG_USE_SYS_WDT=n
+#
+# from $HARMONY_VERSION_PATH/framework/tcpip/config/tcpip_stack.hconfig
+#
+CONFIG_USE_TCPIP_STACK=n
+#
+# from $HARMONY_VERSION_PATH/framework/usb/config/usb.hconfig
+#
+CONFIG_USE_USB_STACK=n
+#
+# from $HARMONY_VERSION_PATH/framework/sample/config/sample_module.hconfig
+#
+CONFIG_USE_SAMPLE_MODULE=n
+#
+# from $HARMONY_VERSION_PATH/framework/test/config/test.hconfig
+#
+CONFIG_USE_TEST_HARNESS=n
+#
+# from $HARMONY_VERSION_PATH/framework/decoder/config/decoder.hconfig
+#
+CONFIG_USE_DECODER=n
+#
+# from $HARMONY_VERSION_PATH/framework/net/pres/config/net_pres.hconfig
+#
+CONFIG_NET_PRES_USE=n
+#
+# from $HARMONY_VERSION_PATH/bsp/config/bsp.hconfig
+#
+CONFIG_USE_BSP=n
+#
+# from $HARMONY_VERSION_PATH/third_party/rtos/config/rtos.hconfig
+#
+CONFIG_USE_3RDPARTY_RTOS=n
+#
+# from $HARMONY_VERSION_PATH/third_party/tcpip/config/wolfssl.hconfig
+#
+CONFIG_USE_3RDPARTY_WOLFSSL=n
+#
+# from $HARMONY_VERSION_PATH/third_party/tcpip/iniche/config/embtcp.hconfig
+#
+CONFIG_IN_EMB_TCPIP_USE_TCP=n
+#
+# from $HARMONY_VERSION_PATH/third_party/tcpip/iniche/config/embdual.hconfig
+#
+CONFIG_IN_EMB_DUAL_USE_TCP=n
+#
+# from $HARMONY_VERSION_PATH/third_party/tcpip/iniche/config/stack.hconfig
+#
+CONFIG_IN_TCPIP=n
+#
+# from $HARMONY_VERSION_PATH/config/harmony.hconfig
+#
+CONFIG_DEVICE_CONFIGURATION=y
+#
+# from $HARMONY_VERSION_PATH/utilities/mhc/config/PIC32MZ2048ECG064.hconfig
+#
+CONFIG_USERID=0xffff
+CONFIG_FMIIEN="ON"
+CONFIG_FETHIO="OFF"
+CONFIG_PGL1WAY="ON"
+CONFIG_PMDL1WAY="ON"
+CONFIG_IOL1WAY="ON"
+CONFIG_FUSBIDIO="OFF"
+CONFIG_FPLLIDIV="DIV_1"
+CONFIG_FPLLRNG="RANGE_5_10_MHZ"
+CONFIG_FPLLICLK="PLL_FRC"
+CONFIG_FPLLMULT="MUL_80"
+CONFIG_FPLLODIV="DIV_8"
+CONFIG_UPLLFSEL="FREQ_12MHZ"
+CONFIG_UPLLEN="OFF"
+CONFIG_FNOSC="SPLL"
+CONFIG_DMTINTV="WIN_127_128"
+CONFIG_FSOSCEN="OFF"
+CONFIG_IESO="ON"
+CONFIG_POSCMOD="OFF"
+CONFIG_OSCIOFNC="OFF"
+CONFIG_FCKSM="CSECME"
+CONFIG_WDTPS="PS1048576"
+CONFIG_WDTSPGM="STOP"
+CONFIG_WINDIS="NORMAL"
+CONFIG_FWDTEN="OFF"
+CONFIG_FWDTWINSZ="WINSZ_25"
+CONFIG_DMTCNT="DMT31"
+CONFIG_FDMTEN="OFF"
+CONFIG_DEBUG="OFF"
+CONFIG_JTAGEN="OFF"
+CONFIG_ICESEL="ICS_PGx1"
+CONFIG_TRCEN="ON"
+CONFIG_BOOTISA="MIPS32"
+CONFIG_FECCCON="OFF_UNLOCKED"
+CONFIG_FSLEEP="OFF"
+CONFIG_DBGPER="PG_ALL"
+CONFIG_EJTAGBEN="NORMAL"
+CONFIG_CP="OFF"
+CONFIG_TSEQ=0xffff
+CONFIG_CSEQ=0xffff
+#
+# from $HARMONY_VERSION_PATH/utilities/mhc/config/project.hconfig
+#
+CONFIG_XC32_HEAP="4096"
diff --git a/firmware/src/system_config/default/framework/system/clk/src/sys_clk_static.c b/firmware/src/system_config/default/framework/system/clk/src/sys_clk_static.c
new file mode 100644
index 0000000..06a146b
--- /dev/null
+++ b/firmware/src/system_config/default/framework/system/clk/src/sys_clk_static.c
@@ -0,0 +1,283 @@
+/*******************************************************************************
+ SYS CLK Static Functions for Clock System Service
+
+ Company:
+ Microchip Technology Inc.
+
+ File Name:
+ sys_clk_static.c
+
+ Summary:
+ SYS CLK static function implementations for the Clock System Service.
+
+ Description:
+ The Clock System Service provides a simple interface to manage the oscillators
+ on Microchip microcontrollers. This file defines the static implementation for the
+ Clock System Service.
+
+ Remarks:
+ Static functions incorporate all system clock configuration settings as
+ determined by the user via the Microchip Harmony Configurator GUI. It provides
+ static version of the routines, eliminating the need for an object ID or
+ object handle.
+
+ Static single-open interfaces also eliminate the need for the open handle.
+*******************************************************************************/
+
+//DOM-IGNORE-BEGIN
+/*******************************************************************************
+Copyright (c) 2014 released Microchip Technology Inc. All rights reserved.
+
+Microchip licenses to you the right to use, modify, copy and distribute
+Software only when embedded on a Microchip microcontroller or digital signal
+controller that is integrated into your product or third party product
+(pursuant to the sublicense terms in the accompanying license agreement).
+
+You should refer to the license agreement accompanying this Software for
+additional information regarding your rights and obligations.
+
+SOFTWARE AND DOCUMENTATION ARE PROVIDED AS IS WITHOUT WARRANTY OF ANY KIND,
+EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION, ANY WARRANTY OF
+MERCHANTABILITY, TITLE, NON-INFRINGEMENT AND FITNESS FOR A PARTICULAR PURPOSE.
+IN NO EVENT SHALL MICROCHIP OR ITS LICENSORS BE LIABLE OR OBLIGATED UNDER
+CONTRACT, NEGLIGENCE, STRICT LIABILITY, CONTRIBUTION, BREACH OF WARRANTY, OR
+OTHER LEGAL EQUITABLE THEORY ANY DIRECT OR INDIRECT DAMAGES OR EXPENSES
+INCLUDING BUT NOT LIMITED TO ANY INCIDENTAL, SPECIAL, INDIRECT, PUNITIVE OR
+CONSEQUENTIAL DAMAGES, LOST PROFITS OR LOST DATA, COST OF PROCUREMENT OF
+SUBSTITUTE GOODS, TECHNOLOGY, SERVICES, OR ANY CLAIMS BY THIRD PARTIES
+(INCLUDING BUT NOT LIMITED TO ANY DEFENSE THEREOF), OR OTHER SIMILAR COSTS.
+*******************************************************************************/
+//DOM-IGNORE-END
+
+// *****************************************************************************
+// *****************************************************************************
+// Section: Include Files
+// *****************************************************************************
+// *****************************************************************************
+
+#include "system_config.h"
+#include "system_definitions.h"
+#include "peripheral/osc/plib_osc.h"
+
+// *****************************************************************************
+// *****************************************************************************
+// Section: File Scope Functions
+// *****************************************************************************
+// *****************************************************************************
+
+// *****************************************************************************
+/* Function:
+ void SYS_CLK_Static_Initialize ( const SYS_CLK_INIT const * clkInit )
+
+ Summary:
+ Initializes hardware and internal data structure of the System Clock.
+
+ Description:
+ This function initializes the hardware and internal data structure of System
+ Clock Service.
+
+ Remarks:
+ This is configuration values for the static version of the Clock System Service
+ module is determined by the user via the Microchip Harmony Configurator GUI.
+ This template will build a sys_clk_static.h and sys_clk_static.c file with
+ the configuration per the user's choice.
+
+ The objective is to eliminate the user's need to be knowledgeable in the function of
+ the 'configuration bits' to configure the system oscillators.
+*/
+
+void SYS_CLK_Initialize( const SYS_CLK_INIT const * clkInit )
+{
+ SYS_DEVCON_SystemUnlock ( );
+
+ PLIB_OSC_FRCDivisorSelect( OSC_ID_0, OSC_FRC_DIV_1);
+
+ /* Enable Peripheral Bus 1 */
+ PLIB_OSC_PBClockDivisorSet (OSC_ID_0, 0, 2 );
+ PLIB_OSC_PBOutputClockEnable (OSC_ID_0, 0 );
+ /* Disable Peripheral Bus 2 */
+ PLIB_OSC_PBOutputClockDisable (OSC_ID_0, 1 );
+
+ /* Enable Peripheral Bus 3 */
+ PLIB_OSC_PBClockDivisorSet (OSC_ID_0, 2, 2 );
+ PLIB_OSC_PBOutputClockEnable (OSC_ID_0, 2 );
+ /* Enable Peripheral Bus 4 */
+ PLIB_OSC_PBClockDivisorSet (OSC_ID_0, 3, 2 );
+ PLIB_OSC_PBOutputClockEnable (OSC_ID_0, 3 );
+ /* Disable Peripheral Bus 5 */
+ PLIB_OSC_PBOutputClockDisable (OSC_ID_0, 4 );
+
+ /* Enable Peripheral Bus 7 */
+ PLIB_OSC_PBClockDivisorSet (OSC_ID_0, 6, 1 );
+ PLIB_OSC_PBOutputClockEnable (OSC_ID_0, 6 );
+ /* Disable Peripheral Bus 8 */
+ PLIB_OSC_PBOutputClockDisable (OSC_ID_0, 7 );
+
+ /* Disable REFCLKO1*/
+ PLIB_OSC_ReferenceOscDisable ( OSC_ID_0, OSC_REFERENCE_1 );
+ /* Disable REFCLK1_OE*/
+ PLIB_OSC_ReferenceOutputDisable ( OSC_ID_0, OSC_REFERENCE_1 );
+ /* Disable REFCLKO2*/
+ PLIB_OSC_ReferenceOscDisable ( OSC_ID_0, OSC_REFERENCE_2 );
+ /* Disable REFCLK2_OE*/
+ PLIB_OSC_ReferenceOutputDisable ( OSC_ID_0, OSC_REFERENCE_2 );
+ /* Disable REFCLKO3*/
+ PLIB_OSC_ReferenceOscDisable ( OSC_ID_0, OSC_REFERENCE_3 );
+ /* Disable REFCLK3_OE*/
+ PLIB_OSC_ReferenceOutputDisable ( OSC_ID_0, OSC_REFERENCE_3 );
+ /* Disable REFCLKO4*/
+ PLIB_OSC_ReferenceOscDisable ( OSC_ID_0, OSC_REFERENCE_4 );
+ /* Disable REFCLK4_OE*/
+ PLIB_OSC_ReferenceOutputDisable ( OSC_ID_0, OSC_REFERENCE_4 );
+
+ SYS_DEVCON_SystemLock ( );
+}
+
+//******************************************************************************
+/* Function:
+ inline uint32_t SYS_CLK_SystemFrequencyGet ( void )
+
+ Summary:
+ Gets the system clock frequency in Hertz.
+
+ Description:
+ This function gets the System clock frequency in Hertz.
+
+ Precondition:
+ None.
+
+ Parameters:
+ None.
+
+ Returns:
+ System clock frequency in Hertz.
+
+ Example:
+ <code>
+ uint32_t sysClockHz;
+
+ sysClockHz = SYS_CLK_SystemFrequencyGet ( );
+ </code>
+
+ Remarks:
+ */
+
+inline uint32_t SYS_CLK_SystemFrequencyGet ( void )
+{
+ return SYS_CLK_FREQ;
+}
+
+//******************************************************************************
+/* Function:
+ inline uint32_t SYS_CLK_PeripheralFrequencyGet ( CLK_BUSES_PERIPHERAL peripheralBus )
+
+ Summary:
+ Gets the selected clock peripheral bus frequency in Hertz.
+
+ Description:
+ This function gets the selected peripheral bus clock frequency in Hertz.
+
+ Precondition:
+ None.
+
+ Parameters:
+ peripheralBus - Reference clock bus selection. One of the possible value from
+ CLK_BUSES_PERIPHERAL enum. For devices that do not have multiple
+ clock channels for Reference clock, CLK_BUS_PERIPHERAL_1 should be
+ the selection.
+
+ Returns:
+ Clock frequency in Hertz.
+
+ Example:
+ <code>
+ unsigned long peripheralClockHz;
+
+ peripheralClockHz = SYS_CLK_PeripheralFrequencyGet ( CLK_BUS_PERIPHERAL_5 );
+ </code>
+
+ Remarks:
+ Most of the devices doesn't have multiple Peripheral clock buses. In that case,
+ pass CLK_USB_PERIPHERAL_1 as the bus number.
+ */
+
+inline uint32_t SYS_CLK_PeripheralFrequencyGet ( CLK_BUSES_PERIPHERAL peripheralBus )
+{
+ uint32_t freq = 0;
+
+ switch (peripheralBus)
+ {
+ case CLK_BUS_PERIPHERAL_1:
+ freq = SYS_CLK_BUS_PERIPHERAL_1;
+ break;
+ case CLK_BUS_PERIPHERAL_2:
+ break;
+ case CLK_BUS_PERIPHERAL_3:
+ freq = SYS_CLK_BUS_PERIPHERAL_3;
+ break;
+ case CLK_BUS_PERIPHERAL_4:
+ freq = SYS_CLK_BUS_PERIPHERAL_4;
+ break;
+ case CLK_BUS_PERIPHERAL_5:
+ break;
+ case CLK_BUS_PERIPHERAL_7:
+ freq = SYS_CLK_BUS_PERIPHERAL_7;
+ break;
+ case CLK_BUS_PERIPHERAL_8:
+ break;
+ }
+
+ return freq;
+}
+
+
+//******************************************************************************
+/* Function:
+ inline uint32_t SYS_CLK_ReferenceClockFrequencyGet ( CLK_BUSES_REFERENCE referenceBus )
+
+ Summary:
+ Gets the selected Reference clock bus frequency in Hertz.
+
+ Description:
+ This function gets frequency of the selected Reference clock bus in Hertz.
+
+ Precondition:
+ None.
+
+ Parameters:
+ peripheralBus - Reference clock bus selection. One of the possible value from
+ CLK_BUSES_REFERENCE enum. For devices that do not have multiple
+ clock channels for Reference clock, CLK_BUS_REFERENCE_1 should be
+ the selection.
+
+ Returns:
+ Clock frequency in Hz.
+
+ Example:
+ <code>
+ unsigned long sysClockOutputHz;
+
+ sysClockOutputHz = SYS_CLK_ReferenceClockFrequencyGet ( CLK_BUS_REFERENCE_3 );
+ </code>
+
+ Remarks:
+ */
+
+inline uint32_t SYS_CLK_ReferenceClockFrequencyGet ( CLK_BUSES_REFERENCE referenceBus )
+{
+ uint32_t freq = 0;
+
+ switch (referenceBus)
+ {
+ case CLK_BUS_REFERENCE_1:
+ break;
+ case CLK_BUS_REFERENCE_2:
+ break;
+ case CLK_BUS_REFERENCE_3:
+ break;
+ case CLK_BUS_REFERENCE_4:
+ break;
+ }
+
+ return freq;
+} \ No newline at end of file
diff --git a/firmware/src/system_config/default/framework/system/clk/sys_clk_static.h b/firmware/src/system_config/default/framework/system/clk/sys_clk_static.h
new file mode 100644
index 0000000..23a0cf5
--- /dev/null
+++ b/firmware/src/system_config/default/framework/system/clk/sys_clk_static.h
@@ -0,0 +1,65 @@
+/*******************************************************************************
+ SYS CLK Static Interface Declarations for Clock System Service
+
+ Company:
+ Microchip Technology Inc.
+
+ File Name:
+ sys_clk_static.h
+
+ Summary:
+ SYS CLK interface declarations for the static system service.
+
+ Description:
+ The Clock System Service provides a simple interface to manage the oscillators
+ on Microchip microcontrollers. This file defines the interface
+ Declarations for the SYS CLK system service.
+
+ Remarks:
+ Static interfaces incorporate all system clock configuration settings as
+ determined by the user via the Microchip Harmony Configurator GUI. It provides
+ static version of the routines, eliminating the need for an object ID or
+ object handle.
+
+ Static single-open interfaces also eliminate the need for the open handle.
+*******************************************************************************/
+
+//DOM-IGNORE-BEGIN
+/*******************************************************************************
+Copyright (c) 2014 released Microchip Technology Inc. All rights reserved.
+
+Microchip licenses to you the right to use, modify, copy and distribute
+Software only when embedded on a Microchip microcontroller or digital signal
+controller that is integrated into your product or third party product
+(pursuant to the sublicense terms in the accompanying license agreement).
+
+You should refer to the license agreement accompanying this Software for
+additional information regarding your rights and obligations.
+
+SOFTWARE AND DOCUMENTATION ARE PROVIDED AS IS WITHOUT WARRANTY OF ANY KIND,
+EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION, ANY WARRANTY OF
+MERCHANTABILITY, TITLE, NON-INFRINGEMENT AND FITNESS FOR A PARTICULAR PURPOSE.
+IN NO EVENT SHALL MICROCHIP OR ITS LICENSORS BE LIABLE OR OBLIGATED UNDER
+CONTRACT, NEGLIGENCE, STRICT LIABILITY, CONTRIBUTION, BREACH OF WARRANTY, OR
+OTHER LEGAL EQUITABLE THEORY ANY DIRECT OR INDIRECT DAMAGES OR EXPENSES
+INCLUDING BUT NOT LIMITED TO ANY INCIDENTAL, SPECIAL, INDIRECT, PUNITIVE OR
+CONSEQUENTIAL DAMAGES, LOST PROFITS OR LOST DATA, COST OF PROCUREMENT OF
+SUBSTITUTE GOODS, TECHNOLOGY, SERVICES, OR ANY CLAIMS BY THIRD PARTIES
+(INCLUDING BUT NOT LIMITED TO ANY DEFENSE THEREOF), OR OTHER SIMILAR COSTS.
+*******************************************************************************/
+//DOM-IGNORE-END
+
+#ifndef _SYS_CLK_STATIC_H
+#define _SYS_CLK_STATIC_H
+
+// *****************************************************************************
+// *****************************************************************************
+// Section: SYS CLK Module Initialization Routine (Static Version)
+// *****************************************************************************
+// *****************************************************************************
+
+#endif // #ifndef _SYS_CLK_STATIC_H
+
+/*******************************************************************************
+ End of File
+*/
diff --git a/firmware/src/system_config/default/framework/system/ports/src/sys_ports_static.c b/firmware/src/system_config/default/framework/system/ports/src/sys_ports_static.c
new file mode 100644
index 0000000..b125472
--- /dev/null
+++ b/firmware/src/system_config/default/framework/system/ports/src/sys_ports_static.c
@@ -0,0 +1,130 @@
+/*******************************************************************************
+ SYS PORTS Static Functions for PORTS System Service
+
+ Company:
+ Microchip Technology Inc.
+
+ File Name:
+ sys_ports_static.c
+
+ Summary:
+ SYS PORTS static function implementations for the Ports System Service.
+
+ Description:
+ The Ports System Service provides a simple interface to manage the ports
+ on Microchip microcontrollers. This file defines the static implementation for the
+ Ports System Service.
+
+ Remarks:
+ Static functions incorporate all system ports configuration settings as
+ determined by the user via the Microchip Harmony Configurator GUI. It provides
+ static version of the routines, eliminating the need for an object ID or
+ object handle.
+
+*******************************************************************************/
+
+//DOM-IGNORE-BEGIN
+/*******************************************************************************
+Copyright (c) 2013 released Microchip Technology Inc. All rights reserved.
+
+Microchip licenses to you the right to use, modify, copy and distribute
+Software only when embedded on a Microchip microcontroller or digital signal
+controller that is integrated into your product or third party product
+(pursuant to the sublicense terms in the accompanying license agreement).
+
+You should refer to the license agreement accompanying this Software for
+additional information regarding your rights and obligations.
+
+SOFTWARE AND DOCUMENTATION ARE PROVIDED AS IS WITHOUT WARRANTY OF ANY KIND,
+EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION, ANY WARRANTY OF
+MERCHANTABILITY, TITLE, NON-INFRINGEMENT AND FITNESS FOR A PARTICULAR PURPOSE.
+IN NO EVENT SHALL MICROCHIP OR ITS LICENSORS BE LIABLE OR OBLIGATED UNDER
+CONTRACT, NEGLIGENCE, STRICT LIABILITY, CONTRIBUTION, BREACH OF WARRANTY, OR
+OTHER LEGAL EQUITABLE THEORY ANY DIRECT OR INDIRECT DAMAGES OR EXPENSES
+INCLUDING BUT NOT LIMITED TO ANY INCIDENTAL, SPECIAL, INDIRECT, PUNITIVE OR
+CONSEQUENTIAL DAMAGES, LOST PROFITS OR LOST DATA, COST OF PROCUREMENT OF
+SUBSTITUTE GOODS, TECHNOLOGY, SERVICES, OR ANY CLAIMS BY THIRD PARTIES
+(INCLUDING BUT NOT LIMITED TO ANY DEFENSE THEREOF), OR OTHER SIMILAR COSTS.
+*******************************************************************************/
+//DOM-IGNORE-END
+
+#include "system_config.h"
+#include "peripheral/ports/plib_ports.h"
+#include "peripheral/int/plib_int.h"
+
+
+void SYS_PORTS_Initialize(void)
+{
+
+ /* PORT B Initialization */
+ PLIB_PORTS_OpenDrainEnable(PORTS_ID_0, PORT_CHANNEL_B, SYS_PORT_B_ODC);
+ PLIB_PORTS_Write( PORTS_ID_0, PORT_CHANNEL_B, SYS_PORT_B_LAT);
+ PLIB_PORTS_DirectionOutputSet( PORTS_ID_0, PORT_CHANNEL_B, SYS_PORT_B_TRIS ^ 0xFFFF);
+ PLIB_PORTS_ChangeNoticePerPortTurnOn(PORTS_ID_0, PORT_CHANNEL_B);
+ PLIB_PORTS_ChannelModeSelect(PORTS_ID_0, PORT_CHANNEL_B, SYS_PORT_B_ANSEL ^ 0xFFFF, PORTS_PIN_MODE_DIGITAL);
+ PLIB_PORTS_ChannelChangeNoticeEnable(PORTS_ID_0, PORT_CHANNEL_B, SYS_PORT_B_CNEN);
+ PLIB_PORTS_ChannelChangeNoticePullUpEnable(PORTS_ID_0, PORT_CHANNEL_B, SYS_PORT_B_CNPU);
+ PLIB_PORTS_ChannelChangeNoticePullDownEnable(PORTS_ID_0, PORT_CHANNEL_B, SYS_PORT_B_CNPD);
+
+ /* PORT C Initialization */
+ PLIB_PORTS_OpenDrainEnable(PORTS_ID_0, PORT_CHANNEL_C, SYS_PORT_C_ODC);
+ PLIB_PORTS_Write( PORTS_ID_0, PORT_CHANNEL_C, SYS_PORT_C_LAT);
+ PLIB_PORTS_DirectionOutputSet( PORTS_ID_0, PORT_CHANNEL_C, SYS_PORT_C_TRIS ^ 0xFFFF);
+ PLIB_PORTS_ChangeNoticePerPortTurnOn(PORTS_ID_0, PORT_CHANNEL_C);
+ PLIB_PORTS_ChannelModeSelect(PORTS_ID_0, PORT_CHANNEL_C, SYS_PORT_C_ANSEL ^ 0xFFFF, PORTS_PIN_MODE_DIGITAL);
+ PLIB_PORTS_ChannelChangeNoticeEnable(PORTS_ID_0, PORT_CHANNEL_C, SYS_PORT_C_CNEN);
+ PLIB_PORTS_ChannelChangeNoticePullUpEnable(PORTS_ID_0, PORT_CHANNEL_C, SYS_PORT_C_CNPU);
+ PLIB_PORTS_ChannelChangeNoticePullDownEnable(PORTS_ID_0, PORT_CHANNEL_C, SYS_PORT_C_CNPD);
+
+ /* PORT D Initialization */
+ PLIB_PORTS_OpenDrainEnable(PORTS_ID_0, PORT_CHANNEL_D, SYS_PORT_D_ODC);
+ PLIB_PORTS_Write( PORTS_ID_0, PORT_CHANNEL_D, SYS_PORT_D_LAT);
+ PLIB_PORTS_DirectionOutputSet( PORTS_ID_0, PORT_CHANNEL_D, SYS_PORT_D_TRIS ^ 0xFFFF);
+ PLIB_PORTS_ChangeNoticePerPortTurnOn(PORTS_ID_0, PORT_CHANNEL_D);
+ PLIB_PORTS_ChannelModeSelect(PORTS_ID_0, PORT_CHANNEL_D, SYS_PORT_D_ANSEL ^ 0xFFFF, PORTS_PIN_MODE_DIGITAL);
+ PLIB_PORTS_ChannelChangeNoticeEnable(PORTS_ID_0, PORT_CHANNEL_D, SYS_PORT_D_CNEN);
+ PLIB_PORTS_ChannelChangeNoticePullUpEnable(PORTS_ID_0, PORT_CHANNEL_D, SYS_PORT_D_CNPU);
+ PLIB_PORTS_ChannelChangeNoticePullDownEnable(PORTS_ID_0, PORT_CHANNEL_D, SYS_PORT_D_CNPD);
+
+ /* PORT E Initialization */
+ PLIB_PORTS_OpenDrainEnable(PORTS_ID_0, PORT_CHANNEL_E, SYS_PORT_E_ODC);
+ PLIB_PORTS_Write( PORTS_ID_0, PORT_CHANNEL_E, SYS_PORT_E_LAT);
+ PLIB_PORTS_DirectionOutputSet( PORTS_ID_0, PORT_CHANNEL_E, SYS_PORT_E_TRIS ^ 0xFFFF);
+ PLIB_PORTS_ChangeNoticePerPortTurnOn(PORTS_ID_0, PORT_CHANNEL_E);
+ PLIB_PORTS_ChannelModeSelect(PORTS_ID_0, PORT_CHANNEL_E, SYS_PORT_E_ANSEL ^ 0xFFFF, PORTS_PIN_MODE_DIGITAL);
+ PLIB_PORTS_ChannelChangeNoticeEnable(PORTS_ID_0, PORT_CHANNEL_E, SYS_PORT_E_CNEN);
+ PLIB_PORTS_ChannelChangeNoticePullUpEnable(PORTS_ID_0, PORT_CHANNEL_E, SYS_PORT_E_CNPU);
+ PLIB_PORTS_ChannelChangeNoticePullDownEnable(PORTS_ID_0, PORT_CHANNEL_E, SYS_PORT_E_CNPD);
+
+ /* PORT F Initialization */
+ PLIB_PORTS_OpenDrainEnable(PORTS_ID_0, PORT_CHANNEL_F, SYS_PORT_F_ODC);
+ PLIB_PORTS_Write( PORTS_ID_0, PORT_CHANNEL_F, SYS_PORT_F_LAT);
+ PLIB_PORTS_DirectionOutputSet( PORTS_ID_0, PORT_CHANNEL_F, SYS_PORT_F_TRIS ^ 0xFFFF);
+ PLIB_PORTS_ChangeNoticePerPortTurnOn(PORTS_ID_0, PORT_CHANNEL_F);
+ PLIB_PORTS_ChannelModeSelect(PORTS_ID_0, PORT_CHANNEL_F, SYS_PORT_F_ANSEL ^ 0xFFFF, PORTS_PIN_MODE_DIGITAL);
+ PLIB_PORTS_ChannelChangeNoticeEnable(PORTS_ID_0, PORT_CHANNEL_F, SYS_PORT_F_CNEN);
+ PLIB_PORTS_ChannelChangeNoticePullUpEnable(PORTS_ID_0, PORT_CHANNEL_F, SYS_PORT_F_CNPU);
+ PLIB_PORTS_ChannelChangeNoticePullDownEnable(PORTS_ID_0, PORT_CHANNEL_F, SYS_PORT_F_CNPD);
+
+ /* PORT G Initialization */
+ PLIB_PORTS_OpenDrainEnable(PORTS_ID_0, PORT_CHANNEL_G, SYS_PORT_G_ODC);
+ PLIB_PORTS_Write( PORTS_ID_0, PORT_CHANNEL_G, SYS_PORT_G_LAT);
+ PLIB_PORTS_DirectionOutputSet( PORTS_ID_0, PORT_CHANNEL_G, SYS_PORT_G_TRIS ^ 0xFFFF);
+ PLIB_PORTS_ChangeNoticePerPortTurnOn(PORTS_ID_0, PORT_CHANNEL_G);
+ PLIB_PORTS_ChannelModeSelect(PORTS_ID_0, PORT_CHANNEL_G, SYS_PORT_G_ANSEL ^ 0xFFFF, PORTS_PIN_MODE_DIGITAL);
+ PLIB_PORTS_ChannelChangeNoticeEnable(PORTS_ID_0, PORT_CHANNEL_G, SYS_PORT_G_CNEN);
+ PLIB_PORTS_ChannelChangeNoticePullUpEnable(PORTS_ID_0, PORT_CHANNEL_G, SYS_PORT_G_CNPU);
+ PLIB_PORTS_ChannelChangeNoticePullDownEnable(PORTS_ID_0, PORT_CHANNEL_G, SYS_PORT_G_CNPD);
+
+
+ /* PPS Input Remapping */
+
+ /* PPS Output Remapping */
+
+
+}
+
+
+/*******************************************************************************
+ End of File
+*/
diff --git a/firmware/src/system_config/default/system_config.h b/firmware/src/system_config/default/system_config.h
new file mode 100644
index 0000000..a8faed8
--- /dev/null
+++ b/firmware/src/system_config/default/system_config.h
@@ -0,0 +1,165 @@
+/*******************************************************************************
+ MPLAB Harmony System Configuration Header
+
+ File Name:
+ system_config.h
+
+ Summary:
+ Build-time configuration header for the system defined by this MPLAB Harmony
+ project.
+
+ Description:
+ An MPLAB Project may have multiple configurations. This file defines the
+ build-time options for a single configuration.
+
+ Remarks:
+ This configuration header must not define any prototypes or data
+ definitions (or include any files that do). It only provides macro
+ definitions for build-time configuration options that are not instantiated
+ until used by another MPLAB Harmony module or application.
+
+ Created with MPLAB Harmony Version 1.06
+*******************************************************************************/
+
+// DOM-IGNORE-BEGIN
+/*******************************************************************************
+Copyright (c) 2013-2015 released Microchip Technology Inc. All rights reserved.
+
+Microchip licenses to you the right to use, modify, copy and distribute
+Software only when embedded on a Microchip microcontroller or digital signal
+controller that is integrated into your product or third party product
+(pursuant to the sublicense terms in the accompanying license agreement).
+
+You should refer to the license agreement accompanying this Software for
+additional information regarding your rights and obligations.
+
+SOFTWARE AND DOCUMENTATION ARE PROVIDED AS IS WITHOUT WARRANTY OF ANY KIND,
+EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION, ANY WARRANTY OF
+MERCHANTABILITY, TITLE, NON-INFRINGEMENT AND FITNESS FOR A PARTICULAR PURPOSE.
+IN NO EVENT SHALL MICROCHIP OR ITS LICENSORS BE LIABLE OR OBLIGATED UNDER
+CONTRACT, NEGLIGENCE, STRICT LIABILITY, CONTRIBUTION, BREACH OF WARRANTY, OR
+OTHER LEGAL EQUITABLE THEORY ANY DIRECT OR INDIRECT DAMAGES OR EXPENSES
+INCLUDING BUT NOT LIMITED TO ANY INCIDENTAL, SPECIAL, INDIRECT, PUNITIVE OR
+CONSEQUENTIAL DAMAGES, LOST PROFITS OR LOST DATA, COST OF PROCUREMENT OF
+SUBSTITUTE GOODS, TECHNOLOGY, SERVICES, OR ANY CLAIMS BY THIRD PARTIES
+(INCLUDING BUT NOT LIMITED TO ANY DEFENSE THEREOF), OR OTHER SIMILAR COSTS.
+*******************************************************************************/
+// DOM-IGNORE-END
+
+#ifndef _SYSTEM_CONFIG_H
+#define _SYSTEM_CONFIG_H
+
+/* This is a temporary workaround for an issue with the peripheral library "Exists"
+ functions that causes superfluous warnings. It "nulls" out the definition of
+ The PLIB function attribute that causes the warning. Once that issue has been
+ resolved, this definition should be removed. */
+#define _PLIB_UNSUPPORTED
+
+
+// *****************************************************************************
+// *****************************************************************************
+// Section: Included Files
+// *****************************************************************************
+// *****************************************************************************
+/* This section Includes other configuration headers necessary to completely
+ define this configuration.
+*/
+
+
+// *****************************************************************************
+// *****************************************************************************
+// Section: System Service Configuration
+// *****************************************************************************
+// *****************************************************************************
+
+// *****************************************************************************
+/* Common System Service Configuration Options
+*/
+#define SYS_VERSION_STR "1.06"
+#define SYS_VERSION 10600
+
+// *****************************************************************************
+/* Clock System Service Configuration Options
+*/
+#define SYS_CLK_FREQ 80000000ul
+#define SYS_CLK_BUS_PERIPHERAL_1 40000000ul
+#define SYS_CLK_BUS_PERIPHERAL_3 40000000ul
+#define SYS_CLK_BUS_PERIPHERAL_4 40000000ul
+#define SYS_CLK_BUS_PERIPHERAL_7 80000000ul
+#define SYS_CLK_CONFIG_PRIMARY_XTAL 24000000ul
+#define SYS_CLK_CONFIG_SECONDARY_XTAL 32768ul
+
+/*** Ports System Service Configuration ***/
+
+#define SYS_PORT_B_ANSEL 0x0
+#define SYS_PORT_B_TRIS 0x0
+#define SYS_PORT_B_LAT 0x0
+#define SYS_PORT_B_ODC 0x0
+#define SYS_PORT_B_CNPU 0x0
+#define SYS_PORT_B_CNPD 0x0
+#define SYS_PORT_B_CNEN 0x0
+#define SYS_PORT_C_ANSEL 0x0
+#define SYS_PORT_C_TRIS 0xf000
+#define SYS_PORT_C_LAT 0x0
+#define SYS_PORT_C_ODC 0x0
+#define SYS_PORT_C_CNPU 0x0
+#define SYS_PORT_C_CNPD 0x0
+#define SYS_PORT_C_CNEN 0x0
+
+#define SYS_PORT_D_ANSEL 0x0
+#define SYS_PORT_D_TRIS 0xe3f
+#define SYS_PORT_D_LAT 0x0
+#define SYS_PORT_D_ODC 0x0
+#define SYS_PORT_D_CNPU 0xe3f
+#define SYS_PORT_D_CNPD 0x0
+#define SYS_PORT_D_CNEN 0x0
+
+#define SYS_PORT_E_ANSEL 0x0
+#define SYS_PORT_E_TRIS 0xff
+#define SYS_PORT_E_LAT 0x0
+#define SYS_PORT_E_ODC 0x0
+#define SYS_PORT_E_CNPU 0xff
+#define SYS_PORT_E_CNPD 0x0
+#define SYS_PORT_E_CNEN 0x0
+
+#define SYS_PORT_F_ANSEL 0x0
+#define SYS_PORT_F_TRIS 0x3b
+#define SYS_PORT_F_LAT 0x0
+#define SYS_PORT_F_ODC 0x0
+#define SYS_PORT_F_CNPU 0x3b
+#define SYS_PORT_F_CNPD 0x0
+#define SYS_PORT_F_CNEN 0x0
+
+#define SYS_PORT_G_ANSEL 0x0
+#define SYS_PORT_G_TRIS 0x1c0
+#define SYS_PORT_G_LAT 0x0
+#define SYS_PORT_G_ODC 0x0
+#define SYS_PORT_G_CNPU 0x0
+#define SYS_PORT_G_CNPD 0x0
+#define SYS_PORT_G_CNEN 0x0
+
+
+// *****************************************************************************
+// *****************************************************************************
+// Section: Driver Configuration
+// *****************************************************************************
+// *****************************************************************************
+
+
+// *****************************************************************************
+// *****************************************************************************
+// Section: Middleware & Other Library Configuration
+// *****************************************************************************
+// *****************************************************************************
+
+
+
+
+
+
+
+#endif // _SYSTEM_CONFIG_H
+/*******************************************************************************
+ End of File
+*/
+
diff --git a/firmware/src/system_config/default/system_definitions.h b/firmware/src/system_config/default/system_definitions.h
new file mode 100644
index 0000000..5bc5468
--- /dev/null
+++ b/firmware/src/system_config/default/system_definitions.h
@@ -0,0 +1,119 @@
+/*******************************************************************************
+ System Definitions
+
+ File Name:
+ system_definitions.h
+
+ Summary:
+ MPLAB Harmony project system definitions.
+
+ Description:
+ This file contains the system-wide prototypes and definitions for an MPLAB
+ Harmony project.
+ *******************************************************************************/
+
+//DOM-IGNORE-BEGIN
+/*******************************************************************************
+Copyright (c) 2013-2014 released Microchip Technology Inc. All rights reserved.
+
+Microchip licenses to you the right to use, modify, copy and distribute
+Software only when embedded on a Microchip microcontroller or digital signal
+controller that is integrated into your product or third party product
+(pursuant to the sublicense terms in the accompanying license agreement).
+
+You should refer to the license agreement accompanying this Software for
+additional information regarding your rights and obligations.
+
+SOFTWARE AND DOCUMENTATION ARE PROVIDED AS IS WITHOUT WARRANTY OF ANY KIND,
+EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION, ANY WARRANTY OF
+MERCHANTABILITY, TITLE, NON-INFRINGEMENT AND FITNESS FOR A PARTICULAR PURPOSE.
+IN NO EVENT SHALL MICROCHIP OR ITS LICENSORS BE LIABLE OR OBLIGATED UNDER
+CONTRACT, NEGLIGENCE, STRICT LIABILITY, CONTRIBUTION, BREACH OF WARRANTY, OR
+OTHER LEGAL EQUITABLE THEORY ANY DIRECT OR INDIRECT DAMAGES OR EXPENSES
+INCLUDING BUT NOT LIMITED TO ANY INCIDENTAL, SPECIAL, INDIRECT, PUNITIVE OR
+CONSEQUENTIAL DAMAGES, LOST PROFITS OR LOST DATA, COST OF PROCUREMENT OF
+SUBSTITUTE GOODS, TECHNOLOGY, SERVICES, OR ANY CLAIMS BY THIRD PARTIES
+(INCLUDING BUT NOT LIMITED TO ANY DEFENSE THEREOF), OR OTHER SIMILAR COSTS.
+ *******************************************************************************/
+//DOM-IGNORE-END
+
+#ifndef _SYS_DEFINITIONS_H
+#define _SYS_DEFINITIONS_H
+
+
+// *****************************************************************************
+// *****************************************************************************
+// Section: Included Files
+// *****************************************************************************
+// *****************************************************************************
+
+#include <stdint.h>
+#include <stddef.h>
+#include <stdbool.h>
+#include "system/common/sys_common.h"
+#include "system/common/sys_module.h"
+#include "system/clk/sys_clk.h"
+#include "system/clk/sys_clk_static.h"
+#include "system/devcon/sys_devcon.h"
+#include "system/ports/sys_ports.h"
+
+
+#include "app.h"
+
+
+// DOM-IGNORE-BEGIN
+#ifdef __cplusplus // Provide C++ Compatibility
+
+extern "C" {
+
+#endif
+// DOM-IGNORE-END
+
+// *****************************************************************************
+// *****************************************************************************
+// Section: Type Definitions
+// *****************************************************************************
+// *****************************************************************************
+
+// *****************************************************************************
+/* System Objects
+
+ Summary:
+ Structure holding the system's object handles
+
+ Description:
+ This structure contains the object handles for all objects in the
+ MPLAB Harmony project's system configuration.
+
+ Remarks:
+ These handles are returned from the "Initialize" functions for each module
+ and must be passed into the "Tasks" function for each module.
+*/
+
+typedef struct
+{
+ SYS_MODULE_OBJ sysDevcon;
+
+} SYSTEM_OBJECTS;
+
+
+// *****************************************************************************
+// *****************************************************************************
+// Section: extern declarations
+// *****************************************************************************
+// *****************************************************************************
+
+extern SYSTEM_OBJECTS sysObj;
+
+
+//DOM-IGNORE-BEGIN
+#ifdef __cplusplus
+}
+#endif
+//DOM-IGNORE-END
+
+#endif /* _SYS_DEFINITIONS_H */
+/*******************************************************************************
+ End of File
+*/
+
diff --git a/firmware/src/system_config/default/system_exceptions.c b/firmware/src/system_config/default/system_exceptions.c
new file mode 100644
index 0000000..73a2380
--- /dev/null
+++ b/firmware/src/system_config/default/system_exceptions.c
@@ -0,0 +1,143 @@
+/*******************************************************************************
+ MPLAB Harmony Exceptions Source File
+
+ File Name:
+ system_exceptions.c
+
+ Summary:
+ This file contains a function which overrides the deafult _weak_ exception
+ handler provided by the XC32 compiler.
+
+ Description:
+ This file redefines the default _weak_ exception handler with a more debug
+ friendly one. If an unexpected exception occurs the code will stop in a
+ while(1) loop. The debugger can be halted and two variables _excep_code and
+ _except_addr can be examined to determine the cause and address where the
+ exception occured.
+ *******************************************************************************/
+
+// DOM-IGNORE-BEGIN
+/*******************************************************************************
+Copyright (c) 2013-2015 released Microchip Technology Inc. All rights reserved.
+
+Microchip licenses to you the right to use, modify, copy and distribute
+Software only when embedded on a Microchip microcontroller or digital signal
+controller that is integrated into your product or third party product
+(pursuant to the sublicense terms in the accompanying license agreement).
+
+You should refer to the license agreement accompanying this Software for
+additional information regarding your rights and obligations.
+
+SOFTWARE AND DOCUMENTATION ARE PROVIDED AS IS WITHOUT WARRANTY OF ANY KIND,
+EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION, ANY WARRANTY OF
+MERCHANTABILITY, TITLE, NON-INFRINGEMENT AND FITNESS FOR A PARTICULAR PURPOSE.
+IN NO EVENT SHALL MICROCHIP OR ITS LICENSORS BE LIABLE OR OBLIGATED UNDER
+CONTRACT, NEGLIGENCE, STRICT LIABILITY, CONTRIBUTION, BREACH OF WARRANTY, OR
+OTHER LEGAL EQUITABLE THEORY ANY DIRECT OR INDIRECT DAMAGES OR EXPENSES
+INCLUDING BUT NOT LIMITED TO ANY INCIDENTAL, SPECIAL, INDIRECT, PUNITIVE OR
+CONSEQUENTIAL DAMAGES, LOST PROFITS OR LOST DATA, COST OF PROCUREMENT OF
+SUBSTITUTE GOODS, TECHNOLOGY, SERVICES, OR ANY CLAIMS BY THIRD PARTIES
+(INCLUDING BUT NOT LIMITED TO ANY DEFENSE THEREOF), OR OTHER SIMILAR COSTS.
+ *******************************************************************************/
+// DOM-IGNORE-END
+
+
+#include <xc.h> /* Defines special funciton registers, CP0 regs */
+#include "system_config.h"
+#include "system_definitions.h"
+#include "system/debug/sys_debug.h"
+
+
+// *****************************************************************************
+// *****************************************************************************
+// Section: Global Data Definitions
+// *****************************************************************************
+// *****************************************************************************
+
+/*******************************************************************************
+ Exception Reason Data
+
+ <editor-fold defaultstate="expanded" desc="Exception Reason Data">
+
+ Remarks:
+ These global static items are used instead of local variables in the
+ _general_exception_handler function because the stack may not be available
+ if an exception has occured.
+*/
+
+/* Code identifying the cause of the exception (CP0 Cause register). */
+static unsigned int _excep_code;
+
+/* Address of instruction that caused the exception. */
+static unsigned int _excep_addr;
+
+/* Pointer to the string describing the cause of the exception. */
+static char *_cause_str;
+
+/* Array identifying the cause (indexed by _exception_code). */
+static char *cause[] =
+{
+ "Interrupt",
+ "Undefined",
+ "Undefined",
+ "Undefined",
+ "Load/fetch address error",
+ "Store address error",
+ "Instruction bus error",
+ "Data bus error",
+ "Syscall",
+ "Breakpoint",
+ "Reserved instruction",
+ "Coprocessor unusable",
+ "Arithmetic overflow",
+ "Trap",
+ "Reserved",
+ "Reserved",
+ "Reserved",
+ "Reserved",
+ "Reserved"
+};
+
+// </editor-fold>
+
+
+// *****************************************************************************
+// *****************************************************************************
+// Section: Exception Handling
+// *****************************************************************************
+// *****************************************************************************
+
+/*******************************************************************************
+ Function:
+ void _general_exception_handler ( void )
+
+ Summary:
+ Overrides the XC32 _weak_ _generic_exception_handler.
+
+ Description:
+ This function overrides the XC32 default _weak_ _generic_exception_handler.
+
+ Remarks:
+ Refer to the XC32 User's Guide for additional information.
+ */
+
+void _general_exception_handler ( void )
+{
+ /* Mask off Mask of the ExcCode Field from the Cause Register
+ Refer to the MIPs Software User's manual */
+ _excep_code = (_CP0_GET_CAUSE() & 0x0000007C) >> 2;
+ _excep_addr = _CP0_GET_EPC();
+ _cause_str = cause[_excep_code];
+
+ SYS_DEBUG_PRINT(SYS_ERROR_ERROR, "\nGeneral Exception %s (cause=%d, addr=%x).\n",
+ _cause_str, _excep_code, _excep_addr);
+
+ while (1)
+ {
+ SYS_DEBUG_BreakPoint();
+ }
+}
+
+/*******************************************************************************
+ End of File
+*/
diff --git a/firmware/src/system_config/default/system_init.c b/firmware/src/system_config/default/system_init.c
new file mode 100644
index 0000000..9c69c4e
--- /dev/null
+++ b/firmware/src/system_config/default/system_init.c
@@ -0,0 +1,210 @@
+/*******************************************************************************
+ System Initialization File
+
+ File Name:
+ system_init.c
+
+ Summary:
+ This file contains source code necessary to initialize the system.
+
+ Description:
+ This file contains source code necessary to initialize the system. It
+ implements the "SYS_Initialize" function, defines the configuration bits,
+ and allocates any necessary global system resources, such as the
+ sysObj structure that contains the object handles to all the MPLAB Harmony
+ module objects in the system.
+ *******************************************************************************/
+
+// DOM-IGNORE-BEGIN
+/*******************************************************************************
+Copyright (c) 2013-2015 released Microchip Technology Inc. All rights reserved.
+
+Microchip licenses to you the right to use, modify, copy and distribute
+Software only when embedded on a Microchip microcontroller or digital signal
+controller that is integrated into your product or third party product
+(pursuant to the sublicense terms in the accompanying license agreement).
+
+You should refer to the license agreement accompanying this Software for
+additional information regarding your rights and obligations.
+
+SOFTWARE AND DOCUMENTATION ARE PROVIDED AS IS WITHOUT WARRANTY OF ANY KIND,
+EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION, ANY WARRANTY OF
+MERCHANTABILITY, TITLE, NON-INFRINGEMENT AND FITNESS FOR A PARTICULAR PURPOSE.
+IN NO EVENT SHALL MICROCHIP OR ITS LICENSORS BE LIABLE OR OBLIGATED UNDER
+CONTRACT, NEGLIGENCE, STRICT LIABILITY, CONTRIBUTION, BREACH OF WARRANTY, OR
+OTHER LEGAL EQUITABLE THEORY ANY DIRECT OR INDIRECT DAMAGES OR EXPENSES
+INCLUDING BUT NOT LIMITED TO ANY INCIDENTAL, SPECIAL, INDIRECT, PUNITIVE OR
+CONSEQUENTIAL DAMAGES, LOST PROFITS OR LOST DATA, COST OF PROCUREMENT OF
+SUBSTITUTE GOODS, TECHNOLOGY, SERVICES, OR ANY CLAIMS BY THIRD PARTIES
+(INCLUDING BUT NOT LIMITED TO ANY DEFENSE THEREOF), OR OTHER SIMILAR COSTS.
+ *******************************************************************************/
+// DOM-IGNORE-END
+
+
+// *****************************************************************************
+// *****************************************************************************
+// Section: Included Files
+// *****************************************************************************
+// *****************************************************************************
+
+#include "system_config.h"
+#include "system_definitions.h"
+
+
+// ****************************************************************************
+// ****************************************************************************
+// Section: Configuration Bits
+// ****************************************************************************
+// ****************************************************************************
+// <editor-fold defaultstate="collapsed" desc="Configuration Bits">
+
+/*** DEVCFG0 ***/
+
+#pragma config DEBUG = OFF
+#pragma config JTAGEN = OFF
+#pragma config ICESEL = ICS_PGx1
+#pragma config TRCEN = ON
+#pragma config BOOTISA = MIPS32
+#pragma config FECCCON = OFF_UNLOCKED
+#pragma config FSLEEP = OFF
+#pragma config DBGPER = PG_ALL
+#pragma config EJTAGBEN = NORMAL
+#pragma config CP = OFF
+
+/*** DEVCFG1 ***/
+
+#pragma config FNOSC = SPLL
+#pragma config DMTINTV = WIN_127_128
+#pragma config FSOSCEN = OFF
+#pragma config IESO = ON
+#pragma config POSCMOD = OFF
+#pragma config OSCIOFNC = OFF
+#pragma config FCKSM = CSECME
+#pragma config WDTPS = PS1048576
+#pragma config WDTSPGM = STOP
+#pragma config FWDTEN = OFF
+#pragma config WINDIS = NORMAL
+#pragma config FWDTWINSZ = WINSZ_25
+#pragma config DMTCNT = DMT31
+#pragma config FDMTEN = OFF
+
+/*** DEVCFG2 ***/
+
+#pragma config FPLLIDIV = DIV_1
+#pragma config FPLLRNG = RANGE_5_10_MHZ
+#pragma config FPLLICLK = PLL_FRC
+#pragma config FPLLMULT = MUL_80
+#pragma config FPLLODIV = DIV_8
+#pragma config UPLLFSEL = FREQ_12MHZ
+#pragma config UPLLEN = OFF
+
+/*** DEVCFG3 ***/
+
+#pragma config USERID = 0xffff
+#pragma config FMIIEN = ON
+#pragma config FETHIO = OFF
+#pragma config PGL1WAY = ON
+#pragma config PMDL1WAY = ON
+#pragma config IOL1WAY = ON
+#pragma config FUSBIDIO = OFF
+
+/*** BF1SEQ0 ***/
+
+#pragma config TSEQ = 0xffff
+#pragma config CSEQ = 0xffff
+// </editor-fold>
+
+
+// *****************************************************************************
+// *****************************************************************************
+// Section: Library/Stack Initialization Data
+// *****************************************************************************
+// *****************************************************************************
+
+
+
+// *****************************************************************************
+// *****************************************************************************
+// Section: Driver Initialization Data
+// *****************************************************************************
+// *****************************************************************************
+
+
+// *****************************************************************************
+// *****************************************************************************
+// Section: System Data
+// *****************************************************************************
+// *****************************************************************************
+
+/* Structure to hold the object handles for the modules in the system. */
+SYSTEM_OBJECTS sysObj;
+
+
+// *****************************************************************************
+// *****************************************************************************
+// Section: Module Initialization Data
+// *****************************************************************************
+// *****************************************************************************
+
+/*******************************************************************************
+ Device Control System Service Initialization Data
+
+ <editor-fold defaultstate="collapsed"
+ desc="Device Control System Service Initialization Data">
+*/
+
+const SYS_DEVCON_INIT sysDevconInit =
+{
+ .moduleInit = {0},
+};
+
+// </editor-fold>
+
+
+// *****************************************************************************
+// *****************************************************************************
+// Section: Static Initialization Functions
+// *****************************************************************************
+// *****************************************************************************
+
+
+// *****************************************************************************
+// *****************************************************************************
+// Section: System Initialization
+// *****************************************************************************
+// *****************************************************************************
+
+/*******************************************************************************
+ Function:
+ void SYS_Initialize ( SYS_INIT_DATA *data )
+
+ Summary:
+ Initializes the board, services, drivers, application and other modules.
+
+ Remarks:
+ See prototype in system/common/sys_module.h.
+ */
+
+void SYS_Initialize ( void* data )
+{
+ /* Core Processor Initialization */
+ SYS_CLK_Initialize( NULL );
+ sysObj.sysDevcon = SYS_DEVCON_Initialize(SYS_DEVCON_INDEX_0, (SYS_MODULE_INIT*)&sysDevconInit);
+ SYS_DEVCON_PerformanceConfig(SYS_CLK_SystemFrequencyGet());
+ SYS_PORTS_Initialize();
+
+ /* Initialize Drivers */
+
+ /* Initialize System Services */
+
+ /* Initialize Middleware */
+
+ /* Initialize the Application */
+ APP_Initialize();
+}
+
+
+/*******************************************************************************
+ End of File
+*/
+
diff --git a/firmware/src/system_config/default/system_interrupt.c b/firmware/src/system_config/default/system_interrupt.c
new file mode 100644
index 0000000..a676c11
--- /dev/null
+++ b/firmware/src/system_config/default/system_interrupt.c
@@ -0,0 +1,77 @@
+/*******************************************************************************
+ System Interrupts File
+
+ File Name:
+ system_int.c
+
+ Summary:
+ Raw ISR definitions.
+
+ Description:
+ This file contains a definitions of the raw ISRs required to support the
+ interrupt sub-system.
+
+ Summary:
+ This file contains source code for the interrupt vector functions in the
+ system.
+
+ Description:
+ This file contains source code for the interrupt vector functions in the
+ system. It implements the system and part specific vector "stub" functions
+ from which the individual "Tasks" functions are called for any modules
+ executing interrupt-driven in the MPLAB Harmony system.
+
+ Remarks:
+ This file requires access to the systemObjects global data structure that
+ contains the object handles to all MPLAB Harmony module objects executing
+ interrupt-driven in the system. These handles are passed into the individual
+ module "Tasks" functions to identify the instance of the module to maintain.
+ *******************************************************************************/
+
+// DOM-IGNORE-BEGIN
+/*******************************************************************************
+Copyright (c) 2011-2014 released Microchip Technology Inc. All rights reserved.
+
+Microchip licenses to you the right to use, modify, copy and distribute
+Software only when embedded on a Microchip microcontroller or digital signal
+controller that is integrated into your product or third party product
+(pursuant to the sublicense terms in the accompanying license agreement).
+
+You should refer to the license agreement accompanying this Software for
+additional information regarding your rights and obligations.
+
+SOFTWARE AND DOCUMENTATION ARE PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND,
+EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION, ANY WARRANTY OF
+MERCHANTABILITY, TITLE, NON-INFRINGEMENT AND FITNESS FOR A PARTICULAR PURPOSE.
+IN NO EVENT SHALL MICROCHIP OR ITS LICENSORS BE LIABLE OR OBLIGATED UNDER
+CONTRACT, NEGLIGENCE, STRICT LIABILITY, CONTRIBUTION, BREACH OF WARRANTY, OR
+OTHER LEGAL EQUITABLE THEORY ANY DIRECT OR INDIRECT DAMAGES OR EXPENSES
+INCLUDING BUT NOT LIMITED TO ANY INCIDENTAL, SPECIAL, INDIRECT, PUNITIVE OR
+CONSEQUENTIAL DAMAGES, LOST PROFITS OR LOST DATA, COST OF PROCUREMENT OF
+SUBSTITUTE GOODS, TECHNOLOGY, SERVICES, OR ANY CLAIMS BY THIRD PARTIES
+(INCLUDING BUT NOT LIMITED TO ANY DEFENSE THEREOF), OR OTHER SIMILAR COSTS.
+ *******************************************************************************/
+// DOM-IGNORE-END
+
+
+// *****************************************************************************
+// *****************************************************************************
+// Section: Included Files
+// *****************************************************************************
+// *****************************************************************************
+
+#include <xc.h>
+#include <sys/attribs.h>
+#include "app.h"
+#include "system_definitions.h"
+
+// *****************************************************************************
+// *****************************************************************************
+// Section: System Interrupt Vector Functions
+// *****************************************************************************
+// *****************************************************************************
+
+/*******************************************************************************
+ End of File
+*/
+
diff --git a/firmware/src/system_config/default/system_tasks.c b/firmware/src/system_config/default/system_tasks.c
new file mode 100644
index 0000000..14c834d
--- /dev/null
+++ b/firmware/src/system_config/default/system_tasks.c
@@ -0,0 +1,91 @@
+/*******************************************************************************
+ System Tasks File
+
+ File Name:
+ system_tasks.c
+
+ Summary:
+ This file contains source code necessary to maintain system's polled state
+ machines.
+
+ Description:
+ This file contains source code necessary to maintain system's polled state
+ machines. It implements the "SYS_Tasks" function that calls the individual
+ "Tasks" functions for all polled MPLAB Harmony modules in the system.
+
+ Remarks:
+ This file requires access to the systemObjects global data structure that
+ contains the object handles to all MPLAB Harmony module objects executing
+ polled in the system. These handles are passed into the individual module
+ "Tasks" functions to identify the instance of the module to maintain.
+ *******************************************************************************/
+
+// DOM-IGNORE-BEGIN
+/*******************************************************************************
+Copyright (c) 2013-2015 released Microchip Technology Inc. All rights reserved.
+
+Microchip licenses to you the right to use, modify, copy and distribute
+Software only when embedded on a Microchip microcontroller or digital signal
+controller that is integrated into your product or third party product
+(pursuant to the sublicense terms in the accompanying license agreement).
+
+You should refer to the license agreement accompanying this Software for
+additional information regarding your rights and obligations.
+
+SOFTWARE AND DOCUMENTATION ARE PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND,
+EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION, ANY WARRANTY OF
+MERCHANTABILITY, TITLE, NON-INFRINGEMENT AND FITNESS FOR A PARTICULAR PURPOSE.
+IN NO EVENT SHALL MICROCHIP OR ITS LICENSORS BE LIABLE OR OBLIGATED UNDER
+CONTRACT, NEGLIGENCE, STRICT LIABILITY, CONTRIBUTION, BREACH OF WARRANTY, OR
+OTHER LEGAL EQUITABLE THEORY ANY DIRECT OR INDIRECT DAMAGES OR EXPENSES
+INCLUDING BUT NOT LIMITED TO ANY INCIDENTAL, SPECIAL, INDIRECT, PUNITIVE OR
+CONSEQUENTIAL DAMAGES, LOST PROFITS OR LOST DATA, COST OF PROCUREMENT OF
+SUBSTITUTE GOODS, TECHNOLOGY, SERVICES, OR ANY CLAIMS BY THIRD PARTIES
+(INCLUDING BUT NOT LIMITED TO ANY DEFENSE THEREOF), OR OTHER SIMILAR COSTS.
+ *******************************************************************************/
+// DOM-IGNORE-END
+
+
+// *****************************************************************************
+// *****************************************************************************
+// Section: Included Files
+// *****************************************************************************
+// *****************************************************************************
+
+#include "system_config.h"
+#include "system_definitions.h"
+
+
+// *****************************************************************************
+// *****************************************************************************
+// Section: System "Tasks" Routine
+// *****************************************************************************
+// *****************************************************************************
+
+/*******************************************************************************
+ Function:
+ void SYS_Tasks ( void )
+
+ Remarks:
+ See prototype in system/common/sys_module.h.
+*/
+
+void SYS_Tasks ( void )
+{
+ /* Maintain system services */
+ SYS_DEVCON_Tasks(sysObj.sysDevcon);
+
+ /* Maintain Device Drivers */
+
+ /* Maintain Middleware & Other Libraries */
+
+
+ /* Maintain the application's state machine. */
+ APP_Tasks();
+}
+
+
+/*******************************************************************************
+ End of File
+ */
+
diff --git a/firmware/src/t6963c_specific.c b/firmware/src/t6963c_specific.c
new file mode 100644
index 0000000..6d1b183
--- /dev/null
+++ b/firmware/src/t6963c_specific.c
@@ -0,0 +1,40 @@
+/**
+ * C library for interfacing a T6963C display with a PIC microcontroller
+ * Copyright (C) 2015 Camil Staps <info@camilstaps.nl>
+
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+ */
+
+#include <p32xxxx.h>
+#include "t6963c_specific.h"
+#include "system_config.h"
+
+inline void t6963c_initTimer(void) {
+}
+
+inline void t6963c_startTimer(void) {
+ T2CON = NULL;
+ PR2 = 0xffff;
+ TMR2 = NULL;
+ T2CONSET = 0xa000;
+}
+
+inline unsigned short t6963c_getTimeNs(void) {
+ return TMR2 * t6963c_nspertick;
+}
+
+inline void t6963c_stopTimer(void) {
+ T2CONCLR = 0xa000;
+}
diff --git a/firmware/src/t6963c_specific.h b/firmware/src/t6963c_specific.h
new file mode 100644
index 0000000..12be1f7
--- /dev/null
+++ b/firmware/src/t6963c_specific.h
@@ -0,0 +1,68 @@
+/**
+ * C library for interfacing a T6963C display with a PIC microcontroller
+ * Copyright (C) 2015 Camil Staps <info@camilstaps.nl>
+
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ *******************************************************************************
+ *
+ * File: t6963c_specific.h
+ * Author: Camil Staps
+ *
+ * Example of what you could put in a t6963c_specific.h.
+ */
+
+#ifndef T6963C_SPECIFIC_H
+#define T6963C_SPECIFIC_H
+
+#include <p32xxxx.h>
+
+#define t6963c_rst LATBbits.LATB12 // RESET line
+#define t6963c_cd LATBbits.LATB8 // C/D line
+#define t6963c_ce LATBbits.LATB9 // CE line
+#define t6963c_rd LATBbits.LATB10 // RD line
+#define t6963c_wr LATBbits.LATB11 // WR line
+#define t6963c_t_rst TRISBbits.TRISB12 // TRIS bit of RESET pin
+#define t6963c_t_cd TRISBbits.TRISB8 // TRIS bit of C/D pin
+#define t6963c_t_ce TRISBbits.TRISB9 // TRIS bit of CE pin
+#define t6963c_t_rd TRISBbits.TRISB10 // TRIS bit of RD pin
+#define t6963c_t_wr TRISBbits.TRISB11 // TRIS bit of WR pin
+#define t6963c_data LATB // Data port (the lowest 8 bits are assumed)
+#define t6963c_t_data TRISB // TRIS register of data port
+
+#define t6963c_rows 16 // Number of rows of the LCD
+#define t6963c_columns 40 // Number of columns of the LCD
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+#define t6963c_nspertick 25
+
+/**
+ * Define the project-specific timer functions here
+ * @see t6963c.h
+ */
+inline void t6963c_initTimer(void);
+inline void t6963c_startTimer(void);
+inline unsigned short t6963c_getTimeNs(void);
+inline void t6963c_stopTimer(void);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* T6963C_SPECIFIC_H */
+