Well I'm at a stage where poclbm mines but all shares are rejected so i must be doing something wrong.
I want to be sure I'm sending the correct data to your opencl kernel but unsure which parts of the state, state2 and f arrays poclbm generates i should be sending as what variable. In particular I'm referring as to what i should supply for "data16", "data17" & "data18".
Are you calculating mid state in python anywhere?
I think a couple of code snippets will make it more clear..
in Switch.decode:
binary_data = block_header.decode('hex')
job.headerX = binary_data[:76]
job.dataX = unpack('<19I', job.headerX)
in OpenCLMiner.mining_thread:
state = skeinhashmid(pack('>16I', *work.dataX[:16]))
for i in xrange(8):
self.kernel.set_arg(i, state[i * 8:i * 8 + 8])
for i in range(16, 19):
self.kernel.set_arg(i - 8, pack('>I', work.dataX[i]))
I do not use poclbm's engine to recalculate the merkle tree, just always use full getwork as it has arrived from the server. Probably it does not play well with stratum, but works to some extent.
skeinhashmid is a ctypes wrapper for skein calculation in shared lib, I believe I have posted the C function for that somewhere below the kernel itself.
I won't lie, this is still a struggle for me but I don't expect to be drip fed bits of code until it works. I'm doing this to learn and I'm certainly achieving that so thank you