使用条形码自动对实验室试管进行分类。

博客分类:条形码   .NET

2025/07/02

现代医疗和研究实验室每天都要处理成百上千份生物样本。管理试管流不仅需要效率,还需要最大限度地减少分类和处理每个阶段的错误。在这种情况下,基于条形码技术的自动化对于提高工作流程的效率、准确性和安全性至关重要。



自动化分拣的原理和步骤

试管的自动化分拣基于机器视觉和条形码识别技术。所有试管在制备阶段均贴有独立的GS1条形码,其中包含生物材料类型、患者信息、所需分析及其他相关信息。系统的主要原理:

自动化阶段:




技术的关键任务和挑战

自动试管分拣是一项创新解决方案,可显著简化和加快实验室流程。尽管优势显而易见,但此类技术的实施仍面临着许多重要的任务和挑战。

关键任务:

挑战:




软件条形码扫描器的作用。

软件条形码扫描器在自动化中占据核心地位。其算法旨在:

例如:专用算法能够读取圆柱形表面上的条形码,快速处理多个试管(批量扫描),并与实验室的会计和分拣系统集成。

实施的实际优势:




结论

基于条形码的自动试管分拣不仅是一项技术创新,更是现代实验室物流的成熟基础,确保了高度的安全性、准确性和效率。软件扫描器是这一自动化的核心,使实验室能够满足未来的需求。

VintaSoft Barcode .NET SDK 是实验室中使用条形码进行自动试管分拣的最佳解决方案之一,因为该 SDK:

以下是一段 C# 代码,演示了如何识别实验室试管图像中的 GS1-128 条形码:
/// <summary>
/// Reads GS1-128 barcodes from a <see cref="System.Drawing.Bitmap"/>.
/// </summary>
/// <param name="bitmap">A bitmap with barcodes.</param>
public static void ReadGS1_128BarcodesFromBitmap(System.Drawing.Bitmap bitmap)
{
    // create barcode reader
    using (Vintasoft.Barcode.BarcodeReader reader = new Vintasoft.Barcode.BarcodeReader())
    {
        // specify that reader must search for GS1-128 barcodes
        reader.Settings.ScanBarcodeTypes = BarcodeType.None;
        reader.Settings.ScanBarcodeSubsets.Add(BarcodeSymbologySubsets.GS1_128);

        // read barcodes from image
        Vintasoft.Barcode.IBarcodeInfo[] infos = Vintasoft.Barcode.GdiExtensions.ReadBarcodes(reader, bitmap);

        // gets a GS1 Application identifiers from barcode value
        GS1ApplicationIdentifierValue[] aiValues = ((GS1BarcodeInfo)infos[0]).ApplicationIdentifierValues;

        StringBuilder printableValue = new StringBuilder();

        // print Application identifiers values
        for (int i = 0; i < aiValues.Length; i++)
        {
            GS1ApplicationIdentifierValue aiValue = aiValues[i];
            GS1ApplicationIdentifier ai = aiValue.ApplicationIdentifier;
            Console.WriteLine(string.Format("[{0}] {1}", i + 1, aiValue));
            Console.WriteLine(string.Format("Application identifier   : {0}", ai.ApplicationIdentifier));
            Console.WriteLine(string.Format("Value                    : {0}", aiValue.Value));
            Console.WriteLine(string.Format("Data title               : {0}", ai.DataTitle));
            Console.WriteLine(string.Format("Data content             : {0}", ai.DataContent));
            Console.WriteLine(string.Format("Format                   : {0}", ai.Format));
            Console.WriteLine(string.Format("Is contains decimal point: {0}", ai.IsContainsDecimalPoint));
            Console.WriteLine(string.Format("Is variable length       : {0}", ai.IsVariableLength));
            Console.WriteLine();
            printableValue.Append(aiValue.ToString());
        }

        // print GS1 printable value
        Console.WriteLine("Printable GS1 value: " + printableValue.ToString());
    }
}