Page 1 of 1
new fifoInternalSend too buggy.
Posted: Thu Jun 04, 2009 5:47 pm
by z.g
the new implementation of 'fifoInternalSend' has serios bugs.
1. in case then 'fifoInternalSend' called and 'fifo_send_queue' not empty, firstword didnt' go to queue.
2. in case then 'fifo_send_queue' is empty and hardware fifo buffer have space only for part of data the rest of data goes to 'fifo_send_queue' but 'fifo_send_queue.head' dont' update and this rest never sended to another cpu.
Posted: Thu Jun 04, 2009 10:49 pm
by z.g
patch
submitted.
another problem.
FIFO_CHANNEL_BITS now defined as 3, so maximem possible chanels — 8. why in fifocommon.h defined FIFO_USER_0* if they cant' be used?
Re: new fifoInternalSend too buggy.
Posted: Sun Jun 07, 2009 1:59 am
by WinterMute
You caught me releasing half finished code :p I was kind of hoping nobody would notice that until I got a chance to do some more testing.
The FIFO_CHANNEL_BITS thing was something else I was testing and forgot to revert before commit, sorry about that.
Have a look at the code I just submitted to SVN, it should be relatively sane now but needs a bit more testing. So far I've found it difficult to actually drop through into the buffered code in practice - the data gets pulled out of the FIFO pretty quickly on the other side.
Re: new fifoInternalSend too buggy.
Posted: Sun Jun 07, 2009 2:23 am
by z.g
WinterMute wrote:So far I've found it difficult to actually drop through into the buffered code in practice - the data gets pulled out of the FIFO pretty quickly on the other side.
very easy:
Code: Select all
void vBlank()
{
static u32 vBlankCounter=0;
if(vBlankCounter++>30)
{
vBlankCounter=0;
swiDelay(1000000);
}
}
…
irqSet(IRQ_VBLANK,vBlank);
…