Episode #125 of the Stack Overflow podcast is here. We talk Tilde Club and mechanical keyboards. Listen now

Questions tagged [microcontroller]

A device which includes a central processing unit (CPU), memory, and (generally) an assortment of I/O peripherals (UART, ADC, DAC, general-purpose I/O, I2C, etc.) in a tightly-coupled standalone package.

Filter by
Sorted by
Tagged with
0
votes
0answers
21 views

Water Level Sensor with SPI or I2C Interface

I would just like to know if ADC121C021 can be used as a water level sensor? Or if there are any other water level sensors with an SPI or I2C interface that I could use, please recommend them. Thank ...
0
votes
0answers
21 views

What's the difference between sam and sam0?

I'm wanting to deep dive into learning about microcontrollers and took on the personal project to write my own bootloader. First, though, I'm just trying to flash anything to it with my JLink. I'm ...
0
votes
1answer
39 views

best practices in detecting relay contacts status

Currently i'm experimenting with 12VDC energy meters latching relays and at least for me the feature of detecting status of contacts ( required by some clients ) which is built in as in the diagram ...
0
votes
0answers
65 views

How do I perform division of two numbers in PIC16F877A in assembly language?

I'm currently using MPLab x IDE for PIC16F877A I want to divide two numbers and find out the quotient ( Let the two numbers be 10 and 4) and store in some register. I was thinking of a loop which ...
1
vote
3answers
346 views

If a module is “arduino compatible”, does that necessarily mean it isn't compatible with other microcontrollers?

I'm trying to find a GSM module to pair with a PIC32 microcontroller for a project and I've found some nice ones. The one I'm really interested in is the SIM800C GSM module. Many of them say they are "...
0
votes
6answers
147 views

Is there a switch that can be made when it is spun around a given axis, like a gyroscope solenoid?

Given in the title, I'm looking to design a small embedded system that only turns on when the part it's inside is spinning. The electronics is completely enclosed. I've done some googling for rotary ...
0
votes
1answer
97 views

Shorting the crystal

Just curious to know what will happen incase I short the Pin1 and Pin2 of my crystal while my board is ON. Crystal is connected to MPC5606S. What will go wrong and why ?
0
votes
1answer
35 views

How can I wire a microusb to a MIMXRT1062DVL6A?

I've never touched a barebones microcontroller before. I've been toying around with an Arduino and Teensy for a few years now. Recently I've been itching to ditch the comfort of those buttercup ...
0
votes
1answer
25 views

What does _SFR_IO8(0x04) is doing? AVR

I'm trying to write a program in assembly to toggle the on-board LED of the Arduino MEGA2560 in assembly. To do so I just have to indicate the direction of the pin (13 in this case which is PB7) as ...
0
votes
0answers
26 views

Relay Switching MCU Hanging/Reset

I am working on samD21 MCU to control the 16 relays. I am also using a circuit to detect the input AC switch status On/OFF (Connected serially to the relays). This is connected through optocoupler ...
1
vote
1answer
40 views

power consuption of internal 32kHz RC oscillator

I am looking for the typical power consumption of the OSCULP32K (Ultra Low Power Internal 32kHz RC Oscillator) of ATSAMC20J18A. Found nothing in family datasheet so far, only XOSC32K. Can I expect the ...
0
votes
1answer
66 views

What is the problem in my timeout implementation?

I'm trying to use a DHT22 (temperature and humidity sensor). Here is its datasheet: DHT22 Datasheet In first few seconds, I can get values. But after a while it gets stuck in here: So I tried to ...
0
votes
1answer
24 views

AT90CAN128 iocanxx.h vector numbers

The vector numbers in this header do not match the vector numbers in the manual AT90CAN128 doc7679 pdf Section 8.1 They appear to be one position out Can anyone advise on which is correct?
0
votes
1answer
39 views

How to ignore an undesired short output signal coming from arduino?

I'm currently programming a Nodemcu ESP8266 board, fully compatible with Arduino IDE. The project drive a relay board with a GPIO pin set as output. You can see the board pinout in the following ...
0
votes
1answer
30 views

DRV8889 SPI Commands

I've been having some issues diagnosing the relationship between writing to the registers through SPI commands and stepping the motors. That is, it seems like when I write SPI_STEP=1 (and STEP=1) to ...
-8
votes
0answers
88 views

I don't know what is this [closed]

So, I really don't know what is this
0
votes
1answer
58 views

What's best method to synchronize with main AC voltage?

I'm making an active rectifier, to make it work I need precise information about actual phase of main voltage. What I need: 1) exact moment when the positive section of sine wave starts and ends. ...
0
votes
1answer
26 views

FIFO Clock Setup for CMOS Detector

When attempting to construct a miniature laser beam profiler with the Omnivision OV7740 CMOS detector and an Arduino Due, I am running into some problems with FIFO reading/writing. From the datasheet, ...
-2
votes
0answers
26 views

Using an MCU plus an SoC like the TX2 to synchronize multiple CMOS Cameras

I have been looking at various options to obtain synchronized images from three or more cameras. The options available for the TX2 are just simply out of my price range. I accept that of course I ...
0
votes
1answer
41 views

Writing on one flash memory location could affect whole memory page

I am working on designing energy meter using PIC18F46K80. When the power goes off the meter store data on the flash memory (credit and so). Meter power supply stores enough energy to supply the ...
0
votes
1answer
38 views

Is it possible to send data while receiving audio with a bluetooth module

BM64 bluetooth module supports the following profiles : A2DP 1.3, AVRCP 1.6, HFP 1.6, HSP 1.2 and SPP 1.2 Using the A2DP I can stream audio output to a speaker as it is for a sink, thus a speaker. I ...
0
votes
0answers
47 views

high current passing through mosfet is damaging the nrf52

simulate this circuit – Schematic created using CircuitLab recently trying to make a led strip that can be controlled over bluetooth. I need high currents up to 10A. for the test purposes I ...
5
votes
2answers
2k views

RX vs TX operation in Software UART

I am short of 1 UART in my MCU. I needed 4 but so far what I have found suitable is an MCU that has 3 UARTs in it, STM32F103. So the 4th one I will have to implement in SW. Each of my individual ...
0
votes
2answers
188 views

How to turn a coffee machine on/off with a microcontroller? [on hold]

So the thing is, I'm a computer science major and working on an IoT project which is a coffee machine powered by a Particle Photon and controlled with an Amazon Alexa skill. The problem is I have ...
1
vote
1answer
53 views

Detecting movement of a mechanical ring using optical sensors

I need help deciding on which sensor to use for my current home project. Basically I'm trying to replicate the Numio Control but at much cheaper cost. If it is successful I will publish the result ...
0
votes
0answers
46 views

Parallel LTC3127 based software controlled supercapacitor charger

I am trying to charge 3 supercapacitors rated for 2.7VDC-300F connected in parallel, giving a total of 900F@2.7V. The IC I am trying to use is the LTC3127 from Analog Devices(Linear Technologies). I ...
2
votes
3answers
85 views

How to find an MCU with specific characteristics? [closed]

I am trying to find an MCU in which there are some specific requirements for I/O peripherals (such as UARTs, SPI, I2C, etc). I also want to be able to search by the footprint size. Should I go to each ...
0
votes
1answer
24 views

How to set up clock for the STM32 Nucleo-64 with libopencm3/rtos

I was using this code from github on a blue pill. Now I would like to adapt it for STM32F401 on a Nucleo-64 board. I tried changing the GPIO to A7 and attaching an led (which lit up when I attached it ...
0
votes
1answer
54 views

Questions regarding voltage divider for micro controller sensing

I am beginner trying to develop two voltage sensors for attiny85 microcontroller. I have two separate voltage levels that I want to sense using the attiny. One of the voltage supply is 0V-5.5V and is ...
0
votes
1answer
100 views

PIC Microcontroller ADC not functioning

I coded an assembly script to take the input values from two LDRs in parallel. Then my microcontroller was supposed to convert this analogue input into an 8-bit digital value (omitting the 2 LSBs). ...
0
votes
0answers
39 views

Impacts of low-pass filter on micro-controller board

I have a micro-controller board, driving small DC servo motors and I control the angle via a PWM signal (50 Hz) and everything is alright. However, there is an oil gas motor, running next to the ...
-2
votes
3answers
153 views

Microcontroller - GPIO [closed]

I have a digital input to a microcontroller in the +5V Domain. This digital input is connected to the Microcontroller. The output of the Microcontroller is connected to an LED Initial LED Logic : ...
0
votes
1answer
67 views

IC design future [closed]

Looking around me in the electronics industry I get the feeling more and more that core IC designing will eventually be replaced by micro controllers, Soc's and programming in C. Are there technical ...
-1
votes
2answers
78 views

Can I use C++ stl in avr-gcc?

I have implemented C++ queue in my codes, those I run on my PC. Now I'm programming an ATmega128 micro-controller to implement a .c code. Can I use that ...
-1
votes
2answers
45 views

Interfacing 4*4 keypad avr-gcc [duplicate]

I have this function for a 4x4 keypad: ...
0
votes
0answers
15 views

Segmented LCD Driver HT1622/HT1621 interface type unclear

I've been leaning working on using and interfacing a microcontroller with an HT1622 + a custom segmented LCD. IMO the datasheet of the IC is very small and left me confused ; is the interface SPI ? ...
2
votes
2answers
257 views

avr-gcc keypad interfacing code problem

I have this function to read key press from a 4x3 key-board: ...
-1
votes
2answers
60 views

Can I use a 3.3v tolerant microcontroller to drive IR leds that require 5v with a darlington array?

I have a microcontroller that is not 5v tolerant and I need to drive IR leds just like in the attached circuit. What I thought of doing is using the 5v line from my raspberry pi as the load voltage ...
1
vote
4answers
74 views

Current booster for relay

I have a DC power source which can provide up to 5V, 50mA (LabJack maximum output current, voltage bus-powered) and I want to power my relay (SDT-S-105LMR2,000) with 5V, 100mA. I have an option to use ...
0
votes
1answer
75 views

LED lights up even though there is not supposed to be an output from the STM32

I'm using an STM32F103C8T6. I connected an LED to the pin PA5 and a tactile button switch to the pin PA0. I wrote the program as follows: ...
0
votes
2answers
57 views

microcontroller serial communication noisy on direct wire connection

I did a simple circuit to test data communication between two separate microcontroller circuits. The big X is actually two wires (not touching each other) that connects the two circuits together. ...
1
vote
1answer
56 views

Replacing switch without transistors

I have a little keyfob style remote that I want to mod. It runs on a 3 volt button cell. I want to control the three switches with an ESP8266. The switches are connected to ground, and directly to a ...
0
votes
1answer
64 views

Which pins support i2c protocols?

I have a ESP32-WROOM-32D , it support I2c protocol but when i refer the i2c pins(SDA,SCL) in datasheet ,i couldn't find . datasheet is given below. which pins that support i2c protocols? ...
0
votes
0answers
63 views

AVR ATMEGA168 UART behaving strangely

I am new to AVR and microcontrollers and I am trying to get the UART working correctly on my Atmega68 chip. When I transmit data from my chip my PC terminal program receives them as weird symbols. I ...
3
votes
1answer
141 views

MeanWell 3-in-1 dimming

I've got a constant current MeanWell LED driver that has 3-in-1 dimming (100k potentiometer, 0-10V signal or 10V PWM), and would like to control the dimming with a microcontroller. I found a few ...
0
votes
3answers
58 views

Determining when a serial connection is opened

I have a PIC24FJ MCU with an FT232RL USB to UART controller. My design has end users opening a serial connection to my MCU to set parameters and get debug information. My question is: How can I tell ...
1
vote
1answer
77 views

How can this PWM converter circuit be improved?

This circuit is intended to use a 1-10Hz PWM signal as input and produce a 1-10kHz 10A PWM output. It will be used for controlling the speed of a water pump: GP1352 The PCB will be ordered with (only) ...
0
votes
0answers
87 views

Help me choose the communication protocols that I need

I am developing an industrial sensor using a sensor IC and an ARM MCU which communicate via I2C. The data size is 3 bytes. Because the environment in which the sensor is located is harsh ( high ...
1
vote
1answer
69 views

Can I power a MOSFET from my uC in this way?

The uC is a PIC10F220, which if I read the datasheet correctly can supply 25mA absolute maximum on its pins. The MOSFET that drives the load is actually 4 pcs NCE0140KA in parallell, but drawn as one ...
0
votes
1answer
44 views

How to use output PWM in AVR

I have this code to blink an array (8-led) of led one after one: ...