dmtxread and dmtxwrite are a command line interface for libdmtx. They can be used to create Data Matrix barcodes and extract the content.