Tagged Questions
3
votes
3answers
82 views
Energy efficient one button on/off with extra function
(Old) cellphones have a button to turn it on (when off), end a call (when on, short press) or turn it off (when on, long press).
I need something similar for a microcontroller. The device is ...
-3
votes
0answers
39 views
How to Start with Pic18f controller and ENC28J60 configuration [closed]
I am a newbie to ethernet control operation using pic18f controller and dont know how to configure my Olimex ENC28J60-H Board with PIC18F controller using SPI communication. However i have written ...
-2
votes
0answers
67 views
How to stabilize the value of ADC in PIC microcontroller? [closed]
I have been designing auto range multimeter using PIC microcontroller. Having problem in the auto range switching due to the ADC reading since ADC reading for particular voltage varies by 100 to 150 ...
4
votes
3answers
85 views
Failed to get Device ID - PICkit 3 & PIC16F684-ICD & AC16205
Like it is already mentioned in the title I have question regarding this dev stack:
MPLAB X IDE v1.80
PICkit 3
PIC16F684-ICD (datasheet)
AC16205
There is image of how things are connected (I don't ...
4
votes
1answer
226 views
Microcontrollers with extreme high temperature range
I am looking for components which works at high temperature. Especially I am looking for microcontrollers which works at 180 °C to 200 °C. I am designing downhole electronics for oil and gas ...
0
votes
2answers
259 views
Creating a lookup table in a microcontroller using in C
How can I create a lookup table in a microcontroller using C? I have one input and one output and want to implement a lookup table in C.
39
votes
9answers
3k views
How can anyone use a microcontroller which has only 384 bytes of program memory?
For instance a PIC10F200T
Virtually any code you write will be larger than that, unless it is a single purpose chip. Is there any way to load more program memory from external storage or something? ...
0
votes
1answer
55 views
PIC32 Issue with using JTAG Pins as Analog Inputs
I'm trying to read in a value using a few analog pins on a PIC32 (MX775F512H), including RB12-- part of the JTAG pins on the device. The device the board is reading from works great, but the board ...
2
votes
2answers
106 views
How can I control 8 LEDs with a timing delay with only one microcontroller (PIC12) written in Assembly?
I can have 5 I/O pins enabled. I'm just confused on how to control them individually.
6
votes
3answers
255 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 ...
-2
votes
1answer
64 views
How to search date wise in flash memory using microcontroller?
I am developing a data logger in which I am using 8 MB of flash memory to store the sensor data with date and time. I am using RF interface to transfer that data to PC. I am planning to have PC ...
2
votes
1answer
83 views
Bit Banging UART
My full code is located here.
Basically, I'm transmitting to an Arduino, and I'm not receiving the correct value (you'll notice I'm trying to send d'22'). Here's the method where I actually bit bang ...
0
votes
1answer
94 views
How to use the PIC16F628A's PORTA,4-7 as inputs?
I'm working on a countdown timer and I want to use the MSN of PortA for my switches.
I'm using MPLAB. I can't use C to program the PIC because the collage taught us to program in decimal, and they ...
5
votes
1answer
167 views
Serial Communication over 1 Pin?
Okay guys, I'm in a bit of a pickle here. I have the following circuit:
As you can see, pin 3 is my only output. I've actually already had this board printed, so there's not much room for ...
6
votes
3answers
137 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 ?
0
votes
2answers
68 views
How to Synchronize two RTC module one internal and other external?
I am developing a data logger based on PIC controller. The PIC has internal RTC but does not have pins for connecting battery so I am using pic's internal RTC to generate interrupt every second and ...
0
votes
2answers
80 views
Read from UART seems to overwrite while in buffer
I am reading sending data to a PIC32MX7xx using UART. The data frames are all 6 bytes long, no exception.
The problem I am facing is that when there are 6 bytes waiting to be read and I send another ...
2
votes
0answers
110 views
How do I convert this analog PID to a digital one?
I want to transform a type III analog PID into a discrete-time one so I can implement it on a PIC18F. The controller is for a buck converter.
When I apply the bilinear transformation to the analog ...
0
votes
1answer
60 views
PIC24H POT input to control LED blink delay not linear
Hello I'm using the PIC24H microprocessor and I wrote a simple program that takes input from a POT using analog input which is then set to a modulus value of delay. It does seem to set the delay, but ...
2
votes
0answers
56 views
PIC16F877A latchup/glitching
I have a PIC16F877A microcontroller with a 19.6608 MHz crystal, wired for 12V ICSP. I can reprogram the chip just fine, and it runs almost flawlessly (it's blinking an LED right now as I type). Only ...
4
votes
4answers
192 views
uC platforms to consider for faster CPU and 30+ GPIO pins
I am building a Persistence of Vision project with 120 RGB leds (=360 total lines to be controlled). We have settled on the TLC5940 for driving the LEDs (and could be open to changing this), however, ...
0
votes
1answer
165 views
Can I remap a car\bike ECU using CAN bus?
I am thinking to use something like this to connect an Arduino to a motorbike engine control unit (ECU): Arduino CAN-Bus Shield with uSD Card Holder.
I never did something like this; using CAN bus, ...
5
votes
3answers
236 views
How do I program a PIC12?
I have a PIC12F675 that I need to program. I'm using a Pickit 2 and the Pickit 2 software. Supposedly I should be able to program it using this circuit, but the Pickit 2 software is not detecting the ...
5
votes
1answer
106 views
How can I lower output impedance of an accelerometer?
I'm planning to use an accelerometer with a microcontroller to measure acceleration. The issue that I have ran across is that in PIC microncontrollers the ADC requires that the connected analog ...
1
vote
2answers
250 views
PIC16F877A (with LCD) not working
I have designed a PIC18F877A micro controller project to read temperature from an LM35 using ADC, display it on an LCD and transmit it to a serial port.
When the program starts, sometimes it shows a ...
2
votes
3answers
159 views
Why pic18fxxx microcontrollers is better for C language
Pic18fxxx family has a lot advantages and improvements from the pic16fxxx family of microcontrollers. What is the particular feature that make them better for C programming than the pic16fxxx devices? ...
5
votes
2answers
131 views
Save energy with PIC project
I want to implement a device with 2 push buttons. When I press the first button, it will increment a counter. When I press the second, the number of times the first one was pressed (counter content) ...
0
votes
1answer
166 views
RE: USART @115200 on PIC18 explorer (PIC18F8722)
I have tried to initialise UART1 and communicate with a PC with no success @115200, as the SPRTG register, which needs to be 4.4253, cannot be so without introducing a large error.
The board has ...
2
votes
3answers
149 views
A syntax error in my C18 program code
I'm using the MPLAB IDE X v1.41 with C18 compiler to pragram a PIC18F45K20. My objective is to retrieve image data from a completely built image sensor board and display on the computer using the ...
3
votes
3answers
170 views
PIC - Time to enter the interrupt
I am using the PIC18F2550 and I wanted to know how much time takes between an event happens (e.g. ADIF)and the interrupt routine starts. In other words, how much time the "interrupt system" takes to ...
5
votes
1answer
416 views
Interrupt Service Routine in C - function at specific address
I need to add an Interrupt Service Routine (ISR) to existing code in C for a PIC18F4620 and a PIC18F46K22. As you can see in section 9 (of both datasheets), these devices have multiple interrupt ...
7
votes
4answers
283 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 ...
2
votes
1answer
179 views
Reading analog input pic18
I'm trying to read an analog input on a PIC18F65J11, and I'm having trouble. I don't think the pin is set up correctly because I'm getting a 0 for the value I read in, and the input is measured to be ...
5
votes
5answers
304 views
Pull-up and Pull-down Resistor Usage on Input or Output MCU Pins
Are pull-up/down resistors (whether internal or external) only needed for MCU INPUT pins? In contrast, an MCU pin configured as an OUTPUT "knows what level it's at" because it does the driving - a ...
2
votes
2answers
113 views
Sinking and Sourcing Current to and from a PIC24F Output Pin
Sinking and sourcing current refers to current going into and out of the MCU (respectively), right? If you configure a GPIO pin as an output, why would current ever go into the pin (since it's ...
0
votes
1answer
39 views
Value of FNOSC in the configuration of my code
I am using PIC24FJ64GA002 and I have configured my setting for PIC as following.
...
0
votes
2answers
147 views
General Questions about PIC24 MCU Input and Output Pin Impedance, Voltage, and Current
I'm having a mental lapse. Try and help me make sense of a few basic things concerning microcontroller pins at the hardware level, please!
Correct me if I'm wrong… in the circuit of Figure 1 (see ...
1
vote
1answer
228 views
How to change the frequency of PIC internal oscillator?
Internal oscillator of PIC16f884 doesn't change frequency in the following code:
...
0
votes
2answers
159 views
Using the C18 compiler on Mac OS X
I'm currently in a microcontrollers class, one where we use the PIC18F4550 and must use the C18 compiler (something Windows oriented and used for grading). I'm trying to install this on Mac OS X, and ...
2
votes
2answers
189 views
LED tachometer with PIC MCU (requires more current)
I've been working on an LED tachometer that will be installed on an open wheel race car. After putting the order through for the PCB I re-calculated the current draw and turns out the PIC's (16F877A) ...
2
votes
3answers
341 views
Using the PICkit3 and PIC18F4550
For my microcontrollers class, I am using an advanced 8-bit microprocessor, the PIC18F4550. I am trying to program it with a PICkit 3.
I have used the device datasheet and the PICkit 3 datasheet to ...
7
votes
3answers
339 views
Absolute address of a function in Microchip XC16
Device: dsPIC33FJ128GP802
I have some *.s files as follows
...
3
votes
1answer
86 views
PIC18 with ACT HC49/US XTAL
As part of my current project I need to ensure that my MCU (namely PIC18F4520) runs smoothly, minimizing the possibility of any interruptions. The datasheet ...
1
vote
1answer
186 views
How to get two buttons to work with the 16f628a - C, Hi-tech comp, mplabx
I'm just began exploring my new hobby - mcu electronics. I have bought an 16f628a after reading some forumposts suggestion that is a good mcu for beginners.
I have download mplabX, the hi-tech ...
2
votes
1answer
87 views
PIC (18 series) 12-bit Instruction Addressing?
I'm trying to find the 12-bit address in hex -- as well as the memory bank being used -- by the last instruction in the sequences listed below.
Before I list the sequences, it is my understanding ...
-4
votes
1answer
114 views
Starter PICs in all device families [closed]
I want a list of PICs that are easy to start with in every device family. That is:
8-bit: PIC10, PIC12, PIC16, PIC18
16-bit: PIC24F, PIC24H, PIC24E
16-bit ds: dsPIC30F, dsPIC33F, dsPIC33E
32-bit: ...
15
votes
2answers
735 views
C coding design - function pointers?
I have a PIC18F46K22 and program it with the XC8 compiler. In the end, I'll have a system like a pc with stdin and stdout. So in ...
0
votes
1answer
314 views
TMR0 interrupt pic microcontroller
I bought a development board from Matrix Multimedia, HP488(datasheet), but I dont know why I fail with a small program.
The program must flash a led with a delay (4 sec) using TMR0.
So, from my ...
2
votes
3answers
827 views
Starting with I2C on PIC18s
For a project I'd like three PICs (two slaves PIC18F4620, one master PIC18F46K22) to communicate over the I2C bus. Later on, more slaves may be added (like EEPROM, SRAM, ...). I'm writing the code for ...
1
vote
2answers
357 views
Current measuring with PIC
I know it is possible to measure analog voltages with the ADC peripheral of advanced PIC microcontrollers. There is no peripheral to measure current though.
Is it possible to convert a current to a ...
