WO2013139166A1 - Counting device for using sensing signal to control single-chip computer to start up and stop - Google Patents

Counting device for using sensing signal to control single-chip computer to start up and stop Download PDF

Info

Publication number
WO2013139166A1
WO2013139166A1 PCT/CN2013/000162 CN2013000162W WO2013139166A1 WO 2013139166 A1 WO2013139166 A1 WO 2013139166A1 CN 2013000162 W CN2013000162 W CN 2013000162W WO 2013139166 A1 WO2013139166 A1 WO 2013139166A1
Authority
WO
WIPO (PCT)
Prior art keywords
counting
relay
reed switch
stop
sensing signal
Prior art date
Application number
PCT/CN2013/000162
Other languages
French (fr)
Chinese (zh)
Inventor
王传荣
潘柯
刘志政
左伟
Original Assignee
山东潍微科技股份有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 山东潍微科技股份有限公司 filed Critical 山东潍微科技股份有限公司
Publication of WO2013139166A1 publication Critical patent/WO2013139166A1/en

Links

Classifications

    • GPHYSICS
    • G01MEASURING; TESTING
    • G01FMEASURING VOLUME, VOLUME FLOW, MASS FLOW OR LIQUID LEVEL; METERING BY VOLUME
    • G01F15/00Details of, or accessories for, apparatus of groups G01F1/00 - G01F13/00 insofar as such details or appliances are not adapted to particular types of such apparatus
    • G01F15/06Indicating or recording devices
    • G01F15/061Indicating or recording devices for remote indication
    • GPHYSICS
    • G01MEASURING; TESTING
    • G01FMEASURING VOLUME, VOLUME FLOW, MASS FLOW OR LIQUID LEVEL; METERING BY VOLUME
    • G01F15/00Details of, or accessories for, apparatus of groups G01F1/00 - G01F13/00 insofar as such details or appliances are not adapted to particular types of such apparatus
    • G01F15/07Integration to give total flow, e.g. using mechanically-operated integrating mechanism
    • G01F15/075Integration to give total flow, e.g. using mechanically-operated integrating mechanism using electrically-operated integrating means
    • G01F15/0755Integration to give total flow, e.g. using mechanically-operated integrating mechanism using electrically-operated integrating means involving digital counting

Definitions

  • the invention relates to a counting device, in particular to a counting device or the like which can be used for measuring instruments such as water meters, electric meters and gas meters, and more particularly to a counting device for controlling the start and stop of a single chip by using a sensing signal.
  • counting devices for measuring instruments such as water meters, electric meters, and gas meters mostly use a single-chip microcomputer to collect and measure the sensing signals, such as: Chinese patent 201110267269. 2, 201020544489. 6 >
  • the single-chip microcomputer adopts the standby sleep mode of operation, but this mode is power-on state after all, and it needs to wake up frequently.
  • the single-chip microcomputer is still difficult to resist external interference; the identification pulse signal or the interference signal is always a Difficulties, counting errors and failures in actual applications have occurred, and have become a major problem in international electronic metering devices.
  • the technical problem to be solved by the present invention is to provide a counting device for controlling the start and stop of the single chip by using the sensing signal, and to overcome the power consumption, the counting error and the running fault caused by the power-on standby when the existing single chip does not count.
  • the problem is that after the counting device of the invention is used, the single-chip microcomputer is energized during counting, and the power is turned off after counting, so that the number of times of starting and stopping the single chip is used as a new working mode of counting times and
  • the device avoids the interference of magnetoelectricity, static electricity and lightning strike, and solves the fundamental problem that the meter has inaccurate measurement of remote transmission.
  • the counting device for controlling the start and stop of the single chip by using the sensing signal, including the magnetic steel, the reed switch, the relay, the single chip, the characteristic is: setting a magnetic group on the counting wheel Steel, in the corresponding position to set a set of reed switches, the power supply through the reed switch, relays connected to the microcontroller.
  • a set of magnetic steels of opposite polarities are arranged on the counting wheel, two reed switches are arranged at corresponding positions, and a reed switch is arranged to bias magnetic steel, so that the reed switch increases the sensing distance and improves the touch. Point reliability, and two reed switches with switch control and contact self-holding function.
  • a magnetic steel is arranged on the counting wheel, and three reed switches are arranged at corresponding positions, and the power supply is respectively connected to the single-chip microcomputer through two reed switches and relays, and the other dry spring is directly connected to the single-chip microcomputer. .
  • the reed switch can also be a micropower (or zero power) Hall switch.
  • the working process of the invention is:
  • the reed switch la When the digital wheel rotates and the magnetic steel rotates to the reed switch la, the reed switch la is closed, and the power supply is turned on by the contact 1 of the relay. After a short period of time, the MCU confirms that the contact of the reed switch la is in stable contact (not interference), and then connects the relay contact to 2, and the MCU itself is powered off. The character wheel continues to rotate. When the magnetic steel rotates to the reed switch lb, the reed switch lb is closed, and the power supply is turned on by the contact 2 of the relay.
  • the MCU After a short period of time, the MCU confirms that the contact of the reed switch lb is in stable contact (not interference), the count is automatically incremented by 1, and then the relay contact is connected back to 1, and the MCU itself is powered off. This is the beginning of the week.
  • Set a set of magnetic steel with opposite polarity on the counting wheel set the reed switch at the corresponding position, and set the bias magnet on the side of the reed switch to increase the sensing distance and increase the contact of the reed switch.
  • Reliability, and the reed switch has the function of closing or opening with the different polarity of the induction magnet, and maintaining the closed or open state until the other polarity is close to the induction to switch the state.
  • the present invention adopts the above technical solutions, and has the following advantages compared with the prior art:
  • the working mode of the power consumption standby in which the conventional single chip microcomputer and its circuit are energized for a long time and the waiting signal arrives becomes a counting signal. Only when the power is turned on, the intermittent operation mode of the power-off is turned off after the counting is completed.
  • the remote meter of water, electricity, gas, heat, etc. has more than 99% of the time, it is completely in the state of power failure, which not only saves a lot of (battery) power, but also absolutely avoids magnetoelectricity. All interferences such as static electricity and lightning strikes completely solved the fundamental problem that the meter has inaccurate measurement of remote transmission.
  • FIG. 1 is a schematic view showing the working mode of the power supply passing through two reed switches and the contacts of the relays and the contacts of the single-chip microcomputer respectively in the first embodiment of the present invention
  • FIG. 2 is a schematic view showing the working mode of the reed switch of the bias magnetic steel and the contacts 1 and 2 of the relay alternately connected with the single chip according to the second embodiment of the present invention
  • FIG. 3 is a schematic view showing the working mode of the power supply by the reed switch and the field effect transistor of the bias magnetic steel and the relay being respectively connected to the single-chip microcomputer in the embodiment 3 of the present invention, and at the same time, the forward rotation of the character wheel can be judged;
  • FIG. 4 is a schematic diagram of the working mode in which the power supply is respectively connected to the single-chip microcomputer through the three reed switches and the contacts of the relays, and the first and second contacts of the relay are alternately connected with the single-chip microcomputer;
  • Embodiment 1 as shown in FIG. 1, when the magnetic steel 2 on the induction character wheel 3 rotates to the reed switch la with the character wheel, la is closed, and the power supply is turned on by the contact 1 of the relay 4, and the single-chip microcomputer is briefly Time processing, after confirming that the reed switch la contact is in stable contact (not interference), connect the relay contact to 2, and the single-chip microcomputer 5 is powered off.
  • the sensing character wheel 3 continues to rotate.
  • the magnetic steel 2 rotates to the reed switch lb, the lb is closed, and the power is turned on.
  • the contact 2 of the relay 4 is turned on to the single-chip microcomputer 5.
  • the single-chip microcomputer After a short time of processing, the single-chip microcomputer confirms that the ten-switch lb contact is in stable contact (not interference), the count is automatically incremented by 1, and then the relay 4 contact is connected back to 1 , the initial state is restored, and the MCU is powered off. This is the beginning of the week.
  • Embodiment 2 as shown in FIG. 2, a bias magnet 6 is respectively disposed on the two reed switches 1a, 1b, and when the S pole of the magnet 2 on the sensing wheel 3 is rotated to the reed switch la, The reed switch la is closed, and the power source is turned on by the contact 1 of the relay 4 to turn on the single chip microcomputer 5. At this time, the N pole of the magnet 2 is rotated just to the reed switch lb, and lb is broken. After a short period of time, the MCU 5 will connect the contact of the relay 4 to 2, and the MCU will be powered off. The sensing character wheel 3 continues to rotate.
  • the reed switch lb When the S pole of the magnet steel 2 on the sensing character wheel 3 rotates to the dry lb, the reed switch lb is closed, and the power supply is turned on by the contact 2 of the relay 4 to the single chip microcomputer 5 (at this time, the magnetic steel The N pole of 2 just turns to the reed switch la, and the reed switch la is disconnected). After a short period of time, the MCU 5 automatically increments by 1, and then connects the contact of the relay 4 back to 1, to restore the initial state, and the MCU is powered off. This is the beginning of the week.
  • a set of magnets 2 of opposite polarity are disposed on the sensing wheel 3
  • two reed switches la, lb are disposed at corresponding positions
  • a bias magnet is disposed on the side of the reed switch. 6
  • Embodiment 3 as shown in FIG. 3, the sensing character wheel 3 rotates in the forward direction (clockwise).
  • the reed switch la is disconnected.
  • the control circuit composed of the field effect transistor 7 and the resistor is turned on because the gate is at a low level, and the power supply is turned on by the contact 1 of the relay 4 to turn on the single chip microcomputer 5.
  • the microcontroller 5 connects the relay 4 contact to 2.
  • the sensing character wheel 3 continues to rotate in the forward direction.
  • the reed switch lb in Fig. 3 is used to detect the reverse of the sensing word wheel 3.
  • the sensing character wheel 3 is rotating forward (clockwise)
  • the reed switch la is turned off, and the FET 7 is low due to the gate.
  • the power supply is turned on by the contact 1 of the relay 4 to turn on the single chip microcomputer 5.
  • the MCU 5 contacts the contact of the relay 4 to 2.
  • the sensing character wheel 3 continues to rotate in the forward direction.
  • the FET in this example can be replaced by a switching circuit, a thyristor, a stern tube, and a gate circuit as the control circuit of the switching circuit.
  • the working process and the switching control of the FET are not fundamentally different. Even if the above-mentioned various tubes or gate circuits are used instead of the FET, the function of the switch control can be fully satisfied.
  • Embodiment 4 is a working mode in which three reed switches are arranged, wherein the reed switches la, lb are the same as the working principle of FIG. 1, and the reed switch lc is used for detecting the inversion of the sensing word wheel 3. .
  • the diode D and the resistor are equivalent to a control circuit. The diode D is connected between the reed switches la and lc and the relay for the reed switch la to be closed, and the positive terminal of the diode is still low when the c c is broken.
  • the reed switch When the character wheel is rotating forward (clockwise), the reed switch is closed and the power is turned on via the contact 1 of the relay 4 to the microcontroller 5. After a short period of time, the MCU 5 contacts the contact of the relay 4 to 2, and the MCU is powered off. The induction word wheel 3 continues to rotate forward, so that when the reed switch lc is closed, the MCU stops at this time, and the lc closure is invalid. The induction word wheel 3 continues to rotate forward, so that when the reed switch lb is closed, the power supply is turned on by the contact 2 of the relay 4 to the single-chip microcomputer 5. After a short time of processing, the single-chip microcomputer automatically increments the count, and then the relay 4 is connected.
  • the microcontroller is powered off. This is the beginning of the week.
  • the sense wheel 3 is reversed (counterclockwise)
  • the reed switch lc is turned on.
  • the power supply passes through the reed switch l c, diode, relay 4 contact 1 turns on the microcontroller.
  • the MCU detects that the P13 port is high from the positive terminal of the diode, and then determines that the sensing word wheel 3 has reversed, and the MCU immediately responds accordingly.

Landscapes

  • Physics & Mathematics (AREA)
  • Fluid Mechanics (AREA)
  • General Physics & Mathematics (AREA)
  • Transmission And Conversion Of Sensor Element Output (AREA)

Abstract

Disclosed is a counting device for using a sensing signal to control a single-chip computer to start up and stop, which comprises magnetic steels, reed switches, a relay and a single-chip computer, and is characterized in that a group of magnetic steels are arranged on a counting character wheel, a group of reed switches are arranged in the position corresponding thereto, and a power supply is in communication with the single-chip computer through the reed switches and the relay. The present invention changes the operation manner in the past that a single-chip computer circuit is powered on for a long time to detect a signal into the alternatively starting-up and stopping operation manner where it is powered on until a counting signal comes, and it is powered off after the counting is completed. The counting sensing signal is simultaneously used as a starting-up and stopping command of the single-chip computer. Under the condition that remote transmission meters for water, electricity, gas, heat, etc. are not counted for more than 99% of time, they are completely in the power-off shutdown state, and start up and use power only in a counting instant. A (battery) power supply is greatly saved, and the stop also absolutely avoids all the interference of magnetoelectricity, static electricity, lightning strike, etc., thereby thoroughly solving the basic problem that the remote transmission measurement of a meter is inaccurate.

Description

用传感信号控制单片机启停的计数装置  Counting device for controlling start and stop of single chip microcomputer by using sensing signal
技术领域 Technical field
本发明涉及一种计数装置, 尤其涉及一种可用于水表、 电表、 气表等计量 仪表的计数装置或类似控制装置, 具体讲是一种用传感信号控制单片机启停的 计数装置。  The invention relates to a counting device, in particular to a counting device or the like which can be used for measuring instruments such as water meters, electric meters and gas meters, and more particularly to a counting device for controlling the start and stop of a single chip by using a sensing signal.
背景技术 Background technique
目前用于水表、 电表、 气表等计量仪表的计数装置, 多采用单片机采集计 量传感信号的方式, 如: 中国专利 201110267269. 2、 201020544489. 6 >  At present, counting devices for measuring instruments such as water meters, electric meters, and gas meters mostly use a single-chip microcomputer to collect and measure the sensing signals, such as: Chinese patent 201110267269. 2, 201020544489. 6 >
200910072638. 5中的所述。 这些方式都是让单片机处于通电等待的状态, 然后 采集来自于传感器的脉冲或开关信号。 无论信号来得快、 慢或不来信号, 单片 机都要通电开机等在那里。 这样, 就带来了很多问题。 首先就是外来干扰的问 题, 在单片机幵机等待的时间里, 遇有静电、 电磁、 雷击等干扰信号, 计数就 会产生错误, 或直接导致单片机死机; 其次是耗电的问题, 尽管单片机耗电不 多, 但对于电池供电、 无线传输、 掌上电脑抄表来说, 也是很值得考虑的; 另 外, 由于外来信号的不规则变化与单片机难以识别等原因, 造成计数错误的情 况也时有发生; 还有由于长期通电开机带来的整机故障率问题等。 Said in 200910072638. These methods are to put the microcontroller in a power-on state, and then collect the pulse or switching signal from the sensor. Regardless of whether the signal comes fast, slow or does not signal, the microcontroller must be powered on and waiting there. This brings a lot of problems. The first is the problem of external interference. In the time when the MCU is waiting for the machine, if there is interference signal such as static electricity, electromagnetic or lightning strike, the counting will generate an error, or directly lead to the crash of the MCU. Secondly, the problem of power consumption, despite the power consumption of the MCU. Not much, but for battery-powered, wireless transmission, handheld computer meter reading, it is also worth considering; In addition, due to irregular changes in external signals and difficult to identify the microcontroller, etc., the counting error has also occurred; There is also a problem of the failure rate of the whole machine due to long-term power-on and power-on.
为了解决以上问题, 许多情况下单片机采用了待机休眠的工作方式, 但这 种方式毕竟是通电状态, 且需要经常唤醒工作, 单片机仍然难以抗击外来的各 种干扰; 识别脉冲信号还是干扰信号一直是个难题, 实际应用中计数错误和造 成故障的情况时有发生, 己成为国际电子计量装置中的一大难题。  In order to solve the above problems, in many cases, the single-chip microcomputer adopts the standby sleep mode of operation, but this mode is power-on state after all, and it needs to wake up frequently. The single-chip microcomputer is still difficult to resist external interference; the identification pulse signal or the interference signal is always a Difficulties, counting errors and failures in actual applications have occurred, and have become a major problem in international electronic metering devices.
试验和经验都巳证明, 要想根本解决以上问题, 唯有用计数传感信号作为 单片机的启动开关 (不是采集脉冲), 计数瞬间开机, 计数完毕关断电源。 发明内容  Both the test and the experience prove that, in order to solve the above problems fundamentally, only the count sensing signal is used as the start switch (not the acquisition pulse) of the single chip microcomputer, the counting is turned on instantaneously, and the power is turned off after counting. Summary of the invention
本发明要解决的技术问题是针对以上不足, 提供一种用传感信号控制单片 机启停的计数装置, 克服现有单片机不计数时通电待机所带来的耗电、 计数不 准和运行故障等问题, 采用本发明的计数装置后, 实现了单片机在计数时通电 工作, 计数后断电停机, 让单片机开停的次数作为计数次数的新的工作方式和  The technical problem to be solved by the present invention is to provide a counting device for controlling the start and stop of the single chip by using the sensing signal, and to overcome the power consumption, the counting error and the running fault caused by the power-on standby when the existing single chip does not count. The problem is that after the counting device of the invention is used, the single-chip microcomputer is energized during counting, and the power is turned off after counting, so that the number of times of starting and stopping the single chip is used as a new working mode of counting times and
1  1
确认本 装置, 避免了磁电、 静电、 雷击的干扰, 解决了计量表具远传计量不准确的根 本问题。 Confirmation The device avoids the interference of magnetoelectricity, static electricity and lightning strike, and solves the fundamental problem that the meter has inaccurate measurement of remote transmission.
为解决以上技术问题, 本发明采用如下技术方案: 用传感信号控制单片机 启停的计数装置, 包括磁钢、 干簧开关、 继电器、 单片机, 其特征是: 在计数 字轮上设置一组磁钢, 在与之对应的位置设置一组干簧开关, 电源通过干簧开 关、 继电器连通单片机。  In order to solve the above technical problems, the present invention adopts the following technical solutions: The counting device for controlling the start and stop of the single chip by using the sensing signal, including the magnetic steel, the reed switch, the relay, the single chip, the characteristic is: setting a magnetic group on the counting wheel Steel, in the corresponding position to set a set of reed switches, the power supply through the reed switch, relays connected to the microcontroller.
在所述计数字轮上设置一组极性相反的磁钢, 在与之对应的位置设置两只 干簧开关, 干簧开关设置偏置磁钢, 以使干簧开关增加感应距离、 提高触点可 靠性, 并使两只干簧开关具有开关可控和触点自保持功能。  A set of magnetic steels of opposite polarities are arranged on the counting wheel, two reed switches are arranged at corresponding positions, and a reed switch is arranged to bias magnetic steel, so that the reed switch increases the sensing distance and improves the touch. Point reliability, and two reed switches with switch control and contact self-holding function.
在所述计数字轮上设置一组极性相反的磁钢, 在所述计数字轮的同一侧设 置两只带有偏置磁钢的干簧开关, 电源通过一只干簧开关、 继电器和通过具有 晶体管或者门电路组成的控制电路、 继电器交替连通单片机, 另一只干簧开关 直接与单片机连通。  Providing a set of magnetic steels of opposite polarity on the counting wheel, two reed switches with bias magnets disposed on the same side of the counting wheel, the power source passing through a reed switch, a relay, and The control circuit with a transistor or a gate circuit alternately connects the single-chip microcomputer, and the other reed switch directly communicates with the single-chip microcomputer.
在所述计数字轮上设置一块磁钢, 在与之对应的位置设置三只干簧开关, 电源分別通过其中两只干簧开关和继电器与单片机连通, 另一只干簧幵关直接 连接单片机。  A magnetic steel is arranged on the counting wheel, and three reed switches are arranged at corresponding positions, and the power supply is respectively connected to the single-chip microcomputer through two reed switches and relays, and the other dry spring is directly connected to the single-chip microcomputer. .
在所述计数字轮上设置一组极性相反的磁钢, 在所述计数字轮的一侧设置 两只带有偏置磁钢的干簧开关, 其中一只通过具有晶体管或者门电路组成的控 制电路连接继电器, 另一只直接连接单片机。  Providing a set of magnetic steels of opposite polarity on the counting wheel, and two reed switches with bias magnets are disposed on one side of the counting wheel, one of which is composed of a transistor or a gate circuit The control circuit is connected to the relay, and the other is directly connected to the microcontroller.
所述干簧开关也可以采用微功耗 (或零功耗) 霍尔开关。  The reed switch can also be a micropower (or zero power) Hall switch.
本发明的工作过程为:  The working process of the invention is:
当计数字轮转动, 磁钢转动到干簧开关 la处时, 干簧开关 la闭合, 电源通 过继电器的触点 1接通单片机工作。 单片机在经过短暂时间的处理, 确认干簧开 关 la的触点稳定接触 (不是干扰)之后, 将继电器触点接到 2, 单片机自身断电停 机。 字轮继续转动, 磁钢转动到干簧开关 lb处时, 干簧开关 lb闭合, 电源通过 继电器的触点 2接通单片机工作。 单片机在经过短暂时间的处理, 确认干簧开关 l b的触点稳定接触 (不是干扰)之后, 计数自动加 1, 然后将继电器触点接回到 1, 单片机自身断电停机。 由此周而复始。 在计数字轮上设置一组极性相反的磁钢, 在与之对应的位置设置干簧开关, 在干簧开关一侧设置偏置磁钢, 可使干簧开关增加感应距离、 提高触点可靠性, 并使干簧开关具有随感应磁钢的不同极性而闭合或断开, 且保持闭合或断开状 态, 直到另一极性靠近感应才能转换状态的功能。 When the digital wheel rotates and the magnetic steel rotates to the reed switch la, the reed switch la is closed, and the power supply is turned on by the contact 1 of the relay. After a short period of time, the MCU confirms that the contact of the reed switch la is in stable contact (not interference), and then connects the relay contact to 2, and the MCU itself is powered off. The character wheel continues to rotate. When the magnetic steel rotates to the reed switch lb, the reed switch lb is closed, and the power supply is turned on by the contact 2 of the relay. After a short period of time, the MCU confirms that the contact of the reed switch lb is in stable contact (not interference), the count is automatically incremented by 1, and then the relay contact is connected back to 1, and the MCU itself is powered off. This is the beginning of the week. Set a set of magnetic steel with opposite polarity on the counting wheel, set the reed switch at the corresponding position, and set the bias magnet on the side of the reed switch to increase the sensing distance and increase the contact of the reed switch. Reliability, and the reed switch has the function of closing or opening with the different polarity of the induction magnet, and maintaining the closed or open state until the other polarity is close to the induction to switch the state.
本发明采用以上技术方案, 与现有技术相比, 具有以下优点: 通过以上的 方式, 将以往单片机及其电路长期通电、 等待信号到来的耗电待机的工作方式, 变成了计数信号来了才通电, 计数完成之后就断电的开停间歇工作方式。 在水、 电、气、热等远传计量表具 99%以上的时间无需采数的情况下, 完全处于断电停 机的状态, 不仅大大节省了 (电池) 电源, 而且停机绝对避免了磁电、 静电、 雷击等所有干扰, 彻底解决了计量表具远传计量不准确的根本问题。  The present invention adopts the above technical solutions, and has the following advantages compared with the prior art: Through the above manner, the working mode of the power consumption standby in which the conventional single chip microcomputer and its circuit are energized for a long time and the waiting signal arrives becomes a counting signal. Only when the power is turned on, the intermittent operation mode of the power-off is turned off after the counting is completed. In the case that the remote meter of water, electricity, gas, heat, etc. has more than 99% of the time, it is completely in the state of power failure, which not only saves a lot of (battery) power, but also absolutely avoids magnetoelectricity. All interferences such as static electricity and lightning strikes completely solved the fundamental problem that the meter has inaccurate measurement of remote transmission.
附图说明 DRAWINGS
附图 1为本发明实施例 1中电源分别通过两只干簧开关、 继电器的 1、 2触点 交替与单片机接通的工作方式示意图;  1 is a schematic view showing the working mode of the power supply passing through two reed switches and the contacts of the relays and the contacts of the single-chip microcomputer respectively in the first embodiment of the present invention;
附图 2为本发明实施例 2中电源分别通过设置偏置磁钢的干簧开关、 继电器 的 1、 2触点交替与单片机接通的工作方式示意图;  2 is a schematic view showing the working mode of the reed switch of the bias magnetic steel and the contacts 1 and 2 of the relay alternately connected with the single chip according to the second embodiment of the present invention;
附图 3为本发明实施例 3中电源通过设置偏置磁钢的干簧开关和场效应管分 别与继电器接通单片机的工作方式, 同时可判断字轮正转倒转的示意图;  3 is a schematic view showing the working mode of the power supply by the reed switch and the field effect transistor of the bias magnetic steel and the relay being respectively connected to the single-chip microcomputer in the embodiment 3 of the present invention, and at the same time, the forward rotation of the character wheel can be judged;
附图 4为本发明实施例 4中电源分别通过三只干簧开关、 继电器的 1、 2触点 交替与单片机接通的工作方式, 同时可判断字轮正转倒转的示意图;  4 is a schematic diagram of the working mode in which the power supply is respectively connected to the single-chip microcomputer through the three reed switches and the contacts of the relays, and the first and second contacts of the relay are alternately connected with the single-chip microcomputer;
其中,  among them,
1-干簧开关, 2-磁钢, 3-感应字轮, 4-继电器, 5-单片机, 6-偏置磁钢, 7- 场效应管。  1-reed switch, 2-magnet, 3-induction wheel, 4-relay, 5-chip, 6-bias magnet, 7-FET.
下面结合附图与实施例对本发明作进一步说明。  The invention will be further described below in conjunction with the drawings and embodiments.
具体实施方式 detailed description
实施例 1, 如图 1所示, 感应字轮 3上的磁钢 2随字轮转动到干簧开关 la时, la闭合,电源通过继电器 4的触点 1接通单片机 5,单片机在经过短暂时间的处理, 确认干簧开关 la触点稳定接触 (不是干扰)之后, 将继电器触点接到 2,单片机 5断 电停机。 感应字轮 3继续转动, 当磁钢 2转动到干簧开关 lb时, lb闭合, 电源通 过继电器 4的触点 2接通单片机 5, 单片机在经过短暂时间的处理, 确认十簧开关 lb触点稳定接触 (不是干扰)之后, 计数自动加 1, 然后将继电器 4触点接回到 1, 恢复初始状态, 单片机断电停机。 由此周而复始。 Embodiment 1, as shown in FIG. 1, when the magnetic steel 2 on the induction character wheel 3 rotates to the reed switch la with the character wheel, la is closed, and the power supply is turned on by the contact 1 of the relay 4, and the single-chip microcomputer is briefly Time processing, after confirming that the reed switch la contact is in stable contact (not interference), connect the relay contact to 2, and the single-chip microcomputer 5 is powered off. The sensing character wheel 3 continues to rotate. When the magnetic steel 2 rotates to the reed switch lb, the lb is closed, and the power is turned on. The contact 2 of the relay 4 is turned on to the single-chip microcomputer 5. After a short time of processing, the single-chip microcomputer confirms that the ten-switch lb contact is in stable contact (not interference), the count is automatically incremented by 1, and then the relay 4 contact is connected back to 1 , the initial state is restored, and the MCU is powered off. This is the beginning of the week.
实施例 2, 如图 2所示, 在两只干簧开关 la、 lb上分别设置了偏置磁钢 6, 当感应字轮 3上的磁钢 2的 S极转动到干簧开关 la时, 干簧开关 la闭合, 电源通过 继电器 4的触点 1接通单片机 5。 此时, 磁钢 2的 N极恰好转动到干簧开关 lb, lb断 开。 单片机 5经过短暂时间的处理后, 将继电器 4触点接到 2, 单片机断电停机。 感应字轮 3继续转动, 当感应字轮 3上的磁钢 2的 S极转动到干 lb时, 干簧开关 lb 闭合, 电源通过继电器 4的触点 2接通单片机 5 (此时, 磁钢 2的 N极恰好转动到干 簧管 la,干簧管 la断开) 。 单片机 5经过短暂时间的处理后, 计数自动加 1, 然后 将继电器 4触点接回到 1, 恢复初始状态, 单片机断电停机。 由此周而复始。  Embodiment 2, as shown in FIG. 2, a bias magnet 6 is respectively disposed on the two reed switches 1a, 1b, and when the S pole of the magnet 2 on the sensing wheel 3 is rotated to the reed switch la, The reed switch la is closed, and the power source is turned on by the contact 1 of the relay 4 to turn on the single chip microcomputer 5. At this time, the N pole of the magnet 2 is rotated just to the reed switch lb, and lb is broken. After a short period of time, the MCU 5 will connect the contact of the relay 4 to 2, and the MCU will be powered off. The sensing character wheel 3 continues to rotate. When the S pole of the magnet steel 2 on the sensing character wheel 3 rotates to the dry lb, the reed switch lb is closed, and the power supply is turned on by the contact 2 of the relay 4 to the single chip microcomputer 5 (at this time, the magnetic steel The N pole of 2 just turns to the reed switch la, and the reed switch la is disconnected). After a short period of time, the MCU 5 automatically increments by 1, and then connects the contact of the relay 4 back to 1, to restore the initial state, and the MCU is powered off. This is the beginning of the week.
如图 2所示, 在感应字轮 3上设置一组极性相反的磁钢 2, 在与之对应的位 置设置两只干簧开关 la、 lb, 在干簧开关一侧设置偏置磁钢 6, 可使干簧开关增 加感应距离、 提高触点可靠性, 并控制干簧开关 la、 lb交替通断。  As shown in FIG. 2, a set of magnets 2 of opposite polarity are disposed on the sensing wheel 3, two reed switches la, lb are disposed at corresponding positions, and a bias magnet is disposed on the side of the reed switch. 6, can make the reed switch increase the sensing distance, improve the reliability of the contact, and control the reed switch la, lb alternately open and close.
实施例 3, 如图 3所示, 感应字轮 3正向 (顺时针) 转动, 当感应字轮 3上的 磁钢 2的 N极转动到干簧幵关 la时, 干簧开关 la断开, 场效应管 7与电阻构成的控 制电路中因栅极为低电平而导通, 电源通过继电器 4的触点 1接通单片机 5。 单片 机 5经过短暂时间的处理后, 将继电器 4触点接到 2。 感应字轮 3继续正向转动, 当感应字轮 3上的磁钢 2的 S极转动到干簧开关 la时, la闭合, 电源通过继电器 4的 触点 2接通单片机 5。 单片机 5经过短暂时间的处理后, 计数自动加 1, 然后将继 电器 4触点接回到 1, 恢复初始状态, 之后单片机断电停机。 由此周而复始。  Embodiment 3, as shown in FIG. 3, the sensing character wheel 3 rotates in the forward direction (clockwise). When the N pole of the magnet steel 2 on the sensing character wheel 3 rotates to the dry spring switch, the reed switch la is disconnected. The control circuit composed of the field effect transistor 7 and the resistor is turned on because the gate is at a low level, and the power supply is turned on by the contact 1 of the relay 4 to turn on the single chip microcomputer 5. After a short period of time, the microcontroller 5 connects the relay 4 contact to 2. The sensing character wheel 3 continues to rotate in the forward direction. When the S pole of the magnet steel 2 on the sensing character wheel 3 is rotated to the reed switch la, la is closed, and the power source is turned on by the contact 2 of the relay 4 to turn on the single chip microcomputer 5. After the microcontroller 5 has been processed for a short period of time, the count is automatically incremented by 1, and then the relay 4 contacts are connected back to 1, and the initial state is restored, after which the microcontroller is powered off. This is the beginning of the week.
图 3中的干簧开关 lb用于检测感应字轮 3的倒转。 当感应字轮 3正转 (顺时 针) 时, 感应字轮 3上的磁钢 2的 N极转动到干簧开关 la时, 干簧开关 la断开, 场 效应管 7因栅极为低电平而导通, 电源通过继电器 4的触点 1接通单片机 5。 单片 机 5经过短暂时间的处理后, 将继电器 4触点接到 2。 感应字轮 3继续正向转动, 当感应字轮 3上的磁钢 2的 N极转动到干簧开关 lb时, lb断开, 此时单片机停机, lb断开无效。 当感应字轮 3倒转 (逆时针) 时, 干簧开关 lb断开。 由于设置了偏 置磁钢, 干簧丌关 lb就保持在断开的状态上, 当感应字轮 3继续反转, 使千簧开 关 la也断开时, 场效应管 7因栅极为低电平而导通, 电源通过继电器 4的触点 1接 通单片机 5。单片机工作后检测到 P13口为低电平, 由此判定感应字轮 3是在倒转, 单片机随即做出相应处理。 The reed switch lb in Fig. 3 is used to detect the reverse of the sensing word wheel 3. When the sensing character wheel 3 is rotating forward (clockwise), when the N pole of the magnetic steel 2 on the sensing character wheel 3 is rotated to the reed switch la, the reed switch la is turned off, and the FET 7 is low due to the gate. When turned on, the power supply is turned on by the contact 1 of the relay 4 to turn on the single chip microcomputer 5. After a short period of time, the MCU 5 contacts the contact of the relay 4 to 2. The sensing character wheel 3 continues to rotate in the forward direction. When the N pole of the magnetic steel 2 on the sensing character wheel 3 is rotated to the reed switch lb, lb is turned off, and the single chip microcomputer is stopped, and the lb disconnection is invalid. When the sensing character wheel 3 is reversed (counterclockwise), the reed switch lb is turned off. Since the bias magnet is set, the reed switch lb is kept in the off state, and when the sensing character wheel 3 continues to reverse, the spring is opened. When the switch 1 is also turned off, the FET 7 is turned on because the gate is at a low level, and the power supply is turned on by the contact 1 of the relay 4 to turn on the single chip microcomputer 5. After the operation of the single chip microcomputer, it is detected that the P13 port is at a low level, thereby determining that the sensing word wheel 3 is being reversed, and the single chip microcomputer immediately performs corresponding processing.
本例中的场效应管可以用开关管、 晶闸管、 燧道管以及门电路等作为开关 电路的控制电路来替代, 其工作过程和场效应管的开关控制没冇本质的区别。 即用上述的各种管或者门电路来取代场效应管, 也完全可以满足其开关控制的 作用。  The FET in this example can be replaced by a switching circuit, a thyristor, a stern tube, and a gate circuit as the control circuit of the switching circuit. The working process and the switching control of the FET are not fundamentally different. Even if the above-mentioned various tubes or gate circuits are used instead of the FET, the function of the switch control can be fully satisfied.
实施例 4, 如图 4所示, 是设置三只干簧开关的工作方式, 其中干簧开关 la、 lb与图 1的工作原理相同, 干簧开关 lc是用于检测感应字轮 3倒转的。 图 中二极管 D和电阻相当于一个控制电路, 二极管 D连接于干簧开关 la和 lc与 继电器之间, 用于干簧开关 la闭合, l c断幵情况下二极管正极端仍为低电位。 当字轮正转 (顺时针) 时, 干簧幵关 la闭合, 电源通过继电器 4的触点 1接通 单片机 5。 单片机 5经过短暂时间的处理后, 将继电器 4触点接到 2, 单片机断 电停机。 感应字轮 3继续正转, 使干簧开关 lc闭合时, 此时单片机停机, lc闭 合无效。 感应字轮 3继续正转, 使干簧开关 lb闭合时, 电源通过继电器 4的触 点 2接通单片机 5 , 单片机在经过短暂时间的处理之后, 计数自动加 1, 然后将 继电器 4触点接回到 1, 恢复初始状态, 单片机断电停机。 由此周而复始。 当感 应字轮 3倒转(逆时针)时, 干簧开关 lc导通。 电源通过干簧开关 l c、二极管、 继电器 4的触点 1接通单片机。 此时, 单片机从二极管正极端检测到 P13口为 高电位, 则判定感应字轮 3出现了倒转, 单片机随即做出相应处理。  Embodiment 4, as shown in FIG. 4, is a working mode in which three reed switches are arranged, wherein the reed switches la, lb are the same as the working principle of FIG. 1, and the reed switch lc is used for detecting the inversion of the sensing word wheel 3. . In the figure, the diode D and the resistor are equivalent to a control circuit. The diode D is connected between the reed switches la and lc and the relay for the reed switch la to be closed, and the positive terminal of the diode is still low when the c c is broken. When the character wheel is rotating forward (clockwise), the reed switch is closed and the power is turned on via the contact 1 of the relay 4 to the microcontroller 5. After a short period of time, the MCU 5 contacts the contact of the relay 4 to 2, and the MCU is powered off. The induction word wheel 3 continues to rotate forward, so that when the reed switch lc is closed, the MCU stops at this time, and the lc closure is invalid. The induction word wheel 3 continues to rotate forward, so that when the reed switch lb is closed, the power supply is turned on by the contact 2 of the relay 4 to the single-chip microcomputer 5. After a short time of processing, the single-chip microcomputer automatically increments the count, and then the relay 4 is connected. Go back to 1, restore the initial state, the microcontroller is powered off. This is the beginning of the week. When the sense wheel 3 is reversed (counterclockwise), the reed switch lc is turned on. The power supply passes through the reed switch l c, diode, relay 4 contact 1 turns on the microcontroller. At this time, the MCU detects that the P13 port is high from the positive terminal of the diode, and then determines that the sensing word wheel 3 has reversed, and the MCU immediately responds accordingly.

Claims

权 利 要 求 书 Claim
1、 用传感信号控制单片机启停的计数装置, 包括磁钢, 干簧开关, 继电 器, 单片机, 其特征是在计数字轮上设置一组磁钢, 在与之对应的位置设置一 组干簧开关, 电源通过干簧幵关、 继电器连通单片机。 1. The counting device for controlling the start and stop of the single-chip microcomputer by using the sensing signal, including magnetic steel, reed switch, relay, single-chip microcomputer, is characterized in that a set of magnetic steel is set on the counting digital wheel, and a set of dryness is set at the corresponding position. The reed switch, the power supply is connected to the single-chip microcomputer through a dry-spring switch and a relay.
2、 根据权利要求 1 所述的用传感信号控制单片机启停的计数装置, 其特 征是在计数字轮上设置两只极性相反的磁钢, 在与之对应的位置设置一组干簧 幵关, 在其干簧开关一侧设置有偏置磁钢, 电源通过干簧开关、 继电器连通单 片机。  2. The counting device for controlling the start and stop of a single-chip microcomputer by using a sensing signal according to claim 1, wherein two counting magnets of opposite polarities are disposed on the counting wheel, and a set of reed springs is disposed at a position corresponding thereto. Shaoguan, a bias magnet is arranged on the side of the reed switch, and the power supply is connected to the single-chip microcomputer through a reed switch and a relay.
3、 根据权利要求 1 所述的用传感信号控制单片机启停的计数装置, 其特 征是在计数字轮上设置两只极性相反的磁钢, 在与之对应的位置设置一组干簧 开关, 在其干簧幵关一侧设置有偏置磁钢, 电源通过一只干簧开关、 继电器和 具有晶体管或者门电路组成的控制电路连通单片机。  3. The counting device for controlling the start and stop of a single chip by using a sensing signal according to claim 1, wherein two counting magnets of opposite polarities are disposed on the counting wheel, and a set of reed springs are disposed at corresponding positions. The switch is provided with a bias magnet on the side of the reed switch, and the power supply is connected to the single chip through a reed switch, a relay, and a control circuit having a transistor or a gate circuit.
4、 根据权利要求 3所述的用传感信号控制单片机启停的计数装置, 其特 征是电源通过一只干簧开关、 继电器和通过具有晶体管或者门电路组成的控制 电路、 继电器交替连通单片机; 另一只干簧开关直接与单片机连通。  4. The counting device for controlling the start and stop of a single chip by using a sensing signal according to claim 3, wherein the power source is alternately connected to the single chip through a reed switch, a relay, and a control circuit formed by a transistor or a gate circuit; The other reed switch is directly connected to the microcontroller.
5、 根据权利要求 1所述的用传感信号控制单片机启停的计数装置, 其特 征是在与计数字轮相对应的位置设置三只干簧开关, 电源分别通过其中两只干 簧开关和继电器与单片机连通, 另一只干簧开关直接连通单片机。  5. The counting device for controlling the start and stop of a single chip by using a sensing signal according to claim 1, wherein three reed switches are disposed at positions corresponding to the counting wheel, and the power source passes through two of the reed switches respectively. The relay is connected to the single chip microcomputer, and the other reed switch is directly connected to the single chip microcomputer.
6、 根据权利要求 3和 4所述的用传感信号控制单片机启停的计数装置, 其 特征是所说的晶体管是场效应管。  6. A counting device for controlling start-stop of a single chip with a sensing signal according to claims 3 and 4, characterized in that said transistor is a field effect transistor.
7、 根据权利要求 1和 3所述的用传感信号控制单片机启停的计数装置, 其 特征是所述十簧幵关 以釆用霍尔开关。  7. The counting device for controlling the start and stop of the single chip by using the sensing signal according to claims 1 and 3, characterized in that the ten spring is turned off to use the Hall switch.
8、 根据权利要求 5所述的用传感信号控制单片机启停的计数装置, 其特征 是所说的两只与继电器连接的干簧开关与继电器之间至少具有一个二极管。  8. The counting device for controlling the start and stop of the single chip by using the sensing signal according to claim 5, wherein the two reed switches connected to the relay and the relay have at least one diode.
PCT/CN2013/000162 2012-03-21 2013-02-21 Counting device for using sensing signal to control single-chip computer to start up and stop WO2013139166A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201210090267.5 2012-03-21
CN2012100902675A CN102620790A (en) 2012-03-21 2012-03-21 Counting device for controlling turn-on and turn-off of singlechip by using sensing signal

Publications (1)

Publication Number Publication Date
WO2013139166A1 true WO2013139166A1 (en) 2013-09-26

Family

ID=46560847

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2013/000162 WO2013139166A1 (en) 2012-03-21 2013-02-21 Counting device for using sensing signal to control single-chip computer to start up and stop

Country Status (2)

Country Link
CN (1) CN102620790A (en)
WO (1) WO2013139166A1 (en)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102620790A (en) * 2012-03-21 2012-08-01 山东潍微科技股份有限公司 Counting device for controlling turn-on and turn-off of singlechip by using sensing signal
CN103324108B (en) * 2013-06-26 2016-07-06 山东潍微科技股份有限公司 One is used for realizing single-chip microcomputer intermittently used and controls device
CN103592879A (en) * 2013-11-22 2014-02-19 苏州博众精工科技有限公司 Single chip microcomputer with outage counting function

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN2235604Y (en) * 1995-06-27 1996-09-18 司玉甫 Card type microcomputerized tariff metering apparatus
CN2270248Y (en) * 1996-11-06 1997-12-10 邢伟华 Micro-watt consumption precharging controller for gas meter and water meter and its pipe shutting-off
WO2004102130A1 (en) * 2003-03-03 2004-11-25 Flowray Inc. Electronic gas flow measurement and recording device
CN201142136Y (en) * 2007-09-21 2008-10-29 大庆石油管理局 Anti-interference anti-dither signal collection device for pre-payment type card meter
CN102620790A (en) * 2012-03-21 2012-08-01 山东潍微科技股份有限公司 Counting device for controlling turn-on and turn-off of singlechip by using sensing signal
CN202547713U (en) * 2012-03-21 2012-11-21 山东潍微科技股份有限公司 Counting device for controlling start and stop of single chip by sensing signal

Family Cites Families (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN2112176U (en) * 1992-02-21 1992-08-05 杜茂林 Mechanical digital code disc electromagnetic converter
CN2176537Y (en) * 1993-12-10 1994-09-07 鞍山市无损检测防护器材开发公司 Remote measuring device of water meter or gas meter
CN2204076Y (en) * 1994-02-07 1995-07-26 阎晓强 Magnetic induction proximity switch
CN2259650Y (en) * 1995-10-30 1997-08-13 扬州市郊区雄飞机械电器厂 Intelligent card gas meter
CN2421622Y (en) * 2000-05-07 2001-02-28 吉林工学院 One card controller for water, gas and electricity meters
CN201548263U (en) * 2009-11-12 2010-08-11 浙江威星智能仪表股份有限公司 Gas meter with double-display mode
CN201780133U (en) * 2009-12-02 2011-03-30 苏州银河龙芯科技有限公司 Magnetic sensing direct reading character wheels of hydroscope

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN2235604Y (en) * 1995-06-27 1996-09-18 司玉甫 Card type microcomputerized tariff metering apparatus
CN2270248Y (en) * 1996-11-06 1997-12-10 邢伟华 Micro-watt consumption precharging controller for gas meter and water meter and its pipe shutting-off
WO2004102130A1 (en) * 2003-03-03 2004-11-25 Flowray Inc. Electronic gas flow measurement and recording device
CN201142136Y (en) * 2007-09-21 2008-10-29 大庆石油管理局 Anti-interference anti-dither signal collection device for pre-payment type card meter
CN102620790A (en) * 2012-03-21 2012-08-01 山东潍微科技股份有限公司 Counting device for controlling turn-on and turn-off of singlechip by using sensing signal
CN202547713U (en) * 2012-03-21 2012-11-21 山东潍微科技股份有限公司 Counting device for controlling start and stop of single chip by sensing signal

Also Published As

Publication number Publication date
CN102620790A (en) 2012-08-01

Similar Documents

Publication Publication Date Title
WO2020006892A1 (en) On-line monitoring method for metering performance of diaphragm gas meter
US8136409B2 (en) Performing metering using pulse counting
WO2013139166A1 (en) Counting device for using sensing signal to control single-chip computer to start up and stop
CN204286505U (en) A kind of electronic measurement water meter of frost-cracking-preventing
CN203054194U (en) Monitoring system for breaking coil and closing coil of breaker
CN202255446U (en) Hall sensor detection device
CN103953222B (en) A kind of electronic lock detecting lock core rotation direction and method of work thereof
CN201255903Y (en) Wireless remote transmission intelligent meter
CN202547713U (en) Counting device for controlling start and stop of single chip by sensing signal
US9275543B2 (en) Tamper detection for pulse-producing device
CN203323808U (en) Water meter measurement module
CN103592538B (en) outlet matrix logic tester
WO2020200009A1 (en) Intelligent gas meter anti-interference metering system
CN207439480U (en) A kind of comprehensive gas metering equipment of photoelectricity Hall
CN103324108B (en) One is used for realizing single-chip microcomputer intermittently used and controls device
CN106199068B (en) A kind of intelligent power supply delay wind speed meteorological sensor
CN204652345U (en) A kind of novel switched amount input circuit
CN106504427A (en) A kind of gas meter, flow meter and gas-fired equipment
CN206584457U (en) A kind of gas meter, flow meter and gas-fired equipment
CN101826721A (en) Low-voltage switch cabinet fault indicating and alarm system
CN203311187U (en) Control device used for realizing intermittent work of single-chip microcomputer
US6255748B1 (en) Switch status sensor
TW200847572A (en) Over-voltage indicator and related circuit and method
JP2000221069A (en) Flow rate detection device
CN102914340A (en) Water meter with interference failure warning function

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 13764395

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 13764395

Country of ref document: EP

Kind code of ref document: A1