• 大小: 251KB
    文件类型: .rar
    金币: 1
    下载: 0 次
    发布日期: 2021-05-14
  • 语言: 其他
  • 标签:

资源简介

CL3000是基恩士推出的同轴激光位移传感器。 相对于旧有型号的H025,H028红色点激光来说,还是有其优势的。具体可以参考使用手册。 这里勇哥只是附上测试用的代码,供大家参考。

资源截图

代码片段和文件信息

using System;
using System.Collections.Generic;
using System.Text;
using System.Runtime.InteropServices;
 

namespace csDmc2210
{
    public class Dmc2210
    {
        internal static object objLock = new object();
        //---------------------   板卡初始和配置函数  ----------------------
        /********************************************************************************
        ** 函数名称: d2410_board_init
        ** 功能描述: 控制板初始化,设置初始化和速度等设置
        ** 输   入: 无
        ** 返 回 值: 0:无卡; 1-8:成功(实际卡数) 
        **           1001 + j: j号卡初始化出错 从1001开始。
        ** 修    改:  
        ** 修改日期: 
        *********************************************************************************/
        [DllImport(“Dmc2210.dll“ EntryPoint = “d2210_board_init“ CharSet = CharSet.Ansi CallingConvention = CallingConvention.StdCall)]
        public static extern UInt16 d2210_board_init();

        /********************************************************************************
        ** 函数名称: d2410_board_close
        ** 功能描述: 关闭所有卡
        ** 输   入: 无
        ** 返 回 值: 无
        ** 日    期: 
        *********************************************************************************/
        public static void d2210_board_close()
        {
            lock (objLock)
            {
                board_close();
            }
        }
        [DllImport(“Dmc2210.dll“ EntryPoint = “d2210_board_close“ CharSet = CharSet.Ansi CallingConvention = CallingConvention.StdCall)]
        private static extern void board_close();

        /********************************************************************************
        ** 函数名称: 控制卡复位
        ** 功能描述: 复位所有卡,只能在初始化完成之后调用.
        ** 输   入: 无
        ** 返 回 值: 无
        ** 日    期: 
        *********************************************************************************/
        public static void d2210_board_rest()
        {
            lock (objLock)
            {
                board_rest();
            }
        }
        [DllImport(“Dmc2210.dll“ EntryPoint = “d2210_board_rest“ CharSet = CharSet.Ansi CallingConvention = CallingConvention.StdCall)]
        private static extern void board_rest();




        //脉冲输入输出配置
        /********************************************************************************
        ** 函数名称: d2410_set_pulse_outmode
        ** 功能描述: 脉冲输出方式的设置
        ** 输   入: axis - (0 - 3) outmode: 0 - 7
        **           6:正交脉冲,A相超前; 7:正交脉冲,B相超前
        ** 返 回 值: 无 
        ** 修改日期:2007.1.27
        *********************************************************************************/
        public static void d2210_set_pulse_outmode(ushort axis ushort outmode)
        {
            lock (objLock)
            {
                set_pulse_outmode(axisoutmode);
            }
        }
        [DllImport(“Dmc2210.dll“ EntryPoint = “d2210_set_pulse_outmode“ CharSet = CharSet.Ansi CallingConvention = CallingConvention.StdCall)]

 属性            大小     日期    时间   名称
----------- ---------  ---------- -----  ----

    ..A..H.     47104  2019-06-15 21:43  cj3000测试\WindowsFormsApplication1\.vs\WindowsFormsApplication1\v15\.suo

     文件        187  2019-06-15 11:07  cj3000测试\WindowsFormsApplication1\WindowsFormsApplication1\App.config

     文件     179200  2018-12-20 19:16  cj3000测试\WindowsFormsApplication1\WindowsFormsApplication1\bin\Debug\CL3_IF.dll

     文件     162816  2015-12-08 09:57  cj3000测试\WindowsFormsApplication1\WindowsFormsApplication1\bin\Debug\DMC2210.dll

     文件      55296  2019-06-15 16:44  cj3000测试\WindowsFormsApplication1\WindowsFormsApplication1\bin\Debug\WindowsFormsApplication1.exe

     文件        187  2019-06-15 11:07  cj3000测试\WindowsFormsApplication1\WindowsFormsApplication1\bin\Debug\WindowsFormsApplication1.exe.config

     文件      89600  2019-06-15 16:44  cj3000测试\WindowsFormsApplication1\WindowsFormsApplication1\bin\Debug\WindowsFormsApplication1.pdb

     文件      24216  2019-06-15 16:52  cj3000测试\WindowsFormsApplication1\WindowsFormsApplication1\bin\Debug\WindowsFormsApplication1.vshost.exe

     文件        187  2019-06-15 11:07  cj3000测试\WindowsFormsApplication1\WindowsFormsApplication1\bin\Debug\WindowsFormsApplication1.vshost.exe.config

     文件        490  2013-03-18 17:00  cj3000测试\WindowsFormsApplication1\WindowsFormsApplication1\bin\Debug\WindowsFormsApplication1.vshost.exe.manifest

     文件      33378  2017-03-17 15:14  cj3000测试\WindowsFormsApplication1\WindowsFormsApplication1\DMC2210.cs

     文件       9545  2019-06-15 16:51  cj3000测试\WindowsFormsApplication1\WindowsFormsApplication1\Form1.cs

     文件       9691  2019-06-15 16:49  cj3000测试\WindowsFormsApplication1\WindowsFormsApplication1\Form1.Designer.cs

     文件       5817  2019-06-15 16:49  cj3000测试\WindowsFormsApplication1\WindowsFormsApplication1\Form1.resx

     文件      33311  2019-06-15 16:21  cj3000测试\WindowsFormsApplication1\WindowsFormsApplication1\MotionCard.cs

     文件      33523  2018-12-20 19:15  cj3000测试\WindowsFormsApplication1\WindowsFormsApplication1\NativeMethods.cs

     文件         42  2019-06-15 21:41  cj3000测试\WindowsFormsApplication1\WindowsFormsApplication1\obj\Debug\CoreCompileInputs.cache

     文件        864  2019-06-15 21:42  cj3000测试\WindowsFormsApplication1\WindowsFormsApplication1\obj\Debug\DesignTimeResolveAssemblyReferences.cache

     文件       7166  2019-06-15 21:41  cj3000测试\WindowsFormsApplication1\WindowsFormsApplication1\obj\Debug\DesignTimeResolveAssemblyReferencesInput.cache

     文件          0  2019-06-15 11:07  cj3000测试\WindowsFormsApplication1\WindowsFormsApplication1\obj\Debug\TemporaryGeneratedFile_036C0B5B-1481-4323-8D20-8F5ADCB23D92.cs

     文件          0  2019-06-15 11:07  cj3000测试\WindowsFormsApplication1\WindowsFormsApplication1\obj\Debug\TemporaryGeneratedFile_5937a670-0e60-4077-877b-f7221da3dda1.cs

     文件          0  2019-06-15 11:07  cj3000测试\WindowsFormsApplication1\WindowsFormsApplication1\obj\Debug\TemporaryGeneratedFile_E7A71F73-0F8D-4B9B-B56E-8E70B10BC5D3.cs

     文件       1311  2019-06-15 16:52  cj3000测试\WindowsFormsApplication1\WindowsFormsApplication1\obj\Debug\WindowsFormsApplication1.csproj.FileListAbsolute.txt

     文件        977  2019-06-15 16:44  cj3000测试\WindowsFormsApplication1\WindowsFormsApplication1\obj\Debug\WindowsFormsApplication1.csproj.GenerateResource.Cache

     文件       2211  2019-06-15 11:07  cj3000测试\WindowsFormsApplication1\WindowsFormsApplication1\obj\Debug\WindowsFormsApplication1.csprojResolveAssemblyReference.cache

     文件      55296  2019-06-15 16:44  cj3000测试\WindowsFormsApplication1\WindowsFormsApplication1\obj\Debug\WindowsFormsApplication1.exe

     文件        180  2019-06-15 16:44  cj3000测试\WindowsFormsApplication1\WindowsFormsApplication1\obj\Debug\WindowsFormsApplication1.Form1.resources

     文件      89600  2019-06-15 16:44  cj3000测试\WindowsFormsApplication1\WindowsFormsApplication1\obj\Debug\WindowsFormsApplication1.pdb

     文件        180  2019-06-15 13:31  cj3000测试\WindowsFormsApplication1\WindowsFormsApplication1\obj\Debug\WindowsFormsApplication1.Properties.Resources.resources

     文件        536  2019-06-15 11:07  cj3000测试\WindowsFormsApplication1\WindowsFormsApplication1\Program.cs

............此处省略23个文件信息

评论

共有 条评论

相关资源