Questions tagged [python]

On-topic questions related to Python would include embedded programming, using it as a tool for circuit analysis, or how Python interacts with computational hardware. Questions about libraries, algorithms, syntax, or code optimization should be directed to stackoverflow.com.

204 questions
21
votes
1 answer

ESP8266 eLUA (NodeMCU) vs MicroPython

I am searching for an unbiased, up-to-date comparison of the eLUA (NodeMCU) and MicroPython on ESP8266. I can only find very superficial reports/blogs of users trying out one or the other. - All of which lacking entirely of technical details. The…
ARF
  • 5,169
  • 9
  • 42
  • 69
21
votes
6 answers

LTspice automation

I have a battery-powered boost converter and I'm attempting to measure the maximum input (battery) voltage droop under various load conditions of high current draws (different duty-cycles/periodicities) in addition to over several battery types…
Joel B
  • 3,477
  • 2
  • 29
  • 37
8
votes
2 answers

Is there a spice directive to export waveform data in LTspice?

http://www.linear.com/solutions/1815 The above web-page explains how to export the waveform data to a text file. You basically run the LTspice simulation, clicking on the waveform window, go to File>>Export, chose the variable to be exported and…
Shashank Sawant
  • 299
  • 4
  • 6
  • 11
7
votes
0 answers

Automate LT-SPICE?

I'm running a lot of simulations in LT-Spice, and I need someway to run them all either sequentially or at the same time. I was going to use Python, but I'm not entirely clear on how I would get past the GUI and open the netlists I have and be able…
Tropical_Peach
  • 251
  • 3
  • 8
7
votes
4 answers

Wheatstone bridge sensitivity and accuracy

From my earlier question I was able to wire up 2 SEN-10245 weight sensors (each forming one half of a wheatstone bridge) with an AD620 InAmp & 47 Ohm resistor (to set the gain to ~1000). I then ran the signal through the MCP3008 Analog to Digital…
Anconia
  • 183
  • 2
  • 6
6
votes
3 answers

Why am I detecting two I2C addresses on the same board, and why do neither of them appear in the datasheet?

I have this MIKROE board wired up to an S2 Feather via the SDA and SCL pins. The MIKROE board is powered by the Feather via 3V3 and GND. I have 2 kΩ pull-up resistors to 3V3 on the SDA and SCL pins. When I don't use pull-ups, I can't detect any…
5
votes
1 answer

Interfacing an old spectrometer with PySerial

I asked this question on the Engineering StackExchange and someone said it might be more appropriate here. I want to interface an old Shimadzu spectrophotometer (Model UV-1601, manual here) through its RS-232C port, which is described in the manual…
Omnistic
  • 53
  • 5
5
votes
3 answers

ESP8266-12E MicroPython Unable to access REPL (Python prompt)

I am trying to install MIcroPython Firmware on my ESP8266-12E chip. I am using esptool.py to flash the firmware. I have successfully uploaded the firmware esp8266-20170612-v1.9.1.bin followed by a flash_erase. I have used following commands to flash…
4
votes
1 answer

FSK Modulation in Python

I am currently writing a script that uses I/Q data to do FSK modulation. My question is about the FFT plot. I expected to have a peak at 1Hz and 2Hz which are the frequencies that represent binary 0 and 1, however I have peaks at 2 and 4Hz. I…
PrematureCorn
  • 558
  • 3
  • 17
4
votes
5 answers

Python serial between Arduino and Raspberry Pi: Data is modified upon reception

I'm using an Arduino for sensor readings and sending them to a Raspberry Pi via USB, using PySerial for data reception. It works great, except for the fact received data is awkwardly modified (And set as constant). For example, I'm reading voltages…
Ahmed Farid
  • 169
  • 2
  • 2
  • 8
4
votes
1 answer

Using Python to simulate an LTspice netlist

I am new to Python, and I want to simulate LTspice circuits automatically using Python. I added the library ltspice and scripted a fair amount in order for Python to automatically generate an LTspice netlist I want. The problem I am facing is that…
user251019
4
votes
1 answer

Am I using Shannon-Hartley Theorem and thermal noise correctly here?

I'm trying to learn about noise, sensitivity, and the Shannon-Hartley theorem, and I'm using some specs for a LoRa node IC to try it out. The Shannon-Hartley theorem says that the maximum data rate \$C\$ is given by $$C = BW \ log_2 \left(1 +…
uhoh
  • 3,399
  • 2
  • 23
  • 63
3
votes
1 answer

Digital Potentiometer (MCP4131) with Raspberry Pi

I'm very new in electronic stuff. I'm used to develop for desktop and mobile applications not for hardware products. I try to wire up my Raspberry Pi board with an MCP4131 digital potentiometer. But it's not very easy to understand. I tried to build…
dannyyy
  • 139
  • 1
  • 1
  • 2
3
votes
1 answer

How does LTSpice solver know the type of the component?

I am doing automation of LTSpice using PyLTSpice library in Python. I need to know the types of the components in the netlist or in the raw file. How can I know programmatically that R1 corresponds to a resistor, and that C1 is a capacitor? And…
Rémi Baudoux
  • 292
  • 1
  • 11
3
votes
1 answer

JFET Id calculation mismatch in SPICE

I'm simulating the following circuit in PySpice: simulate this circuit – Schematic created using CircuitLab In this configuration, the N-JFET is always in saturation mode, as you can see by the plot of Vds - (Vgs - Vto) = Vds - Vgt, which is always…
edwillys
  • 96
  • 6
1
2 3
13 14