Start using pdata area for less-frequently used data sn1-flight1
authorKeith Packard <keithp@keithp.com>
Sun, 19 Apr 2009 06:19:24 +0000 (23:19 -0700)
committerKeith Packard <keithp@keithp.com>
Sun, 19 Apr 2009 06:19:24 +0000 (23:19 -0700)
ao_dbg.c
ao_ee.c
ao_report.c
ao_timer.c

index f7b292f3f08bf65765e5e8006d45f700f70fea3b..f493acc5949b74729e5ce583615266cf808340f3 100644 (file)
--- a/ao_dbg.c
+++ b/ao_dbg.c
@@ -106,7 +106,7 @@ __xdata uint8_t save_dpl1;
 __xdata uint8_t save_dph1;
 
 static uint8_t
 __xdata uint8_t save_dph1;
 
 static uint8_t
-ao_dbg_inst1(uint8_t a)
+ao_dbg_inst1(uint8_t a) __reentrant
 {
        ao_dbg_send_byte(DEBUG_INSTR(1));
        ao_dbg_send_byte(a);
 {
        ao_dbg_send_byte(DEBUG_INSTR(1));
        ao_dbg_send_byte(a);
@@ -114,7 +114,7 @@ ao_dbg_inst1(uint8_t a)
 }
 
 static uint8_t
 }
 
 static uint8_t
-ao_dbg_inst2(uint8_t a, uint8_t b)
+ao_dbg_inst2(uint8_t a, uint8_t b) __reentrant
 {
        ao_dbg_send_byte(DEBUG_INSTR(2));
        ao_dbg_send_byte(a);
 {
        ao_dbg_send_byte(DEBUG_INSTR(2));
        ao_dbg_send_byte(a);
@@ -123,7 +123,7 @@ ao_dbg_inst2(uint8_t a, uint8_t b)
 }
 
 static uint8_t
 }
 
 static uint8_t
-ao_dbg_inst3(uint8_t a, uint8_t b, uint8_t c)
+ao_dbg_inst3(uint8_t a, uint8_t b, uint8_t c) __reentrant
 {
        ao_dbg_send_byte(DEBUG_INSTR(3));
        ao_dbg_send_byte(a);
 {
        ao_dbg_send_byte(DEBUG_INSTR(3));
        ao_dbg_send_byte(a);
diff --git a/ao_ee.c b/ao_ee.c
index 8dbb5e8368f02db1d75103ccde3f46a5364cccb6..ea127c12e4a6cb917de7f7e50ac9f79153c7db92 100644 (file)
--- a/ao_ee.c
+++ b/ao_ee.c
@@ -170,9 +170,9 @@ ao_ee_wrsr(uint8_t status)
 
 #define EE_BLOCK_NONE  0xffff
 
 
 #define EE_BLOCK_NONE  0xffff
 
-__xdata uint8_t ao_ee_data[EE_BLOCK];
-__data uint16_t ao_ee_block = EE_BLOCK_NONE;
-__data uint8_t ao_ee_block_dirty;
+static __xdata uint8_t ao_ee_data[EE_BLOCK];
+static __pdata uint16_t ao_ee_block = EE_BLOCK_NONE;
+static __pdata uint8_t ao_ee_block_dirty;
 
 /* Write the current block to the EEPROM */
 static void
 
 /* Write the current block to the EEPROM */
 static void
index 2c4554b5bcebd7a25ac0f26c4852fa80b8f8c957..cee2bf3a1d58cd6dc955bbda0ff6a949c929000c 100644 (file)
@@ -82,5 +82,5 @@ static __xdata struct ao_task ao_report_task;
 void
 ao_report_init(void)
 {
 void
 ao_report_init(void)
 {
-       ao_add_task(&ao_report_task, ao_report);
+       ao_add_task(&ao_report_task, ao_report, "report");
 }
 }
index 2bd47af1417dd9de3d4090bbc9200e4475110407..8b485cc26f5568efdb97647c8445adbb947f0399 100644 (file)
@@ -21,7 +21,7 @@ static volatile __data uint16_t ao_tick_count;
 
 uint16_t ao_time(void)
 {
 
 uint16_t ao_time(void)
 {
-       __data uint16_t ret;
+       uint16_t ret;
        __critical {
                ret = ao_tick_count;
        }
        __critical {
                ret = ao_tick_count;
        }