Tough question. Seems like the real issue here is what are you being compensated for? And what value are you providing? I find it best when those two are aligned closely.
tl;dr: I think your best bet is to bill hourly regardless of outcome, but clearly define how much of your time they're willing to pay for per board.
I'm a huge advocate for hourly billing, because with that the first question is easy to answer - you're being compensated for your time.
That said, in your case it may be very advantageous to be compensated for the quantity of boards you process. Then an increase of productivity means increased profits.
On the client side of things, it seems like the value to them is known working boards. It's better for them if the count of those boards is high (start with 100 boards, have 95 known to be working at the end).
[I'm inferring a few things here. Since you seem confident that some boards won't have any issues, some will be repairable, and some won't, I'm guessing that the company has a set of boards where the quality is in question. From that, the value to them is - even if it's a smaller group in the end - knowing the quality of each board.]
I believe you'll see the best outcome when what you're selling (charging for) matches the value the client gets - in this case it seems like a per board kind of model might work.
However, you have value concerns about that:
but what if I spend hours troubleshooting and can't find the problem, or worse yet: There is no problem
If the troubleshooting / repair is a very repeatable and consistent process, then you could charge per board. But if not, that's a huge risk to you.
You could modify the per board pricing a bit, and charge for 'good' boards - that would allow you to skip any boards that look to be too time consuming (based on the per board charge). But that doesn't align well with what the client seems to be looking for.
You could charge per board, and be very clear that you'll spend some maximum of time per board before moving on to the next one (translates into what the client is willing to pay to salvage a board). So the client will know that there are potentially
repairable boards in the
Once you're done with your first pass, any leftover time could be used on the most likely repairable boards:
(max_time * total_boards) - time_spent
You could just charge for you time, which is probabbly what I'd do. The client wants to know the boards are either good (possibly repaired) or bad. That takes time - and based on your question, potentially a large variance in that time.
The key is translating the value for your client into time. You can still have a maximum time per board (so the client isn't concerned about an invoice for far more than the value of a working board), and still use the leftover time after a first pass.
But since you've mapped a relationship between the value and the compensation, you can better invoice the client in those decisions. If 90% of the boards are working after the first pass, and you've taken 50% of the time they're willing to pay for - do they really want to spend (potentially) the other 50% of the budget on that last 10%?
Of course in this case - as with most - transparent communication is critical.