texts:
About four years ago i stumbled upon some electronics projects on the internet and ever since i fell in love with it. So I started at basic circuits then moved to analog circuits and spent very little there then logic circuits then microcontrollers.
Each step made the abstraction of the next one very clear and easy to 'de-abstract' if i can say.
So after spending some good time writing code in assembly and with the programs growing more complex and longer , the need for another transition for me from assembly to C has arisen.
The thing is that i didn't know any other programming language before learning assembly , and trying to learn embedded C from the current sources i have seems to be very hard for me as i can't 'de-abstract' the meaning of many of the language syntax.
So i would like that good sources for embedded C language learning be suggested which if possible links the explanations to lower language assembly not higher ones that i already can't 'de-abstract'.


texts: VHDL "casting" a constant into a signal?

texts:
Is there a way to cast a constant value into a signal in order to send it into a function's parameter ?

Let's say I have this function:

Function mylogic(signal a, b, c : std_logic) return std_logic is
Begin
    return ((not a) and (not b) and c);
End Function;

And I would like to call it this way:

... mylogic('0',a(3),a(4))...

I cannot send '0' as a parameter because the function expects a signal, is there any way to have it work without declaring another signal to hold the value '0' ?


texts: Practical High Current Transistor Connections

texts: I'm designing a power supply with n+1 redundancy implemented with MOSFETs and an OR-ing FET controller.  The power supplies are each rated for 35.7A output at 28V (TDK-Lambda CPFE1000FI28) and parallel operation behind diodes for redundancy is explicitly supported - so far so good.  Does anyone have any practical tips for making the high current connection to the MOSFET?  I'll add that the MOSFET hasn't been chosen yet.  A monster like an IXFN360N10T in a SOT-227 package is obviously the easiest but the gate capacitance is about an order of magnitude more than the FET controller recommends.  Right now, I'm looking at something like a SUM50020EL on a 3 oz board with ~550 mil traces but was wondering if there's another solution I'm overlooking.


texts: Anomolous behaviour when taking ADC readings

texts:
I'm using ADC on my STM32F407 to read the signals coming from a piezoelectric sensor. I have written my code in such a way that if input crosses a certain threshold, it starts sampling and storing it in a buffer for 10ms. It seems to work fine when I directly connect a piezoelectric sensor to GND and ADC input pin of the microcontroller. But when I bring in a probe of an oscilloscope in order to check the input for ADC(the input goes to both the oscilloscope as well as to the microcontroller), the reading on the microcontroller does not cross the threshold.But the signal on the oscilloscope shows that this threshold is easily crossed. What's the reason for this?

Edit -  I switched the oscilloscope coupling from DC to AC and it works.


texts:
I'm making a project witch contains a battery monitor, the battery has 20 li-po cells in series (84v 60Ah). Now, i studied a lot of battery charges (like icharger 4010 duo) in order to see how they measure the cells, the most common way i found is to use voltage dividers on the input from cells, then a pair of multiplexers then op amp buffers, then differential op amp, then gain op amp. Then in my application fed in to an AVR 10 bit ADC with 5v reff. I made a simplified schematic showing the concept. The resistors will be 0.1% tolerance, and the op amp tl274 in order to keep error am small as possible, but still my concern is that i might not get an 10mV accuracy, because 10 0.1% tolerance resistors in the measurement chain plus gain of 11.
Somehow for chargers this solution works but i don quite get how the get 10mV accuracy.
One way to improve accuracy is to measure and select the resistors to be very close to the needed value.
The problem noise is filtered in the SW.
So any opinions on the circuit presented might be helpful.

Thank you.


texts:
My question is generic in nature about electronics system design. I am trying to put together an RC car which is powered by an AVR Atmega168 chip. It communicates through an HC-12 module and has a quadruple h-bridge chip to move the tires. The schematics is as follows:

The issue is that, without any load, the voltage regulator LM7805 will provide a stable 4.99v output on standalone basis. However, when put in the configuration below with micro-controller sending and receiving data, the voltage drops to 4.72v or so, depending upon how much current is drawn by the components. I am not an electronics engineer but I suppose any system which is powered by batteries must face similar issues and there must be general solution for such issues. In the schematics above, motor is being powered through 2 separate lipo batteries of 3.7v each. The voltage drop is therefore entirely by the 3 ICs.


texts: PC psu 12v and 5v connection in parallel

texts: I want to connect the 5v and 12v rail on a PC power supply in parallel to get higher current. I need a 255 watt 12 volt power supply, so I tried connecting the 5v and 12v rails together but, the power supply turns off when I do. The 12v rail can supply 15 Amps and the 5v can supply 20 Amps. I hope that I will solve this problem. Thanks in advance.


texts: Why is a cellphone charger rated like that?

texts:
Here is what I read on the nameplate of my phone charger:

Output 5V DC 1A. So, I think the Max. Output power is 5 watts.

Input: 100-240 AC 50/60Hz 200mA.

I assume that the mains voltage is 100 volts. If the input is 5 watts, The input current is 50 mA only.

Why is it rated at 200 mA? I think the headroom of rated input current is too much.

I would rate it at 100 mA which means 50% of safety. Can transients reach more than that?

Thank you very much,


texts: Does anybody know where I can find datasheet of this 2*8 LCD

texts:
You can see a LCD wired on a board above. based on the back of its board, it has 8 pin and its seventh pin and eighth pin is connected to VCC and GND. I search in internet for datasheet of this LCD. But I found nothing. Does any one know where I can find it? What kind of protocol does it use to communicate with MCUs?

And how I can monitor its pin to see the data transfers between it and a MCU? (I don't have scope or logic analyser. I want to monitor its pins by an Atmega32 and send the data to my computer's COM port. but I don't have any idea how!)


texts: Can a cheap, low bandwidth, long-distance wifi be physically and electronically possible for public use?

texts:
Since facebook and all the social media warfare, I have realized that the internet is awesome, but not very scalable to embedded devices: new generation network standards are still expensive to make work.

The internet is good for high bandwidth, but the installations are quite static, and I don't really believe that smartphones and tablets will really replace micro-computers in terms of network capabilities.

So my question:
I'm thinking about a CB-radio-like protocol for P2P data transmission.

Do you think a low frequency, long distance, peer-to-peer radio network would be possible ?

If the protocol would provide unencrypted and encrypted mode, do you think people would use it knowing that somebody could try to sniff packets ? Would this kind of physical protocol be possible to integrated on simple phone (does lower frequencies consume more energy ?).

(Could you redirect me to somewhere I could ask this question if you don't have any idea ?)


texts: Why do reverse Bessel polynomials give rise to flat group delay in Bessel filters

texts: I know that a Bessel filter has a maximal number of derivatives of the group delay at 0 equal to 0.  I have never seen an account of what feature of reverse Bessel polynomials makes this so.  Any hints would be appreciated.


texts: Print voltage from ground node in LTSpice

texts:
I can't reverse the node voltage in LTSpice. Take this simple circuit as an example. Ground is node 0 and the other node is labeled as 1.  I would expect .PRINT DC V(0,1) (from node 0 to node 1) gives -1V whereas .PRINT DC V(1,0) (from node 1 to node 0) gives +1V, but the simulation always prints a positive +1V.
How can I print the voltage from the ground node (i.e. voltage from ground node to node 1 = -1V )?


texts: What is the purpose of the Load transistor in a TTL Logic NOT gate?

texts:
My professor presented the NOT gate in the Transistor-Transistor logic as the following:

Where V is always 5Volts. The two symbols are MOSFETs N-type transistors. The first transistor (which is always conducting) is called the Load transistor, and the second is the one who really does the logic operations. (By first I mean the top one, and second the bottom one).

What I'm unable to understand is why does this Load transistor exists. Can't we just plug the Drain of the other transistor directly in V? Why do we have to add a transistor between them?

Thanks in advance.


texts:
I'm trying to design a logo in silkscreen in Altium without importing an image. I find that when I import a design it is made up of a huge number of primitives making it very difficult to work with. Since my design is actually quite simple I would like to design it in Altium.

Essentially what I would like to do is create a square shaped silkscreen (done already done by placing a solid region on the top overlay) and then remove some text from that solid area. Essentially I'm looking for a silkscreen-keepout layer to draw onto.

Does this exist or is there a way to accomplish this?


texts: Run current and hold current to a stepper motor?

texts:
I am programming a motor controller where I have to specify the run current (coil peak current) and hold current (coil hold current) of the motors. The motor I used is a bipolar stepper motor, with a whopping  1.86Kg/cm of stall torque at 1.5Amp current (0.75A per winding) at 1.8 degree stepping angle.

However, the table in the specification makes me confused: It lists a different current for a different torque.

Here is a link to that motor controller.

How could I determine run current and hold current from this specification?


texts: Driving a LCD from a Basic Stamp 2 microcontroller

texts:
I'm not able to drive a UP018D01 LCD Display (www.ic72.com/pdf_file/u/590916.pdf) with my Basic Stamp II microcontroller.

The first step I'm trying to do is to switch ON the LCD backlight.
According to the UP018D01 datasheet we have to send +5 VDC

So I connected UP018D01's GND to BS2 's VSS and UP018D01's HI to BS2's P9.
Then I ran the folliwing code :

' {$STAMP BS2}
' {$PBASIC 2.5}
main:
HIGH 9
GOTO main

Unfortunately the backlight is OFF! What can I do? Where am I wrong ?


texts: Confusion about "host bus controller" and "host bridge"

texts:
Below part is quoted from the book "Beyond BIOS".

  Each host bridge is represented in EFI as a device handle that
  contains a Device Path Protocol instance, and a protocol instance that
  abstracts the I/O operations that the host bus can perform. For
  example, a PCI Host Bus Controller supports the PCI Host Bridge I/O
  Protocol.

And below is the picture with the above quotation:

  Figure 3.3 shows a platform with n CPUs, and a set of core chipset
  components that produce m host bridges.

I think the HB in the picture stands for Host Bridge. I know the Front Side Bus is a synonym of host bus. And bridge is a piece of hardware to connect different buses. So HB is the bridge to connect the host's bus, which is the FSB, to some other device buses, such as PCI.

But what does the Host Bus Controller mean? Where is it in the picture? I guess it's part of the HB/host bridge. Right?

And in the PCI scenario, does the communication flow go like this:

CPU -> FSB/Host Bus -> PCI Host Bus Controller -> PCI Host Bridge -> PCI bus -> PCI device


texts: ADC: Need to convert 10V-32V(from battery 0-32V) range to 0-5V

texts:
I need to convert 10V-32V range from a battery ( full range 0V- 32V) to a range of 0-5V before applying it to ADC.
This is basically to get more resolution in my required range(10v -32V), since most of the battery applications not require sensing below certain range(Li-ion Bat)


texts: How can a buried terminal have different potential than earth potential?

texts:
I am on my 4th year on Electrical Engineering education. Over the years the concept of earth in electric circuits bugged me. And now, again, I came across with something which I cannot understand.
Take a look at this ancient-patent. It belongs to Amos Emerson Dolbear, an eminent man of science: https://docs.google.com/viewer?url=patentimages.storage.googleapis.com/pdfs/US350299.pdf
Here, between rows 14 and 19, he talks about "[...]a ground the potential of which is considerably above the normal[...]" and again he writes "[...]a ground the potential of which is considerably below the normal[...]".
Now,
i) What does he mean by "normal" potential?
ii) How can you make a buried terminal to have different potential than the ground? Terminal is buried, therefore terminal's potential has to equal be equal to the earth potential (which is accepted as zero potential, right? -Who accepts this? Why they accept this? Is there an evidence regarding the level of potential of the soil/earth?). The only sort-of-explanation I can come up with is that he does not reduce the ground resistance considerably. He keeps the resistance between the buried terminal and the earth, hence this allows two different potential levels on the different sides of the earth resistance.
iii) If we accept the icky-explanation above, how does a current flow into the earth? Is not earth, which contains sand, soil, rocks, minerals and mines, organic waste, an insulator? Certainly, it should not be a conductor.
I know I burst out the questions all over, but I am very ethusiastic to understand this.
Thanks for your attention.
-- imp0nderablef1uid
Edit: To make the question more clear, I summarize the question as follows:
i) how can you get different potential than earth potential on a terminal buried into the ground, and, ii) how can this work, i.e. how can currents flow into what seems like an awful conductor?


texts: Why some TRIACs have mouting base connected to the main terminal?

texts: Why some TRIACs have mounting base connected to the main terminal (one such example: BT139) and how to deal with it? Does it need to be grounded if the user can touch the heatsink?


texts: Voltage drop, current increase when two servos connected

texts:
I'm trying two design a bionic prosthetic hand adding control and movement to an open-source Thingiverse mechanical hand.
The main is to move two MG995 when a muscular contraction is performed (reading using myoware adafruit sensor.) The proposed circuit has two 18650 batteries of 2200 mAh each of it, two charged modules TP4056 (one of it for each battery), a voltage step-up MT3608, a Bluetooth module, and an Arduino Nano for control.
The development was proposed using two PCB circuits: one for control (Arduino, myoware, and Bluetooth) and the other for power (2-TP4056 and the MT3608.) Two 18650 batteries are connected in parallel.
The output of the two batteries (3.7 V) after passing through the TP4056 is connected directly to the two servomotors power and to the MT3608 (which boosts the voltage to 10V and feeds the Arduino board through Vin, Arduino regulates the voltages and power up the Myoware and the Bluetooth board through the 5V pin.)
Between the two positives outputs of the TP4056, there is a switch that should be turned off when the batteries are charging (the batteries stop being in parallel mode, and each TP4056 charges each battery, but the input of the TP4056 is always in parallel.)
There is another switch that turns off / on all the circuits after the TP4056 modules.
I attach the schematics of the circuits.

To power 1 servo everything works perfectly, the voltage goes down 1 volt when its moves. The problem is that when I connected the two servos (connected, not even moving) both start jittering and no moving.
Measuring the voltage in the servo input when two servos are connected, I realize that the voltage goes down from 3.7V to 2 volts when they jitter.
I decided then to add another MT3608 between the two TP4056 and the servos boost the voltage from 3.7 volts to 7 volts. The problem still continued, moving perfectly with 1 servo but jittering when both servos were connected.
I decided to increase the voltage from 3.7 to 12 volts and decrease it with a voltage regulator to 7 volts again. It was worse, even not 1 servo has enough power to move.
I thought that the problem was related to the TP4056 module, so I connected the output of the two batteries directly after the TP4056, bridging it, and the problem continues.
Hope you help me guys, have no ideas left.
If you have any other recommendation, all corrections are recived.

UPDATE:
I connected 4 18650 batteries in parallel directly in the power input servos. The 4 batteries feed directly the servos (with 4.2 v when charged) and power the MT3608 (which elevates the voltage to 5 v to Arduino, instead of 12v like the first). There is not any moving, even when just 1 servo is connected!!


texts: How to measure the RF output power of the PCB board?

texts:
I have designed a PCB board, having a RF power amplifier with an output power of  34dBm and two voltage regulators giving output voltage of 2.7V and 3.5V respectively which will be the input to power amplifier.
How to measure the output power of this PCB board after assembling the components?  or  Is it possible to measure the output power before assembling ?


texts:
The LM2575 is a step-down voltage regulator. I want use it to step down from 9V to 5V in order to power my Arduino board and Bluetooth module.

However, I'm not sure how to wire this into my breadboard:

Where does the feedback pin go?
Where does the ON/OFF pin go?

Should I be using capacitors? Finally, will the RF interference generated be a significant problem with my Bluetooth module?


texts: Capacitive transformerless power supply, AC polarity problem

texts:
I have implemented a "Capacitive transformerless power supply" to control a microcontroller-based circuit that contains capacitive touch sensors, and I had an "AC polarity problem"

Surprisingly, the circuit behavior became affected by the polarity of the input AC (Line & Neutral), such that:

When the "Line" of the AC is connected to the 820nF capacitor and the "Neutral" is connected to the 100 ohm resistor --> behavior of the capacitive touch differs from connecting them in vice versa.

I have no idea how could the AC polarity affects the behavior of the supplied circuit?

Is there any reasonable explanation?

This is the schematic of the Capacitive power supply circuit I implemented:

Note that, the ground symbol in the circuit indicates the common point in the DC part, the AC source is only 2 pins (Line & Neutral)

Thanks in advance.


texts:
I've been teaching myself the basics of circuits for the last few months and have been enjoying going into chip schematics. I'm trying to understand why the resistor values are as they are. For instance, for this NAND gate:

Source: Big Code - Discrete TTL NAND Gate

How would one decide, if making this from scratch, to use 4kΩ, 1.6kΩ, and 130Ω resistors? I've noticed 130Ω to be common in the output stage of TTL and would love to understand why.

Please share any information or good book links for me, as well as offer any feedback on how I can improve my posts here. Thanks!


texts:
I'm seeing the schematic of a Notebook HP Pavilion dv9000 (download). On page 17 in the corner left you can see this part:

Two questions:

Why they didn't use a MOSFET instead of MMBT3904?
What's the usage of capacitor C851? haven't seen to use a capacitor for a BJT at its base, so far.


texts:
So I have a PCB with an LCD hooked up along with a 595 shift register. Unfortunately, when I designed the board I didn't realize that the LCD library used SPI, which on the Arduino Uno is pins 13-10. Therefore, the system overrides the pin 12 for the DHT and it returns nan.

The LCD library I used is here: https://playground.arduino.cc/Main/LiquidCrystal

I've tried modifying the pins_arduino.h on line 40 to set the MISO pin to something else. When I debug the MISO value with serial it prints the value I set it to, however it has no effect on the DHT (still returns nan).

So I'm in a sticky situation because literally every single pin is in use except for 0 and 1, and I've everything is kind of set because I've already made my PCB.

Is it even possible to change the MISO pin, if so, am I going about it the right way?


texts: Sine function approximation circuit. How does this work?

texts: The figure illustrates appox sine function by the equation. How does this work? I could guess that quarter cycle of sine wave (0- pi/2) is approximated by the linear equation.


texts: Test Equipment for generating large voltage spikes

texts:
I am trying to test a tachometer circuit which takes large voltage spikes from an inductive pick up and conditions them for TTL logic. I need input voltages in the order of 200V peak-to-peak but most arbitrary waveform generators generally only go up to 30V peak-to-peak.

What is the correct piece of test equipment to use for this? Do I need to make a custom circuit?


texts:
From my last question, I now understand how to use one Z80 PIO chip.

I'm having trouble understanding how I would wire multiple PIOs up, though. The more I think about it, the less sense it makes.

I mean, I can think of a few ways to do this:

Use a demultiplexer with, say, the last 3 bits of the address bus as inputs, and then connect each output to the enable pin of a different PIO chip. The issue I see here is, how do I then use the A/B and C/D pins on the PIOs?
Use the first two bits of the address bus for A/B and C/D pins, and use the rest to indivually select each PIO chip. The issue here is that unless I'm careful whilst addressing the ports, I could enable two PIOs at the same time.

So, none of these two ways seem to be the "right" way to do it. Is there a standard way of achieving multiple PIOs being controlled by the Z80?


texts: Step up in series with step down DC DC and led driving

texts:
I'm having an issue that I can't seem to resolve. I have 100 watts rgb leds that I'm driving with constant current drivers (https://www.amazon.com/gp/product/B019W4C5IE/ref=ppx_od_dt_b_asin_title_o00_s00?ie=UTF8&psc=1)
I replaced the trimmer pot for voltage with a b10k so that I can easily dim the lights, setting the max current on the cc pot so that it doesn't go above my wanted value.
The led chips I'm using have g and b starting to produce light at around 27 28v which is fine as my input current source is 25v max (6s lipo battery that will decrease to around 21.5v when empty ) and these are step up regulators. The problem comes from the red leds that start lighting at 20v and be full light around 25v. These regulators will provide not less than input voltage which prevent me from dimming the red channel. I tried putting a step down to 12v before the step up, it works, but now I'm facing another problem which is that when I shutdown the whole system with a switch and turn on again, the red channel will only give around 1.5 amps on the red channel. I have to turn down the voltage control pot down and then all up again to get back the set 6.5 amps again and I don't understand why.
How can I work this around and why would that be happening?
Thank you


texts: Which are the input/output requirements of a 12V trigger interface?

texts:
For a personal project, I'm building a simple I/O control board for an audio module. This board has an MCU that implements all the I/O control logic, and some interfacing electronics as well. It will be integrated in the audio module.

One interface that I need to handle is 12V level-triggering. The control board must keep powered up my audio module as long as the TRIGGER IN signal is HIGH (+12Vdc), and power it off when it's LOW (0V). I also need to generate a TRIGGER OUT signal (or several of them) in order to pass this "command" to other external audio modules.

This rudimentary triggering mechanism has been around for decades (and is still widely used) in consumer audio gear. It's very common, like a de-facto standard, but I can't find any reliable source of either formal or informal specifications for this interface, like:

Maximum/minimum input/output impedance.
Maximum/minimum input/output current.
Acceptable input/output tolerance on the 12V level.
Maximum rise/fall time, if applicable.
Any other relevant specifications: isolation requirements, inrush current, etc.

So the question is: which are the input/output requirements of a 12V trigger interface? Is there an specification in place for it?

N.B.:

This question is NOT about how to build the interfacing circuits, as I believe I already have a pretty good idea about the route to go (an optocoupler for receiving TRIGGER IN and a low power 1-2W isolated DC/DC converter for transmitting TRIGGER OUT). What I actually want to know is which are the operating conditions that my interfacing circuits must deal with.


texts: Rechargeable battery configuration for 5V

texts:
I have 6x 18650 (3.7v) cells.
I'm trying to build basic power-bank and wondering what battery configuration would
be better for minimizing power loss in voltage regulation/conversion process?

Edit:
Expected load will be less than 1A (at 5V output).


texts: How to drive an AD9850 at 100 kHz/s sweep using arduino or rasberry pi?

texts:
The basic problem I am interested in doing is using an ADXXX chip to make a linear frequency sweep through the HF bands, from 1-20 MHz.  The sweep rate I would like to achieve is 100 kHz/s, which granted is an upper end requirement.

The chips I have been considering are the AD5930, AD9850/AD9851, and the AD9910.  Ideally, we would drive this using either an arduino, teensy, or a raspberry pi.

My questions are the following:

For the AD9850, is it even possible to send bits fast enough to do a 100 kHz/s sweep?  What calculations would I need to do to test the feasibility of this?  At the very least, this would mean the full transaction of transferring the word and changing the frequency needs to happen in 10 µs.
Is running a DDS chip in a linear sweep mode a silly/stupid thing to do?  Quite honestly, I have been told it is;  I have seen a lot of fixed frequency circuit examples.  What are the issues with trying to accomplish this task?

I am looking for ideas on how to direct an undergraduate.  We have focused a lot of time on the AD5930 which seems to have the right features, but we have had difficulty trying to communicate with the chip using a teensy and arduino.


texts:
I’d like to be able to phase shift a raw guitar signal with a potentiometer between 0 degrees and 360 degrees. The signal is roughly 1V peak to peak and has a fundamental frequency range between 80Hz and around 1000Hz and has harmonic frequencies up to around 10kHz.

I know filters have certain phase shift responses across a certain frequency range, but I don’t want to attenuate my signal, I just want the ability to phase shift it at will. Is this possible with a few op amps and passive components?

I don’t care about attenuating the harmonic frequencies but I’d like to keep the fundamental frequencies as intact as possible.

Edit:

@Transistor: My original motivation for asking this question was in an effort to reproduce the oscilloscope effect shown in this video. I think they are achieving the visual effect in the video with the XY mode on an analog oscilloscope and projecting a live video feed of the oscilloscope screen. I believe the channel 1 input is the raw guitar signal and the channel 2 input is a very slightly delayed (ie phase shifted) version of the same signal. When I first started thinking about this problem, I thought that the channel 1 input could be coming directly from the guitar and the channel 2 input could be coming from the end of a pedal board containing some DSP hardware that reproduces the signal with an imperceptible delay, which got me thinking about reproducing the effect using a simple phase shift circuit. Regardless of the method the musicians used to create the visual effect in the video, I'm still interested in whether or not an answer to my original question exists.


texts:
I was looking at the schematic of an old HP power supply I bought. It can be found here, around page 60-61.

This schematic was drawn long before CAD was a tool used by engineers. Things were still drawn by hand. I was wondering how drawing large schematics took place. Today, we are used to our fancy EDA tools that will have a lot of nice features to make good schematics. Alternatively, schematics for documentation are sometimes drawn in vector graphics programs like Inkscape or Illustrator, because they can give neater results.

In our CAD packages we have nice auto-annotation, it builds us a nice BoM if we set it up right, and often they even allow us to extract SPICE netlists for simulation, and a whole heap of other information about design and electrical rules. If we discover that moving this component here makes our schematic more clear, we just drag-and-drop - no need to redraw the entire thing!

The old schematics I see always have nice consistent symbols - not what you would expect from hand-drawn schematics. Did they use stencils to always have exactly the same transistor, resistor, capacitor, etc. symbol? Or were those symbols defined in their dimensions and just drawn and measured out every time again? Do they maybe have little pieces of paper with each symbol drawn out on it, and then just move those around to make the schematic without having to start from scratch every time (I'm thinking about those old IKEA desk-papers where you got little cutouts of their desks and you could lay them out to try out layouts in your office)?

I'm aware this is somewhat of an open-ended question, but I'm curious how things were before we had OrCAD, Virtuoso, KiCAD and Altium.


texts: Using NPN BJT with a P Channel MOSFET to switch 3.3V to 24V

texts:
simulate this circuit – Schematic created using CircuitLab

I have some 3.3V I/O on a PC Board.

When an output is switched on, I need to switch the 3.3V output voltage with a +24VDC and provide by a nice screw terminal with a 24V output.

On all of my previous PCB plans I have used an N-Type semiconductor and switched the ground - However due to the use case of this output, that isn't an option here.

I have drawn the above circuit based on things I've read - and, with simulations in CircuitLab, I believe it works.

The problem is, I'm not really sure how it works.

Could someone explain to me, what, why, and how, this is working - and suggest if there is a more desirable way to draw this circuit?


texts: Where can I find a Bluetooth chip capable of shipping in bulk?

texts:
Why is it that places like Newegg can sell consumer Bluetooth products for less than $10, but the only Bluetooth modules I can find on Mouser or Digikey cost close to $20?

I am looking for the cheapest way to support bidirectional communication via Bluetooth SPP. Does anyone know why these chips are so expensive?


texts: Sending multiple data between the two NodeMCU using Serial communication

texts:
I'm working on communicating between the two NodeMCU basing on the serial communication protocol. I've used SoftwareSerial and ArduinoJson library for my program according to some sources on the Internet. The problem is at the stability of the reading value from Serial. As far as what I saw on the COM monitor, it was either lack of data or appeared some odd letter. I want the two Node to be able to send and receive data from each other but the instability has stopped me in the first direction. Anyone's help will be appreciated. I'm trying to apply UART because of its simplicity and speed but the suggestion of another solution with other protocols would be great. The code of the transmitting node and the receiving node was attached below:
The sending program
#include <ArduinoJson.h>
SoftwareSerial s(D5,D6);
byte C1;
void setup() {

  pinMode(D0,OUTPUT);
s.begin(115200);
}

void loop() {

  //Sending code
   StaticJsonBuffer<1000> jsonBuffer;
  JsonObject& root = jsonBuffer.createObject();
  root["Temp"] = 100;

if(s.available()>0)
{
 root.printTo(s);
}

The receiving program
#include <SoftwareSerial.h>
SoftwareSerial s(D6,D5);
#include <ArduinoJson.h>

void setup() {
  // Initialize Serial port
  Serial.begin(115200);
  pinMode(D0,OUTPUT);
  s.begin(115200);
  while (!Serial) continue;

}

void loop() {

 //Receiving code
StaticJsonBuffer<1000> jsonBuffer;
  JsonObject& root = jsonBuffer.parseObject(s);

  if (root == JsonObject::invalid())
    return;

  root.prettyPrintTo(Serial);
  Serial.print("Data 1 ");
  Serial.println("");
  int data1=root["Temp"];
  if(data1==100)
  digitalWrite(D0,HIGH);
  else
  digitalWrite(D0,LOW);
  delay(100);
}


texts: Need help selecting the right speed controller for a 3-phase AC motor

texts:
This a three-phase single-volt 5-HP AC motor salvaged from a treadmill with a busted controller board.
The goal is to salvage the treadmill. Originally I was trying to repair the controller board.
I've decided to try a simpler approach of replacing all the digital stuff with just a basic manual motor speed controller. But I'm having trouble selecting the right part for the job.
More about the motor. Six wires in total. Three wires control the phases, one for ground, the other two are thermostat leads.
All I'm really looking for is a hand dial that controls speed reliably and smoothly and doesn't burn out the motor or create jerky motion. My understanding is that some sort of VFD regulator is required. But I'm having trouble selecting one that would result in reasonably smooth performance from 0 mph to a reasonably high speed without damaging the motor.
Speed/distance sensors and digital interfaces are cool, but maybe in some future project. I need to walk before I run. Pun intended.


texts: SN74LS245N outputs 1 Volt when OE is high, 0 Volts when OE is low

texts:
We have been making a Register. When we write all ones, it works fine. When we enable it back onto the bus using 74LS245, it doesn't enable. We used our Multimeter to measure the volts. It seems to have 1 Volt when the Output Enable is high, and then 0 Volts when Low. This is number one not enough to power our LEDs, and number two not the output we expected.

Note; this is based off of Ben Eater's model.


texts:
I would like to understand how the computation process causes the processor to get hot. I understand that the heat is generated by the transistors.

How does the transistors generate the heat exactly?
Is the correlation between the number of chips and the heat generated linear?
Do CPU manufacturers optimize the positions of single transistors in order to minimize the heat generated?


texts: Is Write/Read pin in LCD is need to changed every time? Or is it ok if we fixed it to write only?

texts: We are using 16X2 LCD. In that we are only going to write to LCD we are not going to read anything from it. Is it ok if we put it as write pin ? or every time after writing do we need to change it as read pin? Is there any problem if we only use it for writing. (My friend was saying if we use it as only write pin over the period junk character issue will come .) Is it true??


texts: problem with LED matrix and raspberry pi

texts:
I have a raspberry pi model B+ and an 8x8 LED single color matrix. I connected 8 GPIO pins to the 8 row pins of the matrix and another 8 GPIO pins to the 8 column pins. Note that I am a beginner in this, so have some questions. I have observed by a few tests that if I assign Vcc (HIGH) to the rows and ground (LOW) to the colomn, the LED lights up.

def enlight(i, j):
    GPIO.output(row[i],GPIO.HIGH)
    GPIO.output(col[j],GPIO.LOW)

If I want the LED of coordinate (2,3) to light up, I would set row2 to HIGH and col3 to LOW.

The problem arises in the following scenario. I want two LEDS i.e (0,0) and (1,1) to turn on at once.

    enlight(0,0)
    enlight(1,1)

but instead of only these two, I have two more LEDs turned on i.e (0,1) and (1,0) ; which is quite reasonable because I am setting row0 and row1 HIGH and col0 and col1 LOW. So these 2 pairs of rows and columns are going to intersect in 4 points, hence four points lighting up. To avoid this , I created a delight() function which basically does the opposite of enlight(), i.e setting row to LOW and col to HIGH, turning off LED. In order to light up both (0,0) and (1,1) at once, without any other LEDs turning on, I command it to:

while true:
    enlight(0,0)
    delight(0,0)
    enlight(1,1)
    delight(1,1)

By this, an infinite loop occurs and (0,0) LED is blinking infinitely and just at the moment (0,0) LED is turning off, LED(1,1) is turning on. All of this happen so fast that human eye can't distinguish the blinking and instead sees both LEDs constantly on.

My question is, is this "trick" actually a good trick? Is this how major programs related to LED matrix are done? Or is there any other ways to do so? If there is, please explain in simple terms.


texts: At what voltage is a NiMH battery empty?

texts:
I have a battery pack of NiMH batteries. It is ten cells with 1.2V, 4000mAh each, put together in series. So rated voltage is 12V. After charging, i.e. when the charging device says that it is finished, I measure 14.3V.

When I now discharge, at what voltage should I consider my battery as "empty"? Is this the lowest voltage that I can discharge it to without damaging it? Which voltage is that?


texts: Finding upper cutoff and lower cutoff frequencies on notch circuit

texts:
I need to find upper cutoff (UCF) and lower cutoff (LCF) frequencies based on formulas of a notch circuit, but I'm getting a quadratic equation (as expected) with an imaginary number (IN; not expected.)
I tried to solve this equation transforming the IN to polar coordinates then cutting off the angle (which gave me f'=2MHz and f''=2,57MHz, values very far from what was expected - something around fo.)
How can I find these frequencies?
This is the circuit I've been working on.

This is the formula I used to find UCF and LCF. (Which are represented by f in the formula.)

Some values I have already found:

Zp:21256ohms
Rp:123000ohm
Qp:70ohm
fo=2,269MHz

The roots of the formula fo will be the lower cutoff frequency and the upper cutoff frequency.
I also tried to solve this by calculating the bandwidth (BW), then

UFC=fo+BW/2
LFC=fo+BW/2
Other formulas I used can be found on this photo:


texts: Fake nominal capacity of 18650 batteries?

texts:
I have bought, from different sellers,  two 18650 batteries, but it seems that the capacity is much lower than the 4500 mAh or 3000 mAh label.

In real life, it seems to be able to draw a constant 500 mA during 1.2 hours, not more.

I have charged them with a TP4056 module that seems to have good reviews on the internet.

Are there some tricks to be able to use 18650 at their best?

Or is just that the  ebay UltraFire 18650 batteries I purchased were really bad?

(If so, what would be better manufacturers? I would understand if product recommandation might be off topic, if so, do you have ideas of places that analyze this subject?)


texts: I have bought a level sensor. I cannot find any documentation except this on the linked page. How do I use it with Arduino or anything else?


texts:
I am currently developing my own homebrew GameBoy game and I would like to try some tricks to reduce power consumption (for the sake of learning).

The GameBoy has a HALT instruction that will stop the system's clock until some interrupt is fired. I would like to use it as much as possible but I need a way to verify that it does indeed reduce power consumption. I am quite a beginner in electronics so I'm not sure how to go about it.

My first idea was to use a multimeter between the AA battery and the GameBoy battery pins but I think it will not be helpful as the value displayed would vary a lot and will be unreadable (it is not an average value).

What I really need is a way to compute the average power consumption for a given time duration. Is there any cheap way to do this ?

Also can I assume that voltage will be constant and that measuring average current is enough to computer power?


texts:
This is one of my homework problems and I'm not sure if it is frowned upon to post these kinds of things here but I am very stuck. It seems like VR3 would just be a constant 4V but then I think about how the capacitor may affect it and I cant comprehend how I would make a differential equation for it.

I can make a thevenin equivalent circuit for the two different circuit configurations but I don't know how to "combine" the two solutions for the DE's I would get.

Any help is appreciated!


texts: Does Thevenin's theorem apply in power plants?

texts:
I know when we analyze a circuit's Thevenin equivalent, the best we can ever get is 50% power transfer to the load. I would assume that this holds true for power plants (source) and the rest of the grid (load). I realize this is a fairly simplified view.

Anyway, I'm taking a thermodynamics class in mechanical engineering this summer and we toured a cogeneration plant on campus. I asked about this at the plant, but neither the plant manager nor my thermo professor seemed to know what I was talking about.

This graphic below was produced from data collected by the DOE at LBL. The 62 units lost in the power plant could mean imply the efficiency of a typical power plant, or be half of the current maximum of about 60% efficiency divided in half due to Thevenin. Any way, this is just speculation. I'm hoping a power engineer can weigh in?


texts: How to wire a 5V 6-pin relay switching 110V AC @ ~35 W

texts:
Update:
Thanks for the help -- working circuit below!

I am trying to turn on a 110V AC array of LEDs with a small 5V relay with some explosive results!! :-)

I am not doing something right as I have successfully blown-up two of my relays...

Relay: HK4100F-DC5V-SHG

Spec Sheet: https://img.ozdisan.com/ETicaret_Dosya/445413_4369639.pdf

There are 6 pins, the middle two pins are the coil. When I apply 5V DC I can hear it clicking which I think is expected operation.

I attach the load (array of LEDs) on the left of the photo.

I attach 110V AC from a wall socket on the right side.

Case 1:

a) No voltage to Coil.
b) Load and Power Source attached
c) Result is the LEDs are quite dim.
When I applied DC to coil the LEDs went out.

I'm not exactly sure why my relays exploded on subsequent attempts. Could it be that I reversed wires on the load, or power source? Should this even make a difference with AC?

Hoping this makes sense!

Update:
Working circuit below:


texts:
Suppose we have a signed 12-bit output which is capable of representing both positive and negative numbers, how can this be converted to a +/- 10v signal using DACs, op-amps, etc.

For example, 1100 1011 0111 would result in a negative voltage and 0111 1101 1000 would result in a positive voltage.

What formula could be used to calculate the desired voltage(+/-)?


texts:
when I studied ideal transformer i understand that the flux induced in the primary circuit should be equal to the flux induced in the secondary circuit, and according to Lenz law they should cancel each other so the net flux flowing the in the core should be equal to zero.
then we move to the real transformer, i saw that the difference between the primary and secondary flux should be equal to the mutual flux which NOT reaches zero, and if the difference equal to zero so the transformer will not work and induce current in the secondary will equal to zero.
So why in the ideal case we want to the difference to be zero while in the real case we deal flux difference as the important flux? and from where this difference come from ?


texts:
We were doing an experiment on how to get the battery reading. we will be using a resistive voltage divider with a LM741 op-amp and we were wondering what resistor values is the best to use for the r1 and r2 given that our battery source is around 8v.

thank you.


texts: Creating large custom shape pads in Autodesk Eagle

texts:
I'm pretty new to Autodesk Eagle and trying to design a captive soil moisture sensor probe in Eagle. The shape I'm trying to create is:

I would appreciate it if anyone can help me with any advice on this.
Thanks.


texts:
I wanted to know if I'm correctly thinking.

The idea for current limiting is to force the opamp to output the correct voltage to control the MOSFET. So the maximum voltage possible is somewhere around 12v.

The idea is to have a negative feedback to a certain voltage and have a positive feedback before a sense resistor.

For example in the following example, I wanted to current limit the load at 3A with a resistor of 0.1 Ohm.

At 3A, the voltage dropped by the sense resistor should be 0.3v. With that in mind, we can then compute the voltage divider for the positive feedback.

If R1 is 100K and we want to get 0.3v at the positive input then we have to drop 11.7V through R1. Which will let 0.000117A through R1. With that in mind we can compute R2 with:

V = IR
0.3V = 0.000117A * R
2564 Ohm

With that, no matter which load will be present,  the sensed voltage in the positive feedback will never be higher than the one at the negative feedback. Which in return limit the current.

Also, R2 could be a potentiometer to regulate the current limit or the whole voltage divider could be replaced by PWM input.

One last thing, In my simulation it kind of work and I guess I could probably build it to try it out but there is one thing I'm still unsure. For some reasons, I tried to reverse the feedback +/- and it still work. For that reason, I'm not sure if polarity of the opamp actually matter or it is really dependent on the op-amp spec.

From what I understand, op-amp are trying to make both input equal by changing its output. In this case, only the positive input is driven by the opamp while the negative input is fixed. But I guess my assumption here is wrong and the order actually matters.

simulate this circuit – Schematic created using CircuitLab


texts: If I drove pin DP8 high, would the MOSFET Q1 let current pass?

texts:
I have this circuit in my hand.
If I drove pin DP8 high, would the MOSFET Q1 let current pass or would it not let it?
I also have the same question for DP9. What would happen if I drove the pin DP9 high or low via Arduino? This is my first experience with MOSFETs. So I am sorry if I ask something very basic.


texts: Can I put 2 voltage regulators (5V) in parallel to dissipate the heat better?

texts:
I connected around 10m of christmas light LEDs to a 5V voltage regulator (lm7805). It gets quite hot, put I can still touch it without burning my finger. So in is within its temperature range (120 C max). It's a self regulating voltage regulator so I am not affraid of it burning itself.

But to ensure that my christmas tree wont burn, can I put 2 regulators in parallel to dissipate the heat better?


texts: difference between single double and three phase

texts:
If single phase is 230 V and 3 phase is 440 v then what about for 2 phase?
And why is it so?


texts: Calculating the amount of torque needed to turn shutter

texts:
I'm working to design a motor to control a mechanical shutter. After considering some other possibilities I have decided to try using a stepper-type micro motor. We're using a shutter from Edmond optical. I'd like to pair it with one of the Micromo stepper motors.

The critical datasheet specification seems to be the holding torque which is rated as nMn. I take this to be Millinewton/meter. I rigged up the shutter with a simple pulley and found that a weight of 12.8 grams was sufficient to turn the shutter's lever (which opens and closes the aperture).

This explanation might benefit from a diagram, so I drew up one to illustrate the experiment:

If w=mg then the weight exerts a force of 126 mN on the lever...ignoring the geometry of the pulley and that the lever turns on a circular orbit. My naive self imagines that I need a motor which provides a torque of more than 126 nMn. Is this a correct estimate?

If so it seems all the Micromo stepper motors are too weak to turn the shutter.


texts:
I have seen dozens of different real-time clock chips on the market, as well as a number of processors with a built-in separately-powered real-time clock module.

Nearly all of them not only store time as year-month-day-hours-minutes-seconds, but even the individual fields are stored in BCD rather than binary format.

Is there some underlying reason for this?

Are there any microprocessor applications that do anything more sophisticated than simply display a clock where the BCD format is more useful than binary, or where year-month-day-hour-minutes-seconds format would be more useful than a straight 47-bit count of oscillator state changes?

From what I can tell, it seems RTCC makers add a lot of extra circuitry to make their chips less useful; the only reason I can figure for RTCC modules in processors to behave that way is that the processor vendors use some pre-existing BCD implementation rather than producing their own.


texts:
Say I have a signal driver operating at 50 ohm output impedance, driving something with high (hundred kilo-ohm) input impedance. If the wavelength I'm using (a few kilohertz) is much longer than my chord length (a couple feet), then I understand that standing waves cannot develop..

But, do I need to worry about the reflection causing damage to my driver? I guess a back-reflection always occurs if you have an impedance mismatch. Why do we usually only worry about this sort of thing when standing waves are possible, typically at 'high' (RF) frequency?


texts:
I am building DIY digital clocks as a school side project. I need to generate a 1 hZ clock signal. I currently have some 32.768kHz crystals but I need to choose an IC.

I don’t want to build the oscillator circuit. Would rather use a IC.

I’ve seen suggestions on here to use the CD4060 with a flip flop to divide the clock down to 1 Hz.

Another suggestion i’ve seen is to use a CD4521 because supposedly it can directly take a 32.768kHz crystal to produce a 1 Hz signal. This seems like the better option but can anyone confirm this?


texts: Scope says 59.9 Hz .. yet I can't measure turntable speed

texts:
I needed to measure a turntable's number of revolutions per minute, but didn't have any incandescent lamps around. So I rigged an LED to an ESP8266 SOC and programmed it with delays to output a 60hz square wave to the LED. The scope confirms 60Hz +/- 0.2. Unfortunately, it doesn't work as I can't get a reading on the stroboscope disc.

I know I am missing something .. and it might have something to do with a DC square wave vs. an AC sine wave. Can you show me the direction?


texts:
I have soldered two wires onto this Cree XHP 70.2 LED, tested it in a circuit, and everything works fine.  I intend to wire four of these LEDs in series and drive them together at about 48V and 2.4A (12V each).  My only concern is how close the solder is to the copper LED backplate (see images below).

I'm worried that it might arc to the backplate and create a short circuit, bypassing the LED.  Is this a legitimate concern?


texts: Vias not visible after Eagle Cam Processor

texts:
I am trying to generate a printout of the PCB using Eagle Cam processor to get it made.

My settings are as follows:

Section: *
Device: PS
Style: pos. Coord and Fill pads are enabled
Layers: top, pads and vias for the top; bottom, pads and vias for the bottom

Unfortunately, my vias/holes are not visible in the output file. Am I doing anything wrong?


texts: Sequence detector design demonstration in LTSpice

texts:
This is my first time posting on this board, so I am a little unfamiliar with what I am supposed to put in my question. The sequence I have to detect is 1010... including the overlaps. I am using LTspice to simulate the circuit and am primarily interested in proving that the circuit works by means of the waveform plot.
The schematic for the design I came up with is as follows:

x is the input signal which is 1010....
The waveforms that I get look like this :

(green = clock, blue = input signal (1010...) and red = output)
which I am confused about because the output shows spikes , whereas I am expecting a sustained square
pulses for 1 complete clock cycle. But the spikes appear at the right places (when the input sequence has completed 1010)
In summary, I have two questions

Am I setting the voltage sources to the correct values for the purposes of this demonstration ?
If yes, then why am I getting spikes instead of a square pulse till the next clock edge ?

I will admit that I have a very basic working knowledge of LTspice so if I am doing something wrong I am more than happy to learn thanks! Following is the netlist:
XU1 N002 clk N004 NC_01 D_FF
XU2 x clk N005 N006 D_FF
XU6 N004 x N006 N003 AND_3
XU7 N003 N001 N002 OR_2
XU4 N001 N004 y AND_2
XU3 N005 N007 N001 AND_2
XU5 x N007 INV_1
V§clock clk 0 PULSE(0 5 1ns 1ns 1ns 1ms 2ms)
V2 x 0 PULSE(0 5 1ms 1ns 1ns 2ms 4ms)
.tran 20ms
.lib DigitalLogic.lib
.backanno
.end


texts: What is the "field-weakening" operation?

texts: I'm studying brushless and induction motors, in my studying material "field-weakening operation" and "field-weakening region" are often cited without an explanation. As far as I understood is a method to weaken the rotor flux by controllig stator currents according with the physical voltage and current constraints, but i don't understand what is the final goal.


texts: Connected my audio input to two music systems by splitting the input, but the one with subwoofer produces continuous 100Hz hum

texts:
I have 10 year old Creative 2.1 audio system that has fairly capable subwoofer, and combined its input with a TPA3110 2x15W stereo amplifier module (for better treble). When both systems are powered together the subwoofer produces a humming sound of around 100Hz(noticeable when no music is playing), and it goes away when later is turned off(while still connected). Creative system (uses TDA8510j IC) uses 11.5V 18.4VA AC adapter, and TPA3110 is given 12V 2A DC adapter. Here is screenshot of audio spectrum app.
How do I get rid of this hum? I confirmed there is no continuity between power supply ground and input ground terminal (of both), thats why I connected them directly in first place.
PS: Electronics is not my subject, I do this as hobby.


texts:
I have a laptop with HDD. The cable connecting the HDD to the motherboard is torn and thus the HDD doesn't work. I was wondering if I will be able to do the replacement myself. The cable I am looking for is a ribbon sata cable (in this document, on page 33 the cable with number 5 pointing at it).

My question is how can I find exact part I am looking for?


texts: Sorting of data from instructions ( ARM I-cache and D-cache )

texts:
Some ARM cores like the ARM9 family of cores have a Harvard Architecture, at least at the cache level. That is they access two seperate caches, an I-cache for instructions and a D-cache for data ( example ARM926EJ-S ).

However the I & D caches wind up being interfaced to plain vanilla SDRAM externally. So it seems that at the RAM level we are back to the von Neumann design where one store ( SDRAM ) holds instructions >and< data.

In the example designs I've seen there seems to be just one single bus interfacing the SDRAM to the SOC chip.

How are the instructions and data differentiated, sorted and routed from the combined bus interfacing the external SDRAM to the internal I and D caches?


texts: why base stations have 2 receiving antenna and only one transmitter?

texts:
I read that a base station is divided up into sectors to accommodate multiple service providers on a single tower.
why each sector has two receiving antennas and only one transmitting antenna,
As we require more downlink than uplink?


texts: Simple step-up voltage regulator from 3.7V to 5V?

texts: I have a 3.7V 4.4Ah li-ion battery and would like to use it to power my Raspberry Pi (which needs 5V and 700+ mA). What’s the easiest way to do it with minimum EE experience? Also, what resulting running time can I expect?


texts: Smartphone Gyroscope Range (radians / second)

texts:
I'm using gyroscope recordings of Android Smartphones. The measurements are in radians / second. I recognized that sometimes there are some outliers and also the range is different between smartphones. Thus, currently I'm clipping at -20 and 20 radians / second for each dimension (x,y,z).
I don't know if 20 radians / second for rotation of a smartphone is much or not. Is this a reasonable value or what clipping values should be used?


texts: Can WD40 be used to mitigate water damage on electronics?

texts:
I've heard the advice that WD40 is designed to repel water, and hence, it can supposedly be used to mitigate water damage in electronics. Such as for a device that was submerged, instead of simply allowing it to dry, which might take a very long time, especially in tight places, under components, etc, and allow more oxidation to occur. Spraying WD40 into the device and the tight spaces, supposedly mitigate this problem to some extent.

Is there any merit to this at all, or will it simply make the problems even worse?


texts:
I will be building a 4 propeller quadrocopter drone at some point. I want to make it relatively easy to fly by getting it to hover still when the controls are not touched.

Can someone offer some information on how I'd get the quadrotor to stay put in the air? I was thinking accelerometers to measure drift and roll/pitch/yaw, but they're not sensitive enough to detect very slow drift due to, for example, a light breeze. Is GPS accurate enough to stamp out drift on the 10cm scale (that is, detect a 10cm drift (or less, maybe?) from the drone's original position)?


texts: How do I calculate the necessary resistance for a voltage divider?

texts:
I’m self-taught, and this is a little bit of a thought experiment for me to understand Ohm’s Law better.

I have a very simple voltage divider. Given a 15V DC input, each of three 4.7KΩ resistors cuts the voltage by 33%. I started doing some experimentation, and discovered that no matter what voltage I applied to the circuit, the resistors always cut the voltage and amperage by 33% each.

But let’s say I wanted to create the same circuit and didn’t know the necessary resistance?

Given a 15V input and desired outputs of 10V, 5V and 0V, how would I calculate the necessary resistance to use? Is it possible to create a voltage divder that does not have proportional drops (e.g., let's say that from this same circuit, I want 14V, 12V, 5V and 0V)? And how does that math work? I think where I’m getting stuck is whether to use input voltage, output voltage, or change in voltage as the V value.


texts: Why the noise from cascode transistors are negligible at low frequencies?

texts:
I am reading about noise of cascode amplifier in Razavi book, Design of Analog CMOS Integrated Circuits.

However, I couldn't understand the yellow highlighted sentence below. Could anyone explain it?

Why the noise from M3, M4, M5 and M6 are negligible at low frequencies?

Thank you.


texts: Inductive sensor signal voltage too low, how to boost it for Arduino?

texts:
I have an Inductive proximity sensor that is listed as working with 5v.

M8 2mm sensing DC 5v Inductive Proximity Sensor NPN NO LJ8A3-2-Z/BX-5V

It was the model recommended.

When using 5 V, I get 0 V, and only 2 V when triggered. Using 12 V, I get 0 V  and 2.85 V triggered.

I'm using this with an Arduino Mega, and the 2.85 V is not being read as a HIGH.

What can I do to boost the voltage to trigger the Arduino?

What is the voltage threshold to go High on the digital input?

I have set PULL UP resistor in the arduino Mega (5 V).

I was thinking using a transistor or resistor?


texts:
I have two different voltage sources that can supply a LR load. I need a mechanical DPDT switch that can be used to choose the voltage source. When used properly the switching between sources would occur when neither voltage source is on. One source can supply up to 200A at 100V continuously at frequencies between 1000-5000 Hz whereas the other source supplies short bursts (approximately 250 us) at as much as 8 kA. Here is my two part question:

(1) If the switch is made when neither source is on (proper use) then I suspect that the current and voltage ratings (or maybe just the voltage rating) of the switch isn't very important. I would think that as long as the conductors within the switch are as thick as the wire carrying the current then it will work safely (as far as the hardware is concerned). Is this correct?

(2) However, I should probably consider using a switch that will be safe even if the switch is thrown improperly (ie. thrown when the 200A - 100V source is on) in which case the current and voltage becomes important for safety reasons. What type of switch should I use? A knife blade is simple but not particularly safe for the operator of the switch.

Thanks!


texts:
Every integrated circuit, like any other component, have a working temperature range. The minimum ranges are in the commercial grade (if I did dot forget something), while the military/aersopace grade had the wider one.

In what category falls an CPU, or GPU that we are using in our PCs? I see many people scared (mainly enthusiasts) when their PC is working at 60°C. Looking around, I found some indications on some AMD processors (I have one of these) in which AMD recommends to not reach temperatures above 73°C. Does it means that we are in a grade even lower than the commercial one? Or it is a safety measure?

Are those enthusiasts too much paranoid?


texts: How to calculate the capacity in a system of capacitors

texts:
How to calculate the capacity of the capacitor "C" given that the equivalent capacity of the system of capacitors in the figure is \$C_{eq}=9.22~\mu\mathrm{F}\$. Can you tell me also the relations between the capacitors? I mean if they are in series or in parallel.

$$
\begin{align}
9.22~\mu\mathrm{F}&=\frac{\left(\frac{12~\mu\mathrm{F} \,\cdot\, 8.35~\mu\mathrm{F}}{12~\mu\mathrm{F}\,+\,8.35~\mu\mathrm{F}}+4.25~\mu\mathrm{F}\right) C}{\frac{12~\mu\mathrm{F} \,\cdot\, 8.35~\mu\mathrm{F}}{12~\mu\mathrm{F}\,+\,8.35~\mu\mathrm{F}}+4.25~\mu\mathrm{F}+C}+7.22~\mu\mathrm{F},\\
\\
C&=2.6~\mu\mathrm{F}.
\end{align}
$$


texts: How are the Intersymbol Interference and Symbol Time (duration) related to each other?

texts:
In a lecture slide I noticed that OFDM(Orthogonal frequency-division multiplexing)  mitigates the problem of Intersymbol Intereference over wireless systems because the symbol time is increased, in the case when we multiplex a channel into two subchannels, each with bandwidth half of the bandwidth of the original channel.

However, I can not grasp how the length of the Symbol time is related to Intersymbol Interference?


texts: Strategy for up to 40 ADC inputs using alert feature

texts:
I'm working on a project where I want to monitor 40 phototransistors (IR breaker beams), but without having to constantly poll the ADCs. Ideally I'd want a digital pin pulled when one of the beams is broken and then I'll poll the ADC(s) to find out exactly which one it was. I'll also need to be able to detect a change on each input regardless of the state of the others.

I see there are ADCs with programmable GPIOs and dedicated alert pin(s). I'm just a beginner, and I find - particularly with the programmable GPIO varieties - the datasheets confusing and I doubt I have the experience to successfully make use of those.

Then the variety with dedicated alert pins seem to be easier to program but don't seem to come any larger than 8-channel. Fewest parts please, particularly since the incredibly small IC packages will likely be hand-soldered. AD7997 is currently the chip I'm considering, but would require 5 TSSOP footprints. I would probably AND the alert pins together to the host.

Are there any other ways to do this? Thanks for your input.

More project details: Beaglebone black, Node.js/bonescript, Phototransistor is the LTR-301.

UPDATE 1

Breaker beams will be broken or unbroken for large amounts of time.


texts: How does the inductor ''really'' induce voltage?

texts:
I'm trying to understand the concept but I can't find what I'm looking for. Sorry if I'm wrong at some points as it's the first time I'm studying these stuff.

I understand that when I have an RC circuit the electrons gather at the one plate of the capacitor repelling the next electrons coming , therefore reducing current.Similarly the other plate's positive charge increases creating a potential difference or voltage.This explains to me why current decreases and why voltage increases over time.

Back to inductors now .Let's say we have an RL circuit and I close the switch.The current trying to flow through the inductor will cause a magnetic field around it the direction of which can be found easily with the right-hand rule. The inductor, however, hates change and will try to oppose this change in magnetic flux inducing a voltage.It will be like a battery with the polarity the wrong way.So that is 'why' the voltage is induced. But 'how' is the voltage created because of the change in flux? And how does this voltage progressively get to zero?I know that happens because ΔΦ gets smaller but why doesn't the current stop increasing until the voltage becomes zero?And why does change in flux stop occuring all of a sudden? I'm really trying to find the words here..


texts: The relation between the current and frequency in ohmic resistance

texts:
In the Figure above, I was asked to determine which diagram refers to the relation between current frequency and the intensity of the current in an ohmic resistance.
I am confused between (2) and (3).
Why (2)? Because it is an alternative current, and it is determined from the equation:

  i(max)= Vmax/R (R is constant but Vmax=NBA(2πf)) so current would be proprtional to frequency.

Why (3)? Because I thought that in the AC source both voltage and frequency are adjustable as desired, so the change in frequency doesn't imply a change in voltage, so the intensity of current would be stable.
But anyway, I am waiting your help to understand what is the correct answer.


texts:
I have a DiffAmp AD8132 following an OpAmp LT1818. A 1.5V voltage source, such as voltage divider, voltage reference, or voltage regulator should be connected to the B input pin of the DiffAmp to compensate for the offset of the original signal. I was wondering if output impedance of a voltage source would be as crucial as for Vref pin of the In-Amp, which is discussed in this thread.

I plan to connect the output of the OpAmp directly to point A, and a voltage source  directly to the point B. If the impedance matter in this case too, then which voltage source would be the best choice? Do I need any additional compensation resistors before the A and B? The Vcm (pin 2) of the DiffAmp is set to 1.5V to provide a common mode signal at the output.


texts:
I have a few Li-ion batteries which I want to use in series to have max voltage. But the problem is that the charger I have will not be able to charge the batteries in series, but will be able to charge them in parallel.

So how can I connect the batteries in a way that I will be able to charge them in parallel but use them in series? I'm new to these Li-ion batteries and i have seen the damage they can do I wrongly handled, hence I am not so eager to experiment with something that can blow up in my face, literally, hence the question here.

Regards

PS: Batteries are Samsung 18650 all are working


texts:
I'm designing and building a linear power supply for my tube headphone amplifier. Considering this should be HiFi, I'm trying to make it as good as it gets within "normal" building costs and without building a discrete regulator.

That being said and done, I think I have finalised the schematic (any feedback would be welcomed really). Now, I am working on the layout and I'm trying to decide between using a ground pour or a star ground topology. PCB will be single sided (etched at home), so considering layout simplicity, a ground pour would be advantageous, but I would not want this to deter performance. From what I read, it might not matter so much in this particular in this implementation, as I'm not dealing with RF frequencies, but I'm open to any ideas still.


texts: Aluminum electrolytic or ceramic capacitors for linear regulator input and output?

texts:
I am using this linear voltage regulator. The datasheet indicates the input and output values for the capacitance to use, 1uF and 10uF respectively.

Should these capacitors be or a particular type, or does it not matter?


texts:
I was repairing a PCB, when I noticed that a diode is damaged.

The glass shield is missing a piece but the gap is still covered.
Is the diode still ok?

I don't know how to replace it since part of the writing is missing :/

PS: Here is a video of the diode: https://youtu.be/vms3SuanZtE

PPS:
Voltcraft VC920:
Forward resistance: ~3 M ohm
Reverse resistance: overload
Forward Voltage: 0,63V
Reverse Voltage: overload

PPPS: Seems to be a Schottky or Switching diode, not a Zener.


texts: Software timers and interrupts on a microcontroller

texts:
I have few questions on software timers and interrupts on a microcontroller. Just for information, I use a dsPIC33E microcontroller.

The final goal is to implement a serial communication protocol: RS485 with Modbus. I managed to transmit and receive a message, and now I have to do a message processing part.

Since I need a bunch of timers for all sorts of different tasks (e.g., 3.5 character delay needed for serial communication, some delay needed for buttons debouncing etc.), I plan to implement timers in a software using a single hardware timer. For example, hardware timer period is set to 100 us, and an interrupt is generated on every "overflow", i.e., every 100 us. In the ISR I just update global counters, which are basically software timers with a resolution of 100 us, whereas the hardware timer ISR has the highest priority. Is this a good way to do this, or is there some better way?

Each counter (i.e., a software timer) has defined its own period, and once the counter reaches its "period value", I want to call some function. Now it is not a very good idea to call this function from inside the hardware timer ISR, because that function will be processed with the highest priority since the calling routine is the hardware timer ISR. What I want is to define some function, let's say:

void Modbus_Protocol(void);

and to be able to define it as an interrupt, which will not be of the highest priority. Only the main hardware timer has the highest priority in this concept. In that way, once the counter in the hardware timer ISR reaches its period value, it wouldn't call its function, but it would rather just set a flag to trigger an interrupt (e.g., void Modbus_Protocol(void)), which will be triggered after the main ISR returns, depending on its priority. Can something like this be done, i.e., can I define software interrupts?

I know there is a possibility to use hardware interrupts which are not used, and to just set an interrupt flag from within the software. But I don't think this is an elegant way to implement interrupts if user defined software interrupts are possible.


texts: Is it possible to show fixed point numbers as base 10 in modelsim wave?

texts:
If a person is creating a system using fixed point numbers a decimal point is implied. In this case, if one is going to use the wave window to see the result, it will be beneficial to see the actual value of the fixed point number in radix 10 e.g for unsigned 11.10 it will be 3.5 rather than 14.

I can see that the VHDL has a type called "real" which is part of the language and goes back very far in time. It can be used to contain floating point numbers though I am not sure what its mantissa and exponent ranges are.

In any case, how do I tell ModelSim that a quantity is a fixed point number e.g by telling it about the Qm.n format or otherwise and have it interpreted as such in the wave window?


texts: How do I calculate the size of the diodes used in an H-bridge for a DC motor? What is the relationship between the motor parameters and the diode parameters?


texts: Can I convert my dozens of laptop adapters into universal ones by using RJ-11 or RJ-45 connections?

texts:
I have accumulated dozens of laptop (and other) power bricks over the years. Some of them belong to a corresponding laptop or device, others just haven't been thrown away yet.
I'm trying to make them all useful and had an idea which I think will work, but wanted to see if people who know more about this can tell me if it's feasible or not.
I'm thinking of cutting the wire between block and tip and then connecting an RJ-11 or RJ-45 male on one end, female on the other.
I hope this would allow me to mix-and-match for any given situation.
Would this work? Are there heat or voltage or any other considerations that would make this not feasible? Or, is there an already-existing option that I'm not thinking of?


texts: I want to sense the 3D position of an object with respect to some fixed reference. The position of the point will be within a meter of the reference. The accuracy should be very high, possibly within a cm. The point will be almost static or exhibiting very less movements. Please tell me which sensors can be used to achieve this task. The sensor unit will be connected to a microcontroller unit. It would be better if the entire unit can be accommodated in a single PCB. The output should not change appreciably with temperature. The measurement will be done only once on system startup. Based on the position of the object , some other actuators will be controlled. As it is a one time measurement  so power wont be a big constraint. The system is supported by 6Ah battery


texts: How does a device (dashcam) recognize if it is connected to a computer or a power source?

texts:
I have this A118 dashcam, which I want integrate with a Pi.

I wish to record onto it mounted SD card when driving, and once home within WiFi range, to download the files on the SD card through the Pi to my home network.

This camera, when connected to a 5 V source on my vehicle's cigarette lighter, the camera begins recording right away.

When I connect it to my computer, it prompts (on the dashcam screen) whether to operate in "Mass Storage" or "PC Camera" mode.

This video shows how a problem of a different camera was fixed by insulating the TX and RX terminals from the connection.

How does the camera (or a regular USB device, like a phone too) know whether it is connected to a simple power source or to a computer?

Also, how could I then use this fact to control the dashcam, so when out of my Wifi range, it records as it would when just power is supplied, and when in Wifi range to revert to "Mass Storage" so the Pi can access the video files and transfer them.

I guess relays would work, but their large size does not make it practical. Would optocouplers be a better alternative, or are there other suggestions I may look into?


texts: Any disadvantages to single-supply mode?

texts:
I am using the ATMEL ARM SAM4S MCU for a project. It supports a single-supply mode where an internal voltage regulator provides the 1.08-1.32V necessary for VDDCORE and we need only provide 1.62-3.6V to VDDIO.

I'm just interested to know if there is any situation where one might NOT take advantage of this feature and supply the core externally as well?


texts: PIC32, USB CDC + HID Composite Device fails with Code 10

texts:
I've been busy building a CDC + HID composite USB device for the past couple of weeks, and stuck with This device cannot start. (Code 10) error in Windows 7.

When looking at the device through USBlyzer, I can see the device successfully communicates with the PC, as USBlyzer is able to extract both the USB device and configuration descriptors. USBlyzer isn't pointing out any errors, making it difficult to see what exactly is wrong.

My code is available at bitbucket.org, the Mercurial repository URL is https://bitbucket.org/sparkbuzz/pic32_usb.x.

The project is really simple, and there are basically three important files:

main.c - The main application source.
usb_config.h - Some configuration defines.
usb_descriptors.h - USB device and configuration descriptors.

The project is basically derived from the Device - Composite - MSD + CDC example from Microchips' Libraries for Applications. I've double checked that descriptor size values are correct, and been over the code a dozen times, but not sure what's causing my headaches.

My breadboard setup looks like this, and it is working quite well, since I've tested it with an HID only example, and it worked perfectly (So the problem is definitely somewhere in my code):

The setup uses a PIC32MX250F128B MCU from Microchip, with an LDO on the top right which steps the VUSB 5V down to 3.3V for the MCU Vdd supply. A 12MHz crystal supplies a clock signal to the MCU, which is used to configure the USB Module clock to 48MHz (see configuration bits in the source code). The green LED lights up when USBDeviceState == CONFIGURED_STATE and the red LED simply indicates that the 3.3V supply is on.

The device is visible in Device Manager:

...but off course Windows 7 isn't happy:

Here's the report from USBlyzer:

Some more output from USBTrace, could the problem be to do with configuration selection?

I have no idea what's wrong, and have been trying this entire week to fix this.

Please can someone try to help?


texts:
For all PLC manufacturers, is Mass I/O copying the choice for updating outputs?

I found that there is another possible method: the continuous I/O updating.

Can anyone tell me what is the reason for this choice (Mass I/O copying)?
Are there any advantages over the continuous I/O updating method?


texts: Is the only way to drive a speaker with a positive and negative rail?

texts:
I want to create a simple sinusoidal oscillator (Wien-bridge with soft limiting), connected to a high gain amplifier.

I don't have much experience with audio, but I'm guessing a speaker needs a positive and negative voltage to function.

If I wanted to power this circuit with only a +5V rail, what's the easiest way to get the -5V rail (if needed)?


texts: Differences between flip-flop control inputs and clock inputs

texts:
I'm studying clocked flip-flops (FFs).

However, I cannot differentiate between the two terms control inputs and clock inputs.

Can you tell me the differences between those two types of inputs, or are they the same?

Thanks in advance.


texts: How do I perform an electrochemical impedance spectroscopy test for battery?

texts: I have tried to look online for procedures to perform this test but couldn’t find anything. So if anyone can refer me to a set of procedures or give me procedures that I can use to perform the test and make plots (Bode or Nyquist plot), it would be really helpful


texts: Small signal equivalent circuit BJT question

texts:
This circuit is two BJT transistors in so called 'darlington configuration'. I want to analyse this circuit for AC signals (where the capacitors are shorts).

The question is to calculate Delta_V_L/Delta_V_G (sorry I don't know how to use subscripts here)

This is what I think it should be but unfortunately when I plug in the numbers it's not correct. Solution should be Delta_V_L/Delta_V_G= -50.

Any ideas on how to solve this and is this smallsignal equivalent circuit correct?
Thanks!

Edit: h_ie1 and h_ie2 are the smallsignal model resistances, hence why they aren't on the original circuit

Edit2: I realised that there are different models for small signal analysis, I'm using this one:


texts:
I was wondering on how to implement a sinewave oscillator with a variabke frequency from 20hz to 20khz.

What types of circuits are there to do this and what sort of parameters would affect the frequency range?

Thanks


texts:
My STM32 is behaving weirdly, to say the least. What is the best way to "hard reset" an STM32? I've tried pressing the "reset" button, and unplugging/replugging everything, but it seems like the weirdness remains.

How can I make a hard reset to restore all the registers and all the memory back to their reset values?


texts: What transistor should I use to power my 12v Display and control with a 5v raspberry Pi

texts: So I recently bought a 9v Seven Segment display and I want to control it using my Raspberry Pi Zero. But I realized that the Pi only supplies 5v of power and in order to power it I need 9v. I know how to configure the transistor circuit I just need help with the specs of the transistor.


texts:
I purchased a PNP sensor in error. I should have purchased an NPN version.

I'm stuck with this thing now and I'm trying to get it to work. All the guides online show circuitry from NPN sensor. I do however have multiple NPN transistor 2N2222A if that will help.

Can somebody draw up a quick diagram on how to do this correctly for my case?

Additional information:

Thomas' Auto Bed Tramming guide on how to wire it , I'm left with the ground wire that is to be used as the Z signal...i guess.. here is a pic that i got from instructibles that matches my setup: http://i.imgur.com/cxJdbYO.jpg

I've noticed that even though i followed the wiring guide for an NPN inductive sensor, the light from the inductive sensor does turn on when it's near the aluminium heated bed, and turn off when it is away from the aluminium heated bed.

However the wire i'm left with to use as a signal to the RAMPS 1.4 board from my inductive sensor appears to be a negative terminal. As I undertstand it, I need to send a positive signal, and I'm not sure how to invert a negative/ground signal to positive.


texts:
I have an appliance that is turned on by a timer circuit. I would like to switch my furnace blower fan when the appliance is on. For that I figured I would need a relay that I would add in series with the timer. The timer circuit is using AC of 7-8 volt. I bought a 6VAC rated relay, but it doesn't seem to work. It chatters for a while and then stops. Relaxing  the spring within the relay doesn't help, at most it keeps chattering.

Here is the diagram for the circuit with the timer switch only. I need to add a relay here, so that when the timer switch turns on the appliance, the relay closes an separate circuit.

simulate this circuit – Schematic created using CircuitLab

I tried using a 6VAC (coil rating) relay in series as follows:

simulate this circuit

Information about timer switch here.

This didn't work. The relay that I used was chattering for a short time, the switch wasn't flipped.

Perhaps the AC relay that I used is chattering because the alternating current keeps flipping the switch back and forth. If that is the case, then using a DC relay would avoid this problem. For that I would need to convert the AC current to DC just for the relay. I don't know how to do that or if this is the right idea.

Is converting to DC and using a DC relay the best way to solve the problem  or is there a better approach?


texts: PIC MCU to PC Serial Communication Problem

texts:
I was just trying to send continuous stream of letter 'G' from my PIC MCU (PIC18F452) to my laptop.

Here is my assembly code that i am using :

#include <p18f452.inc>

    CONFIG  OSC=XT,WDT=OFF,PWRT=OFF
    ORG     0H
    MOVLW   D'12'
    MOVWF   SPBRG
    MOVLW   B'00100000'
    MOVWF   TXSTA
    BCF     TRISC,TX
    BSF     RCSTA,SPEN
    OVER    MOVLW   A'G'
    S1      BTFSS   PIR1,TXIF
    BRA     S1
    MOVWF   TXREG
    BRA     OVER
    END

I design the circuit in proteus and simulate it with realterm and hyperterminal i get the desired output.
But when i try to implement the hardware i face some problem. I do not get output at Realterm just when i connect my source. But at the instant i remove the source (unplug just ground or live wire) i get the output (G string).
Can any one tell me what is the problem?
Devices that i use:
01. PIC18F452
02. 8MHz Crystal Oscillator,
03. MAX232 with five 10uF capacitor
04. USB to RS232 cable.
Here is my connection diagram:


texts:
The STM32F1xx "Getting Started" app note shows the BOOT0 and BOOT1 pins connected to ground/VCC via a \$10k\Omega\$ resistor, and so that's what I've always done and everything works fine.

However, now I'd need to switch the internal serial bootloader on/off depending on whether another board (a kind of debugger) is connected, i.e. if the board is connected, BOOT0 is high (boot into internal bootloader), otherwise low (boot from internal flash). In this case, as I will anyway have a debugger detect pin, I could simply pull BOOT0 pin low with a 10k resistor, and connect the (active high) debugger detect directly to the BOOT0 -pin (apologies for the insanely large schematic, I don't know how to adjust it's size):

simulate this circuit – Schematic created using CircuitLab

Now the question: when the debugger is connected, BOOT0 is connected directly to VDD instead of through a resistor, unlike in all the app notes etc. Is there some danger here?


texts:
I am trying to send data wirelessly using an HC12 (transmitter ) radio module and collect them form another HC12(receiver) connected to the 2nd Arduino. then at the receiver, i write them on an excel sheet. currently, i have made 1 seconds updating rate on excel sheet. how to speed up this process by the code?

Transmitter

#include <SoftwareSerial.h>
int analogPin = 14;
int val = 0;
SoftwareSerial HC12(0,1); //HC TX, RX

void setup() {
Serial.begin(9600);
HC12.begin(19200);
analogReadResolution(16);
delay(20);
}

void loop() {

val = analogRead(analogPin);
if(HC12.available() > 1){//Read from serial monitor and send over HC-12
String input = Serial.readString();
HC12.println(val);  delay(50);
}
delay(20);
}

Receiver

#include <rExcel.h>
#include <SoftwareSerial.h>

SoftwareSerial mySerial(10,11); //HC TX, RX

long          idx = 0;                // index
int           outputTiming = 100;     // packet sending timing in ms
important: this dermines the output timing
float         a0;                     // A0 pin reading
float         volt_3v3;               // random number

char          value[16];              // written or read value

rExcel        myExcel;                // class for Excel data exchanging
String input1;
String input2;
float         a1;                     // A0 pin reading

void setup(){

Serial.begin(115200);
mySerial.begin(19200);
delay(20);

// rx buffer clearing
myExcel.clearInput();

// if analog input pin 5 is unconnected, random analog noise will cause the     call to randomSeed() to generate different seed numbers each time the sketch     runs
randomSeed(analogRead(5));
}

void loop() {

static unsigned long  loopTime = 0;
static unsigned long  time1 = 0;
int ret;

if(Serial.available() > 0){//Read from serial monitor and send over HC-12
   input1 = Serial.readString();
  mySerial.println(input1);
}
if(mySerial.available() > 1){//Read from HC-12 and send to serial monitor
   input2 = mySerial.readString();
Serial.println(input2);
}

loopTime = millis();

if ((loopTime - time1) >= outputTiming) {

time1 = loopTime;
a1 =  input2.toFloat();
volt_3v3 = a1/65536*3.0;

myExcel.write("Example", "B5", a1, 2);                  // write the value from A0 pin to worksheet 'Example' cell 'B5' with two digits as decimals
myExcel.write("Example", "B6", volt_3v3, 2);                 // write a random value to worksheet 'Example' cell 'B6' with two digits as decimals
myExcel.write("Example", "B7", idx, 2);                 // write a random value to worksheet 'Example' cell 'B6' with two digits as decimals

 myExcel.writeIndexed("Example", idx+11, 1,"%date%");    // write %date% (that will be converted in current date) to worksheet 'Example' row 'idx+11' column '1'
myExcel.writeIndexed("Example", idx+11, 2,"%time%");    // write %time% (that will be converted in current time) to worksheet 'Example' row 'idx+11' column '2'
myExcel.writeIndexed("Example", idx+11, 3, idx);        // write idx to worksheet 'Example' row 'idx+11' column '3'
myExcel.writeIndexed("Example", idx+11, 4, a1, 2);      // write the value from A0 pin to worksheet 'Example' row 'idx+11' column '4' with two digits as decimals
myExcel.writeIndexed("Example", idx+11, 5, volt_3v3, 2);     // write a random value to worksheet 'Example' row 'idx+11' column '5' with two digits as decimals

idx++;

if (idx > 100) {
  myExcel.clear("Example","A11:F70");                   // clear cells in A11:F70 area of 'Example' worksheet
  //myExcel.clear("Test","C5:C64");                     // clear cells in C5:C64 area of 'Test' worksheet
  //myExcel.save();                                     // save the Excel file (useful for activites over a long time)
  idx = 0;
}
}


texts: How do I simulate an RF mixer in PSS or harmomic balance with an autonomous local oscillator?

texts:
I am designing a CMOS RF downconversion signal chain comprised of a local oscillator and mixer (the LNA is not yet included) using the Cadence Virtuoso Circuit Design Suite with ADE XL as my simulator.
The oscillator is based on a resonant element which should ideally oscillate at 2.400 GHz, but my design tunes it to approximately 2.383 GHz (for a sample set of values that I'm working with throughout this iteration of the design), +/- phase noise on each cycle. I would like to simulate with the LO included in the chain, so I can consider effects such as injection locking/pulling, loading effects, and phase noise.

In order to prepare to simulate active mixer designs and establish a performance baseline, I'm trying to get the whole chain working with a simple double-balanced passive mixer. My testbench drives the RF input of the mixer using a 2.385 GHz input, for an intended downconverted frequency of approximately 2 MHz.
I can run a transient simulation, wherein the oscillator starts up, and the mixer successfully downconverts to approximately 2 MHz (but not exactly, since the oscillator is not tuned exactly to 2.383 MHz). The waveform is decently clean, but (obviously) has significant harmonics and experiences the phase noise of the oscillator. Because the testbench works in transient analysis, I can likely eliminate the most obvious factors of the circuit simply not working.
However, I have severe trouble getting a harmonic balance or periodic-steady-state simulation to succeed with sensible results.
When I use the shooting engine, PSS fails to converge with messages such as the following:

Conv norm = 44.7e+03, max dV(I28.net8) = 11.032 V, took 14.92 s.

on each PSS iteration, or creates such long beat periods that the simulation cannot complete in a reasonable time. Even when I tried measuring my LO frequency as precisely as possible, and setting the RF input to that frequency * 1.001, pss cannot converge. My PSS settings are as follows:

Meanwhile, in harmonic-balance, the simulation runs for a time of tstab (set to allow the oscillator to start up), yet the actual harmonic-balance outputs are in the picovolts, meaning that hb is somehow using the near-steady-state before the oscillator starts up, when the following settings are given:

QPSS simply won't run because the oscillator is not an independent source:

Warning from spectre during Quasi-Periodic Steady State Analysis `qpss'.
    WARNING (SPCRTRF-15267): The number of sources 1 is less than the number of funds 2 set in analysis.Please make sure the analysis is set up correctly.
Error found by spectre during Quasi-Periodic Steady State Analysis `qpss'.
    ERROR (SPCRTRF-15082): The fundamental name lo specified by the 'funds' parameter is either not associated with any fundamental name specified in the input sources, or is not unique.

Am I making a complete misunderstanding of the fundamentals here, or is there some small option that I overlooked?


texts: How to drive a linear MOSFET like IXTK22N100L?

texts: i am trying to simulate an electronic load. in that case i would like to employ a linear MOSFET IXTK22N100  which has Ciss= 7n for having a current at 150khz at output. but in the simulation i couldn’t make it stable and the current is not a pure sinewave at high frequency applications. i am thinking that maybe my op-Amp cannot supply an appropriate current to drive this kind of MOSFET at high frequency but i am not sure that is it true or not? should i use an gate driver stage or using specific gate driver IC between Op-amp and MOSFET? if yes which kind of IC or structure can help me?


texts: Is there something between the 78LXX and 78XX, current wise?

texts: I'm trying to find a 5V regulator that is smaller than the 7805, but the 78L05, while nice and small, is too low current. Ideally, I would like 500mA. Is there something that is also through hole (sadly, surface mount is out). Does anything like this exist?


texts: What is the irregular signal at the bottom of this "spectrogram"?

texts:
I am reading research papers about LoRa, and I have come across the below figure in this one.
The horizontal axis is clearly labeled frequency, but the vertical one isn't. I recognize the chirps in the middle, so I understand that the vertical axis is indeed time for that graph, but I still have no idea what the other, darker blue graph represents. Could you shed some light on this please?


texts: Which configurations are safe to use an oscilloscope?

texts:
A USB device is connected to a Laptop PC.
Laptop PC has a ground earthed power supply.
Oscilloscope's negative lead is connected to ground via its own power supply.
Oscilloscope's negative lead is touching the USB's positive shield.

In this scenario it will be a short circuit as in the figure.

My questions are.
In case the laptop power supply has only 2 pins is there any danger?
I have a very old oscilloscope which has only 2 pins (I think neutral and line).
What happens if power supply is ground earthed and the oscilloscope is not?


texts: I am trying to find a controller chip for either SRAM or S/DRAM which can properly manage access of the memory from one or more devices (i.e. microprocessors). I have been up and down Google and all I have been able to find are academic discussions and silicon level IP. What I would like is an on the market IC which can accomplish this. Speed is not particularly important, I am mostly interested for curiosity/experimentation purposes, and less for practical aspects.


texts: How to estimate the cost for creating a device for test purposes

texts: I have an idea of an electronic device, some kind of a gadget. It will have a bluetooth chip, some memory in it, some led indicators and some controlling chips, not sure yet how it should be constructed. What I need now is to estimate an approximate cost of the gadget hardware itself including the board, chips and the plastic case. What is a good way to calculate the cost?


texts: Ticking sound produced when adjusting voltage on a lab dc power supply

texts: when you adjust the voltage on a dc power supply, at certain stages you can hear a ticking sound. i was wondering what is the source of that sound. this happens on all the power supplies in the lab, so it's not the power supply malfunctioning.


texts: Noise in FET reverse-polarity protection for ADC

texts:
I have quite precise ADC circuit. I want to protect input supply voltage (not ADC input) from reverse-polarity using FET transistor as shown on the picture below.

I wonder: is there any noise / worse performance introduced in ADC measurements due to use of FET on the power line? Power supply is also reference voltage for ADC.
The alternative for me is just not use any re-pol. protection.


texts: Flash and run a .hex file on a different Microcontroller with bigger flash from the same Cortex family

texts:
Is it possible to flash and run a compiled code (.hex-file) for a specific Microcontroller (for example STM32F205RC) on a Microcontroller from the same family with bigger flash-memory and RAM (without creating a new compiled version.)?
Example:
.hex for STM32F205RC (128K flash memory and 64K RAM) on STM32F205RE (512K flash memory and 128K RAM)
(it is obvious that the larger memories is not used)


texts:
Say there are 2 Shift Registers chained together with the following values

SR1 : 11111111
SR2 : 11001111

The data is written to SR1 and then to SR2 like:

digitalWrite(SensLatchPin, LOW);
shiftOut(SR,LSBFIRST,B11001111);//SR2
shiftOut(SR,LSBFIRST,B11111111);//SR1
digitalWrite(SensLatchPin, HIGH);

If the SR2's data is changed with time, does SR1 refresh (as in, set all outputs to 0 and then reset to the same value)?

For example, the following code is executed (only change for SR2)

digitalWrite(SensLatchPin, LOW);
shiftOut(SR,LSBFIRST,B11101111);//SR2
shiftOut(SR,LSBFIRST,B11111111);//SR1
digitalWrite(SensLatchPin, HIGH);

In the above case, does the SR1 outputs toggle or does it remain same without any transition (as the values before and after latching are same?)


texts: What type of sensor is used in this water flow sensor with two wires?

texts:
I am trying to figure out what type of sensor I have that is used to detect water flow. This sensor is placed near a cylinder of water with some type of float. When the water pressure causes the float to pass the head of the sensor some kind of output is registered with the micro-controller indicating the flow of water. However, I have now idea how this device is used in a circuit and connected to a micro-controller.

Because this sensor has only two wires I can't figure out how it works. Is it possible that it just produces a current when a magnetic field is present? And if so, would it likely be necessary to amplify the signal so that a micro-controller analog to digital input can detect the change in voltage?

It came out of a "Pool Warden" which is used to automate pool water chemistry by measuring pH, ORP and temperature. This device is used to let the device know when water is flowing through a water block.

Anybody know how this sensor works, what it might be and how I would use it?