Nios® V/II Embedded Design Suite (EDS)
Support for Embedded Development Tools, Processors (SoCs and Nios® V/II processor), Embedded Development Suites (EDSs), Boot and Configuration, Operating Systems, C and C++
12612 Discussions

Help with Interval timer connected to 3 nios ii processors

Altera_Forum
Honored Contributor II
1,058 Views

Hi, 

 

I currently have 3 nios ii processors, all with their own memory peripherals but connected to the same interval timer(should each processor have its own interval timer?). The timer slave is connected to each of the processor's data and instruction masters but I'm not sure how I can correctly use the timer in my application. I currently just want to send a certain number of characters and see how many seconds it's taking to transmit those characters over the uarts. Any help is appreciated.
0 Kudos
3 Replies
Altera_Forum
Honored Contributor II
321 Views

Timers are so small I recommend using one for each CPU. That said it depends on how you use them whether sharing them would cause a problem. If you didn't use them as a timer in the BSP settings and you just took snapshots of them only from all three processors that should work although you might see some weird glitches if multiple processors attempted to take a snapshot at the same time. As soon as you use them as a timer in your BSP (system timer for example) then you would run into issues because you would have multiple timer drivers attempting to service the same interrupt which would be a nightmare.

0 Kudos
Altera_Forum
Honored Contributor II
321 Views

Thank you for the reply. I've added one timer for each cpu and will be setting the timestamp driver in BSP settings and testing it using its functions.

0 Kudos
Altera_Forum
Honored Contributor II
321 Views

That should work much better. If you were setting the timestamp driver in all three projects to the same hardware I know that would have been problematic.

0 Kudos
Reply