texts: Why some electrolytic capacitors have a bigger distance between their two legs?

texts:
SE fellas

Today I was thinking about electrolytic capacitors. it's a question to me Why some electrolytic capacitors have(or manufacturers make) a bigger distance between their two legs? I'm talking about this:

While other is like this:

I doubt if it would have relation to electrolytic capacitors production line. I guess there is a specific reason for an EE.


texts: What would happen if I used a potentiometer to produce a 5V DC signal for an Arduino from a 9V battery?

texts:
What makes the potentiometer not a good component to use for reducing the 9V to 5V DC for an Arduino?
I thought of using it but I been told it is not a good idea, so I am looking into the reasons why.


texts: Trying to identify a connector for a multi-USB charger

texts:
I've lost a cable for a multi-USB charger. The port looks like:

I'm looking for a replacement 110V/1.5A cable but not sure how to describe the connector. Any suggestions?


texts: Volatile capacitance values at low frequencies

texts: When I measure the capacitance of two cables I get very volatile values if I go to lower frequencies like 500 Hz. The capacitance is about 50 nF. Why does this happen?


texts: What PCB Plating do I need to use Exposed Copper Pads with Pogo Pins?

texts:
I am designing a PCB that will have some Mill-Max pogo pins make direct contact with exposed copper pads on the PCB. This will have many connects and disconnects, think hundreds to thousands.

I know that it needs to be at least gold coated in order for this to be resistant to corrosion, but does that mean ENIG plating is enough? Or do I need selective hard gold plating?


texts: How to prevent or detect counterfeit parts from distributors and manufacturers?

texts:
I am brand new to EE/ECE. My understanding is that, with distributors, you do pay a premium on the parts you order from them, but bundled with that premium is some kind of protection against counterfeit/non-functional parts. Whereas, with the manufacturers, you get what you pay for, and sometimes that means counterfeit or only semi-functional parts.

As a noob, this piques my interest in several ways:

What types of testing/QC do distributors do for you? Do distributors offer refunds or "we're sorry!"-type programs/services when they sell you bad parts, that manufacturers typically don't offer?
Are there any online consumer reports comparing/contrasting reviews for distributors and manufacturers? Sure would be nice to get 3rd party testimonials before I start working with a manufacturer/distributor...
What sort of recourse does one have if parts are found to be counterfeit or only semi-functional after some initial assembly/integration with other parts has already taken place?


texts: Resistors and capacitors calculation for 555 timer circuit

texts:
I am new to electronics and I want to try an experiment.

I want to use a 555 timer to create an automatic food dispenser  for my aquarium (something like opening a small door when the timer has elapsed) and I need some help in timing here.

To have a configurable amount of time (lets say 6 hrs, 12 hrs or 24 hrs), I understand that I need to modify resistors and capacitors accordingly.

Can you please let me know if there is any standard formula or tool for calculating the resistance value required for my resistors and the capacitance value required for my capacitors in my experiment.

Note: If I am completely wrong with my approach, please let me know a better way for creating an automatic timer. I am completely new to electronics and just got this basic info over the net.


texts: Can 66% DC 5V PWM signal damage 3V rated components

texts:
Hopefully a simple question here, but I have a 3V motor that I was hoping to control with a 5V PWM, which got me to thinking more about how PWM averages out a signal to give a lower voltage, essentially. My specific question is this:
Even though, say, a 50% duty cycle 5V PWM signal looks like devices to be 2.5V, can that 5V signal still damage motors, LEDs, etc since its max amplitude is still 5V and could be out of the operating range of, say, 3.3V powered motors? Or perhaps due to how the power is utilized by such devices, the motors cannot tell if the source is a 100% DC 3.3V or a 66% DC 5V signal? I would imagine damage could occur, but I have not found confirmation yet and am curious if we need to worry about this sort of things when powering motors.


texts: How to connect two power sources to a switch?

texts: I want to operate LED lights using either batteries or an AC/DC adapter wall plug. I have a SPDT switch but I’m not sure how to connect the two power sources to the switch. I might be using the wrong switch, if so what switch do you suggest? The main thing is that the AC power source is never connected to the battery and to have a choice by either operating the led lights by battery or AC/DC wall plug.


texts:
I have an issue with a noisy VR-sensor signal that my MAX9926 IC isn’t managing to interpret correctly, and instead outputs rubbish. The wheel that’s being used has one long tooth and one short.

Here is the circuit.  VR1 is the channel used in this case.

Here is a trace made today with my oscilloscope.
Yellow is the VR sensor. Green the output of the MAX9926.
The red dots are the actual edges on the encoder wheel that’s supposed to be picked up.
Blue lines are gaps between the teeth.

As seen in this, more zoomed in scope, the noise is limited to about maximum 200mV.

I have tried to reduce the R4 to 1Kohm, in an attempt to "load down" the VR-sensor and rid some of the noise. Didn't have any affect at all.

I reach out to you to help me with suggestions on the circuit to filter out the noise or configure the MAX9926 in a better way to handle the signal. Thanks in advance.

Update 2020-03-10:
I have added a 400 ohm resistor in parallel with C8 in an attempt to pull the voltage so low, that the MAX9926 doesn't react on it. It kind of worked. But as you can see, the square wave is time shifted from the VR very randomly. And the actual teeth are not translated into square wave.

Here I have made an illustration in RED, as what the actual teeth on the wheel look like, in relation to the YELLOW VR-sensor signal:


texts: Speed control using VFD of three phase motor

texts: what happens to Torque, HP, current and voltage when we increase Speed of three phase induction motor using a VFD?


texts: Measuring voltage with different voltmeters in parallel - influences?

texts:
Let's say we're measuring voltage of a battery with three different voltmeters in parallel, as is shown in the picture:

Would those voltmeters influence each other because of their finite internal resistances?
I'm thinking that, since they're all in parallel, it won't matter how big their internal resistances are, and thus, won't influence each other in therms of that. The reading of each individual voltmeter will only be influenced by themselves (their internal resistances, accuracy, etc).


texts:
I am looking for a small, inexpensive NPN transistor, similar to 2N4401 in specs, with a BEC or CEB pinout.

Does anyone know of any?


texts: Calling a function that uses HW_Delay inside timer interrupt

texts:
I have the following timer interrupt configuration

static void MX_TIM6_Init(void)
{

  /* USER CODE BEGIN TIM6_Init 0 */

  /* USER CODE END TIM6_Init 0 */

  TIM_MasterConfigTypeDef sMasterConfig = {0};

  /* USER CODE BEGIN TIM6_Init 1 */

  /* USER CODE END TIM6_Init 1 */
  htim6.Instance = TIM6;
  htim6.Init.Prescaler = 1080;
  htim6.Init.CounterMode = TIM_COUNTERMODE_UP;
  htim6.Init.Period = 10000;
  htim6.Init.AutoReloadPreload = TIM_AUTORELOAD_PRELOAD_DISABLE;
  if (HAL_TIM_Base_Init(&htim6) != HAL_OK)
  {
    _Error_Handler(__FILE__, __LINE__);
  }
  sMasterConfig.MasterOutputTrigger = TIM_TRGO_RESET;
  sMasterConfig.MasterSlaveMode = TIM_MASTERSLAVEMODE_DISABLE;
  if (HAL_TIMEx_MasterConfigSynchronization(&htim6, &sMasterConfig) != HAL_OK)
  {
    _Error_Handler(__FILE__, __LINE__);
  }
  /* USER CODE BEGIN TIM6_Init 2 */

  /* USER CODE END TIM6_Init 2 */
}

I need to process a web server at the background of the application and a web client in the foreground of the application.

So I created a timer interrupt, but the problem that the calls to the wifi functions gets blocked.

I have tried to set the NVIC to highest priority and the timer to lowest one, but still it stucks there.

  HAL_NVIC_SetPriority(SysTick_IRQn, 0, 0);

  HAL_NVIC_SetPriority(TIM6_IRQn, 15,15); //Enable the peripheral IRQ

Here is the timer interrupt function:

void HAL_TIM_PeriodElapsedCallback(TIM_HandleTypeDef *htim)
{
  // This callback is automatically called by the HAL on the UEV event
  if (htim->Instance == TIM6)
  {
    processServer = true;
    if (WIFI_StartServer(0, WIFI_TCP_PROTOCOL, "TCP_SERVER", 80) != WIFI_STATUS_OK)
      return;

    HAL_Delay(10);

    WIFI_ReceiveData(0, resp, 1200, &respLen, WIFI_READ_TIMEOUT);

    if (respLen > 0)
    {
      char string0[20] = {0};
      float kwh = 1.1;
      if (strstr((char *)resp, "GET")) /* GET: put web page */
      {

        //  modbus_read_kwh(string0, &kwh);
        if (SendWebPage(string0) != WIFI_STATUS_OK)
        {
        }
      }
      if (SendWebPage(string0) != WIFI_STATUS_OK)
      {
      }
    }

    WIFI_StopServer(0);

    processServer = false;
  }
}

Here is the main loop after suggestion

  while (1)
  {

    uint8_t ip[4] = {8, 8, 8, 8};
    if (processServer)
    {
      if (WIFI_StartServer(0, WIFI_TCP_PROTOCOL, "TCP_SERVER", 80) != WIFI_STATUS_OK)
        return;
      WIFI_ReceiveData(0, resp, 1200, &respLen, WIFI_READ_TIMEOUT);

      if (respLen > 0)
      {
        char string0[20] = {0};
        float kwh = 1.1;
        if (strstr((char *)resp, "GET")) /* GET: put web page */
        {

          //  modbus_read_kwh(string0, &kwh);
          if (SendWebPage(string0) != WIFI_STATUS_OK)
          {
          }
        }
        if (SendWebPage(string0) != WIFI_STATUS_OK)
        {
        }
      }

      WIFI_StopServer(0);

      processServer = false;
    }
    else
    {
      WIFI_DNS_Lookup("ipdb-eu2.riddleandcode.com", ip);
      WIFI_OpenClientConnection(0, WIFI_TCP_PROTOCOL, "TCP_CLIENT", ip, 80, 0);
      uint32_t amnt_int = 0;
      //int r = get_balance_amount( end_pos + 11, &amnt_int);
      int r = get_balance_amount("CJL6QoHLS9vmWfk5zRi7qQc6WrEmp2Jh8UpgWMaxHctK", &amnt_int);
      char str[20];
      sprintf(str, "amount %d \r\n", amnt_int);
      // print our string
      SWO_PrintString(str);
      WIFI_CloseClientConnection(0);
    }
  }


texts: How FPGAs offer Deep pipeline parallelism ?

texts: While reading the PPT here (last slide), I found the statement that FPGAs have Deep pipeline parallelism. I have understood the meaning of Deep pipeline parallelism, but can someone explain how actually this is achieved in the FPGA (may be architecture or algorithm point of view)  ?


texts: How to find Rth for the Thevenin Equivalent Circuit?

texts:
So we were given this circuit to solve for I1, I2, I3, and lastly the Thevenin Equivalent Circuit. I was able to solve for I1, I2, I3. However I am having a hard time computing the RTH at ab.

Here is the circuit I was trying to use to find RTH.


texts: How are electric water heating elements isolated?

texts: From what I've seen and understood, electric water heating elements are usually copper tubes/pipes with electricity running through them to heat up the surrounding water. I'm not sure if the electricity directly goes through the tubes/pipes though. How do the heating elements make sure electricity only heats up the water and not run through the water, causing unwanted currents through the water instead?


texts: Creating a combination lock using logic gates?

texts:
I am trying to figure out how to create a combination lock using logic gates, so that a password must be input (let's say pressing numbered buttons) in the correct order.

I understand logic gates completely, and have some of a grasp on flip-flops and latches, but I'm definitely getting stuck on how to use them in the right combination.

So as an example, if there are 3 buttons (call them 1, 2, & 3), I would like to be able to set a password such as 1 2 3 1 (hardcoded is fine), where they have to be input in that exact order, otherwise you have to start at the beginning again (1 2 3 3 3 3 1 will not work).

Any tips, links, hints on this?


texts: Understanding PWM period and frequency calculation on dsPIC30F4013?

texts:
i am working on a project of my own, making a RC CAR. I want to my motor to be controlled with PWM. I understand the basics of basics for PWM but still I get confused with calculation. What is the connection between PRx and OCxR, OCxR register, what does PRx register value do to duty cycle.

I have a motor that works on a 5-9V and frequency of 5-10MHz. My dspic has 10MHz oscillator input with PLL4. In datasheet the formula for PWM period is:

TOSC = 1/FOSC = 1/40MHz = 0.025us

PRx = 0

PWMperiod = (PRx+1) * 4 * TOSC *(TMRprescale 1:1) = 0.1us => PWMfreq = 1/PWMperiod = 10MHz.

That is how i get 10MHz pwm frequency.

If PRx is set to 0 what will happen to the pwm signal?


texts: Operational amplifier bandwidth - why does manufacturer tell it's DC when it is not

texts:
I've been working with op amp datasheets lately and i noticed strange thing with RF amplifiers specifications.
I will provide one example, but there quit more of them with this manufacturer.

HMC625BLP5E
http://www.analog.com/media/en/technical-documentation/data-sheets/HMC625B.pdf

So the description says it's "VARIABLE GAIN AMPLIFIER, DC - 5 GHz"
But application schematic's show that DC blocking capacitor is required at the input of the amplifier

So my questions are:
1) Why would they say it's DC when it's effectively not.
2) What would happen if i would not put that capacitor on the input?


texts: sudden current dropping identifying circuit

texts:
Here is my scenario:
I have a pair of electrodes in my device and it is submerged in seawater, so there is a current.
Once I take it out the current drops and I want to implement a circuit to identify the sudden drop of the current.
The drop will not be same every time because sometime there is some algae and because of that even though I take it out some amount of current is still there.
I don't want to use a microcontroller here. I would like to have a circuit designed to do the exact same thing, and it should be designed the way as it is using a minimum amount of power.
I want to design a switch which will turn on when its take out from the seawater


texts:
Where can I find a basic block diagram with descriptions for a typical 10/100BASE-T PHY output driver stage?

I also wonder whether all drivers use "current-mode" outputs that lead to voltage across the external termination resistors (it seems so, because most of the time I see applications with termination resistors to VDD or GND) or are there devices that use voltage output? Why is current output the better choice? It it easier to steer current sources than voltage sources? (and therefore easier to create the different voltage levels)


texts: Simulation of a class E power oscillator using LTspice

texts:
My goal is to understand and design a class E power oscillator. To this end, I am trying simulate the following schematic using LTSpice. Circuit topology and the design values are extracted from the paper "from here" -

design specifications used in the paper are;
Pout =1W, Supply =4.5V, frequency 800kHz, RL=50ohm, QL=13, efficiency =90%
 Objective of this question is not to understand the paper, but to understand why my repeat simulations does not work - of course, I believe that the circuit should work fine with their values. But to make the question clearer, in this paper, the circuit is modeled using its equivalent impedance sections (assuming only the fundamental harmonic) and the component values are calculated by using class E design equations for 0.5 duty. Few things to note: In their analysis, the the gate-to-source impedance of the MOSFET, Zgs  was measured at 800 kHz and used for the analytical equations, and voltage divider is experimentally tuned to obtain 0.5 duty.

(differences from the original paper are 1. make R2 170k -> 150k because it was not producing the oscillation when R2=170k, 2. zener diode model was not given in the paper)

However, I the oscillation waveforms are follows. Which include Drain Voltage - V(D); Gate voltage - V(G), Voltage across RL - V(RL+) and supply current - I(V1)

What could be the reason for this oscillator not working as expected?
(It is expected to deliver approximately 1W power to RL, but here it is only few milliwatts)

Alternatively, can someone suggest any other reference (preferably open access) to design a class E power oscillator close tho the same design specs?


texts: Wired AND, OR gates and compatibility with TTL/CMOS fan-out?

texts:
When the AND gates run out, and I just need one more, I like to use a "wired" gate, simple resistor-diode logic. Here is AND

and here is OR

Now for the pull-up resistors, I use just 1 kΩ normally. But I am wondering about contention by current flowing back into the inputs. I know if the input has no fan-out, so, if A and B come out of their own gates and are not also routed to be input into another gate, then there is no problem.
I also know that normally one should do this with open-collector gates. But again, at 1 kΩ pull-up for the AND it's probably not going to hurt, I don't think.
But does it confuse other inputs parallel to A? Example, I'm using buffer symbols for whatever TTL devices I might use here, doesn't matter.

simulate this circuit – Schematic created using CircuitLab
The question is if G4's input is not by accident pulled high by this diode? Or is there a magic R1 value that might prevent this from happening? I know that 10 kΩ might be too much to even pull up the input of G3. But what about 2.2 kΩ?
Certainly this has to do with the specific device families. But are there common values considered safe for 74LS* and 74HC* respectively? And certainly pull-up for AND and pull-down for OR will have different sweet spots. I suppose the bigger the fan-out of the upstream outputs, the less it will matter.


texts: Is it legit to use DC source with voltage regulator to create dual power supply for op-amp?

texts: My op-amp needs +12V and -12V voltage supply. I have only one DC source which can output 24V (I can use simple voltage divider to get +12V). I also have one voltage regulator. Is my approach above correct?


texts: TVS diode protection on a capacitor bank?

texts:
I'm currently designing a variable frequency drive for powering an AC induction motor.

I've three 400V/680µF electrolytic caps for smoothing the 325V (nominal) DC bus.

Then the DC bus is chopped by the inverter and fed into the AC motor (which is a very inductive load, with a lot of dv/dt generated during switching).

My question is putting two TVS diodes at the end of the cap bank is useless or not? Can it provide somehow a "clamp" against these voltages spikes and protect the caps?

TD1 and TD2 are Littelfuse 1.5SMC510CA TVS diodes.

Thanks ;)


texts: How do I resize the toolbar and fonts in Proteus?

texts: The workspace is just fine but all of the toolbar have really small icons and fonts are also really small.


texts: Isolated DC/DC converter application circuit / usage

texts:
I'm trying to find a basic application circuit schematic for an isolated DC/DC converter – this one specifically: DCWN03E-12 – but I'm having no luck so far. The thing that led me to this particular product was searching for reasonably compact device that could do:

~5VDC Vin
±12VDC Vout
At least ~125mA per output

I plugged those parameters into a filter with a few other logistic requirements and that converter seemed the most bang for my buck. Seems its usual use case is in medical equipment; I have no need for the current isolation a medical device would call for, this just seemed to fit my spec perfectly.

The datasheet is sparse – I scoured it for details but the closest thing to an application circuit on there is a pinout diagram with the terminals labelled. I [foolishly] assumed this meant: hook your + and - up to 5V, get ±12V out plus a common ground. I can see this is likely not the case now because my multimeter reads a flat 0v on both outputs. Here's a basic schema of how it's hooked up:

simulate this circuit – Schematic created using CircuitLab

I had a sinking feeling that nothing could be so simple, and now I think that feeling was right. No inductor? Output capacitors? Or is there something I'm missing here? Another datasheet perhaps?


texts:
I have an XBee 24 module, and I want to program it. I have used the XCTU configuration software, but my XCTU does not have CE. How can I make my module the coordinator?
I am using an Arduino to connect my module to my laptop, but my module does not have R or C or E sign. It just shows ZB and I am also unable to update my devices firmware.
I appreciate any suggestions from the community.


texts: Must FreeRTOS task stack size account for interrupt stack size?

texts:
I have FreeRTOS running on a MKE06 Cortex-M0+ (based on SAMD20 demo), GCC toolchain. I am trying to figure out optimal task stack sizes (with the help of avstack.pl).

I want to use only static memory allocation.
In the FAQ I have read this:

  The stack requirements of interrupt service routines - which for many RTOS ports is zero as the RTOS will switch to use a dedicated interrupt stack on entry to an interrupt service routine.

I use this port. I don't know much assembly, but I think I do not see anything that would configure stack pointer separately for the interrupts (is such thing even supported by M0+?). I allocated stack for the idle task manually (with vApplicationGetIdleTaskMemory), but I did not find a function to provide stack space for interrupts. Interrupts work fine, I do not use nested interrupts.

My questions:

Should my task stack size be enlarged by at least the biggest possible interrupt stack size?
Can I allocate a separate interrupt stack on Cortex M0+ in plain C (ie. without adding own assembly to each ISR)?


texts:
Like so many else trying to charge a power bank from a solar panel:

I've got a solar panel claiming 18V and 280 mA, so 5W and a 2800 mAh power bank expecting USB in so 5V 1A. The simple "circuit" I've made is simply a 5V, 2.5A step-down voltage regulator connected to the power bank and the panel.

My problem is that the voltage drops to 0.8-1V when in direct sunlight and connected to the power bank. I don't know what charging circuit the bank has (a cheap super market bought one) has but it seems like it's trying to take as much as it can up to 1A and that brings the panel on its knees. The 1V I get is too low to make it charge.

Is there something I can put in between the panel and the bank to either limit the maximum current the bank gets or something charging up and letting out when it's enough to power the bank?

I know the regulator is completely over dimensioned but I had one at hand I assume it won't be the problem. I'm also hoping to get my hands on a more suitable charging IC and battery but before that I'd like to get this prototype working.

*edit:
What I know about the power bank is that it's got USB in and USB out. It says 3.7V and 2800 mAh so I guess it's a single cell li-ion in there. I don't know the tolerance of the bank, I've only got access to 5V and the panel. So I know it charges at 5V and doesn't at 1V. I'm getting a lab power supply this weekend so then I can figure that out.


texts: EVM430F6779 electric meter interface to serial terminal

texts:
I want to interface EVM430F6779 electric meter to serial terminal.

I have already interfaced with the GUI using rs232 to my computer and i am  getting the desired results

I then did some research on DL/T645 and i am able to communicate with meter for getting phase1, phase2 and phase3 readings through serial terminal.

STEP1: I open GUI and wait for the signal to turn green

STEP2: I colse GUI and open serial terminal, configure COM and baudrate and then i send the code for phase1,phase2 and phase3 readings

The problem i am facing is i am not able to communicate directly by opening the serial terminal. First i have to open GUI and once the signal is green i close GUI, open serial terminal and then communicate for meter readings.

If i bypass STEP1 and directly go to STEP2 i dont get any response from the meter. I guess there is some password set in the meter for enabling the communication and when i open GUI the password is sent by GUI and communication is triggered.

Do we really have any password? if yes please let me know the initial command that should be given to trigger communication.

If there is no password then how should i bypass step1?

My goal is to open serial terminal and start communication with the meter without any dependency of GUI.

Please solve my above problems. Thanks in advance.


texts:
I have revised this posting on the off chance that someone else in the future is interested in what I discovered.
TL;DR: I plannned to use an AX159060 wiper motor in an automotive project, but found that the "park" switch appears to be normally open, not the typical normally closed. The (AE)159300 motor is nearly identical to the AX159060 motor, but the park is of the typical normally closed style.
Background: I originally planned to use an AX159060 wiper motor in my project to modernize the windshield wipers on a 1970s Datsun. It appeared to be a convenient form factor, and was relatively common. However, in my testing, I found that the parking feature worked unusually and decided that a different motor would suit my needs better. The motor I decided to replace it with was an (AE)159300 whose internal switching is arranged better for my application. In my searching, I found a schematic for both the AX159060 and (AE)159300 motors which I have attached below for anyone interested.
https://www.youtube.com/watch?v=1Ww5-pmiokc
AX159060 used in 2008-2015 Cadillac CTS and 2007-2010 GM trucks. My motor followed the "W/O DENSO" path and never connected Pin 3 and Pin 5 under any circumstance.
Schematic: https://www.silveradosierra.com/electrical/2010-1500-windshield-wiper-motor-wiring-t239857.html

(AE)159300 used in 2006-2018 Toyota RAV4, 2008-2014 Subaru Impreza, and MANY more. Schematic Page 186: https://frankensteinmotorworks.com/2GRFE/diagrams/Toyota%20RAV4%20Electrical%20Wiring%20Diagrams%20%28EWD%29.pdf

These two wiper motors appear to share a common manufacturer, however I have no proof of this. My hunch is that Toyota makes these motors and then sells them to other companies with unique part numbers according to the application.
I find the Toyota wiper motor to be a convenient form factor, and seems like an ideal choice for design projects or to upgrade from a NLA part.


texts: Sensors for detecting heavy metals in indoor dust

texts:
Does anyone know about a kind of sensors (or how to construct) that could be used together with ex an Arduino or other microprocessor to measure the amount of heavy metals (like lead for example) in indoor dust particles.

The goal of the project is to create a device capable of detecting and logging data about harmful heavy metals in indoor environments.


texts: Tri-state output to three analogue levels?

texts:
Is there a circuit which can transform a tri-state (low, high-Z, high) output to three voltage levels?

Ideally, the circuit will use only passives and diodes.

Would a simple voltage divider across the pin do the job?

             Vdd
              |
              R
              |
tri-state-----+-------out
              |
              R
              |
             Vss


texts: Verilog simulator or development environment on Mac OS

texts: Is there a way to develop some Verilog designs on mac?


texts: Suppress Specific IP Warnings in Modelsim

texts:
A Vivado IP is generating an inordinate amount of Modelsim warnings which are making it difficult to assess the simulation for warnings I actually care about.

I see from the Modelsim command documentation that in order to suppress a warning I need to include the parameter -suppress and then the warning numbers. My current implementation is as follows...

vsim -voptargs=+acc \
-L work \
-L xil_defaultlib \
-L secureip \
-L simprims_ver \
-L unifast_ver \
-L unimacro_ver \
-L unisims_ver \
-L xpm \
-L fifo_generator_v13_1_1 \
-L blk_mem_gen_v8_3_3 \
work.blr_tb xil_defaultlib.glbl -l sv_sim.log -suppress 3015,3017,3722

This code snippet works but I am afraid that this will suppress warnings that are created by problems with my own rtl. Is there a way of suppressing specific warnings of an IP?

For reference the warnings are all from the Vivado MIG IP and look something like this...

# ** Warning: (vsim-3017) ../../ip/xc7k160t2ffg676-2/mig_ddr3_64bit_32G/mig_ddr3_64bit_32G/user_design/rtl/phy/mig_7series_v4_0_ddr_mc_phy_wrapper.v(1260): [TFMPC] - Too few port connections. Expected 9, found 8.
#    Time: 0 fs  Iteration: 0  Instance: /blr_tb/blr_sbk_top_i/ddr3_balor_i/u_mig_ddr3_64bit_32G/u_mig_ddr3_64bit_32G_mig/u_memc_ui_top_std/mem_intfc0/ddr_phy_top0/u_ddr_mc_phy_wrapper/gen_dqs_iobuf_HP/gen_dqs_iobuf[0]/gen_dqs_diff/u_iobuf_dqs File: C:/Xilinx/Vivado/2016.2/data/verilog/src/unisims/IOBUFDS_DIFF_OUT_DCIEN.v

The MIG is compiled with the following command...

vlog  -work xil_defaultlib -incr \
"$SBK_IP_DIR/mig_ddr3_64bit_32G/mig_ddr3_64bit_32G/user_design/rtl/mig_ddr3_64bit_32G.v" \
"$SBK_IP_DIR/mig_ddr3_64bit_32G/mig_ddr3_64bit_32G/user_design/rtl/mig_ddr3_64bit_32G_mig_sim.v" \
"$SBK_IP_DIR/mig_ddr3_64bit_32G/mig_ddr3_64bit_32G/user_design/rtl/clocking/*.v" \
"$SBK_IP_DIR/mig_ddr3_64bit_32G/mig_ddr3_64bit_32G/user_design/rtl/controller/*.v" \
"$SBK_IP_DIR/mig_ddr3_64bit_32G/mig_ddr3_64bit_32G/user_design/rtl/ecc/*.v" \
"$SBK_IP_DIR/mig_ddr3_64bit_32G/mig_ddr3_64bit_32G/user_design/rtl/ip_top/*.v" \
"$SBK_IP_DIR/mig_ddr3_64bit_32G/mig_ddr3_64bit_32G/user_design/rtl/phy/*.v" \
"$SBK_IP_DIR/mig_ddr3_64bit_32G/mig_ddr3_64bit_32G/user_design/rtl/ui/*.v"


texts:
I am designing a PCB that will have a wireless RF IC on it. It uses the NRF24L01+ (datasheet) and an RF Front End RFX2401C (datasheet).
I know that the PCB layout is very important for RF applications, so I tried to look up and follow as many rules as I could. I am limited by my design constraints to a two-layer, 1.6mm, standard FR-4 board. This is also a low-cost design.
Here is a list of the rules that I found online and tried to apply to my design.

Ground Planes
ALOT of vias (though I would like an explanation of why)
Small 0402 component parts
Shortest possible trance length
No Ground Plane under the antenna to avoid signal reflections

Is there anything that I am missing or that I got wrong?
Here is the schematic that I have created.

And the following board layout:


texts:
I have a diagram that I've recreated from a PCB by studying it's trace routing and what components are in use. Limited to what was listed on the components themselves, I believe I have gotten most of the diagram correct (to a degree). The trouble I am having is how the logic of this circuit works in general.
It's takes Composite Video in on I7, and pipes that back out on O7 for normal use, but the PCB also has RCA out that goes through this circuit. There's some extra circuits also in use for audio however this is a simple high pass filter that I've figured out already.
I've done some research on how transistors work, and while I under stand that and it's general flow, the diagram is still confusing my brain when it comes to the signal's routing. Any thoughts?

edit to be confirmed by OP
Diagram re drawn based on what seems to be symmetry.

simulate this circuit – Schematic created using CircuitLab


texts: State Model Representation of RLC network

texts:
I am confused with the above problem. Should I take a new state variable for rightmost capacitor or 3 variables are sufficient?

Please help me in writing the state space equations.


texts: Using a microwave oven transformer as ballast by shorting the secondary

texts:
I am self learning electricity and have some basic understanding of RLC circuits.

I came across 2 separate articles (here or here) describing playing around with microwave oven transformers (MOT) which are basically high power step up transformers. What I am interested in is not about getting a high voltage electric arc. Instead, both articles describe some similar techniques in limiting the current to the MOT. Both involve having a second MOT with the secondary shorted together and connect it in series with either the secondary or primary of the first MOT:

First method connect a second shorted MOT in series with in the primary

Second method either use a resistance in series with the primary or another shorted MOT in series with the secondary.

I understand that, in both cases, the second MOT is just an inductive load.  But what puzzle me is why short the secondary in both cases? Isn't that by shorting the secondary, we are drawing unlimited current and will blow up the fuse instead of limiting the current?


texts:
I am working on a project that requires a 5 pin connector but it seems like the USB cable is causing some issues. I am using a microUSB B male-male cord to transfer some power and data. Through further research, I am seeing that Micro USB B may be more complex than a simple 5 wire cord. I found the following quote online:

"Contrary to popular belief, D+ and D- operate together; they are not separate simplex connections."

http://pinouts.ru/PortableDevices/micro_usb_pinout.shtml

What does this mean? Is there a way I can use this cable as 5 separate lines?


texts:
(Edited text 15:53--05/1-2017)

I got these two steppers for my home project, and thought that I just needed a H-bridge and then I am good, until I found that either I am misunderstanding these ratings, or I have a special stepping engine.
Stepper It has data 3.3V and 3A. and it is a 4 wired Bipolar

The idea was to have an arduino with 4 sensors that would make a "scan" every 1 or 2. hour. Then the arduino shuld tell 1 step motor to turn left/right and another motor to go up/down, so the sun panels would get most out of the sun.

So, looked at WWW to get some ideas on what chip to use, and most recommended the L293D and then i got stuck. then i wrote a post in here and now im super confused hehe.. (so i edited this text to clarify my thoughts and what is my end goal, and how)

I have a 12V battery as a supply! But I just step that down.

The L293D, or SN754410, require 5V or more, or have less then 3A current. (the steppers was 3.3V 3A)

Q.
Am I misunderstanding something, or am I just blind?

Q. Can any help me design a schematic for my own bridge for driving 2 steppers, if there really ain't any out there in the world?

A. I wont just buy one of them already done prints (example). I just need the chip, or help designing my own bridge, that can drive 2 steppers 3.3V 3A


texts: Is it safe to parallel wall-wart inputs via a single cable?

texts:
I have 4 identical devices each with their own low amperage wall wart, and I want to tidy up my power cabling. (They are more like laptop power supplies than wall warts, as they have an AC cable, instead of just a wall plug.)

I'm not any kind of expert on electricity, but I started thinking about power bars, and assume they must connect things in parallel.  This made me think I might be able to cut the all the AC leads off the wall warts and join them together, to create one plugin source feed to all 4.

Is this dangerous, or is it as simple as it sounds? They are grounded, so I would be joining the grounds together as well.


texts: Spatial multiplexing MIMO, antenna critical spacing, antenna isolation

texts: How does antenna isolation affect single user spatial multiplexing MIMO performance? Text books talk about a critical antenna spacing in a rich scattering environment of 1/2 of the wavelength. Would that be the sole criterion? or would the antenna-antenna  isolation rather be the criterion to observe?


texts: What do the 47k resistors and 10k resistors do in this circuit?

texts: I found this here: Multiple buttons connected to reset pin which is what I want to do but it doesn't really explain how it works. I copied it to a simulator to try and understand it but even after removing/changing some resistors I'm failing to see why they are there and why it works the same without them. I understand the top right of the circuit and how that resets but the diodes and 47k resistors don't fully make sense. I was also able to remove the middle 10k and the circuit worked so is that needed too?


texts: LM324 - Issue with output in negative feedback

texts:
In my analogue output circuit, the following ripple voltage occurs when wired to the analogue input of a PLC with an input resistance of 69.3 kΩ.

If I put a resistor in series, this ripple disappears.

Why is that? Is it an impedance problem?

The schematic of the circuit is the next:


texts: I was just giving my mother's mobile for repair at my local store and saw the owner stocking parts for them. I saw him stocking cheap (I mean really cheap) LCD (coloured and black & white). I was wondering where I can learn to use them in my circuits.


texts:
I am working on building a battery pack for a solar car. I need to know if there is a device on the market that will "profile" the batteries (lifepo4) that I have, so that I can put like batteries together in a pack.

What would a device like this be called?

Just as a note, I am not looking for sales links, or which is the best, but I just want to know what to search for.


texts: A high power RF amplifier design using an RFMD IC RF6886

texts:
I am designing a high power RF amplifier using an RFMD IC, RF6886. This IC's operating frequency range is 100MHz-1000HMz. I am designing it for a frequency of 145MHz. I received a document from RFMD which contains the evaluation schematic for this IC within the frequency range of 135MHz-175MHz.

In this schematic, the RF components post the IC consist of 3 capacitors in parallel, then an inductor in series followed by 2 capacitors in parallel, another inductor in series, again 2 capacitors in parallel and finally a capacitor in series.

What is the significance of these lumped components? As far as I know, they together form a matching circuit for the IC, matching it's impedance to 50ohms. How exactly does this happen though? What variations in the values of the above components should I perform to match the impedance and in what manner? Is there some kind of standard method for matching using which I can meaningfully vary the values?


texts: Unknown indicator of package specification

texts:
I am creating the footprint of an IC, and the manufacturer has specified this below:

I cannot figure out what C0.3 stands for. Is it the length of the diagonal? If it helps, according to another drawing for this rectangular pad, X=1.55mm and Y=1.40mm


texts: Capacitor connected directly with battery

texts:
This may be a dumb/begginer question, but I'm having trouble to understand what exactly happens when we connect a real capacitor directly with a battery.

In my understanding, theoretically, when an uncharged capacitor is connected directly to a battery of, let's say, 9 volts, instantly the capacitor will be charged and its voltage will also become 9V. This will happen because there is no resistance between the capacitor and the battery, so the variation of current by time will be infinite. Obviously, this is true when talking about ideal components and non-realistic circuits.

I thought that doing it in real life would cause sparks, damaged components, explosions, or whatever. However, I saw some videos and people usually do connect batteries directly with capacitors. Also, the current that flows from the battery to the capacitor is somehow of low magnitude, since it takes some considerable time to make the capacitor have the same voltage as the battery.

I would like to know why this happens, thanks.

This is an example of the circuit I talked about:


texts:
I'm using two 1K potentiometers and I want to achieve this result:
When the first pot is set to 1K (100%), adjusting the second pot should change the output from 0 to 1Kohms.
When the first pot is set to 500 ohms (50%), adjusting the second pot should change the output from 0 to 500ohms.
I have wired the potentiometer like this schematic. but the lower range changes too. for example when I set the first pot to 120 ohms, turning the second pot changes the output to Arduino from 60 to 120 when I want it to be 0 to 120.

I want the output to be linear. How can I approach this problem?


texts: Altium error message: Net(s) Not Found in Differential Pair

texts:
When I try to validate changes from my project, I get this error message:

  Net(s) Not Found in Differential Pair PA_D : Positive Net [PA_D_P] & Negative Net [PA_D_N] in current PCB document


texts: Is it OK to inject voltage to an unpowered LDO output?

texts:
I'm designing for the first time a PCB that can be powered from an external +12V supply or from the USB connector.

In the input of the board, just after the power connector (VINLDO net is the +12V power input), I've placed two LDOs in series. The first provides regulated +5V and the other +3.3V as the schematics shows:

When VBUS = +5V and there's no voltage in VINLDO net could I damage the U5 (MCP1703AT-5002E/MB) voltage regulator, since I'm "feeding" a +5V signal into its output?


texts: What to consider when choosing a crystal

texts:
I'm working on a Datalogger project power by a battery that needs to take sensor measurements and broadcast the parameters to a server.
The power source to the CPU is 3.3Vcc from the battery.
The communication baud rate with sensors and the cellular modem is 19200 9600 and 1200 (SDI12),
my dilemma is in choosing the crystal for the ATmega1280 (datasheet link).
I'm debating between 8MHz and 4MHz.

I'm also using the Brown-out to protect the EEPROM and Flash from low battery conditions
The 110 line is for 4MHz and the 101 line is for 8MHz.

I'm using CodeWizardAVR for the UART configurations and these are the result for both crystals:
8MHz:
, ,
4MHz:
, ,
The system has no real-time requirement.
What should be my considerations in choosing the right crystal?
I understand that in crystal 4 the BOD level is lower so I can use the battery for longer.
But are there any other things I need to consider?


texts: Connectorless MicroUSB or miniUSB on PCB: Feasible?

texts:
This question extends upon "Connectorless USB on a PCB". Our requirements are for a smaller connector than standard USB, and also 5 leads instead of USB 1.0's 4.  The connector will be used perhaps twice in the lifetime of the board, for ICSP / JTAG  programming / firmware updates. The product is a low-cost throwaway device somewhat like the DigiSpark.

Edit: Also, the connector will be inaccessible without breaking open the enclosure, so it is production-access-only. If end-customers break open a $5 toy, well, they have earned the right to destroy or reprogram it!

Cost and added height of adding a connector of some sort, such as a microUSB socket is highly undesirable.

We would like to do our programming / update using a standard USB to MicroUSB cable such as is shipped with many modern smartphones, plugged into a configuration & testing board (not an actual USB port).

Edit: [28-Oct-2012]

It turns out that microUSB is not viable, if only because of the thin PCB required.
USB 1.1 / 2.0 are not viable due to having only 4 contacts on the USB-A end: Thanks @DaveTweed!
Top 5 contacts of USB 3.0 Type B cable (image) appear PCB friendly, so question remains open

The questions:

Has anyone had success using such a connector etched onto a PCB? Could you share a link please?
What thickness of PCB would we have to go into production with, for such a connector to work?
Is there any available reliable footprint we could use for such a connector?
What else would we need to keep in mind - such as board cutting/milling tolerances, stiffness of PCB, rounding of "connector" corners, ...

SOLUTION: Added here for reference.

The solution that worked out best for us was a 3M SOIC narrow test clip, which has 7 contacts to a side, and a conventional IDC 0.1" cable going back to our programming board.

No additional milling is required, half of a standard SOIC pad footprint close to the edge of the board, with solder bumps on the pads, works out perfectly, and the clip grips the board firmly. Varying PCB thicknesses have been tested, they all work fine.

A bit of a convenience hack we added: Positioning two of the nearby components equidistant from either edge of the SOIC "programming pad footprint" ensures that the clip can be attached very quickly and perfectly aligned to the pads.

In laying out the programming pad pins, we ensured that a misalignment of the clip would not cause any problems either due to shorts or problematic signal injection. Needing only 5 of the 7 pads simplified this reshuffle.

Hopefully this solution would help others with similar requirements.

An observation: Pogo pins suitable for 0.05" spacing worked out way too expensive compared to the SOIC test clip approach.


texts:
I have a stereo VU meter. (Audio in on Arduino pins A0 and A1 and GND to common GND also 32ohm resistors going to GND on A0 and A1 to simulate coming speakers)

Now my problem is software architecture makes each channel very sensitive to voltage changes (adapting to lower volume on each volume separately) so in turn when there is only single channel input I get fluctuations (about the same) on each channel. So, how do I isolate the two analog inputs on Arduino?

Edit: software proves, if AREF if 5V then we are measuring about 0.01V for one step on a ten step VU meter. That's why I blame very fine voltage changes in overall Vin to GND voltage for this effect I'm seeing.

schematic http://i.imgup.hu/3OqfH5.png

If I remove the 32ohm resistors going to GND, nothing changes. Should I provide Arduino code?


texts: Electromagnetic Repulsion Coil Calculations

texts:
We have a 3x3 mm circular thin plate, which is made of copper, aluminium similar materials and thickness of the plate is 1 mm i.e. a very light and small piece of metal.

To lift this plate about 2 mm (against gravity), how much current is required? Is there a mathematical formula? To investigate whether there is a realistic approach for our situation, we need the help of experienced people.

To help image the setup, see below (except, we'll use solid not a ring):


texts: microcontroller input protection with Schottky clipping diodes

texts:
I regularly see the use of Schottky diodes in order to protect microcontroller inputs from overvoltages (>5V). The Schottky diodes are connected to the 5V power supply (cathode) and the microcontroller input (anode).

I was wondering what happens when current flows through these diodes due to overvoltage? Where does this current flow into?
It probably flows into the power supply unit...but what happens there?
Isn't it so, in fact, that we are applying an overvoltage to the power supply output and that we expect the power supply to take care of it...?

Anyone with bad experiences with this solution?
Are there any better solutions?

(In fact, the ESD protection diodes in the microcontroller itself apply the same trick for short spikes...the spike current flows into the power supply...)


texts: Is it ideal to solder joins by placing the solder first on the component, and then having the soldering iron on top of it?

texts:
I know the proper way of soldering wires and other components on PCBs and breadboards is by first heating up the joint with the soldering iron and then feeding it solder.

However, the breadboards that my Electronics teacher is giving us at school are so small that I can't have the soldering iron and the solder both on the same joint, which makes it more difficult to make a good joint. Instead, would it work if I heated the joint I wanted to solder, and then place solder on that joint and then put the tip of the soldering iron on the solder.

Theoretically, that should make a good joint, although I just wanted some feedback before actually trying this next week at school, in case I make a big mess.


texts: How can I increase inductive spike voltage?

texts:
I would like to know how I can increase the maximum voltage of inductive spikes.
I’m investigating their use in electrolysis - the bigger the spike the better.  To create the spikes, I’m using an IRF840 MOSFET and a 40mH coil as in the circuit shown below.

As I understand it, the peak voltage of the spike will depend on the coil inductance and also di/dt which will I assume will be a function of how fast the FET shuts off.
My coil is fixed with an inductance of 40mH but I have six of them and yet, if I string them together to make an inductance of 240mH, the peak voltage remains roughly the same, maybe because the total resistance of the coils is now about 10ohms compared to 1.5ohms for a single coil.
So the other option would seem to be to encourage the FET to shut off faster and for that, based on another post in this forum, I thought one can use a ‘pull-down’ transistor as in the following diagram.

Are there any other circuit modifications I could make to increase di/dt, including perhaps a different FET for the job? At the moment the peak voltage is a bit over 220V and I'm hoping it can be made over twice that.


texts: Which symbol to use in my schematic for a supply signal which is also an output?

texts:
The following diagram shows a voltage regulator that gets two inputs (+-24V) and generates two outputs (+-15V). For this reason, I am representing the 15V signals as outputs, but I don't know if this is right or not.

Below, there is another regulator, which uses a 15V supply. Should I use an input sign, to keep the same logic as above, or in this way is right?

I study control and automation engineering, and so far I have a bit of difficulty to standardize my schematics, as it looks like every schematic I see is different from one another. Any thoughts on that are appreciated as well...


texts: How to connect GND between both sides of a signal transformer

texts:
I am doing a test board to learn more about ethernet, differential pairs, etc.

I understand that the transformer will isolate my board from the world. But I wonder how to design the termination circuit.

What about the center tap? Can I use the same GND in this case?

This is the schematic I am using:


texts: Energizing relay using short pulse signal

texts:
I have DPDT relay which I would like to energize using pulse signal (duration of that pulse should be adjustable) and switch. When switch is on, coil of relay is shortly energized by pulse signal and then deenergized when pulse signal ends, although switch is maybe still closed. When I open switch, nothing happens but when I close it, process repeats.
Any idea how to implement this circuit? Relay model is Omron DPDT 10A 12V DC.
Thanks in advance

Edit:
I looked for solution using 555 timer but it will not work in my case. Here is example of monostable 555 timer:
http://www.electronics-tutorials.ws/waveforms/555_timer.html

If I put switch between pin 2 and ground and close it, output will be high but it will not go low itself If I keep switch closed. I need output to go low even if I keep switch closed for long time.
They say also:

"The Monostable 555 Timer circuit triggers on a negative-going pulse applied to pin 2 and this trigger pulse must be much shorter than the output pulse width allowing time for the timing capacitor to charge and then discharge fully."


texts: Z-parameters measurement in active circuits

texts:
What difficulty faced in measuring Z parameters in active circuits, how is it taken care of?,what is limitation at high frequency?

I heard that we use inductor instead of open ckt and capacitor instead of short ckt, but how it works?


texts:
I'm following this tutorial: http://pdp11.byethost12.com/AVR/ArduinoAsProgrammer.htm
I saw elsewhere, and I simply can't get it to work. I've connected the 10,11,12,13 pins exactly as shown in the schematic in said tutorial, checking and double checking and triple checking that I have it right.

Here's the message that pops up, using avrdude:

Now, after removing the MOSI/MISO/RESET/SCR pins, here's my connection scheme:

As it is, what happens is that the LED, that's connected to a random pin, lights up in a chaotic fashion, if I touch a circuit in a certain way or move a certain wire, it changes how much it lights.

Another thing is that the chip heats up quite a bit, just by setting the voltages and grounds.

So, I don't think my atmega32a (http://www.atmel.com/Images/doc8155.pdf) is behaving as it should. Does anyone have any ideas on what could be going wrong and on what I can do to make avrdude recognize the chip??

Thank you in advance.


texts: ATEX: PCB design for intrinsically safe, output capacitor

texts:
We're looking into restricted breathing or encapsulation concept because PCB has a complex circuit that makes it impossible to achieve SMD clearance under 'ic' or increased safety concept.

I have a simple 4-20mA sensor transmitter attached to the MTL7700 series Zener barrier, which connects custom made electronics PCB which contains AFE and 24V Power.

The 24V PSU has a 20uF ceramic X7R capacitance on the output before the Zener barrier (Fuse, 300R and 28V Zener clamp), is there a restriction on output capacitance from the PCB (I recall it was 1.65uF, but can't remember where this number come from in IEC60079-XX). Why this matter because the Zener barrier already limits the energy?


texts: Unable to communicate with LCD2004a via I2C (Nucleo-F103RB)

texts:
Hell guys, i'm trying to communicate with LCD2004a with the I2C extender.

i followed this guide: https://www.youtube.com/watch?v=7mQppaEJjT4

what i did:

I generated project using CUBEMX to Keil uvision
configure I2C with those parameters: 100Khz CLK, slave address 0x27( i checked with I2C scanner that is actually the address)
added the library i2c-lcd to my project (downladed from the link in the youtube video)
change the parameter SLAVE_ADDRESS_LCD in the source code of the library to 0x27
connect the SDA to PB7 and SCL to PB6 like the default pinout that CUBEMX offer me

and nothing happened.
its look like the LCD not communicate with my board at all.
those modules working well with Arduino so the problem is not with them.

here is my main function (simple hello world):

int main(void)
{
  /* USER CODE BEGIN 1 */

  /* USER CODE END 1 */

  /* MCU Configuration--------------------------------------------------------*/

  /* Reset of all peripherals, Initializes the Flash interface and the Systick. */
  HAL_Init();

  /* USER CODE BEGIN Init */

  /* USER CODE END Init */

  /* Configure the system clock */
  SystemClock_Config();

  /* USER CODE BEGIN SysInit */

  /* USER CODE END SysInit */

  /* Initialize all configured peripherals */
  MX_GPIO_Init();
  MX_I2C1_Init();
  MX_USART2_UART_Init();
  /* USER CODE BEGIN 2 */
    lcd_init();
    lcd_send_cmd(0x80|0x00);                        // first line address
    lcd_send_string("Hello word");
  /* USER CODE END 2 */

  /* Infinite loop */
  /* USER CODE BEGIN WHILE */
  while (1)
  {
    /* USER CODE END WHILE */

    /* USER CODE BEGIN 3 */
  }
  /* USER CODE END 3 */
}

here is my pinout

here is the library i use:

/** Put this in the src folder **/

#include "i2c-lcd.h"
extern I2C_HandleTypeDef hi2c1;  // change your handler here accordingly

#define SLAVE_ADDRESS_LCD 0x27 // change this according to ur setup

void lcd_send_cmd (char cmd)
{
  char data_u, data_l;
    uint8_t data_t[4];
    data_u = (cmd&0xf0);
    data_l = ((cmd<<4)&0xf0);
    data_t[0] = data_u|0x0C;  //en=1, rs=0
    data_t[1] = data_u|0x08;  //en=0, rs=0
    data_t[2] = data_l|0x0C;  //en=1, rs=0
    data_t[3] = data_l|0x08;  //en=0, rs=0
    HAL_I2C_Master_Transmit (&hi2c1, SLAVE_ADDRESS_LCD,(uint8_t *) data_t, 4, 100);
}

void lcd_send_data (char data)
{
    char data_u, data_l;
    uint8_t data_t[4];
    data_u = (data&0xf0);
    data_l = ((data<<4)&0xf0);
    data_t[0] = data_u|0x0D;  //en=1, rs=1
    data_t[1] = data_u|0x09;  //en=0, rs=1
    data_t[2] = data_l|0x0D;  //en=1, rs=1
    data_t[3] = data_l|0x09;  //en=0, rs=1
    HAL_I2C_Master_Transmit (&hi2c1, SLAVE_ADDRESS_LCD,(uint8_t *) data_t, 4, 100);
}

void lcd_clear (void)
{
    lcd_send_cmd (0x00);
    for (int i=0; i<100; i++)
    {
        lcd_send_data (' ');
    }
}

void lcd_init (void)
{
    // 4 bit initialisation
    HAL_Delay(50);  // wait for >40ms
    lcd_send_cmd (0x30);
    HAL_Delay(5);  // wait for >4.1ms
    lcd_send_cmd (0x30);
    HAL_Delay(4);  // wait for >100us
    lcd_send_cmd (0x30);
    HAL_Delay(10);
    lcd_send_cmd (0x20);  // 4bit mode
    HAL_Delay(10);

  // dislay initialisation
    lcd_send_cmd (0x28); // Function set --> DL=0 (4 bit mode), N = 1 (2 line display) F = 0 (5x8 characters)
    HAL_Delay(1);
    lcd_send_cmd (0x08); //Display on/off control --> D=0,C=0, B=0  ---> display off
    HAL_Delay(1);
    lcd_send_cmd (0x01);  // clear display
    HAL_Delay(1);
    lcd_send_cmd (0x06); //Entry mode set --> I/D = 1 (increment cursor) & S = 0 (no shift)
    HAL_Delay(1);
    lcd_send_cmd (0x0C); //Display on/off control --> D = 1, C and B = 0. (Cursor and blink, last two bits)
}

void lcd_send_string (char *str)
{
    while (*str) lcd_send_data (*str++);
}


texts: synchronous buck ls-FET switching losses and dead time minimization

texts:
I'm designing a Synchronous buck converter. I'm having doubts regarding the following:

In the rectifying period of the converter, using a Schottky diode in parallel with the low side MOSFET will prevent the body diode from conducting, and so it should render the switching losses in this FET equal to zero.
However I would expect that while the LS-MOSFET is switching it would be conducting at least a bit and therefore some losses would occur.
Can you explain this to me, everyone just assumes there are no switching losses and that's that...
And plus, are there any problems if a Schottky diode isn't used?
Minimizing the losses in the diode conduction period equals to minimize the dead time between the signals that control both MOSFETs.
While testing for a small dead time, I took it too far and had both FETs short circuited (even though I calculated the switching times according to the gate driving current).
Is there a procedure to find a small yet safe dead time for the complementary PWMs?


texts: How to configure my favorite editor in ModelSim?

texts:
I want to set up my favorite editor in ModelSim. The default behavior is that ModelSim uses its own internal editor, which I don't like.

I've Googled and I've searched the ModelSim User Manual. I figured out that:

If you set the EDITOR environment variable, the TCL edit command will use your editor.
You can configure the project to execute a custom command when you double-click a file (I've set this custom command to edit %f which opens the file with my editor.

Still, when I double-click a compile error, the default (built-in) editor is opened. This is not what I want.

Is there a global setting so that the internal editor is not used, but my own editor is?


texts:
I am trying to design a circuit that has a timing sequence. The timing sequence will be started by a SPST momentary switch. For the first 2-4 seconds a green led will display. When the first timer has finished a second should start, and the green led should turn "off" and a red led should light for 2-4 seconds. After the second timer has completed, the red led should turn "off" and a buzzer should sound for around 0.5 seconds. I need to design this using op-amps, capacitors, inductors (if needed), and resistors. I have designed an op-amp timer for the first LED, but I am having trouble trying to tie in a second timing sequence.
Here is my circuit thus far:

EDIT:
For those who asked this is a project I am working on that requires only op-amps, capacitors, inductors, and resistors be used to create the timing sequence.


texts: Why does `RCC_GetClocksFreq` return different results than I expect?

texts:
I have a STM32F427 MCU with a 8MHz HSE crystal. I am setting up the clock as follows:

#include <stm32f4xx.h>
#include <stm32f4xx_rcc.h>

void initClocks(void);

void initClocks(void) {
    /*
    HSE: 8 MHz
    PLL: HSE / 8 * 192 => 192 MHz
    SysCLK:  PLL / 2 => 96 MHz
    PrphCLK: PLL / 4 => 48 MHz
    */
    RCC_PLLConfig(RCC_PLLSource_HSE, 8, 192, 2, 4);
    RCC_PLLCmd(ENABLE);

    // Wait
    while(RCC_GetFlagStatus(RCC_FLAG_PLLRDY) == RESET) continue;

    // Use PLL
    RCC_SYSCLKConfig(RCC_SYSCLKSource_PLLCLK);

    while (RCC_GetSYSCLKSource() != 0x08) continue;

    RCC_HCLKConfig(RCC_SYSCLK_Div1);
    RCC_PCLK2Config(RCC_SYSCLK_Div1);
    RCC_PCLK1Config(RCC_SYSCLK_Div1);
}

int main(void) {
    RCC_ClocksTypeDef ClksFreq;

    initClocks();
    SystemCoreClockUpdate();

    RCC_GetClocksFreq(&ClksFreq);

    while(1) {}
}

HSE_VALUE is defined to 8000000

My debugger shows that SYSCLK in ClksFreq is 57.6MHz, though I would expect it to be 96Mhz.

What am I missing?


texts: What's the relationship between ESC pwm input and output?

texts:
I'm using ESC(Electronic speed controller) to control outrunner brushless dc motor.
As you know ESC detects ppm signal between 1ms and 2 ms approximately. So my ESC detects signal between 4% and 9% duty cycle at 50 Hz as an input.
However, it is unknown what kind of relationship exist between this input signal and output signal that drive BLDC motor.

Is ESC linear? How ESC converts input signal into required voltage for motor?


texts: In MOSFETs why is the gate-body inversion layer voltage able to create a conducting channel, yet the same source-drain voltage not?

texts:
I have very little experience with electrical engineering, so please bear with me. I was hoping to get a qualitative explanation as well as pointers to the maths/formulas which could formally explain the principles behind the following question:

In a MOSFET, I understand the concept of why an inversion layer can be formed by the gate-body voltage, but why is it that the required gate-body voltage to create this inversion layer is so much lower than the voltage required to overcome the reverse bias - i.e. It takes only 6V to create an inversion layer via the gate, but it would take 100V to create an "inversion layer" between the source and drain (overcoming the reverse bias junction). Is it the positioning of the gate perpendicularly to the npn junctions which somehow affects the ease with which the electrical field can make an inversion channel across the device? Or perhaps that the gate-created "inverted" channel across the middle-p-section is a smaller area than would be inverted if the source-drain voltage were high enough to create a channel? Or is it the proximity of the gate (and thus its field) to the area on the semiconductor it is trying to invert?

If so, what are the physics formulas which explain this? (I have a hunch that the electrical field of the gate is like chipping a small channel across the top of a brick wall rather than trying to push it down from the front)


texts:
I'm experimenting with a TI Dual Output Buck Converter, the TPS54383. In section 11.3, on page 43, the datasheet says

11.3 PowerPAD Package
The PowerPAD package provides low thermal impedance for heat removal from the device. The PowerPAD
derives its name and low thermal impedance from the large bonding pad on the bottom of the device. The circuit board must have an area of solder-tinned-copper underneath the package. The dimensions of this area depend on the size of the PowerPAD package. Thermal vias connect this area to internal or external copper planes and should have a drill diameter sufficiently small so that the via hole is effectively plugged when the barrel of the via is plated with copper. This plug is needed to prevent wicking the solder away from the interface between the package body and the solder-tinned area under the device during solder reflow. Drill diameters of 0.33 mm (13 mils) work well when 1-oz. copper is plated at the surface of the board while simultaneously plating the barrel of the via. If the thermal vias are not plugged when the copper plating is performed, then a solder mask material should be used to cap the vias with a diameter equal to the via diameter of 0.1 mm minimum. This capping prevents the solder from being wicked through the thermal vias and potentially creating a solder void under the package. (See the Related Documentation section.)

Also, in the pin function table for the thermal pad it says

This pad must be tied externally to a ground plane and the GND pin.

My questions 1) does this mean I need to have a solder connection between the chip and the pad? Or will having enough solder so that the pad on the IC touches the pad on the PCB? 2) If I need a connection, like for pins, how do I heat up the solder underneath enough to reflow? I only have a solder iron, no hot air gun.
Edit 1
Here is a picture of the pads on the PCB. I started to tin one corner but stopped because I wasn’t sure how to connect the thermal pad (if I need to).


texts: Is it possible to compute delay with an IIR filter between peaks?

texts:
I am developing a project which receives accelerometer signals as input, which must then be analysed via peak-detection algorithms (among other techniques).

In order to do so more effectively, I first filter the signal with a low-pass Butterworth digital filter (an IIR filter) with order 20.

By plotting the signal to a graph, I can then see a delay between the peaks to be detected, which wouldn't matter much if I just needed to detect the peaks themselves.

But since I need to compare the output of this filter with the input and then some other filtered outputs, I need to be able to match these peaks between themselves.

I know this can be done (approximately) with FIR filters by calculating their delay (which is n/2), so I ask: is this possible with an IIR filter?

Filter coefficients:

A = [ 1; -5,98758963; 16,67219332; -28,2587879; 32,15975649; -25,6017496; 14,40568743; -5,647074344; 1,473727937; -0,230919346; 0,016479631 ]

B = [ 1,68E-06; 1,68E-05; 7,58E-05; 2,02E-04; 3,54E-04; 4,24E-04; 3,54E-04; 2,02E-04; 7,58E-05; 1,68E-05; 1,68E-06 ]


texts:
I have a load (LEDs) that draws 36V, 5A. The circuit is made in this way:

Power Supply (AC-DC) -> LED Drivers (5 in parallel) -> LEDs (5 strips).

What component I need to install if I want to add second power supply but that ONLY when the first turns off (or stops working) the other immediately intervenes and the power supply to the LED Drivers is never cut off.


texts:
I am looking at the product spec of NRF52832, in particular the Radio Electrical Specifications (here, the information is on page 232 of v1.4). Within it is a section called Rx Intermodulation that shows this:

IMD performance, 1 Msps (3MHz, 4MHz, and 5MHz offset)        -33 dBm

I have talked to a few people, but the opinions as to what this means practically vary.

My question is: If I have this receiver set to listen on frequency X, and I start a transmitter on frequency Y = X + 3 (and all settings allow the receiver to decode the transmitter's messages), does that mean that intermodulation will make it possible for me  to receive the transmitter's messages with the received signal strength reduced by 33dB?


texts:
I am trying to clean up a source signal that has a lot of jitter between 3.7v+ and 5.6v+. I need a steady 5 volts with with a current of 1.2 amps minimum. The problem I face is that every-time I connect my circuit, the voltage drops to 3v+. I used ohms law to verify my circuits current requirements and I am meeting that with 2 amps. My circuit draws 1.2 amps. I am not sure if my source is total garbage or if I am doing something wrong! Any ideas on if a bypass capacitor will even help me?

The source is a 5v 2 amp usb cell phone charge hooked up to a OSEEP USB to DC Barrel Jack Connector plugged into a Breadboard PowerSupply (http://www.amazon.com/gp/product/B010UJFVTU?psc=1&redirect=true&ref_=oh_aui_detailpage_o01_s00)

I don't have a Type A to Type A usb cable which is why I am using the barrel jack.

The load is a DHT11 connected to an ESP8266 (3.3v breadboard rails). and a Arduino Pro Mini 5v (5v breadboard rails). With pullup resistors and LEDS for debugging.

The ESP8266 is running its own core and the Pro Mini is being used as a debugger  and programmer as I don't trust connecting the ESP8266 directly to my computer even via an FTDI.

Still, my main problem is that the breadboard power supply is producing inconsistent voltages with my multimeter as the only load. Other than using wall warts, this is the first power supply I have ever used.

If I can find time I will Fritzing a Circuit Diagram for you. However, I am not sure how much help that could be since the problem is before the circuit is even  applied.


texts: Soldering connector on PCB to connect to logic analyser or scope

texts:
When it comes to digital circuits, it is often important to get certain internal design signals to an I/O pin and then view it on scope. This is in-spite of all the other techniques that exist to debug such designs. We could get the signal onto an oscilloscope or logic analyser.
If one wants to include a special connector dedicated to this purpose, what options exist? This would be a connector with a small form factor that can be easily connected to logic analyser or oscilloscope probe.
Edit:
Please assume that I need 16-20 pins to be dedicated to this purpose and since it is for an FPGA, it is going to be for digital circuits


texts: Drive 6-wire 2 center-tap stepper with Stepper Driver

texts:
I've come across a stepper with the operation logic shown in the snippet below.

I've read elsewhere that I can operate the stepper using an EasyDriver or BigEasyDriver by simply ignoring the center taps. I have had some success, but it very frequently skips steps or jerks as though it is skipping steps. I have verified that I am running it at the rated voltage (12 V). I have also tried a few different micro-stepping options on those driver boards. At certain operation speeds, it looks like it sort of works, but too slow or too fast and it doesn't move at all or moves questionably. Based off the logic diagram, I'm suspicious I might not be able to run this stepper using the mentioned drivers.

However, I'd like very much if someone can prove me wrong. Otherwise, my next step is to source a bi-polar stepper with similar dimensions.

UPDATE 1

So I've been looking at using this bi-polar stepper (it won't let me post the link, so its the DRV8825 from www.pololu.com) to drive this particular motor. It seems like if I leave the center tap's powered at 12 volt as intended then the driver should successfully power half of the coils shown in the diagram. What I'm not sure about is what will happen when one of the driver's outputs (A for example) is at 0 current. Does this mean the H-Bridge for A is fully open (meaning no current can flow)? Or does it mean that the outputs are both high or both low? I hope the former because then I should be able to drive this in half coil without fear of damaging the motor or the driver. I'll do some experimenting...

UPDATE 2

To answer update 1, you can control the stepper without damaging the stepper motor. Only half the coils are charged, however.


texts:
When uC1 wants to talk to uC2 via uart, the Tx of uC1 is connected to Rx of uC2 and vice versa.
Half Duplex states that only 1 uC can use the communication line at a time and Full Duplex states that both uC can use the line at the same time.
The Tx and Rx pin connections still remain the same for both methods of duplexing, but how 2 different scenarios are possible?
Does the presence of separate Buffers for tx and rx determine duplexing or are special IC's and pin connections needed?
Im confused because im working on a system where 2 uC's communicate with each other and both can send data at any point of time across a common uart connected to both of them(uC1=UART1,uC2=UART1).This will help me decide if priority among the 2 uC's is needed or not(i.e force them to work in half duplex, cos il be using ACK/NACK for messages sent via uart,and if both can send at any point of time,theres chances of misinterpretation/corruption of data(i.e uC1 is expecting ACK from uC2 in its rx buffer but uC2 is sending a message and not an ACK for the received message)).

  Update

Im using 2 LPC1778,where the UART1 TX of uC1 is connected to UART1 RX of uC2 and UART1 RX of uC1 is connected to UART1 TX of uC2. Both uC can send data at any point of time simultaneously(full duplex)and no transceivers will be used(direct uC-uC communication).The uC's have separate Tx and Rx Shift registers. When uC1 is Tx'ng,data is going to uC2 Rx FIFO. If uC2 transmits,data will be going to uC1 Rx FIFO. So, if both uC's send, there wont be any collision right?


texts:
In high frequency, this plots the input voltage and the current in a simple circuit with a resistor and a diode.

The behaviour I see is that the diode remains forward-biased for longer than an ideal diode would, but as soon as it does it goes back to the usual, perhaps exponentially in a very low time, without any phase shifts.

I have been attempting to (macro) model that particular behaviour of the real diode using an ideal diode and other components (capacitor, resistance, inductor), but so far, failing miserably

Short question is, what could I add to the black box of an ideal diode for it to behave that way?

I would appreciate, should you come up with something, to know how you went about thinking about this, since learning is the only purpose of this question.

Thanks a lot


texts: Is it normal to have 40% capacity after 1.5 years of charging Li-Ion?

texts:
I have a laptop computer that spends 99% of its time plugged in. The last time prior to today I used the computer not plugged in was 1.5 years ago.

Today morning, I put the computer to sleep (with its battery capacity at 95%), went to work with the laptop in my bag, and started to use the laptop after 4 hours of sleep not plugged in. I was surprised to see the battery capacity was at 40%!

Then I used the computer plugged in for few hours, put it to sleep, put the computer to my bag, and after 4 hours of sleep in my bag turned it back on. Now battery capacity was at 100%.

So, it appears if you charge a lithium-ion battery for a really long amount of time such as 1.5 years, its actual capacity can be 40% whereas the displayed capacity is at 95%.

My question is: is this normal?

And before you ask, the full charge capacity has went from 46642 mWh to 44084 mWh, i.e. very minimal decrease.


texts: Which parameters in datasheet give information about a BJT's step response quality?

texts:
I did a test with randomly chosen 12 NPN BJTs. I applied a clock pulse to each of them and observed their collector voltages. Some of them showed very low rise time, while some responded terribly slow. As far as I realized, power transistors like 2N3055 yield very high rise times, while those which have very low collector current rating yield very low rise times.

I used to think that the "transition frequency" would give enough information about this. I chose a 100MHz transistor (BC817), but it couldn't survive even at 20kHz. Therefore, the "transition frequency" parameter shouldn't be giving enough information alone, or it should be about something totally different (I don't know).

My question is, how do I roughly predict step response characteristics of a BJT by looking at its datasheet? Which datasheet entries give information about this behavior?


texts:
A signal from a measurement is filtered with an analog 2nd order low pass filter.
The original signal which consists of the sum of two exponentials (one positive amplitude the other one negative amplitude) slightly changes its shape.
Since the information of important parameters can only be extracted from the unfiltered signal, I would like to undo the filtering digitally. I am aware that it is not possible to obtain the full original bandwidth, but could I theoretically increase the bandwidth?
The filter's transfer function numerator is 1 while the denominator is a 2nd order polynomial.

Added:

My goal is to determine the values of an RC low pass (life science application).
A voltage pulse is applied to the low pass filter.
The arising current (which is a mono-exponential and contains the information of the R,C values in its time constant) is converted to a voltage (with an I-V-converter).
The signal is then low-pass-filtered with a 2nd order Bessel filter.
The sampling rate of the system is 20 kHz while the cutoff frequency of the filter is 3 kHz.
Fitting algorithms are used to cancel noise in the output.
My goal is to obtain the mono-exponential for any output signal.

Added:
This is the actual circuit I wish to analyze.

I would like to obtain the current input at the ampere-meter for any output voltage. Of course in this simulation there is no noise. Before I apply the method to the real system I would like to make it work for the simulation.
I've been using the MATLAB system identification toolbox in order to estimate the transfer function. By applying the inverse transfer function to the output I should be able to recover the original current input.


texts:
I recently completed a PCI-E Gen 1.0 line card design. The line card consisted of 4 Spartan 6 FPGAs sharing one PCIE reference clock. Early on in the design there was a decision to solely use the PCIE reference clock to clock all the internal logic from this PCIE reference clock and hence no on board crystal was used. The FPGAs interface to a bunch of servos on the other side over 10/100MBS interface and the FPGAs used the DCM to divide the PCIE- Reference clock to 25MHz and used for the MII and the PHY interface. There was a lot of Receive Data valid errors on the PHY interface which was attributed to the PCIE reference clock and its inherent jitter of 30KHz to 33KHz(Spread spectrum modulation). We decided to turn off the SSC function in the host software and we stopped seeing the receive error and things are back to normal.
I wanted to ask and see if others had different experience using the PCIE-ref clock for clocking all FPGA logic including the 25MHz PHY interface. I was under the impression that the FPGA's DCM would clean up the PCI- reference clock after it gets in to the PCIE MGT hard macro before it was divided down. This is my first FPGA design and hence would appreciate some insight.


texts:
This question started as a design specific question but is (now) more of a general question going forward onto other PCB product designs...

For now, I am designing an I/O PCB and want to mix supply voltage (+24V) and signal I/O onto one Molex (36-pin) type header.  I plan to use 12 pins (non-adjacent) for +24V/0V, these will power (2-3mA/device) 12ea prox-type (PNP) sensors.   The lion's share of the load will be 6 pins (adjacent) for +24V/0V that will power 3 external 2A contactors; duty-cycle TBD.

The datasheet does not offer any current/thermal/loaded-pins graphs but the general current rating (per pin) is 3A. My research is telling me that rating connectors for current/thermal is very subjective in terms of the datasheet's current rating per pin.  Current density, plating, exposure to open-air, PCB/plug conductor size, ambient air temp and the list goes on; all play into the over-all power/thermal rating of any connector.

That said, no one-size-fits-all and to provide all of the details and worst-case scenarios could be exhaustive and perhaps this type of question is too general for ESE. I spent a reasonable amount of time looking for some technical guide-lines for rating connectors but have yet to find a one-stop-shop in an effort to demonstrate and design in due-diligence.

Finally, here is my question.  How do I rate/de-rate connectors for ampacity?


texts:
I want to dim an LED strip.
It's about 1.5m in total length and could work for prolonged time on a battery.
If it weren't for the battery limitation I would probably just put a resistor in series, but I'd like to make it as efficient as possible so I'm thinking of using PWM.
I've got a 5V uC. Strip is running off of 12V. I have a bunch of IRLZ44N transistors laying around which is probably overkill for this job but that's what I have so I'll just use it.
My question is in two parts:

In this famous greatscott video it is explained that switching higher loads causes oscillations that can't lead to anything good. Since I don't own an oscilloscope, how can I tell if my load/frequency are causing voltage spikes?

In this question's accepted answer, a comment states that current can rush back into the component driving the gate. How does that happen and does it mean that driving the gate from a uC pin is guaranteed to fry the uC, making a driver ic a requirement?


texts: Why does my SEPIC converter output more power at higher temperatures? What are the implications of this behavior?

texts:
I have a Pololu S18V20ALV SEPIC voltage regulator board that is wired to a high-amperage 5V USB power source on the input and a DC brushless fan on the output. The output is set to about 5.5V. Contrary to the typical behavior of a power supply where higher temperatures reduce maximum output, I've noticed that it delivers more power when hot:

If I heat up the regulator by shorting the output pins for about ten seconds, then remove the short, the fan runs faster than it otherwise would.
If I hook up a 10A ammeter to the output, the meter readout progressively increases from less than 1A to as high as 3A as the voltage regulator heats up. The limit is due to the thermal shutdown function on the TPS55340 regulator chip.

Why is my voltage regulator doing this? Is this behavior typical for a SEPIC converter? What implications does this have? (Does this mean that an overloaded SEPIC converter without thermal protection can experience thermal runaway and consequently catastrophic failure?)


texts: Very precise position motor recommendation

texts: I've been searching for a suitable motor for my solar panel and I need two motors to rotate to two angle that is solar azimuth and altitude. Since it involved a very precise angle calculation and so I hope I can find some motor that suit the project. My tracker is much more smaller compare to the others. Any motor that can recommend to me? I hope the price can be a lot cheaper.


texts: Why does this big button require 12V DC for an LED?

texts:
I'm looking at the Spark Fun Big Dome Push button. The spec on the page (and other places selling it) says that the LED is 12VDC. Does this mean that I need 12V as a minimum? Am I not able to just swap out the LED for one of my own (much lower voltage) if I dismantle it? I can't seem to find a datasheet for it.

Ultimately I want to have it connected to my machine via USB - which is why I can't provide it with 12V. My first thought at accomplishing this was to use an ATTiny85 I have connected via a USB to Serial breakout (or one of those USBs with an FTDI chip in them).

Any help would be much appreciated. Or alternately if my method to read the button's input is roundabout please let me know as I don't have an EE background!


texts:
Let us assume the universe is filled with positive charges. At a particular point, all the positive charged particles will be symmetrical. Now, we assume a sphere of radius r (finite) as our Gaussian surface. And now we apply Gauss law.

According to Gauss law the electric flux through the sphere will be some finite value as it contains some positive charge. But by symmetry the electric field through the Gaussian and hence electric flux will be zero. Hence contradictory!


texts: What is the application for the ramp frequency function? For example, I know that ramping from 1kHz to 100kHz in 1kHz increments is one way of determining the stability of a device under test. But other than that, are there any other applications for a frequency ramp?


texts:
I've been watching videos how to make PCB at home and I understand the process. But none of them shows how 2 sides are connected, I see on some PCBs there are some circular end points, so it must be going to other side. But how is it connected ?

On arduino mini, I can see the coating inside header holes ? So does it require to coat carbon again ?


texts: Is it generally possible to uniquely identify an individual MCU (for licensing purposes) (no MAC address available)

texts:
I am being asked to enhance the firmware installation program for an MCU (specifically, a Freescale MC9S12E64 - though I don't know if this matters).

The purpose of the enhanced installation is to limit the number of times the firmware can be installed. It seems the best way to do this would be to uniquely identify the specific MCU in use during firmware installation, in order to keep track in a central database.

If the MCU had a MAC address, this would seem to be feasible. Unfortunately, these MCU's have no network interface, and hence no MAC address. Looking through the manual for the MCU noted above, I cannot find an indication of a unique identifier for the MCU.

My question is: Do MCU's typically have unique identifiers associated with them - analogous to a MAC address - that can be obtained by software as firmware is burned into these devices?


texts: How do you properly ground a digital pot and an op-amp?

texts:
I'm going to take a 5V 500mA power supply and pass it through a digital potentiometer AD5235 and then step it up through an op-amp with a gain 2 to get up to 10V output and put that into voltage based meanwell dimmer controller.

I'm a little confused on how to handle grounding with this. They are circled blue. Can I "ground" the -5V from the pot, and the -10V from the dimmer and the opamp together without damaging the pot by connecting them on the power supply -5V terminal of the wall wart I'll be using?

Also I have a couple questions about the pin meanings:

WP - Optional Write Protect. When active low, WP prevents any changes to the present contents
PR - Optional Hardware Override Preset. Refreshes the scratchpad register with current contents of the EEMEM register.  PR is activated at the logic high transition.
RDY - Ready. Active high open-drain output

What is active low vs just low, why the verb active?

What do Logic high transitions and active high open-drain output mean exactly?


texts: Low volume mixed signal electronics production (hardware test, calibration, flashing) automation

texts:
I am designing a mixed-signal board with microcontroller that will need flash memory programming for its firmware, (self-)testing, and documentation for the final production steps.
I know there is a whole branch of the electronics manufacturing industry just around testing (ATE), but I have not yet found a simple list of steps and options for the basic process, just to get started and figure out the simplest, low cost way of automating this for a small scale.

Let's start with the essential flashing of the micro:

Connect device to programmer (PC+Software)
Click "program" button to flash firmware
Disconnect device

How would one simplify this to minimal human involvement like

Insert device
Remove device

? Likely with

a test jig and spring-loaded probes (pogo-pins) for the connections.
a method for the computer to detect the device (switch, or retry until successful connection to MCU was established).
a human-machine interface (audio, visual via PC or on test jig)

The machine IO could be as "simple" as another microcontroller board (say Arduino) connected via serial port (UART/RS-232). Then the PC software might have to be customized to control the process (IO and Flasher software).
Of course for flashing alone there are several options (vendor specific link, JTAG, bootloader).

Next of interest would be automated testing and calibration of the device. Of course, this is very specific to the hardware. The necessary equipment could be generalised as

power supply
signal generator (reference voltage / signal)
measuring device (multimeter, oscilloscope)
loads (sinks, sources)
interfaces

Instead of using self-test or IO routines on the hardware (separate testing firmware or test routines part of production firmware), low-level tests could be run by external control host via hardware Boundary scan / JTAG.

Depending on the circuit, this might be simplified to self-testing with a passive jig that mostly acts as a loopback device.

In any case, a general sequence for test/calibration might be:

apply signal
measure signal
[calculate / store calibration parameters]

For instance, outputs could loop back to (multiple) inputs via the test jig.
Analog signal calibration requires a reference that could be external. Signal switching might be required if using a reference with inputs (ADC) and outputs (DAC), e.g.

apply external reference voltage to input
calibrate input
switch output to input
self-calibrate output (adjust until output is same as reference)

Alternatively an external comparator could be used with the reference voltage for feedback (requiring an input and a routine to search for the correct output value).
Of course, off-the-shelf test equipment with control interfaces are available and allow direct setting/measurement of analog signals to calculate calibration values.

Writing the calibration data to the device or attached memory requires corresponding data structures/addresses used by the firmware.
The data could be written directly to memory where possible (flash memory limitations e.g. erase cycle, block size) or embedded into firmware/eeprom image before writing final production firmware.
Alternatively, if the firmware has a calibration interface, this could be used to transfer/update these values after flashing once the device is running.

As for ID and documentation, if no hardware ID is present in the devices, one might be generated by the test environment and written to the device.
Firmware and product information could be written to database and sent to label printer for physical ID on the device.

Of course, any solution is always a trade-off and can only be approached further based on the details of the test requirements.

I'd be interested in further ideas or pointers to accounts of implementations.

Also see:

Optimizing product tests?
https://en.wikipedia.org/wiki/In-circuit_test


texts: Is to possible to measure electric signals using a capacitive touchscreen?

texts:
Thanks to a very good explanation by Mr. Ghosh, I found that a capacitive touchscreen measures the change in capacity, induced by contact with a conductive material, along a grid. I have two questions:

If the capacitance is measured using a high-frequency signal, would it be possible to (indirectly) measure natural electrical signals (low frequency) from the body using the same system? I am interested in using mobile phones to measure these signals.
Is the change in capacitance dependent on the local composition of the body part that touches the screen?


texts: PCB Design Review: Impedance Matching & Termination Resistors

texts:
I hope you can help review my design-
I'm working on a keyboard PCB design. I thought I was nearly done, but after happening across discussions on USB impedance matching of the data traces (and differential pair routing), I thought I'd better at least try and address this.
Due to design constraints, I'm not able to place the USB plug near the MCU (Atmega32u4) - so I have to route the data traces a loooong way across the board.

From what I read, to attempt to design to match an impedance value, you need to put a copper fill (GND) on the back of the PCB, have no interruptions to that ground plane under the traces, and set your data line traces to be a specific width, and a specific width apart - and - also try and keep the traces the same length.
I've managed to get the ground plane in, uninterrupted from USB plug to MCU. I've also set my D+/D- trace widths and separation, as per this calculation - trying to reach 90 ohms on differential impedance.

(Values picked from the manufacturer: https://jlcpcb.com/capabilities/Capabilities)
Since this is only a keyboard, I don't need high transfer speeds, so I guess that means my design does have to be 110% perfect in this regard... Due to the spacing of the USB connector pins and MCU pins, I had to compromise on trace width and taper it in..
Here are a few close-ups:

Here are the Termination Resistors:
In the keyboard design world, it common convention to put in 22 ohm resisters in the D+/D- lines:

These are 0402 package resistors (so, tiny).
Here is another chat about these termination resistors for USB:
https://www.eevblog.com/forum/projects/why-usb-data-series-resistors/
Questions:

Do you think I've done a reasonable job at routing those D+/D- traces to try and match impedance? Any obvious things I could improve?
I'm worried about the Termination Resistors - they cause the traces to diverge a bit... I think that will mess up the impedance matching efforts? I don't have JLCPCB specs for min distance for SMT assembly... So I don't know if I can move them closer... Any thoughts on this? Should I just try and make them as close as possible together?
The very value of Termination Resistors is a question... 22 ohm is the usual value cited (also in the atmega32u4 datasheet) but I don't know how that factors into the overall impedance of the D+/D- lines? (I'm still learning...)

Thank you very much :)


texts:
What is the lowest current way of inverting the output from a GPIO pin?

I have a solar board that has an add-on that can turn a USB port power off if a LiPO gets below 3.3v. The problem is, they added the ability to control this battery-based switching using a two pin connector for 'Enable' and 'Control'  (when Enable is 'high', control is ignored and the USB is turned off [if on] whenever the voltage drops below 3.3v and turned back on [when off] when the voltage rises above 3.8v)

The problem is, I can't turn this mode 'on' when the Raspberry Pi is off. I can only turn it off when the Raspberry Pi is on.

I would like to be able to hook an inverter on the GPIO pin so that it is 'high' when the GPIO pin is 'low' but consume as little additional current as possible to do this. That way I can disable the battery switching as long as the RPi is on, read the voltage and safe-shutdown the pi if it gets to 3.3v. Then, when the Pi is off completely, the battery voltage will turn off via the USB device.


texts: Inductance to capacitance ratio in LC filter for PWM

texts:
When using parallel LC filter for smoothing out PWM, I'm using the following equation to calculate its frequency:

F\$_C = \dfrac{1}{2\pi\sqrt{LC}}\$

Here is a schematic of an LC filter I'm talking about:

simulate this circuit – Schematic created using CircuitLab

In theory, I can use any L or C values as long as a result is substantially lower than PWM frequency. So for example 10uH and 1000uF gives the same frequency of 1591Hz as 100uH and 100uF. I'm not sure how these two options will differ in practice. I know that you can also calculate a Q factor for the circuit with:

\$Q = R\sqrt{\dfrac{C}{L}}\$

As far as I understand I'll have best results when Q is closest to 0.5, so inductor value would have to be higher than capacitor value. The problem is that it's much easier to get bigger capacitors (like 2200uF/16V for a dollar or so) than inductors (I need something that handles about 8A).

If I understand correctly, the bigger the Q factor is, the longer ringing time, but I'm not sure what practical implications does it have for me, if any. I'm also not sure how to calculate ringing time. Do I have to worry about it or just use whatever I have? (in my case it would be 10uH inductor and 1000uF capacitor).

Update:

I played with such a circuit in LTSpice and I think that I have a feeling of what Q factor means, at least with an approximation of how LTSpice simulates things. With an L = 220uH and C = 22uF I get a nice smooth start when filtering PWM:

These values give a resonant frequency of 2287Hz and a Q factor ~0.47, with R = 1.5 Ohms.

With the values "swapped", ie. L = 22uH and C = 220uF I get a much worse effect for the same frequency:

This is a Q factor of 4.74 with current spiking up to 10A before setting at 6A.

I guess the question now becomes: how do I calculate the maximum spike (just to confirm what I got in LTSpice) and how bad are the spikes assuming that my components can handle them?


texts:
I have some bulbs like this.

Which takes about 3.8V, 0.3A current. Now I wanted to drive 21 bulbs in parallel. But i have only 12V voltage source. So I decided to use a voltage divider . when I calculate the resistor value required for voltage divider I get the following result.

Since each bulb takes 0.3A current and voltage across each bulb is 3.8V.

But when I simulate it in proteus I have seen that  increasing the load causes decreasing the output voltage across the resistor R2.i.e, the output voltage drops from 3.8V to 3.76V. But my requirement is 3.8V. My question is there anything wrong in my equation or solving method??


texts: Is it possible to have a charging unit and output unit connected to a battery at the same time?

texts:
I am very new to DIY and electronics stuff, so please excuse myself having little knowledge about this stuff.

Here is what I am trying to do:

Assuming I have both things (The Converter with USB output and the mini-USB input charger) connected to the battery, and only one thing on at a time, would it short circuit either of the modules, or the battery? Also, can I even have the charger and discharger connected together and to the battery without causing a short circuit?


texts: In order to simulate a wireless sensor in ltspice, i need to model a load which draws 25mA current for 1sec every 10 min. Rest of the time it draw 40uA. Is there any way to do that?. I tried behavioral modelling but there are only behavioral sources. Instead of drawing 25mA its generating 25mA


texts: absolute minimum wire and pad sizes for hand-made PCB's

texts:
I manage to get the autorouter in Eagle to complete the routing if I use small sizes for the wire and small clearances between wire and pad and wire and wire.

Since I'm making the circuit on a transparency for lazer printers, I'm just curious, what would be the absolute smallest size I could get away with for pads and wires (circuit-board lines) without potentially wrecking the circuit board?

I will be inserting the parts manually (mostly IC's but some LED's and resistors and capacitors) and then soldering them, and the drill I have that I plan to use is 1/16ths of an inch.

My lazer printer can print up to 600 dpi.


texts: This is a typical audio socket. In the datasheet there is a schematic, but it only has description for 3 pins out of 5, what is the use of the rest of the 2 pins?. Also what does the symbol in front of each pin in the schematic mean ?