Posted by Yash I think P6 Data register and control register addresses are swapped. Regards, Yash /************************************************************/ #define P6CR (*(volatile char *)(0xffe9)) int userdelay = 10; void dummy (void) void somewhere (int x) void sleep (int delay) while (1) /************************************************************/
![]()
on July 31, 2003, 9:42:13, in reply to "why it don't work"
203.124.158.130
Hi,
Can you try following LED Blinking program ? It works on EVB3644F.
#define P6DR (*(volatile char *)(0xffd9))
int count = 0;
{
}
{
count += x;
}
{
int i,j;
for (j = 0; j < 1000; j++)
for (i=0; i<delay; i++)
dummy();
}
void main (void)
{
int i, j =0;
P6CR |= 0x01; /* Set bit 0 for output */
{
somewhere (j++);
for (i = 0; i < 10; i++)
{
/* Toggle the light */
P6DR ^= 0x01;
sleep (userdelay);
}
}
}
--Previous Message--
: it is my fist program with a hitachi
: h8/3644 and i want to turn on an off
: a pair of led.
: but it don't work and i think it is
: well done.
: #include <inh8.h>
: #include <ioh83644.h>
: #pragma language=extended
: sfr PC6 = 0xffffffD9;
: sfr PORT6 = 0xffffffE9;
: void main()
: {
: char tope;
: char i;
: set_interrupt_mask (2);
: PC6 = 0X03;
: tope=1000;
:
: PORT6 = 1;
:
: for (i=0;i<tope;i++);
: PORT6 = 2;
:
: for (i=0;i<tope;i++);
: PORT6 = 3;
: }
: can someone tell me what is the
: problem?
: thank, merci, danke , gracias
:
Message Thread
![]()
« Back to index
Evaluation Kit Support
Renesas Evaluation Boards are intended for evaluation of Renesas microprocessors only, not as development tools.