BkkCoins,
Are you sure the firmware can handle everything ok? It only has 1Kbytes of SRAM.
I'm about to order boards for the Quarter Stick DIY and I wanted to make sure.
thanks.
I believe so. Work so far indicates that it will be very close with a work queue of 4 items (192 bytes), and a 108 byte buffer for pushing work. So if it gets too tight for that I may have to drop to only 2 work items queued. Compiled with the USB stack it's using about half the RAM, without my code and work queue, (and 727 bytes with my code but no push buffer yet), but I also think that could be optimized and reduced a some if really need be (the stack seems a little bloated in C instead of assembly. I can't fathom why they didn't do it in assembly for something that could be included in every PIC - though maybe they expect their users to optimize their own versions). By slowing down the push-work a bit with a buffer switch mid-way, I could cut 48 bytes and keep the queue at 4 but I haven't gone over everything looking to optimize RAM.
Also, I haven't tried the Pro XC-8 yet. Apparently it cuts down a lot of code space, though whether it can get much better at RAM use is questionable. I'll have a better estimate later this afternoon after I integrate in the "push work" assembly code. I'd code everything in assembler before giving up.
An output queue also reduces the work required by the miner dramatically.
The BFL SC code we wrote has an independent thread that simply checks for results and times those checks to attempt to minimise the polling - this makes the process of getting results optimal in the extreme.
If we know the queue is 2 (or 4 or 8 ) in size then we know we only have to poll at most twice per expected result (or even less if the time per result is less than 100ms) to ensure work is getting returned and the queue isn't filling up
If, on the other hand, there is no queue, then we need to poll as required to avoid losing results and to keep synchronisation - and 'as required' can be good or bad depending on how the output works.