Show Posts
Pages: [1]
1  Using Arduino / Project Guidance / Re: Using ATMega328 on breadboard on: January 29, 2012, 03:47:00 pm
Thanks John S!  I'll have to give that a go!

John Wasser- just so I don't blow something up in testing, is the following schematic (in terms of power rails) correct for a +-2.5V supply?


Thanks for the copious amounts of help to the both of you.

EDIT - I should probably have an LPF on that AREF pin, I'll add that into the schematic.  Oops.
2  Using Arduino / Project Guidance / Re: Using ATMega328 on breadboard on: January 28, 2012, 01:11:17 am
Be sure to disable the auto-reset on the UNO.  After uploading ArduinoISP connect a 1 to 10 microfarad capacitor from Reset (+) to Ground (-) or, alternatively, connect a 100 to 120 ohm reeitor from Reset to +5V.

Hmm, I've tried the resistor to high but not the cap to low.  I'll give that one a go when I get a chance, thanks!

FWIW, I don't need a resistor or capacitor. I don't know why if everyone else does?

1. Upload the ISP sketch to your UNO
2. Close the IDE (I'm using 0023)
3. In preferences change upload.using=bootloader to upload.using=arduinoisp
4. Reopen IDE, select the board version you want to upload to (nano, UNO, attiny, ect. I use UNO when it's a standalone 328)
5. Connect all appropriate wires from your UNO to the board you want to upload to.
6. Upload your sketch with the upload button.

Perhaps there's a bit of a mis-communication here.  The chip I will be using does not have a bootloader.  The steps you listed seem fine for a chip that already has a bootloader but mine will not which is why I wanted to use the Arduino as an ISP.  Aside from the preference file changes (I changed it right in the IDE) I already performed those exact steps to no avail, unfortunately.
3  Using Arduino / Project Guidance / Re: Using ATMega328 on breadboard on: January 27, 2012, 03:25:51 pm
You can?  I was trying and I kept getting avrdude errors.  Had the ISP sketch and the boards.txt files all updated and it still didn't work so I just assumed that the page was still relevant.  Do I just follow the same steps outlined in the tutorial or is there something special that needs to be done?
4  Using Arduino / Project Guidance / Re: Using ATMega328 on breadboard on: January 27, 2012, 11:49:23 am
Ok, that's what I was hoping.  Now, just to be completely clear, I am using 2.5V as a reference for my analog reads.  If I am using the -2.5V rail as ground, I will have an analog reference range of 5V (from +2.5 to -2.5), correct?
5  Using Arduino / Project Guidance / Using ATMega328 on breadboard on: January 27, 2012, 11:12:22 am
Hi all.  I'm working on a project and have opted to use an Arduino for development.  The chip will be on a PCB in the end but I only have +-2.5 V rails to my disposal.  Will the ATMega that I took off my Arduino Uno be able to run off of 2.5V VCC (using the external 16MHz clock)?  If not, would I be able to connect the GND of my Arudino to the -2.5 rail in order to achieve the required 5V drop?  I haven't been able to find any material on the atmega chips to give be a definitive answer.  Obviously, my other option is to burn a bootloader onto my chip that uses the internal 8MHz clock but I am incredibly pressed for time and found out about 5 minutes ago that I cannot use my Uno as an ISP which really limits my options.

Hopefully someone can help me out with an answer!

Thanks.
6  Using Arduino / Networking, Protocols, and Devices / Bluetooth Communication using Sparkfun BluetoothMate Silver on: July 07, 2011, 01:29:27 am
I'm currently working on a project where I need to get my Arduino Mega2560 communicating over bluetooth (using SparkFun's Bluetooth Mate Silver) to a Wiimote.  After quite a bit of work I seem to be stuck and can't get anywhere.  I am having SEVERE problems debugging since I can't seem to view any serial output on my monitor and the only known succesfull command I have sent to the module was to rename it (as I can see the name on my Android phone- currently my only active debugging tool).  Is there anyone that actually knows how to work with these Bluetooth modules that can help (all the help online just seems to be for connecting to a PC which I do not want to do).

Thanks in advance!

Here's my code:
Code:
#include <avr/io.h>
#include <NewSoftSerial.h>

#define WIIADDR          001B7A3E9745
#define ANDROIDADDR      64A769C453A6


int bluetoothTx = 10;                  // TX-O pin of bluetooth mate
int bluetoothRx = 11;                  // RX-I pin of bluetooth mate

NewSoftSerial bluetooth(bluetoothTx, bluetoothRx);

void setup()
{
  Serial.begin(9600);                  // Begin the serial monitor at 9600bps
 
  bluetooth.begin(115200);             // The Bluetooth Mate defaults to 115200bps
  bluetooth.print("$$$");              // Enter command mode
  delay(100);                          // Short delay, wait for the Mate to send back CMD
  bluetooth.println("U,9600,N");       // Temporarily Change the baudrate to 9600, no parity
 
  bluetooth.begin(9600);               // Start bluetooth serial at 9600
  bluetooth.print("$$$");
  delay(100);
  bluetooth.println("SM,0");           // Set BTMate to slave
  delay(100);
  bluetooth.println("SN,BTMate");      // Rename Bluetooth Device
  delay(100);
  bluetooth.println("IS,5");           // Begin Inquiry Scan
  delay(100);
  bluetooth.println("C,64A769C453A6");  // Connect to Android phone
  delay(100);
  bluetooth.println("---");            // Turn off command mode
}

void loop()
{

}
7  Using Arduino / Project Guidance / Wiimote Robotic Control on: July 03, 2011, 03:45:12 pm
Hey guys, part of a robotics project I decided to tackle for one of my classes is to control a robot (specifically a quadrocopter) using a Wiimote.  Initially I read over the Wiibrew wiki for the wiimote [link] and it seemed quite feasible so in a bit of haste I decided to buy the SparkFun Bluetooth Mate Silver.  I've been trying to just test it to make sure it's working and I ran into a few problems:
  • I cannot view Serial output via the Serial Monitor (though using some LEDs I can see SOMETHING is happening)
  • I'm not entirely sure I can even connect to the Wiimote using this method

For the first problem- are there any good workarounds where I can view the serial output as well as send data via serial? It seems I can only do one or the other.  the SoftwareSerial library would be an option if it didn't have baud rate limite of 9600 (the bluetooth module runs at 115200).  

For the second problem- well, it really says it all.  Can I even connect the wiimote to my arduino using the Bluetooth Mate as an intermediary?  My second option (one that seems like less of a nightmare to program but more of an expense) is to send the Wiimote info through a PC and then back out to the Arduino via bluetooth.  I'd prefer to solve it without the use of a PC but if it is absolutely necessary I can concede on that point.

If ANYONE can help, offer more reading material, ANYTHING, I'd be extremely grateful!

And for reference, my current code:

Code:
#include <avr/io.h>
//Wii Address = 00:1B:7A:3E:97:45

void setup()
{
  // put your setup code here, to run once:
  pinMode(31,OUTPUT);
  Serial1.begin(115200);   // opens serial port, sets data rate to 9600 bps
  Serial1.flush();
  //enter command mode
  digitalWrite(31,HIGH);
  Serial1.write('$$$');             // CMD mode
  delay(100);
  Serial1.write('SA,1');            // Require BT Authentication
  delay(100);
  Serial1.write('SR,001B7A3E9745'); // Store Remote BT address
  delay(100);
  Serial1.write('C');               // Attempts to connect to remote address
}

void loop()
{

}
Pages: [1]