RL78G23 128pin Fast Prototyping Board - renesas/Arduino GitHub Wiki

RL78/G23-128p Fast Prototyping Board

Description

  • The RL78/G23-128p Fast Prototyping Board is provided with interface pins for Arduino Uno conversion.

1. pinlist

  • A pin list of the RL78/G23-128p Fast Prototyping Board is shown below.
RL78/G23-128p port Number Pin Name Arduino Pin Number(Digital IO) Arduino Uno I/F MCU header Pmod I/F Grove I/F Analog IO PWM(β€»4) Serial Wire SPI Interrupt Tone PulseIn ShiftIn ShiftOut Servo Stepper LED User Switch
P33 0 0 〇 - - - - - RxDA1 - - - - 〇 〇 〇 〇 〇 - -
P34 1 1 〇 - - - - - TxDA1 - - - - 〇 〇 〇 〇 〇 - -
P145 ~2 2 〇 - - - - TAU0 - - - - 〇 〇 〇 〇 〇 〇 - -
P106 ~3 3 〇 - - - - TAU1 - - - - 〇 〇 〇 〇 〇 〇 - -
P105 ~4 4 〇 - - - - TAU1 - - - - 〇 〇 〇 〇 〇 〇 - -
P104 ~5 5 〇 - - - - TAU1 - - - - 〇 〇 〇 〇 〇 〇 - -
P103 ~6 6 〇 - - - - TAU1 - - - - 〇 〇 〇 〇 〇 〇 - -
P46 ~7 7 〇 - - - - TAU0 - - - 0 〇 〇 〇 〇 〇 〇 - -
P42 ~8 8 〇 - - - - TAU0 - - - - 〇 〇 〇 〇 〇 〇 - -
P31 ~9 9 〇 - - - - TAU0 - - - 1 〇 〇 〇 〇 〇 〇 - -
P64 10 10 〇 - - - - - - - - - 〇 〇 〇 〇 〇 〇 - -
P65 ~11 11 〇 - - - - TAU1 - - - - 〇 〇 〇 〇 〇 〇 - -
P66 ~12 12 〇 - - - - TAU1 - - - - 〇 〇 〇 〇 〇 〇 - -
P67 ~13 13 〇 - - - - TAU1 - - - - 〇 〇 〇 〇 〇 〇 - -
P144 14 14 〇 - 〇 - - - TxD3 - MOSI - - 〇 〇 〇 〇 〇 - -
P143 15 15 〇 - 〇 - - - RxD3 - MISO - - 〇 〇 〇 〇 〇 - -
P02 16 16 〇 - 〇 - - - TxD1 - - - - 〇 〇 〇 〇 〇 - -
P03 17 17 〇 - 〇 - - - RxD1 - - - - 〇 〇 〇 〇 〇 - -
P13 18 18 〇 - 〇 - - - TxD2 - - - - 〇 〇 〇 〇 〇 - -
P14 19 19 〇 - - 〇 - - RxD2 SDA2 - - - 〇 〇 〇 〇 〇 - -
P61 20/SDA 20 〇 - - 〇 - - - SDA0 - - - 〇 〇 - - - - -
P60 21/SCL 21 〇 - - 〇 - - - SCL0 - - - 〇 〇 - - - - -
P40 - 22 - 〇 - - - - - - - - - - - - - - - -
P80 - 23 - 〇 - - - - - - - - - 〇 〇 〇 〇 〇 - -
P05 - 24 - 〇 - - - - - - - - - - - - - - - -
P81 - 25 - 〇 - - - - - - - - - 〇 〇 〇 〇 〇 - -
P82 - 26 - 〇 - - - - - - - - - 〇 〇 〇 〇 〇 - -
P85 - 27 - 〇 - - - - - - - - - 〇 〇 〇 〇 〇 - -
P86 - 28 - 〇 - - - - - - - - - 〇 〇 〇 〇 〇 - -
P87 - 29 - 〇 - - - - - - - - - 〇 〇 〇 〇 〇 - -
P30 - 30 - 〇 - - - - - - - - - - - - - - - -
P50 - 31 - 〇 - - - - - - - - - 〇 〇 〇 〇 〇 LED1 -
P51 - 32 - 〇 - - - - - - - - - 〇 〇 〇 〇 〇 LED2 -
P52 - 33 - 〇 - - - - - - - - - 〇 〇 〇 〇 〇 - -
P53 - 34 - 〇 - - - - - - - - - 〇 〇 〇 〇 〇 - -
P54 - 35 - 〇 - - - - - - - - - 〇 〇 〇 〇 〇 - -
P55 - 36 - 〇 - - - - - - - - - 〇 〇 〇 〇 〇 - -
P56 - 37 - 〇 - - - - - - - - - 〇 〇 〇 〇 〇 - -
P57 - 38 - 〇 - - - - - - - - - 〇 〇 〇 〇 〇 - -
P17 - 39 - 〇 - - - - - - - - - 〇 〇 〇 〇 〇 - -
P12 - 40 - 〇 - - - - TxD0 - - - - 〇 〇 〇 〇 〇 - -
P11 - 41 - 〇 - - - - RxD0 - - - - 〇 〇 〇 〇 〇 - -
P10 - 42 - 〇 - - - - - - - - - 〇 〇 〇 〇 〇 - -
P90 - 43 - 〇 - - - - - - - - - 〇 〇 〇 〇 〇 - -
P91 - 44 - 〇 - - - - - - - - - 〇 〇 〇 〇 〇 - -
P92 - 45 - 〇 - - - - - - - - - 〇 〇 〇 〇 〇 - -
P93 - 46 - 〇 - - - - - - - - - 〇 〇 〇 〇 〇 - -
P94 - 47 - 〇 - - - - - - - - - 〇 〇 〇 〇 〇 - -
P97 - 48 - 〇 - - - - - - - - - 〇 〇 〇 〇 〇 - -
P112 - 49 - 〇 - - - - - - - - - 〇 〇 〇 〇 〇 - -
P113 - 50 - 〇 - - - - - - - - - 〇 〇 〇 〇 〇 - -
P114 - 51 - 〇 - - - - - - - - - 〇 〇 〇 〇 〇 - -
P101 - 52 - 〇 - - - - - - - - - 〇 〇 〇 〇 〇 - -
P111 - 53 - 〇 - - - - - - - - - 〇 〇 〇 〇 〇 - -
P146 - 54 - 〇 - - - - - - - - - 〇 〇 〇 〇 〇 - -
P23 - 55 - 〇 - - - - - - - - - 〇 〇 〇 〇 〇 - -
P22 - 56 - 〇 - - - - - - - - - 〇 〇 〇 〇 〇 - -
P21 - 57 - 〇 - - - - - - - - - - - - - - - -
P130(β€»2) - 58 - 〇 - - - - - - - - - - - 〇 〇 〇 - -
P102 - 59 - 〇 - - - - - - - - - 〇 〇 〇 〇 〇 - -
P06 - 60 - 〇 - - - - - - - - - - - - - - - -
P137(β€»3) - 61 - 〇 - - - - - - - 2 - 〇 〇 - - - - SW1
P70 - 62 - 〇 - - - - - - - - - 〇 〇 〇 〇 〇 - -
P71 - 63 - 〇 - - - - - - - - - 〇 〇 〇 〇 〇 - -
P72 - 64 - 〇 - - - - - - - - - 〇 〇 〇 〇 〇 - -
P73 - 65 - 〇 - - - - - - - - - 〇 〇 〇 〇 〇 - -
P74 - 66 - 〇 - - - - - - - 3 - 〇 〇 〇 〇 〇 - -
P75 - 67 - 〇 - - - - - - - 4 - 〇 〇 〇 〇 〇 - -
P76 - 68 - 〇 - - - - - - - 5 - 〇 〇 〇 〇 〇 - -
P77 - 69 - 〇 - - - - - - - 6 - 〇 〇 〇 〇 〇 - -
P121 - 70 - 〇 - - - - - - - - - 〇 〇 〇 〇 〇 - -
P122 - 71 - 〇 - - - - - - - - - 〇 〇 〇 〇 〇 - -
P123 - 72 - 〇 - - - - - - - - - - - - - - - -
P124 - 73 - 〇 - - - - - - - - - - - - - - - -
P125 - 74 - 〇 - - - - - - - - - 〇 〇 〇 〇 〇 - -
P126 - 75 - 〇 - - - - - - - - - 〇 〇 〇 〇 〇 - -
P127 - 76 - 〇 - - - - - - - - - 〇 〇 〇 〇 〇 - -
P41 - 77 - 〇 - - - - - - - - - 〇 〇 〇 〇 〇 - -
P45 - 78 - 〇 - - - - - - - - - 〇 〇 〇 〇 〇 - -
P32 - 79 - 〇 - - - - - - - - - 〇 〇 〇 〇 〇 - -
P35 - 80 - 〇 - - - - - - - - - 〇 〇 〇 〇 〇 - -
P36 - 81 - 〇 - - - - - - - - - 〇 〇 〇 〇 〇 - -
P37 - 82 - 〇 - - - - - - - - - 〇 〇 〇 〇 〇 - -
P120 - 83 - 〇 - - - - - - - - - 〇 〇 〇 〇 〇 - -
P01 - 84 - 〇 - - - - - - - - - 〇 〇 〇 〇 〇 - -
P141 - 85 - - 〇 - - - - - SS - - 〇 〇 〇 〇 〇 - -
P142 - 86 - - 〇 - - - - - SCK - - 〇 〇 〇 〇 〇 - -
P140 - 87 - - 〇 - - - - - - 7 - 〇 〇 〇 〇 〇 - -
P00 - 88 - - 〇 - - - - - - - - 〇 〇 〇 〇 〇 - -
P16 - 89 - - 〇 - - - - - - 8 - 〇 〇 〇 〇 〇 - -
P62 - 90 - - 〇 - - - - SCL1 - - - 〇 〇 - - - - -
P63 - 91 - - 〇 - - - - SDA1 - - - 〇 〇 - - - - -
P47 - 92 - - 〇 - - - - - - - - 〇 〇 〇 〇 〇 - -
P110 - 93 - - 〇 - - - - - - - - 〇 〇 〇 〇 〇 - -
P04 - 94 - - 〇 - - - - - - - - 〇 〇 〇 〇 〇 - -
P07 - 95 - - 〇 - - - - - - - - 〇 〇 〇 〇 〇 - -
P15 - 96 - - - 〇 - - - SCL2 - - - 〇 〇 〇 〇 〇 - -
P43 - 97 - - - 〇 - - - SCL3 - - - 〇 〇 〇 〇 〇 - -
P44 - 98 - - - 〇 - - - SDA3 - - - 〇 〇 〇 〇 〇 - -
P95 - 99 - - - 〇 - - - SCL4 - - - 〇 〇 〇 〇 〇 - -
P96 - 100 - - - 〇 - - - SDA4 - - - 〇 〇 〇 〇 〇 - -
P84 - 101 - - - 〇 - - RxDA0 - - - - 〇 〇 〇 〇 〇 - -
P83 - 102 - - - 〇 - - TxDA0 - - - - 〇 〇 〇 〇 〇 - -
P115 A0 103 〇 - - - A0 - - - - - - 〇 〇 〇 〇 〇 - -
P116 A1 104 〇 - - - A1 - - - - - - 〇 〇 〇 〇 〇 - -
P117 A2 105 〇 - - - A2 - - - - - - 〇 〇 〇 〇 〇 - -
P147 A3 106 〇 - - - A3 - - - - - - 〇 〇 〇 〇 〇 - -
P100 A4 107 〇 - - - A4 - - - - - - 〇 〇 〇 〇 〇 - -
P156 A5 108 〇 - - - A5 - - - - - - 〇 〇 〇 〇 〇 - -
P155 A6 109 〇 - - - A6 - - - - - - 〇 〇 〇 〇 〇 - -
P154 A7 110 〇 - - - A7 - - - - - - 〇 〇 〇 〇 〇 - -
P153 A8 111 〇 - - - A8 - - - - - - 〇 〇 〇 〇 〇 - -
P152 A9 112 〇 - - - A9 - - - - - - 〇 〇 〇 〇 〇 - -
P151 A10 113 〇 - - - A10 - - - - - - 〇 〇 〇 〇 〇 - -
P150 A11 114 〇 - - - A11 - - - - - - 〇 〇 〇 〇 〇 - -
P27 A12 115 〇 - - - A12 - - - - - - 〇 〇 〇 〇 〇 - -
P26 A13 116 〇 - - - A13 - - - - - - 〇 〇 〇 〇 〇 - -
P25 A14 117 〇 - - - A14 - - - - - - 〇 〇 〇 〇 〇 - -
P24 A15 118 〇 - - - A15 - - - - - - 〇 〇 〇 〇 〇 - -
- EVDD(IOREF) - 〇 - - - - - - - - - - - - - - - - -
- RESET - 〇 - - - - - - - - - - - - - - - - -
- 3V3 - 〇 - - - - - - - - - - - - - - - - -
- 5V - 〇 - - - - - - - - - - - - - - - - -
- GND - 〇 - - - - - - - - - - - - - - - - -
P20(β€»1) AREF - 〇 - - - - - - - - - - - - - - - - -
  • (β€»1) External reference voltage supply pin.
  • (β€»2) Pin 58 (P130) is an output-only port, so the INPUT setting cannot be used.
  • (β€»3) Pin 61 (P137) is an input-only port, so the OUTPUT setting cannot be used.
  • (β€»4) Pin 10 cannot be used when outputting PWM from TAU1.

2. Functions

  • The functions of the RL78/G23-128p Fast Prototyping Board are listed below.
No. Name Function
1 Digital IO 111 Digital input pins / 93 Digital input_pullup pins / 107 Digital output pins
2 Analog IO 16 Analog input pins
3 PWM 11 PWM output pins(β€»6)(β€»7)
4 Serial(UART) 6 Serial(UART) channels(β€»1)(β€»2)(β€»3)(β€»4)(β€»5)
5 SoftwareSerial 9 RX pins / 107 TX pins
6 Wire(I2C) 5 Wire(I2C) channels(β€»2)(β€»3)(β€»4)
7 SPI 1 SPI channel(β€»5)
8 Interrupt 9 Interrupt pins
9 Tone 12 Tone output pins(β€»6)(β€»8)
10 PulseIn 111 Pulse input pins
11 ShiftIn 107 Clock output pins / 111 Data input pins
12 ShiftOut 107 Clock output pins / 107 Data output pins
13 Servo 107 Servo output pins(β€»7)(β€»8)
14 Stepper 107 Stepper output pins
15 LED 2 on Board LED (pin 31 and pin 32)(β€»9)
16 User Switch 1 on Board User Switch (pin 61)(β€»10)
  • (β€»1) Serial(RxD0, TxD0) connects to a Micro-USB connector via a USB-serial converter.

  • (β€»2) Serial cannot be used simultaneously with the Wire3 channel.

  • (β€»3) Serial2 cannot be used simultaneously with the Wire2 channel.

  • (β€»4) Serial3 cannot be used simultaneously with the Wire4 channel.

  • (β€»5) Serial4 cannot be used simultaneously with the SPI channel.

  • (β€»6) Simultaneous use of PWM/Tone between pins using the same TAU terminal is not possible.

  • (β€»7) If there are more than 25 pins using Servo, simultaneous use of PWM using Servo/TAU0 pins not possible.

  • (β€»8) If there are more than 25 pins using Servo, simultaneous use of Servo/Tone using pin 2 is not possible.

  • (β€»9) LED1 (pin 31) and LED2 (pin 32) are pulled up on the circuit.

  • (β€»10) User Switch (pin 61) is pulled up on the circuit.

  • Refer to the following link for reference on the various functions.

  • Arduino Reference - Arduino Reference

2-1. Digital IO

  • The RL78/G23-128p Fast Prototyping Board has 111 Digital input pins and 93 Digital input_pullup pins and 107 Digital output pins.
  • When using digital IO, pinMode() must first be called to set the specified pin to operate as an input or output.

    1. Using pin 2 as an input.
   pinMode(2,INPUT);
   val = digitalRead(2);
    1. Using pin 3 as an input_pullup.
   pinMode(3,INPUT_PULLUP);
   val = digitalRead(3);
    1. Using pin 4 as an output.
   pinMode(4,OUTPUT);
   digitailWrite(4,HIGH);
  • The pins corresponding to digital I/O are as follows.
Digital input pin Digital input_pullup pin Digital output pin memo
0-21, 23, 25-29, 31-56, 59, 61-71, 74-118 0-19, 23, 25-29, 31-54, 59, 62-71, 74-89, 92-107 0-19, 23, 25-29, 31-56, 58, 59, 62-71, 74-89, 92-118 -

2-2. Analog IO(Analog Input)

  • The RL78/G23-128p Fast Prototyping Board has 16 analog input pins.
  • Analog input signals are A/D converted and the resulting digital values are returned.
  • To use analog input, use analogRead() to specify the analog pin name and read the data.
  • The reference voltage used for analog input is 5V by default. When analogReference(INTERNAL) is called, the reference voltage is the internal reference voltage (1.48V).

  • Use A0 pin
val =analogRead(A0);
  • The pins corresponding to analog input are as follows.
analog input pin memo
A0-A15 -

2-3. PWM

  • The RL78/G23-128p Fast Prototyping Board has 11 PWM output pins.
  • To use PWM output, use analogWrite() to specify the pin name and duty, and generate PWM output.
  • To change the PWM output pulse frequency, use analogWriteFrequency() to set the frequency, then use analogWrite() to generate PWM output.
  • The pins corresponding to PWM output are as follows.
PWM output pin memo
2-9, 11-13 -

2-4. Serial(UART)

  • The RL78/G23-128p Fast Prototyping Board has 6 serial (UART) channels.
  • The default transmit buffer size when using each channel is 256 bytes.
  • The default receive buffer size when using each channel is 256 bytes.
  • The pin assignments of the channels are as follows.
Channel Transmit pin Receive pin memo
Serial 40 41 Serial cannot be used simultaneously with the Wire3 channel. Connect to Micro USB port via USB-Serial Converter when J17 is open-circuit.
Serial1 1 0 -
Serial2 18 19 Serial2 cannot be used simultaneously with the Wire2 channel.
Serial3 16 17 Serial3 cannot be used simultaneously with the Wire4 channel.
Serial4 14 15 Serial4 cannot be used simultaneously with the SPI channel.
Serial5 102 101 Connected to Grove5 I/F.

2-5. SoftwareSerial

  • The RL78/G23-128p Fast Prototyping Board has 9 RX pins and 107 TX pins for SoftwareSerial.
  • The pins corresponding to SoftwareSerial are listed below.
RX pin TX pin memo
7, 9, 61, 66-69, 87, 89 0-19, 23, 25-29, 31-56, 58, 59, 62-71, 74-89, 92-118 -

2-6. Wire(I2C)

  • The RL78/G23-128p Fast Prototyping Board has 5 wire (I2C) channels.
  • The pin assignments of the channels are as follows.
Channel Data pin Clock pin memo
Wire 20(SDA) 21(SCL) -
Wire1 91 90 Connected to Pmod2 I/F.
Wire2 19 96 Connected to Grove2 I/F. Serial2 cannot be used simultaneously with the Wire2 channel.
Wire3 98 97 Connected to Grove3 I/F. Serial cannot be used simultaneously with the Wire3 channel.
Wire4 100 99 Connected to Grove4 I/F. Serial3 cannot be used simultaneously with the Wire4 channel.

2-7. SPI

  • The RL78/G23-128p Fast Prototyping Board has one SPI channel.
  • The pin assignment of the channel is as follows.
Channel Chip Select pin Data out pin Data in pin Clock pin memo
SPI 85 14 15 86 Connected to Pmod1 I/F. Serial4 cannot be used simultaneously with the SPI channel.

2-8. Interrupt

  • The RL78/G23-128p Fast Prototyping Board has 9 external interrupt pins.
  • The correspondences between external interrupt numbers and pins are as follows.
Interrupt No. Interrupt pin memo
0 7 -
1 9 -
2 61(SW) -
3 66 -
4 67 -
5 68 -
6 69 -
7 87 -
8 89 -

2-9. Tone

  • The RL78/G23-128p Fast Prototyping Board has 12 tone output pins.
  • The correspondences between tone outputs and pins are as follows.
Tone output pin memo
2-13 -

2-10. PulseIn

  • The RL78/G23-128p Fast Prototyping Board has 111 pulse input pins corresponding to pulseIn().
  • The pins corresponding to pulseIn() are as follows.
Pulse input pin memo
0-21, 23, 25-29, 31-56, 59, 61-71, 74-118 -

2-11. ShiftIn

  • The RL78/G23-128p Fast Prototyping Board has 107 clock output pins and 111 data input pins corresponding to shiftIn().
  • The pins corresponding to shiftIn() are as follows.
Clock pin Data pin memo
0-19, 23, 25-29, 31-56, 58, 59, 62-71, 74-89, 92-118 0-21, 23, 25-29, 31-56, 59, 61-71, 74-118 -

2-12. ShiftOut

  • The RL78/G23-128p Fast Prototyping Board has 107 clock output pins and 107 data output pins corresponding to shiftOut().
  • The pins corresponding to shiftOut() are as follows.
Clock pin Data pin memo
0-19, 23, 25-29, 31-56, 58, 59, 62-71, 74-89, 92-118 0-19, 23, 25-29, 31-56, 58, 59, 62-71, 74-89, 92-118 -

2-13. Servo

  • The RL78/G23-128p Fast Prototyping Board has 107 Servo output pins.
  • The correspondences between Servo output pins are as follows.
Servo output pin memo
0-19, 23, 25-29, 31-56, 58, 59, 62-71, 74-89, 92-118 -

2-14. Stepper

  • The RL78/G23-128p Fast Prototyping Board has 107 Stepper output pins.
  • The correspondences between Stepper output pins are as follows.
Stepper output pin memo
0-19, 23, 25-29, 31-56, 58, 59, 62-71, 74-89, 92-118 -

2-15. LED

  • The RL78/G23-128p Fast Prototyping Board has two LEDs mounted on it.
  • The pins connected to the LEDs are as follows.
Name pin memo
LED1 31 -
LED2 32 -

2-16. User Switch

  • The RL78/G23-128p Fast Prototyping Board has one user switch.
  • The pin connected to the user switch is as follows.
Name pin memo
SW1 61 -
⚠️ **GitHub.com Fallback** ⚠️