Show Posts
Pages: [1]
1  Using Arduino / Sensors / Re: CapSense Code has changed significantly, where is the old code? new not so good on: September 12, 2012, 12:31:35 am
thanks RIDDICK
the mulitpler looks very cool. I'll try it out
thanks
2  Using Arduino / Sensors / CapSense Code has changed significantly, where is the old code? new not so good on: September 10, 2012, 03:11:35 pm
I'm wanting to use capsense library, and have been playing around this in the past, and its worked pretty well. Working on a project now and go back and search for capsense code and its changed significantly, looked pretty interesting so I tried it out but its not as sensitive and don't see how it can be made more sensitive, doing a bit of a search and it seems that the old capsense code links all point to this new code, http://arduino.cc/playground/Code/CapacitiveSensor?from=Main.CapSense
So my question is
1) does anyone know how to make this more sensitive, I want to use it for proximity not direct touch. ( actualy its touch though a couple of layers of 3mm opaque perspex)
2) where is the old code and information, looking at the history it doesn't look like this code was ever the old capsense code that I know and used i.e. #include <CapSense.h>

3  Using Arduino / Networking, Protocols, and Devices / Re: mpr121 - help reading filtered data on: June 03, 2012, 06:37:16 pm
Hi
has anyone got this working with Arduino?
4  Using Arduino / Programming Questions / How do I debug a new class in arduino IDE on: February 09, 2012, 08:21:20 pm
Hi
I've decided that I want to create some classes to make my life easier. The first one that I wanted to create was  a "Line". I get an error message and want to figure out how i can debug this?, this is my code:

Code:
#include <Line.h>

Line line();

void setup() {
  // put your setup code here, to run once:
  line.set(1, 2, 3, 4);
}

void loop() {
  // put your main code here, to run repeatedly:
}


This is my error message:
ColourSphereCode.cpp: In function 'void setup()':
ColourSphereCode:6: error: request for member 'set' in 'line', which is of non-class type 'Line ()()'
ColourSphereCode.cpp: In function 'void loop()':
ColourSphereCode:11: error: request for member 'm' in 'line', which is of non-class type 'Line ()()'

And this is my Line.h:
/*
*/
#ifndef Line_h
#define Line_h

#include "Arduino.h"

class Line
{
  public:
    Line();
    void set(double x1,double  y1,double  x2,double y2);
  double m();
  double c();
  private:
  double _x1;
  double _y1;
  double _x2;
  double _y2;
};

#endif

and this is my Line.cpp:

#include "Arduino.h"
#include "Line.h"

Line::Line()
{
}

// define the two end points of the line
void Line::set(double x1, double y1, double x2, double y2)
{
  _x1 = x1;
  _y1 = y1;
  _x2 = x2;
  _y2 = y2;
}

// return the slope of the line
double m()
{
  return 1.1;
}

// return the offset of the line
double c()
{
  return 2.3;
}

so it would be great if someone can see where I'm going wrong but it would be even better if there is an 'easy" way that I can learn how to debug these errors and work with developing classes. The morse example looks  a little thin on the ground for this, but maybe there is another place that I can look?


Moderator edit: [code] [/code] tags added.
5  Using Arduino / Microcontrollers / Re: ATTiny 25/45/85/2313 Pin numbers on: February 05, 2012, 04:43:47 pm
Hey Karl_B
thanks for this cheat sheet, looks great. Wonder if you could also include attiny84 ?
6  Using Arduino / Microcontrollers / Re: Arduino as ISP, Mininial Circuit Error- pins_arduino.h No such file.. on: February 03, 2012, 09:56:40 pm
Hi Karl_b
thanks for that, tried what you said and added that line to boards but made not difference smiley-sad
Deleted the boards from from my sketchbook location and appended the boards information to the boards.txt file in ...arduino-1.0\hardware\arduino (not sure that its good practice but ...)
This compiled smiley so that was good news. But still was not uploading properly. So I compared the information with Attiny code that uses the arduino as ISP and noticed that "Atmega328 on breadboard" that this line "atmega328bb.upload.protocol=stk500" seemed strange to me so I replaced it with "atmega328bb.upload.using=arduino:arduinoisp", which is what we are doing.
This worked smiley so I'm very happy with. So here is my boards information for AtMega328 on breadboard(8Mhz internal clock), thanks for you help Karl_b great to get jigwas together.
If anyone can see any problems with this let me know.
Quote
##############################################################

atmega328bb.name=ATmega328 on a breadboard (8 MHz internal clock)

atmega328bb.upload.using=arduino:arduinoisp
atmega328bb.upload.maximum_size=30720
atmega328bb.upload.speed=57600

atmega328bb.bootloader.low_fuses=0xE2
atmega328bb.bootloader.high_fuses=0xDA
atmega328bb.bootloader.extended_fuses=0x05
atmega328bb.bootloader.path=arduino:atmega
atmega328bb.bootloader.file=ATmegaBOOT_168_atmega328_pro_8MHz.hex
atmega328bb.bootloader.unlock_bits=0x3F
atmega328bb.bootloader.lock_bits=0x0F

atmega328bb.build.mcu=atmega328p
atmega328bb.build.f_cpu=8000000L
atmega328bb.build.core=arduino:arduino
atmega328bb.build.variant=standard

7  Using Arduino / Microcontrollers / Re: Arduino as ISP, Mininial Circuit Error- pins_arduino.h No such file.. on: February 03, 2012, 09:21:18 pm
Hi Erni
looks like the pins_arduino.h files are there but not in the location you are talking about. In ...arduino-1.0\hardware\arduino\variants there are several folders (eightanaloginputs, leonardo, mega, micro and standard) each of these has a pins_arduino.h
This looks right to me, but I am not expert.
8  Using Arduino / Microcontrollers / Re: Arduino as ISP, Mininial Circuit Error- pins_arduino.h No such file.. on: February 03, 2012, 02:52:52 am
OK take another go at this and it definitely the board selection. choosing the uno instead of the Atmega328 on breadboard verifies/compiles so there is something happening with the setting of this board (Atmega328 on breadboard ).

9  Using Arduino / Microcontrollers / Re: Arduino as ISP, Mininial Circuit Error- pins_arduino.h No such file.. on: February 03, 2012, 12:44:56 am
Hi John
thanks for your last comment. Still learning this environment and now see what you mean. I've reinstalled everything and makes not different but it is a verify/compile issue not upload.

This time tried with blink example code (no changes and just used everything as described). Here is the error
C:\Arduino\arduino-1.0\hardware\tools\avr\bin\avr-g++ -c -g -Os -Wall -fno-exceptions -ffunction-sections -fdata-sections -mmcu=atmega328p -DF_CPU=8000000L -DARDUINO=100 -IC:\Arduino\arduino-1.0\hardware\arduino\cores\arduino C:\DOCUME~1\User\LOCALS~1\Temp\build3115065296870135004.tmp\Blink.cpp -oC:\DOCUME~1\User\LOCALS~1\Temp\build3115065296870135004.tmp\Blink.cpp.o
In file included from Blink.cpp:8:
C:\Arduino\arduino-1.0\hardware\arduino\cores\arduino/Arduino.h:212:26: error: pins_arduino.h: No such file or directory


can anyone point me in the right direction to fix this issue?

10  Using Arduino / Microcontrollers / Re: Arduino as ISP, Mininial Circuit Error- pins_arduino.h No such file.. on: February 02, 2012, 10:03:17 pm
I was trying to upload a sketch to a blank atmega328. I'll reinstall and have another go. I have been able to upload other sketches but just not via arduino as ISP. I was thinking it was something, maybe to do with the "atmega on breadboard (8Mhx internal clock)" board file that was installed i.e. the breadboard.zip. When I looked at it I didn't see anything that referenced arduinoISP, this is what it is:
##############################################################

atmega328bb.name=ATmega328 on a breadboard (8 MHz internal clock)

atmega328bb.upload.protocol=stk500
atmega328bb.upload.maximum_size=30720
atmega328bb.upload.speed=57600

atmega328bb.bootloader.low_fuses=0xE2
atmega328bb.bootloader.high_fuses=0xDA
atmega328bb.bootloader.extended_fuses=0x05
atmega328bb.bootloader.path=arduino:atmega
atmega328bb.bootloader.file=ATmegaBOOT_168_atmega328_pro_8MHz.hex
atmega328bb.bootloader.unlock_bits=0x3F
atmega328bb.bootloader.lock_bits=0x0F

atmega328bb.build.mcu=atmega328p
atmega328bb.build.f_cpu=8000000L
atmega328bb.build.core=arduino:arduino

should be be "atmega328bb.upload.protocol=stk500"?
anyway I will reinstall and see if that makes a difference.
11  Using Arduino / Microcontrollers / Arduino as ISP, Mininial Circuit Error- pins_arduino.h No such file.. on: February 02, 2012, 09:10:24 pm
Hi
I'm wanting to program an atmega 328 using ArduinoISP and the minimal circuit setup.
this is what I have done
1) uploaded the arduinoISP to my Duemilanove board, I'm working in arduino 1.0 IDE. followed instructions http://arduino.cc/en/Tutorial/ArduinoISP
2) Setup that i have used see http://arduino.cc/en/Tutorial/ArduinoToBreadboard, refer bottom of the page for miminal setup


also tried a 120ohm resistor between reset and 5V.

The error that I get in both cases is:
"C:\Arduino\arduino-1.0\hardware\arduino\cores\arduino/Arduino.h:212:26: error: pins_arduino.h: No such file or directory"

looks like I have missed something. Can anyone point me in the right direction.
12  Development / Suggestions for the Arduino Project / Re: Arduino 1.0 SoftwareSerial Documentation Needs Fixes on: January 27, 2012, 12:04:59 am
Thanks for this  smiley
I found point 1) a bit confusing so nice to have it clarified.
point 2) thats nice to know thanks.
point 3) does this mean that flush and peek can also be used (coming from Serial) not sure that Print offers
13  Forum 2005-2010 (read only) / Troubleshooting / Re: not in sync / protocol error on: January 14, 2011, 04:56:21 pm
hey thanks for that. got me also  smiley-sad
Pages: [1]