Ignore:
Timestamp:
Apr 5, 2019, 9:26:53 PM (5 years ago)
Author:
coas-nagasima
Message:

mbed関連を更新
シリアルドライバをmbedのHALを使うよう変更
ファイルディスクリプタの処理を更新

Location:
asp3_tinet_ecnl_arm/trunk/asp3_dcre/mbed/targets/TARGET_RENESAS/TARGET_RZA1XX
Files:
1 added
1 copied

Legend:

Unmodified
Added
Removed
  • asp3_tinet_ecnl_arm/trunk/asp3_dcre/mbed/targets/TARGET_RENESAS/TARGET_RZA1XX/i2c_api.c

    r373 r374  
    1818#include "i2c_api.h"
    1919#include "cmsis.h"
    20 #include "pinmap.h"
     20#include "PeripheralPins.h"
    2121#include "r_typedefs.h"
    2222
    23 #include "riic_iodefine.h"
     23#include "iodefine.h"
    2424#include "RZ_A1_Init.h"
    25 #include "MBRZA1H.h"
    2625
    2726volatile struct st_riic *RIIC[] = RIIC_ADDRESS_LIST;
     
    6160
    6261#define WAIT_TIMEOUT    (3600000)  /* Loop counter : Time-out is about 1s. By 3600000 loops, measured value is 969ms. */
    63 
    64 static const PinMap PinMap_I2C_SDA[] = {
    65     {P1_1 , I2C_0, 1},
    66     {P1_3 , I2C_1, 1},
    67     {P1_7 , I2C_3, 1},
    68     {NC   , NC   , 0}
    69 };
    70 
    71 static const PinMap PinMap_I2C_SCL[] = {
    72     {P1_0 , I2C_0, 1},
    73     {P1_2 , I2C_1, 1},
    74     {P1_6 , I2C_3, 1},
    75     {NC   , NC,    0}
    76 };
    7762
    7863static inline int i2c_status(i2c_t *obj) {
     
    221206    }
    222207    dummy = CPGSTBCR9;
     208    (void)dummy;
    223209}
    224210
     
    415401    int status;
    416402    int value;
    417     volatile uint32_t work_reg = 0;
    418403
    419404    i2c_set_MR3_ACK(obj);
     
    10631048            InterruptHandlerRegister(irqTable[i], handlerTable[i]);
    10641049            GIC_SetPriority(irqTable[i], 5);
     1050            if (i == 1) {
     1051                GIC_SetConfiguration(irqTable[i], 3);
     1052            } else {
     1053                GIC_SetConfiguration(irqTable[i], 1);
     1054            }
    10651055            GIC_EnableIRQ(irqTable[i]);
    10661056        } else {
Note: See TracChangeset for help on using the changeset viewer.