As I understood from some Q&A sessions (see this and this), unit tests should be written by developers.
At my previous workplace we tried to give this task to a QA Engine
There's a subtle but important difference between the intent of unit tests and QA tests: QA testing validates functionality; unit testing validates design. That is, the outer view contrasted with the inner view of the product.
QA people are unfamiliar with the internal design of the product, which is intentional because they have to mimic the user's perspective. Developers, on the other hand, know intimately the inner workings and it is to them a mechanism to validate design would be meaningful, if at all.
Hence, it is absolutely natural that developers not the QA folks write unit tests.