Forum Discussion
Altera_Forum
Honored Contributor
21 years ago_regs.h files...
Hi All, I wondering how I want to access my custom hardware and create this _regs.h file. For information, my custom hardware using 128-bit Avalon bus and I need 128-bit register as the interfa...
Altera_Forum
Honored Contributor
21 years agothank you buddy.. but i'm still confuse.. what did you mean with 4 write? isn't the timing for avalon slave change to 4 inside the Component Editor?
so the example become like this... # define IORD_ALTERA_AVALON_PWM_CLOCK_DIVIDER(base) IORD(base, 0) # define IOWR_ALTERA_AVALON_PWM_CLOCK_DIVIDER(base, data) IOWR(base, 0, data)# define ALTERA_AVALON_PWM_CLOCK_DIVIDER_MSK (0xFFFFFFFF)# define ALTERA_AVALON_PWM_CLOCK_DIVIDER_OFST (0) # define IORD_ALTERA_AVALON_PWM_DUTY_CYCLE(base) IORD(base, 4) # define IOWR_ALTERA_AVALON_PWM_DUTY_CYCLE(base, data) IOWR(base, 4, data)# define ALTERA_AVALON_PWM_DUTY_CYCLE_MSK (0xFFFFFFFF)# define ALTERA_AVALON_PWM_DUTY_CYCLE_OFST (0)