Find Jobs
Hire Freelancers

fix interrupt in AVR

$10-30 USD

Fechado
Publicado há quase 7 anos

$10-30 USD

Pago na entrega
I made this circuit: [login to view URL] And this code: [login to view URL] There's a led in PB1 and a button in PB3. When the button is pressed, PB3 pin change its state from high level to low level, this produces an external interrupt. The code of this interrupt, makes the led turn on for 100ms. But this code, turn ON the led everytime the button is pressed/released, that means everytime PB3 change its state. TASK: I want the led to be turned ON, just when the button is released. (Make this by using interruptions)
ID do Projeto: 14065391

Sobre o projeto

20 propostas
Projeto remoto
Ativo há 7 anos

Quer ganhar algum dinheiro?

Benefícios de ofertar no Freelancer

Defina seu orçamento e seu prazo
Seja pago pelo seu trabalho
Descreva sua proposta
É grátis para se inscrever e fazer ofertas em trabalhos
20 freelancers estão ofertando em média $26 USD for esse trabalho
Avatar do Usuário
Hello Dear, I am an expert with more than 15 years of experience in the field of embedded systems, electronics and programming. I have all the development tools and hardware to develop the solution. Regards Ch
$50 USD em 3 dias
4,5 (64 avaliações)
6,3
6,3
Avatar do Usuário
FREELANCER RECOMMENDED ------------------------------------------------------ Can help... I am an Expert... Lets Start! Please start a Discussion with me and we can get started from there... Please check the past projects I have handled and check my reviews for what employers have to say about my work... Can start right now...
$25 USD em 1 dia
5,0 (6 avaliações)
4,9
4,9
Avatar do Usuário
Hi, You can easily check for the pin (PB3) value in the ISR and if it is high so it is rising edge. Best Regards, Ahmed
$25 USD em 1 dia
4,9 (11 avaliações)
5,0
5,0
Avatar do Usuário
dear Sir i can do this project. I can assure you that if you work with me once, you will always work with me for these kind of projects.
$25 USD em 1 dia
5,0 (11 avaliações)
4,1
4,1
Avatar do Usuário
hi, solution change this line MCUCR &= ~(1<<ISC01) | ~(1<<ISC00); // Trigger INT0 on rising edge to MCUCR &= ~(1<<ISC01) | ~(0<<ISC00); // Trigger INT0 on rising edge let me know
$25 USD em 1 dia
5,0 (5 avaliações)
3,8
3,8
Avatar do Usuário
buenas, tener delay en el ISR es mala idea, la mejor opción es usar una variable para detectar el cambio y hacer el resto en otra parte del código... incluyendo el filtro para el botón. Puedo solucionar el problema y entregar el código. un saludo, Gabriel
$30 USD em 0 dia
5,0 (4 avaliações)
3,6
3,6
Avatar do Usuário
A proposal has not yet been provided
$30 USD em 1 dia
5,0 (5 avaliações)
3,4
3,4
Avatar do Usuário
Hi there. Having worked with Atmel AVR controllers quite a lot, I feel like this feature will be quite simple to implement and I will ideally provide the completed program in under a day. Please feel free to contact me for further details about my skills and qualifications. Thank you.
$25 USD em 1 dia
5,0 (1 avaliação)
2,3
2,3
Avatar do Usuário
I can do it for you; just need to re-config interrupt , and modified the code Thanks
$25 USD em 3 dias
5,0 (1 avaliação)
2,3
2,3
Avatar do Usuário
Try this. This will power on LED when releasing the button, as you specified. Best regards. #define F_CPU 9600000UL #define FALLING 1 #define RISING 2 #include <avr/io.h> #include <util/delay.h> #include <avr/interrupt.h> char edge = FALLING; ISR(PCINT0_vect) { if (edge == FALLING) { edge = RISING; _delay_ms(50); // Remove button debounce MCUCR &= (1<<ISC01) | (1<<ISC00); // Rising edge } else { edge = FALLING; PORTB |= (1<<PB1); _delay_ms(100); PORTB &= ~(1<<PB1); _delay_ms(100); MCUCR &= (1<<ISC01) & ~(1<<ISC00); // Falling edge } } void SystemInit(void) { MCUCR &= (1<<ISC01) & ~(1<<ISC00); // Falling edge //MCUCR &= ~(1<<ISC01) | ~(1<<ISC00); // Trigger INT0 on rising edge PCMSK |= (1<<PCINT3); // pin change mask: listen to portb, pin PB3 GIMSK |= (1<<PCIE); // enable PCINT interrupt sei(); // enable all interrupts } int main(void) { DDRB |= (1<<PB1); DDRB &= ~(1<<PB3); PORTB |= (1<<PB3); //Enable Pushbutton pull-up SystemInit(); while (1) { } }
$15 USD em 1 dia
0,0 (0 avaliações)
0,0
0,0
Avatar do Usuário
A proposal has not yet been provided
$35 USD em 10 dias
0,0 (0 avaliações)
0,0
0,0
Avatar do Usuário
Hello! My name is Jackie. Currently, I am working as an embedded programmer. I have joined many projects to program firmware for micro controller. I am good at C/C++ and have a lot of experience of working with AVR. I make sure to finish your project well. Do not hesitate to contact me.
$30 USD em 1 dia
0,0 (1 avaliação)
0,0
0,0
Avatar do Usuário
A proposal has not yet been provided
$15 USD em 1 dia
0,0 (0 avaliações)
0,0
0,0
Avatar do Usuário
Hello, We are a team of embedded hardware and software professionals with experience in microcontroller based projects. Would like to know more about the project. Looking forward to work on this project. Please feel free to contact us for any further discussions. Thanks and Regards Techoviz
$20 USD em 3 dias
0,0 (0 avaliações)
0,0
0,0
Avatar do Usuário
hello i used some AVR products in my projects and i would like to help you with your task best regards Gehad
$10 USD em 0 dia
0,0 (0 avaliações)
0,0
0,0
Avatar do Usuário
I'm working for Active-Semi Company. I have 2 years experiment in embedded software. Please choose me :)
$10 USD em 1 dia
0,0 (0 avaliações)
0,0
0,0
Avatar do Usuário
Hi, I am experienced embedded systems designer and have been using AVR's for a long time and would love to work on this project. regards,
$25 USD em 1 dia
0,0 (0 avaliações)
0,0
0,0

Sobre o cliente

Bandeira do(a) SPAIN
Porto, Spain
5,0
7
Membro desde dez. 8, 2013

Verificação do Cliente

Obrigado! Te enviamos um link por e-mail para que você possa reivindicar seu crédito gratuito.
Algo deu errado ao enviar seu e-mail. Por favor, tente novamente.
Usuários Registrados Total de Trabalhos Publicados
Freelancer ® is a registered Trademark of Freelancer Technology Pty Limited (ACN 142 189 759)
Copyright © 2024 Freelancer Technology Pty Limited (ACN 142 189 759)
Carregando pré-visualização
Permissão concedida para Geolocalização.
Sua sessão expirou e você foi desconectado. Por favor, faça login novamente.