diff --git a/trunk/config.h b/trunk/config.h index 985cec1..656cd5a 100644 --- a/trunk/config.h +++ b/trunk/config.h @@ -17,12 +17,12 @@ //#define _PARRADIUM_ //#define _MODEL_TEG2_ - // ↑TEG2 CPU + Type-T + // ↑TEG2 CPU + Type-T //#define _MODEL_WM0_ -//#define _MODEL_TS0_ - // ↑TEG2 CPU + Type-C -#define _MODEL_CTR_TS_ - // ↑FINAL SoC + Type-C +#define _MODEL_TS0_ + // ↑TEG2 CPU + Type-C +//#define _MODEL_CTR_TS_ + // ↑FINAL SoC + Type-C //#define _MODEL_CTR_JIKKI_ diff --git a/trunk/i2c_mcu.c b/trunk/i2c_mcu.c index df7e302..fe45b74 100644 --- a/trunk/i2c_mcu.c +++ b/trunk/i2c_mcu.c @@ -72,6 +72,10 @@ u8 iic_send_wo_dma_len; u8 iic_mcu_bus_status; // 一文字リードの時はデータを返す。 // ステータスが必要ならこっちを呼んで +void nop8() +{ +} + /* ======================================================== @@ -401,7 +405,9 @@ __interrupt void int_dma1( ) ST0 = 0x0004; SOE0 = 0; // 受信の時はもっと前に「も」設定してる。(NACK出力) SO0 = 0x0000 | TAUS_MASK; // SCL - NOP( ); + nop8(); +/* + NOP( ); NOP( ); NOP( ); NOP( ); @@ -412,7 +418,10 @@ __interrupt void int_dma1( ) NOP( ); NOP( ); #endif +*/ SO0 = 0x0400 | TAUS_MASK; // SCL + nop8(); +/* NOP( ); NOP( ); NOP( ); @@ -424,6 +433,7 @@ __interrupt void int_dma1( ) NOP( ); NOP( ); #endif +*/ SO0 = 0x0404 | TAUS_MASK; } IICMK10 = 1; @@ -456,6 +466,8 @@ __interrupt void int_iic10( ) ST0 = 0x0004; SOE0 = 0; // 受信の時はもっと前に「も」設定してる。(NACK出力) SO0 = 0x0000 | TAUS_MASK; // SCL + nop8(); +/* NOP( ); NOP( ); NOP( ); @@ -467,7 +479,10 @@ __interrupt void int_iic10( ) NOP( ); NOP( ); #endif +*/ SO0 = 0x0400 | TAUS_MASK; // SCL + nop8(); +/* NOP( ); NOP( ); NOP( ); @@ -479,6 +494,7 @@ __interrupt void int_iic10( ) NOP( ); NOP( ); #endif +*/ SO0 = 0x0404 | TAUS_MASK; } iic_mcu_wo_dma = 0; @@ -539,10 +555,12 @@ static err iic_mcu_send_a_byte( u8 dat ) static void iic_mcu_send_st( ) { SO0 &= ~0x0004; // SDA - NOP( ); - NOP( ); - NOP( ); - NOP( ); + nop8(); +/* + NOP( ); + NOP( ); + NOP( ); + NOP( ); #ifdef _OVERCLOCK_ NOP( ); NOP( ); @@ -550,6 +568,7 @@ static void iic_mcu_send_st( ) NOP( ); NOP( ); #endif +*/ SO0 &= ~0x0400; // SCL SOE0 = 0x0004; // ハード制御へ @@ -566,10 +585,12 @@ static void iic_mcu_send_re_st( ) { ST0 |= 0x0004; SO0 |= 0x0400 | TAUS_MASK; // ( SDA = H ), SCL -> H - NOP( ); - NOP( ); - NOP( ); - NOP( ); + nop8(); +/* + NOP( ); + NOP( ); + NOP( ); + NOP( ); #ifdef _OVERCLOCK_ NOP( ); NOP( ); @@ -577,11 +598,14 @@ static void iic_mcu_send_re_st( ) NOP( ); NOP( ); #endif +*/ SOE0 &= ~0x0004; // ( SCL = H ), SDA -> L - NOP( ); - NOP( ); - NOP( ); - NOP( ); + nop8(); +/* + NOP( ); + NOP( ); + NOP( ); + NOP( ); #ifdef _OVERCLOCK_ NOP( ); NOP( ); @@ -589,6 +613,7 @@ static void iic_mcu_send_re_st( ) NOP( ); NOP( ); #endif +*/ iic_mcu_send_st( ); } @@ -603,10 +628,12 @@ static void iic_mcu_send_sp( ) ST0 = 0x0004; SOE0 = 0; // 受信の時はもっと前に「も」設定してる。(NACK出力) SO0 = 0x0000 | TAUS_MASK; // SCL - NOP( ); - NOP( ); - NOP( ); - NOP( ); + nop8(); +/* + NOP( ); + NOP( ); + NOP( ); + NOP( ); #ifdef _OVERCLOCK_ NOP( ); NOP( ); @@ -614,11 +641,14 @@ static void iic_mcu_send_sp( ) NOP( ); NOP( ); #endif +*/ SO0 = 0x0400 | TAUS_MASK; // SCL - NOP( ); - NOP( ); - NOP( ); - NOP( ); + nop8(); +/* + NOP( ); + NOP( ); + NOP( ); + NOP( ); #ifdef _OVERCLOCK_ NOP( ); NOP( ); @@ -626,6 +656,7 @@ static void iic_mcu_send_sp( ) NOP( ); NOP( ); #endif +*/ SO0 = 0x0404 | TAUS_MASK; } @@ -643,10 +674,12 @@ void iic_mcu_start( ) DEN1 = 0; I2C_PU = 1; SAU0EN = 1; - NOP( ); // 4clkあける - NOP( ); - NOP( ); - NOP( ); + nop8(); +/* + NOP( ); + NOP( ); + NOP( ); + NOP( ); #ifdef _OVERCLOCK_ NOP( ); NOP( ); @@ -654,6 +687,7 @@ void iic_mcu_start( ) NOP( ); NOP( ); #endif +*/ SPS0 = 0x0000; // シリアルユニットのクロック0。(8M/2)/1 SMR02 = bSMR0n_FIXEDBIT | bMD0n2; // 簡易I2Cに設定 #ifdef _OVERCLOCK_ diff --git a/trunk/pm.c b/trunk/pm.c index 357bcf5..d8be15b 100644 --- a/trunk/pm.c +++ b/trunk/pm.c @@ -217,6 +217,7 @@ u8 blset; 起動失敗であれば電源が落ちる 別のタスクで電源落ちは監視していて、ステータスもクリアする ======================================================== */ +// BSR // err PM_LCD_on( ) { u8 rv; @@ -254,7 +255,7 @@ err PM_LCD_on( ) return ( rv ); } - +// BSR // void PM_LCD_off() { SND_DEPOP_ACT; diff --git a/trunk/user_define.h b/trunk/user_define.h index 1a689be..7bb5a5b 100644 --- a/trunk/user_define.h +++ b/trunk/user_define.h @@ -119,8 +119,8 @@ // INTP6 #ifndef _MODEL_CTR_ -#define SND_DEPOP_ACT P7.5 = 1 -#define SND_DEPOP_DEACT P7.5 = 0 +#define SND_DEPOP_ACT P7.6 = 1 +#define SND_DEPOP_DEACT P7.6 = 0 #else #define SND_DEPOP_ACT ; #define SND_DEPOP_DEACT ;