跳至主要內容
Knowledgebase
Home
Renesas Electronics Taiwan - Knowledgebase

Do I need to make some settings as though pin control is possible?

Latest Updated:08/08/2013

Question:

The hardware manual makes it seem as though independent pin control is possible, but I get an error. Or do I need to make some settings somewhere or does some code need to be "included"?

Answer:

It is possible to use RL78/G13 ports as independent pins. However, please note that although port numbers such as P0 and P13 are defined by a device file, they not are defined up to bit position. Therefore, it is necessary to describe them in the following format.

"Port number" + "." + "bit number"

For example, the assembler statement and C statement for setting bit 0 of P0 to 1 are as follows.

SET1 P0.0        ; Assembler statement example

P0.0 = 1;         // C statement example

Suitable Products
RL78 Family