texts: antenna gain, calculating voltage scaling

texts:
I am working on a software defined radio project, but I am kind of new to antennas. There's so much info out there on antennas that I'm having trouble finding the answer to my specific question. Hopefully asking here will speed up my understanding.

Suppose I have an Antenna connected to a proper termination load (50 ohms) with all the proper transmission lines with the proper characteristic impedance. We will assume just about everything is 100% efficient for simplicity. I have an ADC that is monitoring the voltage at that termination load. The ADC is much faster than the received carrier frequencies, so I can extract actual waveforms. I emit some RF energy into my antenna at a "good" azimuth angle, say 0 degrees, which should have a gain of 0 dB according to my antenna's gain plot. I measure the voltage from my ADC over time and it shows I have a 200mV peak sinusoid. I then rotate my antenna such that the emitter is at an angle, say 45 degrees, in which my antenna's gain plot says it should be -4dB. What is the amplitude of the waveform I will measure now?

Here is my guess: The power received from 0 degrees is : P0 = (0.2/sqrt(2))^2 / R. Note that I used the RMS voltage. My power gain in..non-log(?) will be : PG = (dB/10)^10 = (-4/10)^10 = 0.0001048576. That means the power at 45 degrees will be a scaled version of 0 degrees: P45 = PG*P0. Solve for voltage using power equation: Vans = sqrt(2*P45*R). The R's will cancel when you simplify. I got an answer of 2.048 mV peak sinusoid.


texts: How safe are Isolation Amplifiers compared to Voltage Transformer

texts:
I was searching for a miniature transformer for my 240V AC voltage measurement circuit and a kind individual recommended me a pecular IC. The IC is a Differential Isolated Amplifier AMC1100. And it checks everything i am looking for.

Smaller Package than a transformer
Cheaper than the transformer approach
Can read (supposedly i still do not fully understand how it works) Mains voltage

This approach is new to me, contrary to what i know that transformer approach is the safest way to do this. Take a look at the diagram below. How safe is the "safe section" and the circuit down the line ? When both parts fails, which has a worse failure scenario between iso-amplifier and the transformer ? Is the exposed section really safe to haphazardly touch ?


texts:
I am currently using an FPGA (Virtex II NI RIO7831R) to generate the clock for a pulse generator used to drive a Linbo3 optical phase modulator.
http://www.jdsu.com/en-us/Optical-Communications/Products/a-z-product-list/Pages/modulator-ape-phase.aspx#.VXmz-0YpoiI

I would like to directly use the fpga to drive the modulator in real time but i need to generate up to 10 volt square wave with rising time less than 5/10 ns.

Does someone has an idea how to generate a square wave with such a fast rise time?

Than you in advance


texts:
I am using 2 fingerprint module to make an attendance machine.

Normally i have seen the attendance machines just need the user to put his/her finger on the scanner and it is scanned.. then next person put his/her finger and then that finger is scanned.. and so on.. a user is not required to press any button on the machine to start the scanning process. the machine is always in the scanning mode and waiting to detect a finger.

I have seen the command set of the above FP sensor and it works in the polling mode. We have to send a command to start scanning and after successful scanning or timeout it returns. It looks like it cannot do continuous scanning. Or if we need to do continuous scanning then we have to repeatedly send the start-scanning-command over and over again.

I wonder if my understanding is correct or if i am missing something to achieve continuous scanning?

edit:

Adding picture of the available signals on the FP Module.[![enter image description here][![enter image description here]3]3


texts: How can I use a US 120 volt Ryobi charger From a 220 volt main?

texts:
I bought a ryobi kit in the us and I want to use it in in Europe.

I doubt that I can plug it directly into the socket, what kind of converter/adapter do I need?

Is there a way to adapt the charger itself?


texts: Paralleled voltage sources error in LTspice

texts:
I have the following LTspice simulation schematic.

(It's a simplified version, just to demonstrate my dificulty). The LTspice simulator returns a paralleled voltage sources error even when the sources V5 and V6 are clearly not in parallel. Is there any walkaround that avoids putting internal series resistances with the sources? Why is this error coming up at all? I'm using the most recent version of LTspice.


texts: Problem modelling NPN transistor BE junction in LTSpice

texts:
So, I am trying to understand transistors.

I start with the very basics, the part which says that an NPN
transistor kinda look like two diodes joined at the hip (at the
anode, in fact)

I build the "floating collector" circuit below, which - according
to what I've read - should be the functional equivalent of a diode
in series with a resistor.

simulate this circuit – Schematic created using CircuitLab

I then try to calculate by hand the intensity going through the loop,
starting at the emitter and walking my way back towards the source.

Voltage at emitter is 0 (grounded)
Voltage drop in a silicon diode is 0.7V (from textbook)
Therefore, voltage at base has to be 0.7V
Voltage left of R1 is 10V (source)
Therefore voltage drop across R1 is (10-0.7) = 9.3V
Therefore (Ohm's law), intensity across R1 is 9.3/1000 = 9.3 milliAmps
Current has nowhere to go but through emitter and back to source
Therefore (KCL) : intensity is everywhere 9.3 mA

To verify that I've got this right, I build the circuit in LTSpice,
and lo and behold, the darn thing disagrees :-).

When I run an LTSpice simulation, it tells me that:

Ib = 9.1581 mA
Vb = 0.8418 V

Retracing my reasoning backwards, this basically means that my
assumption that a voltage drop across a Si diode is 0.7v is wrong.

Researching this further, I find that the V/I characteristic of a Si diode
has a "round knee" around 0.7v and that therefore, the rule that says:
"Si diode always drops 0.7v when forwards biased" is in fact an approximation
and that the characteristic curve is in fact some sort of exponential.

Ok, fine.

But now, I want to be able to derive the actual value of Vb myself, by hand,
and I am stuck: in the above reasoning, I was relying on a fixed drop across
the diode to derive Vb and go from there to Ib.

Now that Vbe and Ib are tied up in some sort of equation, I'm not sure how
to get to Vb from the knowledge that Ve=0.

I've essentially got two unknowns (Vb, Ib) and only one equation (the diode
characteristic curve) ... how do I compute Vb ?

Am I missing something glaringly obvious ?

Help appreciated.


texts: What options do I have for an ATSC digital television tuner chip?

texts:
I've found a few ATSC digital TV tuner chips (SiLabs, Maxim Integration, NXP) sold via the typical online parts retailers in the USA but they all seem to require contacting sales and signing a NDA to get the full data sheet/documentation.  Even if they let a hobbyist sign a NDA, I'm not willing to, so do I have any other options, or am I out of luck?

More specifically:

1) Are there any ATSC chips sold in USA at hobbyist quantity that don't require NDA?

2) Are there any "general-purpose" RF chips that can be interfaced with something else (hardware/software) to tune ATSC even if the general purpose chip isn't specifically for digital tv tuning?
(Update: I'm not asking for part numbers, I'm asking for which type of parts can be used.)


texts: OpenOCD debugger in Eclipse Neon 4.6.2 Error in final launch sequence

texts:
I have been struggling with OpenOCD debugger under Eclipse Neon 4.6.2. Whenever I run the debug configuration I receive below given error message

I have been attempting to debug the STM32F417VGT6 MCU. My debug configuration setting is following

Main tab

Debugger tab

Startup tab

Source tab

Common tab

Have anybody ever had similar problem? Thanks for any ideas.


texts:
I just started studying circuit design as part of my computer science program. I am trying to use a  8-to-1 MUX. My goal is that the MUX will output 1 only when the inputs (selectors) are 001, and the rest are 0.
I understand that I need to put 1 to D0 input and 0 to all other inputs. Before using a professional software, I am able to draw something to represent the constant. However, as per the requirement of the instructor, I have to switch to Quartus where I can only find Vcc and GND.
From what I have heard, Vcc is a representation of 1 and GND is a representation of 0. As a result, I am not sure if I can connect Vcc to D0 and GND to the rest of the inputs?
PS: I also put GND to the enable port as I assume it is 0 and MUX takes its inverse, so it will thus enable the MUX. Not sure if I am correct


texts:
The 555-timer is used here as a demodulator. I don't understand how the 555-timer generates the desired signal. Shouldn't the output have the same frequency as the carrier signal? Can someone please explain to me how the 555-timer is used here? I am new in this area and therefore do not have so much experience and knowledge.
Here is the link to the AM radio circuit:
http://tubetime.us/index.php/2011/02/23/555-contest-entry/

For example, how does the 555 timer convert the AM signal into an information signal?


texts: Thermometer type in electrical water heater

texts:
I'm working on my home monitoring system and already succeed with electricity consumption measurement and got closer to water system.

Measuring water consumption is almost solved, but as we are using boiler almost 365 days a year I would like to measure water temperature in a tank as well to have more info on it.

As the tank itself is tightly isolated I've got an idea to intrude into boiler and use it's temperature sensor.

Water heater has electronic (buttons) control (model ARISTON VELIS 50)

Under the hood it looks like this (2 tanks)

And temperature sensor for this model is the following

As it seen on the picture the left thermostat has 3 wires which I suppose are:

GND
VCC
DATA

whereas the right tank has kinda 4 wires going out the same place.

I'm wondering:

if its possible to know how to read the temperature data from 3 wires sensor or how to know the "protocol" its using for data transmission?
is it possible to intercept this data not interfering with the boiler board?

Maybe there are some traditional/known approaches for such kind of tasks or this is regular temperature sensor, but I don't have a clue what to start with bec. organizing a workspace under the boiler not knowing what to do is quite uncomfortable.

  Unfortunately I don't have an oscilloscope to read raw signal, but I have both Arduino and RaspberryPi3 and multimiter in my arsenal.


texts: trouble amplifying signal from a blood pulse sensor using an LDR

texts:
im having a bit of trouble with the following circuit. i am using an LED to shine light onto our finger and reflect onto an LDR (RD). the LDR is the source of the signal. the voltage input is in the 20mV range and the amplification should be 100 times to get it up to 2V. however we are getting no amplification and filtering is also not working. we are currently using a high pass filter followed by a 2 stage low pass filter.

LDR characteristics:
- Dark resistance: 0.5M ohm min.
- Light resistance: 2.8K ohm min 8.4K ohm max


texts: Can overhead ground wire of major transmission lines prevent induction through solar storms?

texts: As I understand it the overhead ground wire found on major transmission lines is placed there in the event of a lightning strike which prevents a surge in the phase conductors. My question is, could this ground wire also provide protection from atmospheric surge/induction caused by a major solar storm?


texts:
Givn a function \$f(w,x,y,z)=\Sigma(1,4,5,7,13)+\Sigma_\phi(0,8,9,12,15)\$
I set up a karnaugh map for it, and my question is:
Other than counting, what is the best way to calculate how many \$f\$ are there?
I know this is somewhat a combinatorics question, but since the karnaugh map works in a bit change not all combinations are valid functions.


texts:
Alright, so I've searched just about everywhere to find an answer to this and I've personally experimented a lot to try and find a solution.

The error I'm experiencing is Neopixel (WS2812B 12ct LED ring) flicker using the NeoPixel library (this is a requirement for the project. Otherwise I would use FastLED and see if that has the same issues)

The following is my setup:
ESP32s (Node mcu brand esp32) using the Arduino IDE
3.7v LiPo OR USB power
2x WS2812B rings on pins 25/26 (i've also tried 16/17)

I have a LiPo battery hooked up in parallel with all the components (ESP32 on 5v pin, and both strips separately) with a proper shared ground. This hardware setup worked 100% perfectly when I use an Arduino CH340 Nano 3.3v + Adafruit BLE module separately.

What I've discovered is that the flickering ONLY occurs on patterns where I'm doing division on the pixel color. I.E. a fade or two color fade. Otherwise, in patterns like a Rainbow cycle or a simple Colorwipe, it works perfectly with no flickering on any pixel whatsoever. Occasionally, and much more rarely I get a similar issue when bitshifting to dim the color. The weirdest part is that after the pattern has run for 3 or 4 cycles, it "evens out" and stops flickering. The reason this is weird is that I'm not rebooting the board between patterns. I have an android bluetooth app I cooked up to send Serial BLE signals as a controller. So switching between my patterns, they all look great until I switch to a fading one.

void FadeUpdate()
{
    uint16_t stepUp = (TotalSteps + 1);
    uint8_t red = ((Red(Color1) * (stepUp - Index))) / stepUp;
    uint8_t green = ((Green(Color1) * (stepUp - Index))) / stepUp;
    uint8_t blue = ((Blue(Color1) * (stepUp - Index))) / stepUp;

    ColorSet(Color(red, green, blue));
    show();
    Increment();
}

void TwoColorFadeUpdate()
{
    // Calculate linear interpolation between Color1 and Color2
    // Optimise order of operations to minimize truncation error
    uint8_t red = ((Red(Color1) * (TotalSteps - Index)) + (Red(Color2) * Index)) / TotalSteps;
    uint8_t green = ((Green(Color1) * (TotalSteps - Index)) + (Green(Color2) * Index)) / TotalSteps;
    uint8_t blue = ((Blue(Color1) * (TotalSteps - Index)) + (Blue(Color2) * Index)) / TotalSteps;

    ColorSet(Color(red, green, blue));
    show();
    Increment();
}
uint32_t DimColor(uint32_t color)
{
    // Shift R, G and B components one bit to the right
    uint32_t dimColor = Color(Red(color) >> 1, Green(color) >> 1, Blue(color) >> 1);
    return dimColor;
}

Blue, Green, and Red all just do bit shifting on the uint32_t to grab the uint8_t representation of that color portion

TotalSteps and Index are both a uint16_t (I tried uint32_t as well)

This leads me to believe that my pixel flicking issue is due to some kind of odd rounding error

Things I've tried:

delay(1);
portDISABLE_INTERRUPTS();
casting to int instead of uint32_t for my colors

The first two actually did help slightly, and considering that the pixels flickering are the same ones, depending on the pattern (E.G. pixel 7 and 9 will flicker with X and Y pattern when Fade, but on TwoColorFade it will be pixel 1 and 8) this leads me to believe this could also be some kind of timing error as well.

Things I haven't tried yet:

Attaching the vin of the pixels to the 3v3 pin on the board.
Logic level shifter.
Setting the board clock frequency

I have NOT tried these things yet because the code executes perfectly on the nano, which is also a 3.3v board. I want to test changing the clock frequency but that's next on my list of stuff to test.

I can also post my code, but its split across multiple .ino files because im a novice at Arduino dev, but I still want some organization in my project.


texts:
My board contains an STM32 (manual here) and a SIM card reader (manual here). I need to write drivers to test that the SIM reader is working an properly communicating with the STM32. However, looking through both manuals, I couldn't find a way to get the two devices to "talk" to each other.

Is there a standard SIM card communication protocol for embedded devices? How can I do basic I/O on a SIM card?


texts: What is wrong with my D flip-flop toggle switch?

texts:
Until a few weeks ago, I had never drawn a circuit diagram in my life, so bear with me. I am currently trying to design (in Logisim) a circuit that acts like a toggle switch, using only basic logic gates and no clock. Basically, I want the LED output to turn on when the SINGLE button is pressed and off when it is pressed again, and I have been experimenting with all manner of SR latch/D latch/other combinations to no avail.

I am trying to do it now by making a D flip-flop from scratch, with the button serving as the "clock" and the final Q' output looping right back around as the D input in the first latch, as shown in the picture:

I've looked over this flip-flop very carefully, and I thought I had the master and slave lined up correctly, with the inverters in the correct places, etc., but according to Logisim, it is not correct and doesn't work. What am I missing here?


texts:
I'm kind of new to all this and the choices out there is kind of overwhelming when it comes to selecting a SRAM package and Flash eprom to go with a 10 Mhz Z80180.

I'm looking for a 128 KB SRAM and a small eprom to contain the boot code, the eprom needs to shadow the the first 512 bytes or so of the SRAM (for the boot up process).

Any advice for a good value alternatives is highly appreciated.


texts: How can we measure the coupling loss in a fused fiber Y coupler?

texts:
I'm trying to understand how the (power) loss in optical fibre works and I'm having some trouble.

This is a classic 50/50 fused fibre Y coupler. The output on port 2 is the same as port 3 (so half the power of port 1 plus the losses).

The losses considered here are the coupling loss (same for each port) and the radiated loss at the point of the split. We want to measure the coupling loss.

So my first idea would be to go from port 2 and measure the loss. However, while the radiated loss might be smaller, it seems unlikely that it would completely bypass it. Going from port 3 would bring the same result.

So is there any way I can measure the coupling loss in this configuration?


texts: What small IC could give switchable I2C pullups?

texts:
My goal is to replace a DPST on pullup resistors with something simple, cheap and very small that can be activated with the I2C bus voltage. I thought that this might be a common enough requirement that I would find a simple IC for this task, but after hours searching through datasheets I am not finding a solution as ideal as my gut suggests should exist.

The question on how to Use GPIO for switchable Pullups of I2C has the basics of the thing I am trying to achieve on a very small PCB. I don't necessarily want to use a GPIO to turn the pullups on and off, my goal is flexibility of the design so the pullups could be turned on by a single jumper or a GPIO.

simulate this circuit – Schematic created using CircuitLab

Inspired by the Bus Pirate which does something similar using a CD4066BC, quad bilateral switch I found the TC7W66F, dual bilateral switch which vaguely fits my price and space goals but I imagined something similar to a SOT-23 package.

The question mentioned above has an answer suggesting using FETs and I did find some dual FET packages with source already tied together that seemed like they might work but I'm primarily a software guy and have to admit not feeling 100% comfortable using something like this without further advice, or if it would require further components killing my space desires?


texts:
I am trying to make
A 220 ac to 0-30 dc
Using this schematic

I connected it on the bread board three times but every time I get only a 1.25 V from the regulator but when I change my potentiometer nothing  happens
Here is the breadboard


texts: Differential equation of circuit which contains R,L,C components

texts:
I'm having bit of a trouble finding the differential equation for this circuit.
I'm aware of how to construct the equations for simple paralel and series RLC circuits, but in this case the current valuesare different in the different components.
The real problem is even if i can find the equation for the whole circuit,my task states that i have to find the current and voltage values for each components as well.

Any help is appreciated.


texts: How to measure distance from moving object using RFID?

texts:
I want to make a project on an anti-collision system using RFID. I'm facing many problems selecting RF reader and tag: the required UHF generator, tags and reader are expensive.

Any suggestions on how to measure distance in RTL (real-time location system) using RFID?


texts:
Working on a project where we're using a couple of OP470 Quad Op amps. There are 2 unused op amps, and I need to buffer a signal coming from a sensor (this is according to the sensor's data-sheet). I'd like to use one of the extra op-amps. I know that theoretically you can buffer a signal using the negative feedback of the op amp as shown below:

simulate this circuit – Schematic created using CircuitLab

However, I also vaguely remember something about the dangers of self-oscillation and op amp stability. The OP470 is unity gain stable. Here is the datasheet:

http://www.analog.com/static/imported-files/data_sheets/OP470.pdf

My question is, is it safe to use an op amp in this configuration as a buffer without worrying about self-oscillation? Is there anything else I need to take into consideration?


texts: Response time of RTS and DTS pins of the chip FT232RL (USB to Serial)

texts:
I'm controlling the values ("High" or "Low") of RTS and DTR pins in FT232RL using python package serial. My question is what's the maximum time between executing the command ser.setDTR(True) (for example) and the pin DTR actually reaching a "High" voltage (e.g. +5V). I came across the following documents, but I'm not sure how to get this information from them. From the docs, I'm guessing the response time is 16mS by default but not quite sure!
Doc1
Doc2
Any help is appreciated. Thanks!


texts:
I was wondering if you guys could help me or lead in the right direction. I need to find the voltage across a resistor with an op amp. I was originally going to try solving for nodal voltage. But we can't do that. And usually we can do the Rf/Rs*Vin but it is throwing me off cause there is no Rf so it would be 0?

What is the voltage before and after the op amp?


texts: Difference between lower and higher current rated ESCs and electric skateboard questions

texts:
I am starting a project and would like to build an electric skateboard.
Here are the specs for the parts that I have gathered so far:

a. Two 90mm wheels that each contain a built-in BLDC motor. The power rating for each motor is 550W and the voltage rating is 24V.

b. Approximately 24V battery in 6 series 2 parallel (6S2P) configuration.

Using the formula P = IV, the max total current usage per motor would be 22.917A.

My questions are:-

Does the weight of the person riding the skateboard affect any of the parameters for the project?
Does an ESC that is rated for 6S(24v) and 30A suffice?
Say my project requires a maximum of 30A (an example), what's the difference between using a 40A ESC and a 100A ESC?

Thank you in advance. :)


texts:
Right now im trying to measure the AC voltage with arduino. So my plan was to convert this 230AC to 4,25 DC with this circuit and it works when i read with my tester i've got 4,25V.

(The purpose of measuring AC voltage is because I am doing a wattimeter with arduino and I want it to be the most precise possible, i mean here in spain we should have 230V but i have 235V and some house have 240V I want to be able to read this difference calibrating my arduino with my house voltage, so if the analog input voltage goes up, this means the ac voltage must be higher and arduino makes the conversion)

The problem is when i connect it to arduino, the digital values (0-1023) go from 500-850 and that's a lot of error.

I can't find my error can someone explain me this behaviour.
I also calculated this capacitor to make the most stable line of Dc current.

Do I have any way to fix this ?
Thanks!


texts:
IDE= MPLABx

Toolchain = HiTech PICC Lite

Target = PIC16f876

Burner = PICkit2

This is a new one for me. I have three leds connected to the chip, RC0, RC2 and RC3. RC2 pulses on at the beginning of the program (never again), RC3 pulses continuously through the infinite loop, and RC0 pulses during the interrupt. The program functions properly, as in the interrupt is executed and what not.

However, the chip is being reset. I've determined its the watchdog timer restarting the chip. I've determined this by changing the watchdog prescaler and this extends the time before the chip is reset. I thought the __option WDTE_OFF option would disable the WDT, but this does not seem to be the case.

I am also unsure as to why the WDT is triggering in the first place.

has anyone had this problem or can point me in the right direction?

My code;

#include"pic16f876.h"
#include "pic.h"
#include "htc.h"
#define XTAL_FREQ 20000000
__CONFIG (FOSC_XT, WDTE_OFF, PWRTE_ON, BOREN_OFF,
       LVP_OFF, CPD_OFF, WRT_OFF, DEBUG_OFF);

void setup(void);

int main(void) {
    int counter;
    int timer;
    TRISC=0x00;
    for(counter=0;counter<6000;counter++)
    RC2=1;
    setup();
    T0IF=0;
    di();
    RC2=0;
    for(;;){
       for(counter=0;counter<6000;counter++)
            RC3=0;
       for(counter=0;counter<6000;counter++)
            RC3=1;
    }
}

void setup(void){
 //turn off all interrupts
    INTCON=0x00;
        //for TRISx, 1=input, 0=output
//setup Timer0 as real time interrupt
T0CS=0; //Timer0 set to internal clock cycle
PSA=0; //assign prescale to Timer0
OPTION_REGbits.PS=0b111; //prescale set to 1:256
T0IE=1; //allow RTI
};

void interrupt int_handler(void)
{
    int int_counter;

    if(T0IF==1){
        GIE=0;
        T0IE=0;
        RC0=1;
        for(int_counter=0;int_counter<30000;int_counter++)
        RC0=1;
        for(int_counter=0;int_counter<30000;int_counter++)
        TMR0=0x00;
        T0IE=0;
       //T0IF=0;
        return;
    }
}


texts: AVR DMX Transmitter outputs constant squarewave, not the form of a DMX packet

texts:
I'm using an ATMEGA328, with an external 20MHz crystal and fuses set by avrdude as -U lfuse:w:0x46:m -U hfuse:w:0xdf:m. I want to send DMX with it. Using the code from Radig Ulricht:

/*------------------------------------------------------------------------------
 Copyright:      Radig Ulrich  mailto: mail@ulrichradig.de
 Author:         Radig Ulrich
 Remarks:
 known Problems: none
 Version:        17.12.2011
 Description:    DMX_TX

 Dieses Programm ist freie Software. Sie können es unter den Bedingungen der
 GNU General Public License, wie von der Free Software Foundation veröffentlicht,
 weitergeben und/oder modifizieren, entweder gemäß Version 2 der Lizenz oder
 (nach Ihrer Option) jeder späteren Version.

 Die Veröffentlichung dieses Programms erfolgt in der Hoffnung,
 daß es Ihnen von Nutzen sein wird, aber OHNE IRGENDEINE GARANTIE,
 sogar ohne die implizite Garantie der MARKTREIFE oder der VERWENDBARKEIT
 FÜR EINEN BESTIMMTEN ZWECK. Details finden Sie in der GNU General Public License.

 Sie sollten eine Kopie der GNU General Public License zusammen mit diesem
 Programm erhalten haben.
 Falls nicht, schreiben Sie an die Free Software Foundation,
 Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
------------------------------------------------------------------------------*/

#include <avr/interrupt.h>
#include <avr/io.h>
#include <stdio.h>

#define F_CPU 20000000
#include <util/delay.h>

#define DMX_BAUD 250000
#define DMX_BAUD_BREAK 80000

volatile unsigned char dmx_buffer[512];

//############################################################################
//DMX Senderoutine
ISR (USART_TX_vect)
//############################################################################
{
    static unsigned int  dmx_channel_tx_count = 0;
    static unsigned char dmx_tx_state = 0;

    switch (dmx_tx_state)
    {
        case (0):
            UBRR0   = (F_CPU / (DMX_BAUD_BREAK * 16L) - 1);
            UDR0 = 0; //RESET Frame
            dmx_tx_state = 1;
            break;

        case (1):
            UBRR0   = (F_CPU / (DMX_BAUD * 16L) - 1);
            UDR0 = 0; //Start Byte
            dmx_tx_state = 2;
            break;

        case (2):
            _delay_us(10);
            //Ausgabe des Zeichens
            UDR0 = dmx_buffer[dmx_channel_tx_count];
            dmx_channel_tx_count++;

            if(dmx_channel_tx_count == 512)
            {
                dmx_channel_tx_count = 0;
                dmx_tx_state = 0;
            }
            break;
    }
}

//############################################################################
//Hauptprogramm
int main (void)
//############################################################################
{
    //Init usart DMX-BUS
    UBRR0   = (F_CPU / (DMX_BAUD * 16L) - 1);
    DDRD |= (1<<PIND1); //Output TXD Pin ATmega88
    UCSR0B|=(1<<TXEN0)|(1<<TXCIE0); // TXEN0 Transmitter enable / TXCIE0 TX complete interrupt enable
    UCSR0C|=(1<<USBS0); //USBS0 2 Stop bits
    sei();//Globale Interrupts Enable
    UDR0 = 0;//Start DMX

    //Endlosschleife
    while(1)
    {
        dmx_buffer[0]=255;
        dmx_buffer[1]=255;
        dmx_buffer[2]=255;
        dmx_buffer[3]=255;
        dmx_buffer[4]=0;
        dmx_buffer[99]=128;
        dmx_buffer[511]=128;
    }
}

This code produces me a constant and periodic square wave on the TX pin, not the expected dmx packet with the break times and all... What could be wrong?

EDIT: Scope images


texts: Determine if button press triggered wakeup from STOP mode with STM32F0

texts: I'm using an external interrupt triggered by a button press to wake up an STM32F030K6 from STOP mode. I was wondering if there's any way of distinguishing, within the interrupt handler, a button press that triggered a wakeup from a regular button press.


texts: Custom Arduino board with CH340G not recognized by Windows

texts:
I recently designed my first Arduino Mega board with a CH340G as the serial IC. When I try to plug it into the computer (using USB1 on the board) I do not get a sound and the board is not recognised. I have burnt the bootloader already and I am getting the hearbeat blink on pin 13.
Here is my full design including layout files, and a schematic excerpt showing the USB-to-Serial conversion:

Currently only the SMD parts are on the board which got pick and placed (except the FE1.1s which will be soldered later.) Also the USB1 socket and the 5V input is soldered.
Any help would be appreciated.


texts: LM386 audio amplifier circuit does not work

texts:
I am building a low voltage audio amplifier using LM386 op-amp. I got the datasheet from the manufacturer's website and looked at the pins and their functions. After, I designed my own simple circuit regardless of noise values. However, applying that circuit (see circuit labeled 4 in the attached picture) on a breadboard does not give any results. It gives the same input with an expected noise.

The given circuit in the datasheet works just fine, but why does that circuit work? Theoretically the circuit should look like mine with a positive gain. What is the problem with my circuit?


texts: Unwinding a brushed (AC, 120v 60hz) motor to the tune of one turn, what for to gain length

texts:
I am sure this applies to most if not all brushed motors, however to be specific I am working with a 1990's handheld vacuum cleaner (you know the ones, powered roller brush, bag, usually black/red, much chooch).

Both ends of one of the two windings on the motor have become detached (don't ask) from the "holder" which attaches a brush on one side, the other is a similar situation except it bridges a conductor (line) to the end of the winding wire.

Both of these wires are very taut, and do not have enough reach because of the breakage to be able to re-attached via the little slot/slit that it gets pulled down into in order to bridge the connection. I first concluded that I would perhaps attempt to create more length by attaching some more wire to the existing ends, but thinking about that it seems it would be rather too uninsulated and a bit too rigged for my taste when dealing with high voltage AC.

So I planned a heist to gain my much desired bit of copper, the plan is to steal it from itself! That is, to unwind a turn on both sides in order to have plenty of length. However my intuition tells me that this may upset the delicate electromagnetic balance going on here, and perhaps it may necessitate doing the same to the winding on other side of the motor. It also does not sit well that I would be chopping off a couple inches on each side just to gain a couple more millimeters of wire, not to mention the performance ramifications are unknown to me.

Are my thoughts on this so far on track, or is there a better way of tackling this problem that I have not thought of (very likely)?

I am not trying to win any races with this motor however any details on performance ramifications if I proceed doing this planned would be appreciated. Most importantly, if I do so, is balance/repeating this process to the other side absolutely necessary?


texts: How to calculate day of the week for RTC?

texts: I am using MCP7940 RTC from microchip it requires to enter the day of the week as part of updating RTC with date. So how should I calculate day of the week based on the date provided by the user ?


texts: Driving multiple Pi GPIO using Arduino GPIO

texts:
I am trying to send TTL pulse from single Arduino digital pin to 8 different Raspberry Pi simultaneously. For this I have connected 8 raspberry pi in parallel to arduino digital pin.

Since, Arduino runs at 5V and raspberry Pi at 3.3V, I am using a switching diode (1N4148) connected to 3.3V pin on pi as shown in the figure for droppping voltage levels.

Now here is my question, when I check for output voltage at Arduino it shows 0.2V rather than 5V which means that arduino pin is not able to drive all the pi as they are drawing a lot of current. Also another thing, when I start removing one pi at a time from circuit, the arduino starts working perfectly for 4 pi. As far I can think of this is mostly an issue related to not enough current to drive all pi.

How can I make this ciruit work?? I read up online that a voltage buffer say something like LM110, LM741 can be used to solve this issue. Is this the right direction to work on? Can something else be done?


texts: Driver circuit not controllable, heating up

texts:
I have a driver circuit here.

simulate this circuit – Schematic created using CircuitLab

Current source below is an optocoupler. Problem is: Q2 is on regardless the state of the coupler. I think my circuit has some basic issues.

Some more explanation. The current source is the transistor side of an optocoupler (ACPL-227). The maximum collector current of the coupler is limited by R2, so it cannot exceed 2.5 mA. I want to drive a load with up to 1 A. Load differs. E.g. a fan, a pump or a valve.

My measurements showed the following results:
The output is at 20 mV when driving a fan with 300 mA current. This shows, that Q2 is in saturation.
Node 1 is at 753 mV when the coupler is inactive and at 758 mV when the coupler is active. Doesn't seem to make much difference.
Node 2 is at 4.4 V when inactive and at 0.13 V when active.
Node 3 is at 5.1 V when inactive and at 3.7 V when active.

The components that seem to heat up are R3 and Q1. I can't tell exactly because everything is rather small and I have only my sausage fingers as probes.
What I don't understand: If Q2 is in saturation, then there must be a base current, which is rather obvious when Q1 is heating up. But why is Q1 active? Is the dark current of the coupler (<100 nA) sufficient to open up Q1, or did I miss a bypass or something?

I double checked the board for solder bridges, but found nothing. The PCB contains 8 indentical circuits of this type and all behave the same.


texts: Correct size solar panel to directly run a PC fan?

texts: I'm a novice wanting to put together a solar powered fan to help ventilate a house in sunny Spain.  I have a Pengda technology 'electricity 0.15 A' (is the term it uses) 12v 80mm computer fan. I tried this on a 12 volt car battery and it worked fine. I then tried it on a solar car battery charger 1.5A   17.5volts in the midday sun - nothing. What size of solar panel do I need, please. I only need it to operate when the sun is shining and without batteries.  Many thanks


texts: What is meant by 'modified forward path' in this op-amp problem?

texts:
What is a modified forward path?

In the practise exam paper I'm doing I'm given this circuit and asked to draw an equivalent circuit of the 'modified forward path amplifier'.
I'm told that it should include all resistive loadings of the source, load and feedback network but should ignore actual feedback gain.

I've looked through my course notes and google, but haven't been able to find out what a modified forward path is.

Could someone please explain?


texts: What's the best workflow for creating gerber files from, say, an HFSS project?

texts:
I am curious how everyone gets their RF/microwave designs from their preferred simulation/design suite (HFSS is just an example) into a gerber file for fabrication.

What's a good workflow, including programs you use and tricks & tips?

The real problem for me has been that a lot of the RF designs I work on have a lot of shapes and/or fills that aren't able to be natively re-drawn in PCB software like Eagle or kicad.

I can usually export a DXF, but complex objects just seem to export to a polyline, which cannot be filled in either kicad or Eagle, to my knowledge.

I suppose the krux of my problem is a duplicate of: How to create complex copper shapes in Eagle , but I didn't want to limit the question to Eagle if someone has a better solution to the problem.


texts: Mosfet amp spike in SPICE when connecting power

texts:
When powering this circuit I get a 150 microsecond rush of current at 120 amps.  Is this a real issue with mosfets?

Additional info:  I've been playing with N and P channel slow start mosfet circuits and on some of the P channel ones I get spikes just like that if my resistors are in certain ranges.  I stripped this one down and really expected it to not have a spike in this configuration.


texts: If I, for example, set the voltage of the base of a transistor to 50% duty, will the collecter emitter voltage also be 50% of what it would normally be?


texts: Do I need to solder every header pin to the board?

texts:
When soldering MCU (Arduino and like) to perforated board I apply solder only to the pins in use, leaving the unused ones just sitting in the hole. I do this to minimize soldering accidents. The headers themselves had all their pins soldered to the chip.

It's this a good practice?


texts: In which scenarios is it important to measure microampere?

texts:
With the situation of finding a new multimeter, I found myself lost to the number of available devices on the market. For sure, to find the most suitable device I have to set some requirements. While comparing them, I came to the following point and by this to my question:

Most pro devices have only ampere range with a resolution of 0.001 A (1mA), while semi/hobby devices have ranges for milliampere and even micro-ampere. I saw device reviews on YouTube, where the presenter complained about missing micro-ampere range. While another person on YouTube told the audience that milliampere range is sufficient. So, here my question to the experts:

What kind of scenarios require a measurement of micro-amperes?

For example: Looking at a data sheet an AND gate has "input leakage current" and supply current in micro-ampere range, but when is it necessary to measure this tiny current?

Thanks for all helpful answers.


texts:
Good board - bottom view

Good board - top view

Bad board - bottom view

Bad board - top view

I am new here and mainly a hobbyist when it comes to electronics. I work more with electricity than electronics.

Sorry about the Spanish comments on the schematic. I did that when I sent it to the original designer of the circuit.

Please I need some answers here.

I have three identical circuit boards all with the same circuit configuration.

Now two work perfectly and one does not.

On the one that does not work, I have replaced 99% of the components and still no joy. See the diagram.

When I test the voltages on pin 2 and 3 of the LM3900 in the circuit, the output changes but is still unstable.

However the ICs on the good boards are stable.

I did not design this circuit, I am only trying to fix the board.

I have replaced the IC more than once and still get the same issue with the output 2. It should be that output 2 is off and so is output 1 until the supply voltage changes either going higher or lower.

Adjusting P1 and P2 does not help in this case.

This is an edited copy of the whole schematic. Some connections are not shown except those pertaining to the op-amp

The voltages shown are for a good board in green and the bad board in red.

Remember the IC is new, and I have tested the bad board with at least 7 new chips and get the same results. To me, something is really wrong with the design. I have checked the bad board all over for shorted connections and found nothing.

If needed, I can post the full diagram. I used Autotrax dex as my editor so I need to export the schematic as a Jpeg etc. It would be nice if pdf files were allowed.


texts:
Is there a USB alternative to Mass Storage which works at the filesystem layer?

The goal is to be make a USB device which is mountable as a filesystem, not a block device.

The difference is that working at the filesystem layer would allow the device to coordinate writes to it's backing storage that happen both from the host OS and from the device itself.

Interfacing at the block device layer, means that the device would have to stop writing as soon as it was mounted on the host OS (as SD cards in phones used to).

I'm interested in support in the big three OSs (Linux, OSX and Windows 7+), but not Andriod, iOS or other Unix variants.


texts: pic18f flooding serial with zeros when reset

texts: I'm connecting a pic18f4520 to the pc via serial (and then use Matlab). I used the max232 level converter and the echo test worked fined. However when I reset the pic it floods the connection with zeros: I use s.BytesAvailable in Matlab and it is zero at first until I reset the pic and it starts increasing until it reaches the max buffer size. Any ideas why this is happening?


texts: How do power banks like the OmniCharge, convert 3.7V to 120VAC?

texts:
I've noticed the cells are all put in parallel in these devices and it lead me to asking myself what kind of inverter could they be using? Like isn't it a bit inefficient to convert from such a low voltage all the way up there to 120VAC?
Please elaborate and let's discuss, as I am building something similar and I want to know how the 3.7V inverter works


texts: When chopping off a DC current on its way to a load, what happens to the travelling pulse?

texts:
I am curious what happens if you draw DC power to a load, but as it approaches the load you chop the load connection say with a SSR or switch.

The power will be travelling near the speed of light, following the wire toward the load. When the load is chopped by a switch just before the pulse reaches it, will the power just keep travelling forward, according to Newton's Law of momentum (third law?). Or what comes of it?

Please let me know if you know the answer. Thanks


texts: Assigning Current Direction in a Circuit + Resistors

texts:
I'm a computer science student and am taking a basic electrical circuits course. I'm facing many difficulties, but the one that I want to address here regarding nodal analysis and determining whether or not resistors are in series or parallel. I decided to use a specific problem example from my textbook.

Regarding assigning direction for currents, I noticed that in many cases currents aren't initially given and the reader has to "draw" them on (as I did for I1 and I2 and I3). My question is, how do we know which direction to assign them to?
My next question has to do with combining resistors. I understand the concept of how to combine resistors when they're in series or parallel, but I'm not sure how to determine that in the first place. For example, if resistors are connected like first and second resistors starting from the far left side, are these two resistors in series?

Any help would be greatly appreciated. Thank you!


texts:
The battery in my garage door remote finally quit.  Before replacing it, I measured the voltage with a digital multimeter and was surprised to find it reading 9.70v, quite a bit higher than the typical voltage on a new Alkaline cell (9.15v).  I put it back in the remote and read the voltage as I pressed one of the buttons, and saw it sag down to about 3V.  With a new alkaline cell the voltage drops about 0.1v under load.

The battery is an Eveready 1222 6F22 "Super Heavy Duty".  According to the online datasheet this is a Zn/MnO2 "Leclanché chemistry" cell, which is a little confusing as I thought Leclanché referred to Zinc/Carbon.

Is the behavior I saw (overvoltage when unloaded, deep sag under load) typical of this type of cell at end-of-life?  What causes the overvoltage?


texts: STM32F437 UART doesn't work at 3.6V~4.2V(lithium battery)

texts:
led is on but UART doesn't work when using lithium battery. stm32f437 UART can work at 5V(power supply).

#include "mbed.h"
#include "math.h"
#include "string.h"
#include "stdio.h"
DigitalOut g1(PD_0);
Serial drive(PA_9,PA_10);
void bleread(void);
char blerx[20];

int main(void){
  g1=1;//green led on
  drive.baud(9600);
  drive.attach(&bleread,Serial::RxIrq);
  while(1);
}
void bleread() {
  drive.scanf("%s",blerx);
  if(blerx[0]=='r')drive.printf("hello");
}

Does third picture's power supply correct?


texts: Does my PCB require a 50 ohm impedance trace even if I am using an external antenna?

texts:
I am using the Quectel M95 GPRS Modem on my PCB. The hardware reference guide says
"pin 39 is the RF antenna pad. The RF interface has an impedance of 50Ω."
I am using a u.efl connector and connecting a QuadBand PCB antenna to the connector. The antenna spec says impedance: 50 ohm.
Now I am confused. My layout designer is saying the manufacturer has to put a 50 ohm trace for the u.efl connector while manufacturing.
There is a Pi circuit on the PCB for RF tuning. How do I use that?
For now only a 0R is put there, but if tuning is required the values were to be put in accordingly.
If the antenna already has 50 Ohm impedance, why does the PCB trace also have be to 50 ohm?


texts:
I'm trying to ride a full bridge inverter using SPWM to control the MOSFETs, the signal SPWM that I use to control the MOSFETs comes from an NI elvis, but it only provides 5V and I know the fact that the VGS from the MOSFETs must be higher than the VDS and I'm trying to convert at least 20VDC (I want 50VDC but that's another problem with the bridge), so im need a minimum voltage VGS of 20V. I know there are drivers as the IR2110/12 use to control the mosfets but at least for me it doesn't work, so i'm using the optocoupler 4n35 for amplify the input signal of SPWM,it works well while i'm not exceeding the value of 10Vcc, it amplifies the input signal well, but when i'm using more than 10Vcc in the optocoupler the output signal cross for zero and it goes to negatives values and it doesn't work for control the MOSFETs.
Can someone give me some alternative for my problem o the 4N35 cannot be used for my aplication?

These are the output signals and the circuit that i'm using.


texts: Pin functionality multiplexing in NXP p1010 processor

texts:
I am trying to make a small design using P1010 processor.

During power-up sequence processor fetches configuration through specific pins.

All of them are also used for other functionality.
The processor guide told us we have two options here.

First - use a PLD device (CPLD specifically).
The second one in to use pull-up and pull-down resistors. I don't
need a PLD flexibility now so I will plan to use resistors.

I will write about a specific pins here but generaly it is the same for all of them.

First question:

We have two pins. One of them is EC_MDC/cfg_cpu_boot. The second is READY/
TRIG_OUT. READY: Asserted-indicates that the device has completed the reset operation, and e500 core is not in a power-down state (nap, doze, or sleep).
I need some kind of sheematics here so while READY is 0 the porcessor should use resistor (pullup or pull down). But when READY goes 1 it should use EC_MDC functionality (go to other part of the scematics and bypass resistor)

Second question is almost the same.

We have some pins wich have triple mennings. Something like IFC_CLK_1/USB_NXT/IFC_CS_3_B. We will switch between them using software. But how should we rote this pinn in such a way that we use different part of schemes and completely bypassing others.

For example IFC_CLK_1 is used as a clock during some operations for one part of scematics. At the other time we would like to use IFC_CS_3_B as chip select for completly different part of schematics.

So generally, how can we use pins for different activities represented by different and unrelated same parts?


texts:
Let's say I have a logic stage doing an operation on 2 inputs, giving me an output.

How could I use this output to forward it into another set of logic stage, without having to put everything in the same source to ground circuit ?

For example, I'm trying to imagine something like such:

1st circuit:   A and B = Result1
2nd circuit:   C and D = Result2
3rd circuit:   Result1 and Result2 = Result3

I think I should do it like such (resistors removed for simplicity):

But if I have lots of things to put together, I think I would get an headache debugging and calculating all possible voltages and current in this recursive design. I would like to be able to make all parts one at a time, to make sure they work, and then put them together later.

So this is the first thing that came in my head, but of course it wouldn't make sense, as all my inputs would be ignored:

So I thought about optocouplers but, isn't that a weird solution ? (I couldn't find an optocoupler in Circuit Lab, so I tried to make one on my own):

Thanks !


texts: Voltage divider ratio limitation applied to potentiometer

texts:
I'm trying to find the general formula or more like understanding of how to choose resistor values to limit the voltage ratio when using a potentiometer.

A potentiometer is equal to a voltage resistor divider where the ratio depends on the resistor value. Okay, so you can tune from 0% to 100% which means for a Vin of 5V for example, from 0 to 5V.

Now let's say I want to limit this ratio to a certain value as from 50% to 70% to obtain a Vout ranged from 2.5V to 3.5V. So then, I'm sure when I will change the potentiometer value the voltage will be limited between this voltage range.

I understand by adding a grounded series resistor the ratio will then change to constrained value since when the potentiometer will be at min/max value, there will still be this resistor to take into account:

Which will give a new ratio of 50% to 100% (so if VCC = 5V, 2.5V to 5V) due to the 2k series resistance added. (2k/4k for min potentiometer state and 4k/4k for max potentiometer state)

But I can't get my head around how to now get arbitrary ratio as 50% to 70%.
What I am not seening ?
Thank you


texts:
If you're using mesh analysis, for each loop current do you have to have at least one node, where only that loop current through it?

For instance, if you have 2 loop currents, do you have to have at least two nodes where the current in node 1 is loop current 1 and the current in node 2 is loop current 2?


texts: How can measure the minimum value in LTspice monte carlo simulation curve?

texts:
Attached the LTspice curve result of the monte carlo simulation.

How can measure the minimum value from the curve. Here it show only the middle values while measuring. What setting change should be done.


texts: Offset of Output voltage of an op amp circuit with capacitor

texts:
The following circuit is given:

I needed to calculate the effective value of the output voltage, for an input effective value of 1mV:
$$
U_a=\frac{\frac{1}{jwC}}{R_1+\frac{1}{jwC}}*U=\frac{1}{1+jR_1wC}*U=\frac{1}{1+j*10.053}*1mV=\frac{1}{10.103*e^{j*84.32}}*1mV=0.099*e^{j*-84.32}*1mV\approx 98.9\mu V*e^{j*-84.32}
$$
Therefore the amplitude of the output voltage is:
$$
\hat{u}=\sqrt{2}*U_{eff}=\sqrt{2}*98.9\mu V\approx 139.866\mu V
$$
I wanted to verify the result and used a circuit simulation tool (circuitlab). I received a surprising plot for the output voltage and current:

As you can see, there is an interesting offset applied in some way. Can someone explain me why voltage/current look like that?

EDIT:
Input current of both terminals:


texts: Why do my P-channel MOSFETs keep dying in this H-bridge?

texts:
So this is my H-bridge:

Every time I start using it in one direction the P-channel MOSFET and the NPN BJT which belong to the used direction die in seconds. The killed MOSFET and the BJT developing a short circuit so I can use the other direction no more. They die without noticeable heat or smoke!
The controller is an arduino uno, and only the N-channel MOSFETs are driven with PWM signal, the P-channels are connected to simple digital output pins.
PWM frequency is the default 490Hz for digital pins 9 and 10 (each PWM output is individual).
I've already killed 4-5 P-channel MOSFET + BJT pair, it could happen on both side. (It depends which direction I use first.)
The motor is a 12V car windshield wiper DC motor, the power supply is 12V 5A.
12V and 5V power supply grounds are connected.

There are two things which may be true, but I am not 100% sure as I did not test it thoroughly:

in the former version I was using 1k resistors for R7 and R8, and I did not have any problems. I will try it again but I am running low on P-channel MOSFETs now..
when I cut out the fried MOSFET + BJT pair, I can use the other direction without killing the remaining MOSFET + BJT pair.

Please help me, what is happening here :)

Should I use a resistor between the NPN BJT and the P-channel MOSFET?
Should I use a 2n7000 MOSFET instead of the 2N2222 BJT?

UPDATE:
I've just tested the H-bridge with a 12V 55W light bulb instead of the wiper motor. The P-FET and NPN were killed during the test. The N-channel side was driven with a 40% PWM signal.
Without a load it did not have any problem.

UPDATE2:
I changed back R7 and R8 to 1k from 150R. Now the bridge is working again without any components failing. (I didn't run it for days, but with the 150R resistors the reproducing of the fault only took a few seconds.)
I will add some decoupling capacitors on the bridge between the GND and +12V anyway as Brian suggested. Thanks for the answers to everyone!


texts:
If we have a binary sequence that is \$x\$ bits long, what are the minimum and maximum that can be represented in two's complement form?

The maximum is \$2^{x-1}-1\$, and the minimum is \$-2^{x-1}\$.

But why? How can it be shown that this is the case?


texts: NiMH battery pack charging circuit using Solar panel [Help]

texts:
Recently I have been working on a NiMH battery pack (7.2V / 2100mAh) charging circuit powered by a 12V solar panel. With some research I found charging NiMH takes different forms by measuring change in voltage, change in temperature, voltage across the battery.
Since I need my charging circuit to be simple so I opted for measuring voltage across battery method and slow charging at the rate of C/10. Using this I designed the below circuit.

I have used a LM317 to give output of 8V in its output which will be used to charge the battery. Also I have used a comparator LM311 to activate charging and discharging through MOSFET IRF510. And limited the current to 210mA to charge the battery at the rate of C/10.
I have set the hysteresis of comparator at VL at 7.3 and VH at 7.8 so when battery across battery crosses 7.8V it stops charging and it starts charging once the battery voltage drops below 7.3V.
Now my questions are:

What diode should I choose to connect in series with solar panel to prevent reverse current when Solar panel produces no current? I prefer not to go with traditional silicon diodes since the voltage drop is high and cannot afford any voltage drop.
Is there any design considerations I have missed in the circuit which I should be looking into keeping the circuit as simple as possible?
I intend to use a load which will draw about 250mA from the battery, is it safe to use such load provided it will be ON simultaneously when the battery gets charged using solar panel?


texts: Amateur electro hobbyist here. What can I use to drop both voltage and amps in my circut? I need to drop 19V 2.1A (power source) to 12V 0.8A. I got a bunch of resistors


texts:
I was wondering if integrated eFuse solutions exist that are designed to protect a low voltage AC bus.
In my application I would like to replace a 2A PTC that protects a 24VAC bus but I cannot find an IC which explicitly states that it supports AC current.
For example, the TPS2660 has a diagram in the datasheet that suggests bidirectionality with its two FETs, but also states that it is designed to protect from reverse current flow, which would
prevent use with AC.
Does a solution like this exist or am I bound to design a discrete circuit, given that I have strict thermal and space constraints?
Thanks in advance for the help.


texts: Hardware for Operating System development

texts:
I am heavily interested in Operating System theory and design and have decided I would like to play with developing an OS. I have a background in x86 assembly and have looked into ARM also. I would like a development board to develop the OS for. Has anyone had experience with OS development and/or can suggest some hardware to use?

One board I am considering is the LPC1769 LPCXpresso board.

I am aware I could use a VM, but I would like to use actual hardware.


texts:
Can someone explain the behaviour and the output(at B) for the following circuit?
What I think is that, C will charge and at one point stop conducting. So at B it will be HIGH output at that instant and till it charges.
Now after it is fully charged, it will discharge throught R, so the output should decrease with a slope to 0,and this should repeat. I am not sure if this is right.
Can someone please confirm that?
I tried building the circuit, but the rise and fall happens only once. Can someone explain why would it not repeat itself?

simulate this circuit – Schematic created using CircuitLab


texts: I have a number of parts that I want to re-size so as to fit on paper. How would you resize a part?


texts:
Where does forward voltage of diode come from? I thought that forward voltage came from the transistor Vbe voltage (as far as I know, a diode is made of a transistor) :

simulate this circuit – Schematic created using CircuitLab

This was explaining why the voltage is (most of the time 0,7V). But, I realize that voltage can be even greater. (1,3V for a RS1BL diode that I plan to use).


texts: Why is the voltage measurement of this circuit different when the switch is on?

texts:
I built a simple circuit with two lamps and a slide switch powered by two 1.5 V batteries. When the slide switch is off, the voltage of the circuit measured by a multimeter is 3.15 V:

However, when the slide switch is on, and the lamps are lit, the measured circuit voltage is 2.99 V.

I don't understand why the voltage measurement isn't the same in both cases. Why is there this difference?


texts: Confusion regarding antenna element to element isolation in an array consisting of say 2 antennas

texts: suppose one has an array of 2 isotropic  antennas used for spatial diversity , which means that they need to be as uncorrelated as possible, how does the coupling or isolation between them affect the diversity performance? so suppose the signal needs and SNR of 20 dB to be detected and the isolation is only 15 dB, how would this work?


texts:
I have the attached schematic.  It seems to work and do what it needs to do, but it only works a few times then smokes the P channel mosfet (fqp27p06). It actually works for a bit before it smokes.

I have a 12v motor that is ran from a GPIO pin to turn on the 12v system.  The P channel mosfet suppose to help with the active braking, which does seem to work (a few times).  I am very new to this.  Come someone tell me what I should add to quit smoking parts?

simulate this circuit – Schematic created using CircuitLab


texts: What does the FPGA do with unreferenced I/O pins?

texts:
Here's  one thats been puzzling me for a while.

I have an FPGA design in Altera, driving an audio chip and programmed through its serial interface. I monitor and debug this with an oscilloscope/SignalTAP. The chip is set to a loopback configuration so that whatever is played into LineIn comes out LineOut.

The audio chip schematic is shown below, and shows the I2C_SDAT and I2C_SCL interface pins. Of the inputs, AUD_XCK is provided by an IP clock generator (standard audio ~44 kHz) and AUD_DACDAT is tied to AUD_ADCDAT to create the loopback by connecting the ADC straight to the DAC.

Looking at some of the clocks, the AUD_BCLK (bit rate clock), AUD_DACLRCK and AUD_ADCLRCK (ADC & DAC sample rate clocks) are all generated internally (in what the datasheet calls "master" mode). They are not needed as the digital data from the ADC is fed straight back to the DAC output to go to LineOut.

However! When programming the serial I2C bus I had anomalous behaviour. The bus would program the chip correctly (all ACK's present). However - the ADC-DAC loopback did not function at all. My first thought was that I was failing to program the interface correctly.

After much gnashing of teeth, I stopped scrutinising my I2C (which after all, was being ACK'd by the chip). In order to see if the AUD_BCLK and other clocks were functioning in the logic analyzer, I had to add them to the design - and the very act of doing so made it all start working, even though they were left unconnected as shown below:

I found that simply by including these unconnected clocks made the difference between the chip functioning or not. I'm looking for ideas as to what the Altera tool does to unreferenced pins in the design so that not including the BCLK, DACLRCK/ADCLRCK clocks in the logical design stops the chip working, even though they are logically unconnected! Does Altera tie all unused pins to ground when it abstracts them away or similar?

Sorry for the longer post - I'm hoping that I've managed to explain the scenario, all ideas/recommendations are welcome!

David


texts: How to generate INDUCTION communication field strength of 3 dΒμΑ/m at 10 metres at 1MHz?

texts:
For E field short range communication, the usual limit specification is like 1mW transmitter and use dipole antenna as reference.

What is the equivalent for magnetic induction (H field) communication? Both sender and receiver use coil antenna, example as in RFID tag.

What is 'reference antenna' (equivalent of dipole for E field)? How does it relates to

a) number of turn of coil

b) area of coil

How is 'antenna input power' calculated?

How much drive current (uA) is needed to achieving filed strength of 3 dΒμΑ/m at 10 metres at 1MHz?


texts: Convert analog piezo "transition" to digital signal

texts:
I'm trying to get what amounts to a knock indication into a microcontroller input from a piezo sensor. It's looking fairly good now at the fifth iteration, and about ready to provide digital levels for input to a 3v3 MCU.

I started with an "instrumentation amp" but changed that to a charge amplifier as suggested by @Circuitfantasist. Also based on a comment he made elsewhere, I then changed the hacked 'rectifier' I had before into a standard "precision rectifier". The third change was the addition of the RC pair and a diode to ensure the output stays high for a "little while" after the strike is first registered. The fourth change was the addition of the two-transistor schmitt trigger on the output. Change five replaced the discrete schmitt with an IC comparator using positive feedback for hysteresis and having an open collector output to get the levels set up right for the MCU.

Here's the circuit now:

simulate this circuit – Schematic created using CircuitLab

It seems to work quite well. Yellow is the input signal raw from the piezo device (the signal is essentially the ringing sound of a chunk of steel being hit with a hammer), blue is the output. It's intended to trigger an interrupt with the falling edge:

From here, I think it's ready to have the final output put into an MCU. If that actually changes anything, I'll update here.

As a side note, I learned a lot about verifying the 9v battery you're using is actually still good. This thing oscillated in most curious ways for a while, and I eventually realized that it was the supply rails drooping when things changed state, and that in turn was because my little PP3 9v battery was essentially dead, and putting out about 8.3v with no load. This also reduced the noise on the signal quite a bit. Oh, the joy of learning :)


texts: Arduino Serial.print() sending the data with a delay between bytes

texts:
I'm trying to send some current measured data by Arduino to my main MCU. I used the serial.print() function to do so this is the code I used:

In reciever side I can get the data correctly but after some random minutes of working the reciever doesn't recieve data anymore. I used a logic analyzer to capture the data and I see a timing gap between some data which I guess may cause the problem. What is this gap comming from. I also tried to disable the interrupts while sending data but this didn't help.


texts: TPS54260 DC-DC Buck Regulator BOOT and PH pin voltage drop

texts:
I am using TPS54260 Buck converter which steps down 16V to 5V output.

Load current is 600mA max.

To the inrush current through the output inductor, I did some rework. But after some rework, my 5V output is oscillating as shown below.

Upon inspection, we found the voltage between BOOT and PH pin to be 0.76V.

But in another Board which is working fine (getting stable +5V output), we get the voltage between BOOT and PH pin to be 6.081V.

From the datasheet, Section 7.3.4, page 13, we find this

  " When the voltage from BOOT to PH drops below 2.1 V, the high-side
  MOSFET is turned off using an UVLO circuit which allows the low-side
  diode to conduct and refresh the charge on the BOOT capacitor. Since
  the supply current sourced from the BOOT capacitor is low, the
  high-side MOSFET can remain on for more switching cycles than are
  required to refresh the capacitor, thus the effective duty cycle of
  the switching regulator is high."

I know this has happened due to some improper rework. But can someone tell what might have caused for this to happen and can someone please provide a simple explanation of blockquote operation in simple terms


texts: how remote key of popular car brand working wide range?

texts:
i did remote control for garage opener with cheap module supply with 3v coin cell battey,i got 30-40 meter range by spiral type antenna setup and got 80 meter range wipe type antenna setup. i purchased  antenna for receiver side also. (using USART for data transmission)

but how dose the car key working over 100meter without an antenna?
tell me any tips to develop like those wide range remote controls, i have cheap 433mhz rf tx and rx module, and also PIC12LF1840T39A (rf transmitter with mcu) and MRF39A (RF receiver ic)


texts: the voltage resolution for an analog signal with an amplitude

texts:
say,i have 16-bit DAQ that can read at a rate of 250kSamples/second. What is the voltage resolution for an analog signal with a 2V amplitude? For what value of signal frequency can I safely digitize this signal?

How can we relate bit daq and samplas/second with voltage resolution's amplitude to slove the problem?. For second question i think, it wants us to think about Nyquist frequency, but don't know how to relate those value, either.


texts:
For the exploration of a CCD line scan sensor, I would like to ignore two colors on an RGB sensor. What should I do? Just not connect clocks and outputs? Tie them to ground?

The sensor in question is a PD3728DZ from NEC. The datasheet ist here:

http://www.datasheetlib.com/datasheet/1451098/pd3728dz_renesas-electronics.html

I am not even sure what to look for in there. I would appreciate any help you cand give me.


texts:
I'm working with an LPC2387 (datasheet), and pp. 55-56 of the datasheet specifies several options for the RTC crystal with different load capacitance: 11pf, 13pf, and 15pf. For each of these crystals, different load capacitors are specified.

First, the datasheet speaks exclusively of "32 KHz" crystals. It seems to me that what they really mean is "32.768 KHz", is that correct?

Second, these load capacitances seem odd to me, since neither Digi-Key nor Mouser carry 32KHz crystals with these specifications. There is a 12.5pf crystal, which is possibly close enough, but not exact. Am I expected to calculate the capacitance of my traces and factor that into my choice, or do I simply choose the closest match?

Third, if I do end up having a choice of crystals, should I choose the highest load capacitance? Does that provide a more stable oscillation?


texts: Use Peltier Cooler for effective Air Cooling?

texts:
I am using 4 TEC1-12706 thermoelectric cooler on a suitcase, by cutting 4 holes to fit these through and sealed them. All of them are connected to 12V DC supply from a SMPS and each of them have attached heatsinks with 12V DC fans on their hot sides (which is facing outside the bag).

When run temp 34.9 C, the cold sides on the inside of the bag do get cold enough. Leaving it overnight, i see cold water at the base of the suitcase, but the air itself is not much colder temp 31.2 C than it was before (the cold surfaces are still quite cold).

Assuming this is because of improper temperature flow, i attach 4 heatsinks with fans on the cold sides as well.

When run temp 32.5 C, the heatsinks on the cold side feel very slightly cold. Leaving it overnight, there is neither any water formation, nor is the temperature cold enough temp 31.2 C.

Why is this not working? What am i doing wrong heer?

This is my first experience with Peltier coolers.


texts:
I am trying to design a pre-amplifier before going into a power amplifier. I essentially just want to signal condition a little more before the power amplifier.

Whats really confusing me is the input/output impedance of the OP-AMP (LM833N) and what it can potentially drive. The datasheet doesn't say its maximum current capability so I dont know where to start.

I am trying to create 1st order passive filters just to make a simple, however I know that I have to take into account of its impedance as well. I was wondering if anyone can tell me if I am on the right track and some design tips in creating filters for this case.

simulate this circuit – Schematic created using CircuitLab


texts:
I am wondering whether I am free to use any transmit/receive methods on this particular frequency or do I need to stick to some standards.

I am willing to buy a chip with PHY layer of 868 MHz and we do have the software MAC provided with it ( it is a ZigBee standard access layer) I am wondering whether I need to use it and if not what can I do to make sure I wont disturb existing application of devices nearby using the ZigBee, and in fact I don't even know whether it should my mine concern or will the PHY make sure that the other devices in the area which are using the ZigBee will be fine.


texts:
I'm considering making a replacement solution for an automotive fan output stage.
The original part gets quite warm and tends to be unreliable - it's cooled with massive fins and sits directly in the air stream of the fan it controls to keep it cold.
I found modern TO-220 MOSFETs with suitable voltage ratings with Rds(on) values of less than 2 mOhm, which should result in much less heat and much simpler cooling than the original part - it'll have to switch up to 40 A at 14 V.
My question:
How good have MOSFET developments been in the last 2-3 decades with regard to on-state resistance? Were sufficiently low-resistance MOSFETs just not available back then such that an extensive cooling solution was required?


texts:
I've just started using IC's, and am am trying to understand exactly how they work.

I know that you must first clock in data to the shift register using Arduino's shiftOut() function, then latch the data by setting the OUTPUT pin to HIGH, but was wondering what this nomenclature actually means.

Can somebody describe for me and any other beginners having the same question what exactly does it mean to clock and latch


texts:
I am designing a software PID control. Logic is almost final but I wonder how do I decide the value of \$k_p\$, \$k_i\$ and \$k_d\$. Also, I need to determine the max and min value for the Pterm Item and Dterm. How do I do that?. Also, I am trying to implement the inverse control. Also, am I going in the right way in designing the software PID? Also, if integral time and \$k_i\$ both are same?
The code I wrote so far is given below.

Calculate_Error();
    P_Term = Percnt_Error;

    P_Term = KP * P_Term;

    if(P_Term >= PMAX)
    {
        P_Term = PMAX;
    }
    else if(P_Term <= PMIN)
    {
        P_Term = PMIN;
    }

// Integral calculation

    if(Integraltime==1)                 // Take integration at every 1s
    {
        Integraltime = 0;
        Error_Accum = Error_Accum + Percnt_Error;   // Error Accumulation over time
        if(Error_Accum >= MaxAccumError)
        {
            Error_Accum = MaxAccumError;
        }

        if(Error_Accum <= -MinAccumError)
        {
            Error_Accum = -MinAccumError;
        }

        I_Term = (Error_Accum)*KI;

        if(I_Term >= IMAX)
        {
            I_Term = IMAX;
        }
        else if(I_Term <= IMIN)
        {
            I_Term = IMIN;
        }
    }


texts: Changing all via and routing sizes at once (Altium Designer, PCB Design)

texts: I have a completed PCB design drawn by Altium Designer. I want to increase via sizes. But there are too much of them, and changing all of them one by one will be a very long and bothersome work. Is there any way that I can select and resize them all at once?


texts: Can an electrolytic capacitor be charged reversed bias by a small voltage?

texts:
In this monostable circuit the C1 capacitor is reverse biased. When T1 is closed and C1 is discharged what will happen on the right side of C1?

Will it charge up to 0.6 volts so that T2 can be opened and then discharge again over the base-emitter line and than charge through R2?

That would mean that the polarized capacitor could be loaded reverse biased. Is that true?


texts:
Why do 7490 and 7493 have gated reset inputs?
For example: 7493 has two inputs MR1 and MR2. Internally, these two inputs are fed into a nand gate, the output of which is use as the reset ( active low ) input for all the four flip flops.

Wouldn't it have been better if there is just one input (say, MR ) which will reset all the flip flops?

Internal Circuit Diagram of 7490 : link 7493 : link


texts: can I charge battery at the same time as using it if it is the new usb c pd

texts:
Sorry for such a newbie question. I am still trying to find my feet.  I know that a battery cannot be charge and discharge at the same time as I find this:

No, a battery can't be charged and discharged at the same time. If a
battery is connected to a charger delivering 1 A and a load drawing 3
A, then the battery will be discharged at 2 A. There is no
simultaneous charging and discharging going on

on here:
https://findanyanswer.com/can-you-charge-and-use-a-battery-at-the-same-time#:~:text=No%2C%20a%20battery%20can't,charging%20and%20discharging%20going%20on.
But I have just purchased this:
RAVPower Portable Charger 20000mAh 60W PD 3.0 USB C Power Bank 2-Port Power Delivery Battery Pack High-Capacity External Battery
from here:
https://www.amazon.co.uk/gp/product/B083J2YKRL/ref=ppx_yo_dt_b_asin_title_o01_s00?ie=UTF8&psc=1
Does that make a difference?  Can I charge and discharge at the same time?  I forgot to order the PD plug so I cannot actually test that at the moment.
Any guidance even just to tell I am stupid? :)
Thanks
NB
To add more info. This is my User Case:
I have an enclosure with a raspberry pi.  It is connected to a usb power bank. I have an external port where I can plug the usb power bank to an external charger. At the moment when the battery runs down I charge it by connecting a power source to this charger.  I also turn the Pi off via  SSH command. It charges OK. I was only wondering if I could avoid that step of using software to turn device off. So, scenario is:

Raspberry Pi is running and powered by usb power bank
The usb power bank runs out of charge
The raspberry then powers off
I plug an external power supply to recharge this usb power bank
As soon as it does the raspberry pi starts up again.

So i am now in the situation  that the Raspberry pi is running and the usb power bank is charging at the same time.
I figured it MAY be able to work because you recharge a phone this can also be the same scenario?


texts: Possible to measure voltage while charging?

texts:
Suppose we have a simple DC power source charging a battery or capacitor.

If we try to measure the capacitor's voltage in this simple circuit we will instead read the power source voltage:

simulate this circuit – Schematic created using CircuitLab

Is it possible to directly measure the voltage of the capacitor without disconnecting the power source and without knowing the capacitor's time constant and capacitance?

I.e., I'm wondering if there's a circuit that can accomplish this without exploiting the following solutions:

If we temporarily disconnect or turn off the power source, the voltmeter will read the voltage across the capacitor.
If we know the time constant and capacitance we could instead connect an ammeter and deduce the capacitor's voltage from that.  (Or, if we knew it was fully discharged initially, we could integrate the amperage from the start of charging to calculate its voltage.)

I've been trying to picture some clever arrangement of diodes that might allow for measurement during charging, but that has left me thinking that this is theoretically impossible using a static circuit.


texts: Controlling an electrical motor with my laptop

texts:
I want to control an electrical motor with my laptop, I want to start with the following:

a mini server connected through WiFi to my laptop
I want to connect an electrical engine to this mini server
with my laptop I want to be able to control the speed of the engine (lets start with two speed levels, 50% - 100%)
written in python

I'm a complete beginner in electrical engineering, I do have a few years of experience in web development, so that's a start.

Can anyone point me into the right direction?

is python a good choice?
what components do I need (motor, laptop, power source etc)?
is this idea advanced or really basic?
any good tutorial websites?

As I said im complete new in this field, so I don't even know how I should Google this. I think this is great way to develop my skills and great fun of course.
Please tell me if I need to be more specific.

Thanks in advance for your advice


texts:
I bought an ATmega32 IC recently, but now I found out the program I wrote in Atmel Studio reports an error due to an overflow of memory. It is 134.1% over the recommended memory of this chip. Are there alternatives that exist?

I don't want to go and buy another chip as they are quite expensive.


texts:
I would like to ask: is there a mechanism that would gradually reduce in voltage to 0V when it is on? Like when a capacitor is fully charged, no current flows across it?

I need this mechanism to eventually produce a logical LOW output (0V) but I need for it to be turned HIGH at first then eventually be LOW.

At first I thought that capacitors in series would do the thing but I found out that the voltage isnt actually affected when capacitor is fully charged.

Please help me.
Thanks in advance.


texts: Does LiPo4 battery amperage output increase as voltage decreases from 4.2V to 3.57? I'm trying to size up a diode

texts:
I'm trying to determine the max amp output of a battery pack that has 28 cells in it. To be more specific towards what I'm doing: I'm trying to size up a diode for the charge port; the battery charges at 29.4V max. On the website where I bought the e-bike it says it's a 466Wh battery. So, doing conventional math 466 / 29.4 = 15.85A. But, theoretically if a cell says it's rated at 7.56Wh, and the voltage drops from 4.2v to 3.7v, the battery would have to increase amps to maintain 7.56Wh. In my case my battery may be putting out 15.85A at 29.4V, but when the battery is low at 25.9V does it put out 17.99A? One website recommended using a diode that's twice the rating as the output to reduce the need for a heat sink. In this case I would be looking at a diode rated at 58.8v and 35.98A.

Update 10:44AM: I need a diode between the battery harness and battery charger; the charger gives me an error that says it's receiving current from the battery, so it's unwilling to charge the battery pack. It makes sense as it would be better to not have current flowing from the charge port.


texts: Could most AC devices run off of DC rather than AC?

texts:
To be clear - I have absolutely ZERO intention of ever doing this.  But when I learned what a rectifier does (flip the negative portion of the voltage into positive), it occurred to me that it ought to be able to accept DC as well (it would just have nothing to "rectify" beyond the polarity of the source voltage).

Is this correct?  If so, in what cases would it NOT work?


texts: Calculating resistance of an electric brush

texts:
For a certain application, I'm using carbon based brushes to transmit power from a stationary component to a moving component. I'd like to calculate the resistance of the carbon based brushes to know the maximum current it can carry without problems. I did the same with the copper using the following formula:

$$R = \frac{\rho L}{A}$$

Is it valid to use the same formula with the brushes?

Where the resistivity of carbon is: 2.50E−6 to 5.00E−6

Also, if low voltage and high current is applied between the surfaces of each component is an arc possible? There should be no gaps at all, all surfaces are in direct contact.


texts:
I have an LED multiplexer circuit (inspired by https://www.instructables.com/id/Multiplexing-with-Arduino-Transistors-I-made/) in which I have set the resistor values to maximize the current through the LEDs (without exceeding the maximum forward current through the LEDs or the maximum power dissipation in any of the components). It looks like this:

The R1, R2, R3, C1, C2, and C3 pins are Arduino digital pins while the 5V pin is the 5V from the Arduino. I have this circuit assembled on my breadboard and it works as expected. (Though please let me know if there is anything atrociously bad about it).

What I want to do is add a potentiometer between the 5V pin and the collectors of the Q-RX NPN BJTs so that I can vary the LED light level from off (or almost off) to "full brightness". It seems to me that this should work in theory. When I replace the 5V pin with GND in my simulation, I get ~0 current through the LEDs, which is what I want:

However, when I test with a single LED enabled and I unplug the 5V pin from the Arduino, the LED dims some but is still fairly bright. I measure ".001 A" with my multimeter (I get 0 with it set it to mA). This must be from current flowing from base to emitter of the Q-RX BJTs. I have been trying to re-familiarize myself with how transistors operate, but I need some help here to understand this. A few questions:

Am I trying to use the NPN BJTs completely incorrectly?
Why does my simulation (I'm using OrCAD Capture Lite) show ~0 current through the LEDs when I can measure it at ~1 mA and there is obviously enough to light the LEDs?
How can I adjust this circuit to achieve my goal? Should logic level MOSFETs be used instead?

Reference:

LEDs: https://www.cree.com/led-components/media/documents/C512A-WNS-WNN-942.pdf
BJTs (2N3904): https://www.fairchildsemi.com/datasheets/MM/MMBT3904.pdf
Resistors: https://www.amazon.com/gp/product/B07J48VNR7

Side note: I just noticed that my simulation shows ~54 mA at the C1, C2, and C3 pins which exceeds the 40 mA Arduino pin limit, but that is besides the point.

Any help is greatly appreciated! Thanks!


texts: How does shifting Product/Divide Block work?

texts:
I've just learned about PID MRAC using MIT Rule, and to build it in Simulink I need to use the Product/Divide Block.
https://www.mathworks.com/help/simulink/slref/product.html

This is a figure from "Automatic Tuning of PID Controllers Using Model Reference Adaptive Control Techniques" paper by K. Pirabakaran and V. M. Becerra.

If I try to shift the pointed product block above to the left, the Kp or the output on the right will be messed up.

Let me simplify the problem by this block diagram.

Here is the output on the scope

The first block output (ya), output the same as the second block (yb).

I expect four of them to be the same.

$$y_a(t)=y_b(t)=y_c(t)=y_d(t)$$

With its transfer function combined altogether.

$$\frac{Y(s)}{U(s)} = \frac{1}{(s+1)(s+1)(s+1)} $$

How does it happened? I expect the product blocks to be working as transfer function multiplication. Am I wrong? Does it exist in the Simulink library then of what I've been expecting?

Add info as per comments

I'm using MATLAB R2018b Update 5 and I've also tried using ode14x, ode1, ode2, ode3, ode4, ode5, and ode8 solver with fixed 1 ms time step. Even also tried to use the convolution block with 3 different computation method. The result still the same.

Suppose if my expectation above wrong that product block will act as a transfer function multiplication, then

$$Y_a(s)=\frac{1}{s} \cdot \frac{1}{(s+1)^3}$$

and

$$Y_b(s) = Y_c(s) = Y_d(s) = \frac{1}{s^2} \cdot \frac{1}{(s+1)^3}$$

But, as we see from the simulation \$Y_a(t) = Y_b(t)\$ and \$Y_b(t) \ne Y_c(s) \ne Y_d(s)\$.

So what's wrong?


texts:
I need to pass a 100MHz continous clock between an MCU and FPGA. The clock edges are aligned to various interface signals between both devices.  I wonder if I can pass a submultiple of the clock like 50MHz or 25MHz and use the PLL inside the FPGA to multiply the incoming slower clock to 100MHz again.

What is the phase relationship between input and output clock of a PLL when the output is a strict integer multiple of the input clock?


texts:
I want to use bluetooth to grab the info off my 3pi rather then have it display on the small LCD.
Pololu provides a lib for serial communication.

I'm wondering what the best bluetooth/serial module to use is?

A friend recommended the Xbee module - Any thoughts?


texts:
I am building a type of telegraph with my Arduino and instead of using Morse code I am taking each character and giving it a value of 1-26 (a-z), 27 for a space and 28 for unknown. Then I convert that number to binary. But I keep getting errors. Could someone please help me? Thanks!

int button_0 = 13;
int button_1 = 12;

int out_0 = 11;
int out_1 = 10;

int in_0 = 9;
int in_1 = 8;

int buzzer = 7;

void setup() {

  pinMode(button_0, INPUT);
  pinMode(button_1, INPUT);

  pinMode(out_0, OUTPUT);
  pinMode(out_1, OUTPUT);

  pinMode(in_0, OUTPUT);
  pinMode(in_1, OUTPUT);

  pinMode(buzzer, OUTPUT);

  Serial.begin(9600);

}

void loop() {

  Serial.println("Message to binary: ");
  String input = "Hello World";
  String message = input.toLowerCase();
  String binaryNumber = "";

  for(int i = 0; i <= message.length(); i++) {

    char l = message.charAt(i);
    int letter = 0;

    if (l == 'a') {

      letter = 1;

    }
    else if (l == 'b') {

      letter = 2;

    }
    else if (l == 'c') {

      letter = 3;

    }
    else if (l == 'd') {

      letter = 4;

    }
    else if (l == 'e') {

      letter = 5;

    }
    else if (l == 'f') {

      letter = 6;

    }
    else if (l == 'g') {

      letter = 7;

    }
    else if (l == 'h') {

      letter = 8;

    }
    else if (l == 'i') {

      letter = 9;

    }
    else if (l == 'j') {

      letter = 10;

    }
    else if (l == 'k') {

      letter = 11;

    }
    else if (l == 'l') {

      letter = 12;

    }
    else if (l == 'o') {

      letter = 13;

    }
    else if (l == 'm') {

      letter = 14;

    }
    else if (l == 'n') {

      letter = 15;

    }
    else if (l == 'p') {

      letter = 16;

    }
    else if (l == 'q') {

      letter = 17;

    }
    else if (l == 'r') {

      letter = 18;

    }
    else if (l == 's') {

      letter = 19;

    }
    else if (l == 't') {

      letter = 20;

    }
    else if (l == 'u') {

      letter = 21;

    }
    else if (l == 'v') {

      letter = 22;

    }
    else if (l == 'w') {

      letter = 23;

    }

    else if (l == 'x') {

      letter = 24;

    }
    else if (l == 'y') {

      letter = 25;

    }
    else if (l == 'z') {

      letter = 26;

    }
    else if (l == ' ') {

      letter = 27;

    }
    else {

      letter = 28;

    }

    binaryNumber = binaryNumber + String(letter, BIN) + " ";

  }

  Serial.println("Message to binary:\n"+binaryNumber);

}

Here is my error:

binary_telegraph.cpp: In function ‘void loop()’:
binary_telegraph.cpp:37:38: error: conversion from ‘void’ to non-scalar type ‘String’ requested


texts: Need help understanding oscillator circuit

texts:
simulate this circuit – Schematic created using CircuitLab

Does anyone know what type of oscillator is this and how this works?


texts:
Here I have built the following schematic but have encountered some problems. The treble was crackling and the bass was dropping out. I have somewhat fixed the treble issue with grounding the pots but I still have an issue with them. I think what has happened the heat from the soldering iron has damaged them. I was very quick in soldering but I think it's just cheap potentiometers. I can't seem to find these value potentiometers dual gang linear 1M and 500k.

There is a 50 Hz hum present with the tone control circuit wired in my valve amp.
My question is what is causing these problems (mainly the hum) and how do I resolve it?
Also what would happen if I changed the bass and treble potentiometer form 1M/500k potentiometers to 100k/250k potentiometer would I loose the bass and treble adjust range or would it have no effect?

UPDATE

Here I found this tone control circuit on the internet. It looks like to me it would be better than the other circuit. As there is no DC on the potentiometers that caused the previous problem with my last circuit but can anyone tell me if I should go ahead with this one? is there any improvements I can make?


texts:
Thank you for reading this question and forgive me if I sound naive.

I am working with a device that uses 4-20mA as set-point, I need 3 fixed values to work with this device:
(4mA, 12mA, 20mA)
The only output source I have left in my system to drive that are 24VDC outputs.
The simplest way I could imagine was to use a resistor for each line to provide the appropriate current.
6kOhm for 4mA, 2KOhm for 12mA, and 1.2KOhm for 4mA. which works fine as long as you have precise resistors and fixed voltage.

I have changed the resistors to Trimpot (10k, 500mW) to make my life easier in terms of finding the right resistance, and it works fine as long as the voltage is stable. However, I would like to know if there are any other solutions that are more elegant and/or can provide more robustness to this design.

Edited: I have at least 30 digital outputs (24VDC) that should drive 30 fixed set-points. and that is the challenge to keep it as simple as possible.

I have looked at LT3092, looks decent LT3092 datasheet, but I'm not sure if it right for me. I like to know what you think.

Regards,
Pat


texts:
I am trying to figure out some online resource to figure out how to configure the GPIO Registers on an STM32F4 Cortex M4 board. I only have examples for the Cortex M4

typedef struct
 {
   __IO uint32_t MODER;    /*!< GPIO port mode register,               Address offset: 0x00      */
   __IO uint32_t OTYPER;   /*!< GPIO port output type register,        Address offset: 0x04      */
   __IO uint32_t OSPEEDR;  /*!< GPIO port output speed register,       Address offset: 0x08      */
   __IO uint32_t PUPDR;    /*!< GPIO port pull-up/pull-down register,  Address offset: 0x0C      */
   __IO uint32_t IDR;      /*!< GPIO port input data register,         Address offset: 0x10      */
   __IO uint32_t ODR;      /*!< GPIO port output data register,        Address offset: 0x14      */
   __IO uint16_t BSRRL;    /*!< GPIO port bit set/reset low register,  Address offset: 0x18      */
   __IO uint16_t BSRRH;    /*!< GPIO port bit set/reset high register, Address offset: 0x1A      */
   __IO uint32_t LCKR;     /*!< GPIO port configuration lock register, Address offset: 0x1C      */
   __IO uint32_t AFR[2];   /*!< GPIO alternate function registers,     Address offset: 0x24-0x28 */
 } GPIO_TypeDef;

Here are the registers. But there is nothing online that shows me how to actually configure a pin to say output/input etc. Can someone point me a resource?


texts: But, the answer is different. Given \$i=-8A\$ and \$v_0=48V\$. Can't understand where is my mistake. Please help.


texts:
I have this Triac which I believe is failed because of a hight current we had in the house. The varistors that were next to it were totally burned.

I am trying to buy some online, but I really don't know how to narrow the specifications.

How do I read its specification?

Here is what you see in the picture.

BTA06-600CW
GK072  VU
CHN  233

Thank you


texts: In ac supply positive cycle is equal to negative cycle then given voltage is taken and fed back to mains then why we pay electricity bills?


texts: Am I right about measuring current, and power

texts:
I have a meter that can measure: current, active power, reactive power and complex power.

simulate this circuit – Schematic created using CircuitLab

So, when I measure the four things: current, active power, reactive power and complex power. Will they be described by the following formula's?:

Current:
$$I=\frac{\hat{V}}{\sqrt{2}\cdot\left|Z_{in}\right|}$$
Real power:
$$P=UI\cos\varphi=\frac{\hat{V}}{\sqrt{2}}\cdot\frac{\hat{V}}{\sqrt{2}\cdot\left|Z_{in}\right|}\cdot\cos\varphi=\frac{\hat{V}^2}{2}\cdot\frac{1}{\left|Z_{in}\right|}\cdot\cos\varphi$$
Reactive power:
$$Q=UI\sin\varphi=\frac{\hat{V}}{\sqrt{2}}\cdot\frac{\hat{V}}{\sqrt{2}\cdot\left|Z_{in}\right|}\cdot\sin\varphi=\frac{\hat{V}^2}{2}\cdot\frac{1}{\left|Z_{in}\right|}\cdot\sin\varphi$$
Complex power:
$$S=UI=\sqrt{P^2+Q^2}$$
Power factor:
$$\varphi=\left|\arg\left(V\right)-\arg\left(I\right)\right|=\left|\arg\left(V\right)-\arg\left(\frac{V}{\text{Z}_{in}}\right)\right|=$$
$$\left|\arg\left(V\right)-\left(\arg\left(V\right)-\arg\left(\text{Z}_{in}\right)\right)\right|=\left|\arg\left(Z_{in}\right)\right|$$


texts: How can I get more amps from a voltage regulator?

texts:
I'm a noob that is just getting started.

I'm using an LM317T to generate 6V but I need a little more amperage.  Can I just double my LM317T and resistors configuration and put them in parallel?

simulate this circuit – Schematic created using CircuitLab

Ignore the resistor.


texts: Performing loadflow on islanded microgrid

texts: I am working with a grid connected microgrid model for analysis. the microgrid has residential load, PV and Energy storage system. Now I am able to perform load flow when I have grid connection by making the grid as swing bus. I am not sure how to perform load flow with islanding option. Anyone have some thoughts?


texts: Op-amp: Virtual ground principle and other doubts

texts:
I can't understand some stuff about op-amps. Here is my list of doubts:

If an op-amp amplify the difference between the V+ and the V-, how can it work if for the principle of virtual ground V+ = V-, and so if V+ = V- there aren't difference to amplify.
Considering this circuit as the ideal one of the op-amp, why V+ = V- ? Why does the principle of virtual ground exist? Why is the voltage on V+ is equal to the one in V- ?

Is correct to say that all the Vin applied on this equivalent circuit will fall on the Ri?
Take a look at this circuit, my teacher says that I1 is equal to I2, but I can't understand why:

If the two resistor have respectively a knot to mass, the only condition when I1 = I2 is when Vin = Vo and when R1 = R2
The I1 and the I2 that will go to the point of the virtual ground (the point marked on this photo), where will they go at the end? Will they go to the physical ground?


texts: Camera LED in phones - PWM or analog current controlled?

texts: The LED illuminator/flash that is used on cellphones with cameras is also controlled by flashlight apps. Is the light level controlled by pulse width modulation or is it analog current controlled? In other words, does reducing the illumination also reduce battery drain?