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.
7
votes
4answers
278 views
Can individual pins of different port of a microcontroller be mapped to a register and their values be changed when changing the register value?
Q: Can individual pins of different port of a micro-controller be mapped to a register and their values be changed when changing the register value?
Scenario: I have used up some pins from each ...
7
votes
2answers
1k views
ESD protection devices - necessary for MCUs?
I'm working with two chips on a board, a dsPIC33F and a PIC24F as well as a serial EEPROM (24FC1025.)
I've seen these little ESD protection devices in 0603 packages:
...
7
votes
2answers
615 views
Problems programming LPC1343 microcontroller in Ubuntu
When I copy a binary that works on a lpc1343 to the mounted usb-device representing the lpc1343 flash, the binary file is changed and does not work. Doing the same with the flash mounted via usb on ...
7
votes
2answers
255 views
Generating servo signal in atmega2560
I'm new to AtmelStudio. I need to know how to generate a servo control signal using timer modules of atmega2560. I'm using an Arduino Mega board. (please refer the last paragraphs of this page for ...
7
votes
3answers
321 views
Is it safe to run long I/O wires to a microcontroller?
I'm contemplating using an MCU sitting in my garage to read data from a couple of sensors, one of which may be as much as 10m distant. I'm not using analog sensors, as this question asks, instead, ...
7
votes
1answer
692 views
Arduino + gyro/accelerometer == flight controller …?
Can I use the combination of an Arduino Mega + MPU-6050 gyro/accelerator module instead of a flight controller? Is there something else needed?
It is said that the gyro/acceleration can be used to ...
7
votes
3answers
331 views
Absolute address of a function in Microchip XC16
Device: dsPIC33FJ128GP802
I have some *.s files as follows
...
7
votes
3answers
631 views
DIY FP - Implementing floating point math on a microcontroller without a hardware FPU
I'm working on a little personal project (targeting a Parallax Propeller, but this should be pretty generalizable) that needs floating point math.
The micro-controller I am working with does not have ...
7
votes
1answer
176 views
Current flow priorities in PSU / PSU review
Being an electronics hobbyist, I'm having quite a challenge to design a PSU, which must run both on batteries (during the night time) as well as on Solar energy (daytime). The device is intend to run ...
6
votes
5answers
5k views
How can I control many LED's with just a few pins on my micro?
I am using an Atmel ATTINY13 which has a 6-pin I/O. I'd like to control about 15 LED's but am unsure how to connect everything. Without multiplexing of any sort, it seems I'd only be able to control 6 ...
6
votes
4answers
1k views
Least expensive way to plug in a microcontroller into 120V (without wall wart or batteries)
I need to be able to power a Atmega168 by plugging it into a wall. The circuit is a little bit more complex but not too much. The Atmega168 needs between 1.8V and 5V at 200mA. The ideal solution ...
6
votes
7answers
365 views
Alternatives to using EEPROM
As I understand it, EEPROM is a part of a computer (in my case, an AVR microcontroller) which stores data, and holds on to it even when the device completely shuts down. It allows data to be written ...
6
votes
7answers
5k views
Encryption Library for Arduino
I am using an Arduino to read a keypad and open an electric strike upon keypad PIN entry. For this sketch I wanted to use some sort of lightweight encryption to store the PINs in EEProm.
Does anyone ...
6
votes
6answers
2k views
How do I sample a -2 V to +2 V analog signal with a PIC microcontroller?
I am using a PIC micro with a 10bit ADC to take readings from an analog signal with a frequency less than 300 hz. However that analog signal is in the range of -2 V and +2 V. How can I condition the ...
6
votes
4answers
1k views
Reading a 16-bit timer on an 8-bit MCU
Since an 8-bit MCU can't read the whole 16-bit timer in one cycle, this creates a race condition where the low-word can roll over between reads. Does the community have a preferred method of avoiding ...
6
votes
2answers
7k views
What is a boot loader, and how would I develop one?
I've met many projects in which an AVR microcontroller uses with a bootloader (such as the Arduino), but I don't understand the concept very well.
How can I make a bootloader (for any ...
6
votes
2answers
632 views
Sharing an oscillator between two ICs
I have a microcontroller and an FPGA on the same board. If they're both going to run at the same clock speed, can I just use one oscillator to clock them both? There seems like there is something I ...
6
votes
2answers
468 views
meaning of set low/set high
I often see those phrases in tutorials with microcontroller I/O. An example use is "set pin 3 high", or "set pin 5 low for 20 ms".
I also recall reading several different definitions on what that ...
6
votes
3answers
254 views
Switching from PIC to AVR [closed]
I have worked with PIC16 and PIC18s for over three years now and would like to get to know AVR as well. I have no specific project in mind, but would like to try around with the different ...
6
votes
5answers
370 views
What does it mean for a signal to have an amplitude below 0 dB?
I am a software developer (using high level languages like .NET,C,C++ etc) trying to understand how computers work at a lower level.
I understand that amplitude is always positive because it is ...
6
votes
2answers
1k views
What happens when data is written to LATCH?
This is what I found in PIC16F1947 data sheet:
Reading the PORTB register reads the status of the pins,
whereas writing to it will write to
the PORT latch. All write operations
are ...
6
votes
6answers
1k views
What is the reason my PIC16 multitasking RTOS kernel doesn't work?
I am trying to create a semi-pre-emptive (co-operative) RTOS for PIC x16 microcontrollers. In my previous question, I've learnt that accessing hardware stack pointer is not possible in these cores. I ...
6
votes
5answers
2k views
What is the simplest and cheapest way to interface with USB?
If I wanted to make a simple device that communicates with my computer, say maybe a switch that could mute my computer when turned on and off and plug it in via USB, what would be the cheapest and ...
6
votes
2answers
432 views
connecting devices with two different power supplies
I wanted to know if this configuration is fine with two different grounds. the microcontroller is powered up with 3.3V and the transistor is powered by 5V. Both grounds are separate.
My question is ...
6
votes
4answers
2k views
Accessories for Android devices with USB host
The Android Accessory SDK relies on the accessory having USB host. However, my understanding is that newer versions of Android (3.1, 2.4?) have USB host support in the kernel. And I know many ...
6
votes
6answers
443 views
Multi node bus options
I want a master node consisting of a TI Stellaris Cortex M3 core connected to what can be up to 32 slave nodes of TI MSP430 (or possibly more Stellaris slave nodes). These will be maximally 0.5 meters ...
6
votes
4answers
391 views
What is Arduino?
What is this Arduino concept that I keep hearing about? Is it a microcontroller family, or a demoboard?
Please include pictures in your answer, and if there are multiple possible items known as ...
6
votes
2answers
867 views
Op-Amp Slew Rate Requirements
After looking over this question and the answers received, it prompted me to wonder:
Given pulse signals generated by a uC, what kind of slew rate on an op-amp will you need to reproduce the waveform ...
6
votes
2answers
189 views
Data bus between uC and SRAM: what happens when both are writing concurrently?
My understanding of interfacing a standard SRAM chip is the following: When the host wants to write, the OutputEnable# is driven high to bring the SRAM data bus to High-Z and the host is driving the ...
6
votes
3answers
2k views
Control 220V AC line using MCU
I want to switch ON and OFF an incandescent bulb using MCU. Please suggest an electric switch (like relay or something) for 220V 50Hz AC line which can be used here. I would prefer something very ...
6
votes
1answer
154 views
What's a microcontroller “ordering code”?
I'm shopping for an ATtiny13A microcontroller for an Instructable, and I see lots of them offered online, but none are named just "ATtiny13A" — they're all things like:
ATtiny13A-PU
ATtiny13A-SU
...
6
votes
2answers
510 views
microcontroller low battery indicator
I am powering a board and circuit with a 9V battery (those alkaline ones). And I would like to read the 9V battery to keep track of how much power it has left. I have read that I can do this with a ...
6
votes
3answers
292 views
Embedded System LINT use
I currently develop embedded systems using a number of different compilers, the most common coming from IAR systems.
My love of hardware is what drives doing embedded systems and firmware. I however ...
6
votes
7answers
2k views
eZ430-Chronos Development on *nix?
So I just got my TI eZ430-Chronos Dev kit (a runners watch & eZ430 micro dev combined), and I am chomping at the bit to start playing around with my new toy. I have just a few issues the ...
6
votes
3answers
506 views
How do I measure loudness?
I was toying around with an idea for a digital musical instrument with breath control. I've successfully experimented with pressure sensors and they are probably the right way to go, but my first idea ...
6
votes
3answers
134 views
How to calculate day of the week for RTC?
I am using MCP7940 RTC from microchip it requires to enter the day of the week as part of updating RTC with date. So how should I calculate day of the week based on the date provided by the user ?
6
votes
2answers
410 views
driving a relay with transistor and Opto-isolator
I am very new in electronics. I am controlling a relay with stm32 micro controller. For the isolation I have used a 4N33 opto-isolator. As my relay coil needs around 250 mA, I used a mps222 ...
6
votes
4answers
1k views
Is this a good design for MOSFET H-Bridge?
I have been looking around trying to design a simple but working H-Bridge for an RC car motor (12V and 2~3A).
This bridge will be driven from a microcontroller and need to be fast to support PWM. So ...
6
votes
2answers
325 views
How to measure power consumed by mains device
I would like to measure the power consumed by a mains device. I have heard that it's not as trivial as simply measuring the average current, as the device may be resistive, capacitive or inductive, ...
6
votes
1answer
279 views
Interfacing with Nichrome heater
I'm using Nichrome wire for a heating application and just using some scavenged parts from a slow cooker. What would be the easiest way to turn on/off the Nichrome? I'm thinking of just having a ...
6
votes
1answer
2k views
How to measure pulse width of an IR signal using an 8-bit PIC?
My friend and I want to design a universal learning remote controller, like this one, for learning purposes. What we want to do basically is store and replay infrared pulses.
We want to detect 36kHz, ...
6
votes
5answers
981 views
getting started with NXP microcontrollers - Programmers/IDEs/Compilers/Eval Boards
I asked this question ago. (Don't need to read it to answer this one)
out growing 8-bit AVRs, not sure where to move on to
I really liked the answers about the NXP line of microcontrollers. I'm ...
6
votes
3answers
1k views
Wide voltage supply for PIC microcontroller
I am looking to power a PIC microcontroller with a supply voltage that ranges from 4.5V to 18V.
This will be a battery powered device so I would like to conserve power, ie. linear regulators like the ...
6
votes
4answers
467 views
Turning the TV-B-Gone into a universal remote
Ok, so I don't really want to turn the TV-B-Gone into a universal remote, specifically, but I would like to know/learn how I could go about creating a universal remote (I merely thought that working ...
6
votes
1answer
109 views
Is DIL (Dual in Line) a standard?
Here's a picture of two chips next to each other:
The ATTiny85 and the nRF24l01+.
The ATTiny85 will fit in a standard 8Pin DIL, but the nRF chip won't because the connectors are more tightly spaced ...
6
votes
3answers
673 views
EEPROM read/write errors on dsPIC
I'm running a Microchip dsPIC30F6012a. I have this chip on several PCBs, all running the same software, and observe the same problem on all of them. This implies a systemic problem, not a one-off ...
6
votes
1answer
125 views
How do I select long-lived microcontrollers for designs so we do not have to revamp our product if they stop making the chip?
I'm working for a small toy company who has all of their engineering/programming in China. They have had a few of their electronics product needing revamping because the microcontroller that the ...
6
votes
1answer
2k views
Computer control of RC helicopter
I am interested in controlling an RC helicopter using a desktop/laptop computer. I see two possible approaches for such a project:
Wire the RF remote to a PC either directly or through some ...
6
votes
3answers
529 views
PIC18 Memory Management
The limited stack size of budget PICs is a problem area and I have adjusted my code to accommodate this reality. I currently adopt a rough paradigm of grouping closely related functions into a module ...
6
votes
4answers
212 views
Protecting Microcontroller Input Pins from Soft Power Switch
I'm working on a soft power switch for a microcontroller where a momentary switch can turn the circuit on (including microcontroller), and then when the switch is pushed a second time, the ...