ENCYCLOPEDIA OF RADIO ELECTRONICS AND ELECTRICAL ENGINEERING We construct a valcoder. Encyclopedia of radio electronics and electrical engineering Encyclopedia of radio electronics and electrical engineering / Nodes of amateur radio equipment Valcoder - a device that changes some value depending on the rotation of the axis. Such a thing is found, for example, in a roller mouse or in a music center. Actually, the encoder itself is quite simple, but we will complicate the task by not using a microcontroller, as is practiced in all industrial designs. The valcoder is interesting because it intertwines many techniques used in digital and analog electronics. So TK: to develop a device that changes the output voltage in the range of 0 - 3V, linearly depending on the angle of rotation of the axis. The change in voltage must be reversible, with a number of gradations of at least 80. The output signal must be isolated from the operating voltages of the device (galvanic isolation). Full rise/fall of voltage occurs when the angle of rotation of the axis changes from 0 to 1440 degrees (4 turns). The device must remain operational in the supply voltage range from 8 to 15V. Provide digital voltage indication. 1. Where to start? Let's define what they want from us: A. Firstly, the "head" of the device will be digital, because. will count the pulses generated by the rotary knob.
2. Now let's try to describe the operation algorithm - When enabled, the output is 0. - IF the output is 0 AND there is a pulse from the sensor AND the knob is turned clockwise - add 1 to the output code. - IF the output is 0 AND there is a pulse from the sensor AND the knob turns counterclockwise - do not perform any action - IF the output is 1010000 AND there is a pulse from the sensor AND the knob turns clockwise - do not perform any action - IF the output is 1010000 AND there is a pulse from the sensor AND the knob is turned counterclockwise - subtract 1 from the output code - IF the output is a number other than 0 and 1010000 AND there is a pulse from the sensor AND the knob is turned clockwise - add 1 to the output code - IF the output is a number different from 0 and 1010000 AND there is a pulse from the sensor AND the knob is turned counterclockwise - subtract 1 from the output code. - IF there is no pulse from the sensor - do not perform any action. 3. Draw up a block diagram of the device Obviously, the mechanical part must report both the rotation itself and its direction. So the sensor should give 2 signals. As a result, it turns out that the device should consist of a reversible counter, a matching-decoupling unit and a digital-to-analog converter. The matcher must output an overflow signal and disable the counter from adding (if the maximum is received) or subtracting (if the minimum is received). 4. Designing the sensor Enough water has been poured out, now we can speak more specifically. Mechanics depends on electronics, and electronics on mechanics, so consider the sensor as a whole. It is quite clear that it is much more convenient to use an optical sensor than a contact one, which means we have come to a perforated wheel. Getting impulses is easy, it remains to determine the direction of rotation. There are two ways: use two optocouplers (emitter + receiver) and arrange them in such a way that first one receiver is illuminated, and then the second. Or use a damper sliding on the same axle as the wheel (the moment generated by the axle must exceed the mass of the damper and it must not rotate under its own weight). This damper rotates synchronously with the wheel at a certain angle (no more than 4,5 degrees in both directions) and opens / obscures the additional (strobe) photodetector. This option greatly complicates the mechanics, although it is very simple in circuit implementation (logic "AND"), so let's return to the first option. Now let's estimate the time diagrams of the signals generated by the sensor. As can be seen from the figure, the receiver signals are out of phase by 90 degrees. This is easily achieved by placing the receivers side by side in one line. Thus, when the hole passes over the receivers, the first receiver is illuminated first, then both, then the second.
Suppose the wheel (3) rotates clockwise around the axis (2). When the hole (1) approaches the optocouplers, the right receiver (5) is illuminated first, then both, then only the left one (4). And this is repeated 20 times in one revolution. It can be seen from the above diagrams that a certain strobe signal is formed at the trailing edge of the pulse from the right receiver. We will build the resulting sensor signal on it: firstly, it is generated in a single copy when the receivers are illuminated, and secondly, it perfectly characterizes the direction of rotation. Coinciding with the pulse of the left sensor when rotated clockwise, it makes it possible to isolate a positive pulse using the logical element "AND". To get this miracle pulse, we need a single vibrator to get the desired duration. The initial edge is negative, so it must be inverted. Let's try to sketch a diagram: the OOS loop of a single vibrator is calculated based on the maximum wheel speed - the duration of the strobe pulse should not exceed 1/4 of the period of the "right" signal. The C1R4 chain is calculated based on the fact that the impulse generated by it should be 0,1 Tstr. 5. Let's build the simplest block in the device - a counter I wanted to draw a circuit on triggers, but it seemed to me a completely monstrous mockery of electronics. If interested, a flip-flop up/down counter circuit can be found in any digital IC reference book. Therefore, our task is reduced to choosing a standard counter from the traditional CMOS series. So, let's define the requirements for the counter: - Supply voltage 8-15V - Reverse These conditions are met by K561IE14 As you can see in the picture, the counter has preset inputs. Using these inputs, we can quickly set the required voltage at the output by calling the appropriate code from the external RAM. Of course, a certain bank of saved levels must be created in RAM. The specification does not specify such a possibility, so we use the preset inputs for reset. There is also a count inhibit input (RO). But using it to protect the encoder from overflow will not work. The fact is that this input completely blocks the counter and does not allow it to count even in the free direction, but we need that when the critical level is reached in one direction, the free direction remains free. Therefore, we will highlight the overflow signal after the decoder. With this signal we will strobe input "C". 6. Now you can deal with relatively simple, but cumbersome nodes - a decoder and a digital-to-analog converter (DAC) So, for example, I got a decoder. Nothing tricky: mass decoders and transistor switches for controlling optocouplers and LED-OA semiconductor indicators. The decoders are quite traditional: K561ID1 - binary to decimal converter and K561ID4 - binary to seven-segment converter. The DAC will be built in a similar way. The only subtle point is the definition of ranges. Mapping of adjustment limits to tens and units. We have 7 tens and 10 ones. We divide the total output voltage by 80 gradations: it turns out 0,04. Multiply by 10 - it turns out 0,4. This means that a single discharge regulates the voltage within 400mV. Therefore, the remaining 2,6V is controlled by tens. Now it remains only to pick up the resistors switched by optocouplers and, with their help, build the desired adjustment scale. This is what happened. Author: Pavel A. Ulitin (Soundoverlord); Publication: cxem.net See other articles Section Nodes of amateur radio equipment. Read and write useful comments on this article. Latest news of science and technology, new electronics: Artificial leather for touch emulation
15.04.2024 Petgugu Global cat litter
15.04.2024 The attractiveness of caring men
14.04.2024
Other interesting news: ▪ The music department was found in the brain ▪ Virus-eating bacteria discovered ▪ Men and women have different dreams ▪ Stress makes the body age faster News feed of science and technology, new electronics
Interesting materials of the Free Technical Library: ▪ site section And then an inventor (TRIZ) appeared. Article selection ▪ article Equivalents of TV models of various companies. Directory ▪ Article Nasturtium is large. Legends, cultivation, methods of application
Leave your comment on this article: All languages of this page Home page | Library | Articles | Website map | Site Reviews www.diagram.com.ua |