new fifoInternalSend too buggy.

Post Reply
z.g
Posts: 22
Joined: Thu Dec 18, 2008 8:33 pm

new fifoInternalSend too buggy.

Post by z.g » Thu Jun 04, 2009 5:47 pm

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.

z.g
Posts: 22
Joined: Thu Dec 18, 2008 8:33 pm

Post by z.g » Thu Jun 04, 2009 10:49 pm

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?

WinterMute
Site Admin
Posts: 2060
Joined: Tue Aug 09, 2005 3:21 am
Location: UK
Contact:

Re: new fifoInternalSend too buggy.

Post by WinterMute » Sun Jun 07, 2009 1:59 am

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.
Help keep devkitPro toolchains free, Donate today

Personal Blog

z.g
Posts: 22
Joined: Thu Dec 18, 2008 8:33 pm

Re: new fifoInternalSend too buggy.

Post by z.g » Sun Jun 07, 2009 2:23 am

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);
…

Post Reply

Who is online

Users browsing this forum: No registered users and 8 guests