changeset 1:e4e662746c02

init2
author heinrichsweikamp
date Wed, 24 Apr 2013 19:39:39 +0200
parents 11d4fc797f74
children ab8a7c3f1db0
files .hgignore doc/how_to_setup_mplabx.txt src/18F87K22_ostc3.lkr src/aa_fonts.asm src/icons.asm src/ostc3.asm tools/crop_ostc3_hex.bat
diffstat 7 files changed, 43 insertions(+), 31 deletions(-) [+]
line wrap: on
line diff
--- a/.hgignore	Wed Apr 24 19:22:45 2013 +0200
+++ b/.hgignore	Wed Apr 24 19:39:39 2013 +0200
@@ -0,0 +1,3 @@
+syntax: glob
+ostc3.X/*
+tools/o3_tiny.hex
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/doc/how_to_setup_mplabx.txt	Wed Apr 24 19:39:39 2013 +0200
@@ -0,0 +1,11 @@
+How to setup MPLAB X IDE:
+- Clone repository to local dir
+- Create new project
+- Choose PIC18F87K22
+- Choose C18 Toolchain (v3.42 or above)
+- Add Files:
+	.asm to Source Files
+	.c to Source Files
+	p2_definitions.h and shared_definitions.h to Header Files
+	.inc to Important Files
+	18F87K22_ostc3.lkr to Linker Files
\ No newline at end of file
--- a/src/18F87K22_ostc3.lkr	Wed Apr 24 19:22:45 2013 +0200
+++ b/src/18F87K22_ostc3.lkr	Wed Apr 24 19:39:39 2013 +0200
@@ -7,7 +7,6 @@
 
 // General PROM code area
 CODEPAGE   NAME=page       START=0x0            END=0x1DCFF
-CODEPAGE   NAME=boot       START=0x1E000        END=0x1FFFF
 
 // Special area reserved for tables. Just to make sure the linker won't
 // relocate something at the end of the bühlmann text table...
--- a/src/aa_fonts.asm	Wed Apr 24 19:22:45 2013 +0200
+++ b/src/aa_fonts.asm	Wed Apr 24 19:39:39 2013 +0200
@@ -39,8 +39,8 @@
 			DB	'¿'-aa_font16_firstChar     ; replace by ¿ when unknown.
 			DB	aa_font16_height + 0x80
 ;
-#include	"../OSTC3/Fonts/aa_font16_idx.inc"				; SHOULD FOLLOW !
-#include	"../OSTC3/Fonts/aa_font16.inc"
+#include	"../src/Fonts/aa_font16_idx.inc"				; SHOULD FOLLOW !
+#include	"../src/Fonts/aa_font16.inc"
 aa_font16_end:
 ; Make sure this is coherent...
 	if aa_font16_nbbits != 3
@@ -76,8 +76,8 @@
 			DB	0x83-aa_font28_firstChar; replace by ¤ when unknown.
 			DB	aa_font28_height + 0x80
 ;
-#include	"../OSTC3/Fonts/aa_font28_idx.inc"				; SHOULD FOLLOW !
-#include	"../OSTC3/Fonts/aa_font28.inc"
+#include	"../src/Fonts/aa_font28_idx.inc"				; SHOULD FOLLOW !
+#include	"../src/Fonts/aa_font28.inc"
 aa_font28_end:
 ; Make sure this is coherent...
 	if aa_font28_nbbits != 3
@@ -116,8 +116,8 @@
 			DB	0x87-aa_font34_firstChar; replace by ¤ when unknown.
 			DB	aa_font34_height + 0x80
 ;
-#include	"../OSTC3/Fonts/aa_font34_idx.inc"				; SHOULD FOLLOW !
-#include	"../OSTC3/Fonts/aa_font34.inc"
+#include	"../src/Fonts/aa_font34_idx.inc"				; SHOULD FOLLOW !
+#include	"../src/Fonts/aa_font34.inc"
 aa_font36_end:
 ; Make sure this is coherent...
 	if aa_font34_nbbits != 3
@@ -138,8 +138,8 @@
 			DB	0x3E-aa_font48_firstChar
 			DB	aa_font48_height + 0x80		; AA flag.
 ;
-#include	"../OSTC3/Fonts/aa_font48_idx.inc"
-#include	"../OSTC3/Fonts/aa_font48.inc"
+#include	"../src/Fonts/aa_font48_idx.inc"
+#include	"../src/Fonts/aa_font48.inc"
 aa_font48_end:
 ; Make sure this is coherent...
 	if aa_font48_nbbits != 3
@@ -158,8 +158,8 @@
 			DB	0x2F-aa_font90_firstChar
 			DB	aa_font90_height + 0x80		; AA flag.
 ;
-#include	"../OSTC3/Fonts/aa_font90_idx.inc"
-#include	"../OSTC3/Fonts/aa_font90.inc"
+#include	"../src/Fonts/aa_font90_idx.inc"
+#include	"../src/Fonts/aa_font90.inc"
 aa_font90_end:
 ; Make sure this is coherent...
 	if aa_font90_nbbits != 3
--- a/src/icons.asm	Wed Apr 24 19:22:45 2013 +0200
+++ b/src/icons.asm	Wed Apr 24 19:39:39 2013 +0200
@@ -13,12 +13,12 @@
 
 ; Dive mode warning icon
 	global	dive_warning_block
-#include "../OSTC3/Icons/dive_warning.inc"	;45x39 px
+#include "../src/Icons/dive_warning.inc"	;45x39 px
 ; small warning icon
 ;	global	warning_block
-;#include "../OSTC3/Icons/warning.inc"       ;25x22 px
+;#include "../src/Icons/warning.inc"       ;25x22 px
 	global	ostc3_logo_block
 ; OSTC3 scribble
-#include "../OSTC3/Icons/ostc3_logo.inc"    ;220x61 px
+#include "../src/Icons/ostc3_logo.inc"    ;220x61 px
 
         END
--- a/src/ostc3.asm	Wed Apr 24 19:22:45 2013 +0200
+++ b/src/ostc3.asm	Wed Apr 24 19:39:39 2013 +0200
@@ -12,23 +12,22 @@
 #include "ostc3.inc"
 
 ;=============================================================================
-;
 ;----------------------------- CONFIG ---------------------------------
-;    CONFIG	RETEN = OFF          ;Disabled - Controlled by SRETEN bit
-;    CONFIG	SOSCSEL = HIGH       ;High Power SOSC circuit selected
-;    CONFIG XINST = OFF          ;Code won't excute in extended mode...
-;    CONFIG	FOSC = INTIO2        ;Internal RC oscillator, no clock-out
-;    CONFIG	PLLCFG = OFF
-;    CONFIG	IESO = OFF           ;Disabled
-;    CONFIG	PWRTEN = OFF         ;Disabled, because incompatible with ICD3 (Ri-400)
-;    CONFIG	BOREN = ON           ;Controlled with SBOREN bit
-;    CONFIG	BORV = 2             ;2.0V
-;    CONFIG	BORPWR = MEDIUM      ;BORMV set to medium power level
-;    CONFIG	WDTEN = ON           ;WDT controlled by SWDTEN bit setting
-;    CONFIG	WDTPS = 128          ;1:128
-;    CONFIG	RTCOSC = SOSCREF     ;RTCC uses SOSC
-;    CONFIG	MCLRE = ON           ;MCLR Enabled, RG5 Disabled
-;    CONFIG	CCP2MX = PORTBE      ;RE7-Microcontroller Mode/RB3-All other modes
+    CONFIG	RETEN = OFF          ;Disabled - Controlled by SRETEN bit
+    CONFIG	SOSCSEL = HIGH       ;High Power SOSC circuit selected
+    CONFIG XINST = OFF          ;Code won't excute in extended mode...
+    CONFIG	FOSC = INTIO2        ;Internal RC oscillator, no clock-out
+    CONFIG	PLLCFG = OFF
+    CONFIG	IESO = OFF           ;Disabled
+    CONFIG	PWRTEN = OFF         ;Disabled, because incompatible with ICD3 (Ri-400)
+    CONFIG	BOREN = ON           ;Controlled with SBOREN bit
+    CONFIG	BORV = 2             ;2.0V
+    CONFIG	BORPWR = MEDIUM      ;BORMV set to medium power level
+    CONFIG	WDTEN = ON           ;WDT controlled by SWDTEN bit setting
+    CONFIG	WDTPS = 128          ;1:128
+    CONFIG	RTCOSC = SOSCREF     ;RTCC uses SOSC
+    CONFIG	MCLRE = ON           ;MCLR Enabled, RG5 Disabled
+    CONFIG	CCP2MX = PORTBE      ;RE7-Microcontroller Mode/RB3-All other modes
 ;=============================================================================
 boot    CODE
     global init_ostc3
--- a/tools/crop_ostc3_hex.bat	Wed Apr 24 19:22:45 2013 +0200
+++ b/tools/crop_ostc3_hex.bat	Wed Apr 24 19:39:39 2013 +0200
@@ -1,3 +1,3 @@
 :: Crops hex file from MPLAP X to work with Tinybld
 :: Downloaded from http://srecord.sourceforge.net/download.html
-srec_cat ../ostc3_code.X/dist/default/production/ostc3_code.X.production.hex -intel -crop 0x00000 0x1E000 -o o3_tiny.hex -intel
\ No newline at end of file
+srec_cat ../ostc3.X/dist/default/production/ostc3.X.production.hex -intel -crop 0x00000 0x1E000 -o o3_tiny.hex -intel
\ No newline at end of file