Issues with Atmega 1280 based boards

This forum is dedicated to software development related to MultiWii.
It is not the right place to submit a setup problem.
Software download
Post Reply
User avatar
dramida
Posts: 473
Joined: Mon Feb 28, 2011 12:58 pm
Location: Bucharest
Contact:

Issues with Atmega 1280 based boards

Post by dramida »

Today i flew my octocopter with atmega 1280 and dev0714 software.

2 issues:


- main status led is still on pin13, and couldn't change the buzzer led and status led accordingly to Alex Mega FINAL specs :https://spreadsheets0.google.com/spreadsheet/pub?hl=en&hl=en&key=0As_pEI-_SlWGdGt0RC1jd1pHeGxPUXBYa1ZPUE1vNEE&output=html

- after acc calibration, further tweaking of stable attitude with full throttle and right stick movements aren't working for mega.

Alexinparis
Posts: 1630
Joined: Wed Jan 19, 2011 9:07 pm

Re: Issues with Atmega 1280 based boards

Post by Alexinparis »

Hi,

You're right about the LED pin assignment.
It's still not included.
to modify it on PIN 30:

Code: Select all

  #define LEDPIN_PINMODE             pinMode (30, OUTPUT);
  #define LEDPIN_SWITCH              PINC  |= (1<<7);
  #define LEDPIN_ON                  PORTC |= (1<<7);
  #define LEDPIN_OFF                 PORTC &= ~(1<<7);


after acc calibration, further tweaking of stable attitude with full throttle and right stick movements aren't working for mega.

It's maybe a ROLL rc stick range problem (should be more than 1100-1900) ?

User avatar
dramida
Posts: 473
Joined: Mon Feb 28, 2011 12:58 pm
Location: Bucharest
Contact:

Re: Issues with Atmega 1280 based boards

Post by dramida »

Thank you Alex, now ledpin is on 30 and working.

Please tell me how to program Buzzer pin on 32. This is my code actually:

#define BUZZERPIN_PINMODE pinMode (32, OUTPUT);
#define BUZZERPIN_ON PORTC |= 1<<6;
#define BUZZERPIN_OFF PORTC &= ~1<<6;


The range of rol and pitch is 1050-1950 and the status led confirms the setting of acc. I want to test the effect in flight.

Alexinparis
Posts: 1630
Joined: Wed Jan 19, 2011 9:07 pm

Re: Issues with Atmega 1280 based boards

Post by Alexinparis »

nok ;)

PIN 32 is associated with PORTC 5 and not PORTC 6
it should be
#define BUZZERPIN_ON PORTC |= 1<<5;
#define BUZZERPIN_OFF PORTC &= ~1<<5;

see: http://arduino.cc/en/uploads/Main/ardui ... ematic.pdf

Post Reply