Loading...
  Show Posts
Pages: [1] 2 3 ... 7
1  Using Arduino / LEDs and Multiplexing / Re: ShiftPWM support topic. Latest update: Schematics, high power LED's, LED strips on: May 10, 2013, 05:14:18 pm
Hi,

I get errors while using this with the DUE, so I guess its not ready yet. Any date when its done? Or are there any simple steps to make it work?
My Goal is to have Duo LEDs Shiftpwmed on the DUE smiley
2  Using Arduino / Microcontrollers / Re: Selfmade Due running way to slow on: May 09, 2013, 02:54:11 pm
Sorry for doupleposting, but could anyone look on their Due to tell me which Crystal is installed? I read several Threads where it says there is an 16mhz Crystal, which would explain the whole thing here.
3  Using Arduino / Microcontrollers / Re: Selfmade Due running way to slow on: May 09, 2013, 02:46:19 pm
But the Due also uses an 12mhz fast and 32.768 Slow Crystal  smiley-sad
http://arduino.cc/en/uploads/Main/arduino-Due-schematic.pdf
4  Using Arduino / Microcontrollers / Re: Selfmade Due running way to slow on: May 09, 2013, 01:22:12 pm
Hi,

thanks for the fast response. Im using an 12mhz and 32.xxkhz Crystal. The Sam3x8e doesnt use Optiboot.
Also, I cant find the Fuse settings, the only bits I can set are the GPNVM and Lockbits.
Where do I have to look? Do I need any other external tools?
5  Using Arduino / Microcontrollers / Selfmade Due running way to slow on: May 09, 2013, 11:03:51 am
Hi!

I build my own Due Board (kind of). I programmed it using an J-Link (SWD). My first try was uploading the Blink sketch. When trying to Blink with Output Digital 50, it way to slow! When I set the Sketch to have an Intervall of 1 sec, the Due actually takes 6 sec to do it!

I uploaded the sketch (as I said) using my Segger J-Link and AtmelStudio with the Arduino DUE Project file selected. What could that be? are there any fuses I need to set?
6  Using Arduino / Project Guidance / Re: Arduino based PCB - layout, crystal and planes on: March 30, 2013, 06:46:35 pm
Hi,

As already mentioned try to use supply or ground planes, they make routing more easy and also shield the lanes.

I manufactured my pcbs at eurocircuit. They're fast and even offer Support in german Language.
Also, they do have some interisting Manuals about layouting. Give it a try!


Grüße aus Bremen

-tsaG
7  Using Arduino / Project Guidance / Re: Controlling a rs-232 Relaisboard via web on: March 30, 2013, 09:35:54 am
Hi!

Thanks for your reply. Yes, the Board is crappy designed but I just got 4 of them for free, so I wanted to give it a try smiley-grin

I managed to get it to work.

There is an Attiny2313 on the board to set the Relais. I already tried to flash the Attiny but it doesnt really work out, so I flashed it back.

The reason why it didnt work to use the RX/TX Output directly on the boards connection is the MAX232 Chip. I soldered my wires directly to the Attiny 2313 and it worked!

Here is my function I used (using Myserial)


Code:
void sendCommand(int command, int cardAddr, int data){
  byte bytes[4];
  bytes[0] = byte(command);
  bytes[1] = byte(cardAddr);
  bytes[2] = byte(data);
  bytes[3] = bytes[0] ^ bytes[1] ^ bytes[2];

  writeBytes(bytes,4);
  delay(250);
}

void writeBytes(byte arr[], int len){
  for(int i = 0; i < len; i++){
    mySerial.write(arr[i]);
  }
}

First you have to Initialise them (1.0.0) then Set them (3.0.x). Works good.

The next step is Adding the Webserver capability. I already tested it using the simpled Webserver youll find when googling "ArduinoWebServerLED".
I wanted to use the SDcard to store my Website, but how can I do that? I already found "TinyWebServer" but even the examples it wont compile smiley-sad

Code:
SimpleWebServer.ino:11:19: warning: Flash.h: No such file or directory
SimpleWebServer.ino: In function 'boolean index_handler(TinyWebServer&)':
SimpleWebServer.ino:38: warning: only initialized variables can be placed into program memory area
SimpleWebServer:38: error: no match for 'operator<<' in 'web_server << (const __FlashStringHelper*)({...})'
SimpleWebServer.ino: In function 'const char* ip_to_str(const uint8_t*)':
SimpleWebServer.ino:48: warning: embedded '\0' in format
SimpleWebServer.ino: In function 'void setup()':
SimpleWebServer.ino:54: warning: only initialized variables can be placed into program memory area
SimpleWebServer:54: error: expected `)' before 'FreeRam'
SimpleWebServer:54: error: expected `)' before ';' token
SimpleWebServer.ino:72: warning: only initialized variables can be placed into program memory area
SimpleWebServer:72: error: no match for 'operator<<' in 'Serial << (const __FlashStringHelper*)({...})'
SimpleWebServer.ino:76: warning: only initialized variables can be placed into program memory area
SimpleWebServer:76: error: no match for 'operator<<' in 'Serial << (const __FlashStringHelper*)({...})'
SimpleWebServer.ino:79: warning: only initialized variables can be placed into program memory area
SimpleWebServer:79: error: no match for 'operator<<' in 'Serial << (const __FlashStringHelper*)({...})'

Are there any Libraries I can use? Is there "ONE" library everyone uses for those Webservers (using SD-Card for switching pins or sth.)?

8  Using Arduino / Microcontrollers / Re: ATmega2560 custom board problem on: March 30, 2013, 07:41:35 am
The best way for me was to use the sketch from Gammon. Give it a try smiley

http://www.gammon.com.au/forum/?id=11635

Thanks, I'll try that later. Is that a sketch that you put on one adruino board to program a bootloader to another board? Specifically made for ATMega2560 it looks like?

Cheers

Well, its an "all in one" sketch. You can upload it to your mega and connect your mega proto to it. It recognizes it and chooses the proper boot loader.

If you get verification errors while using this sketch change the clockdivider to the following

Code:
 // slow down SPI for benefit of slower processors like the Attiny
  SPI.setClockDivider (SPI_CLOCK_DIV64);

to

Code:
 // slow down SPI for benefit of slower processors like the Attiny
  SPI.setClockDivider (SPI_CLOCK_DIV128);


9  Using Arduino / Microcontrollers / Re: ATmega2560 custom board problem on: March 30, 2013, 05:35:46 am
The best way for me was to use the sketch from Gammon. Give it a try smiley

http://www.gammon.com.au/forum/?id=11635



10  Using Arduino / Microcontrollers / Re: Attiny2313 Programming on: March 29, 2013, 11:45:35 am
I changed the delay path so now its fixed. but not the other errors like (for example):

Code:
/Users/patrick/Documents/Arduino/hardware/tiny/cores/tiny/Print.cpp: In member function 'void Print::print(const String&)':
/Users/patrick/Documents/Arduino/hardware/tiny/cores/tiny/Print.cpp:48: warning: comparison between signed and unsigned integer expressions

/Users/patrick/Documents/Arduino/hardware/tiny/cores/tiny/wiring_pulse.c: In function 'pulseIn':
/Users/patrick/Documents/Arduino/hardware/tiny/cores/tiny/wiring_pulse.c:48: warning: cast to pointer from integer of different size

/Users/patrick/Documents/Arduino/hardware/tiny/cores/tiny/wiring_digital.c: In function 'pinMode':
/Users/patrick/Documents/Arduino/hardware/tiny/cores/tiny/wiring_digital.c:43: warning: cast to pointer from integer of different size
/Users/patrick/Documents/Arduino/hardware/tiny/cores/tiny/wiring_digital.c: In function 'digitalWrite':
/Users/patrick/Documents/Arduino/hardware/tiny/cores/tiny/wiring_digital.c:120: warning: cast to pointer from integer of different size
/Users/patrick/Documents/Arduino/hardware/tiny/cores/tiny/wiring_digital.c: In function 'digitalRead':
/Users/patrick/Documents/Arduino/hardware/tiny/cores/tiny/wiring_digital.c:146: warning: cast to pointer from integer of different size

/Users/patrick/Documents/Arduino/hardware/tiny/cores/tiny/pins_arduino.c:70: warning: initialization makes integer from pointer without a cast

The sketch some works some kid when i just que the digitalpin1.on.. digitalpin1.off..digitalpin2.on ...  Without the delay. So I tried the "Blink without delay" example but this doesnt work at all. Looks like as if none of the libraries are working (?)
11  Using Arduino / Microcontrollers / Re: Attiny2313 Programming on: March 29, 2013, 10:52:05 am
Okay, I imported the library and everything compiled so far.

I uploaded it using Atmel Studio (since I dont want to use the Bootloader on the small Attiny smiley-grin). As I plugged it in, its way to fast! I chose 8mhz in the menu but the 1mhz version doesnt work neither.

Then, when I tried another output, works finde but still the "speed problem". Now I added another Output to it so it switched between 11 and 12. Doesnt work!

It just switches the first in line! So my guess is that this thing is setting the output and then (somehow) restarting, setting the output..... and so on.

Any suggestions?

I flashed the Attiny of this Relayboard.
http://www.produktinfo.conrad.com/datenblaetter/175000-199999/197720-an-01-ml-8FACH_RELAISKARTE_24V_7A_de_en_fr_nl.pdf
http://www.conrad.de/ce/de/product/197720/Conrad-8fach-Relaiskarte-24-VDC-7-A-Baustein-8-Relaisausgaenge
Quite simple. an 7805 for power supply. An Toshiba Darlington Array and a MAx232 chip for Serial Output (not needed).

The Attiny is powered on pin 20 (VCC) and 10 GND. 8Mhz Oscillators on Pin 4 and 5.

The fuses are set as the following (didnt change it and left the default settings):

I also activated the internal clock divider once but there is no difference

BTW: I get some warnings while compiling, are those warnings normal? Mainly delay.h


Code:









/Applications/Arduino.app/Contents/Resources/Java/hardware/tools/avr/bin/avr-g++ -c -g -Os -Wall -fno-exceptions -ffunction-sections -fdata-sections -mmcu=attiny2313 -DF_CPU=1000000L -MMD -DUSB_VID=null -DUSB_PID=null -DARDUINO=104 -I/Users/patrick/Documents/Arduino/hardware/tiny/cores/tiny /var/folders/yh/7z4yt3513s508pr0kwzw7zb40000gn/T/build6049173189546008161.tmp/Blink.cpp -o /var/folders/yh/7z4yt3513s508pr0kwzw7zb40000gn/T/build6049173189546008161.tmp/Blink.cpp.o
/Applications/Arduino.app/Contents/Resources/Java/hardware/tools/avr/bin/avr-gcc -c -g -Os -Wall -ffunction-sections -fdata-sections -mmcu=attiny2313 -DF_CPU=1000000L -MMD -DUSB_VID=null -DUSB_PID=null -DARDUINO=104 -I/Users/patrick/Documents/Arduino/hardware/tiny/cores/tiny /Users/patrick/Documents/Arduino/hardware/tiny/cores/tiny/pins_arduino.c -o /var/folders/yh/7z4yt3513s508pr0kwzw7zb40000gn/T/build6049173189546008161.tmp/pins_arduino.c.o
In file included from /Users/patrick/Documents/Arduino/hardware/tiny/cores/tiny/wiring_private.h:32,
                 from /Users/patrick/Documents/Arduino/hardware/tiny/cores/tiny/pins_arduino.c:38:
/Applications/Arduino.app/Contents/Resources/Java/hardware/tools/avr/bin/../lib/gcc/avr/4.3.2/../../../../avr/include/avr/delay.h:36:2: warning: #warning "This file has been moved to <util/delay.h>."
/Users/patrick/Documents/Arduino/hardware/tiny/cores/tiny/pins_arduino.c:70: warning: initialization makes integer from pointer without a cast
/Users/patrick/Documents/Arduino/hardware/tiny/cores/tiny/pins_arduino.c:71: warning: initialization makes integer from pointer without a cast
/Users/patrick/Documents/Arduino/hardware/tiny/cores/tiny/pins_arduino.c:73: warning: initialization makes integer from pointer without a cast
/Users/patrick/Documents/Arduino/hardware/tiny/cores/tiny/pins_arduino.c:79: warning: initialization makes integer from pointer without a cast
/Users/patrick/Documents/Arduino/hardware/tiny/cores/tiny/pins_arduino.c:80: warning: initialization makes integer from pointer without a cast
/Users/patrick/Documents/Arduino/hardware/tiny/cores/tiny/pins_arduino.c:82: warning: initialization makes integer from pointer without a cast
/Users/patrick/Documents/Arduino/hardware/tiny/cores/tiny/pins_arduino.c:88: warning: initialization makes integer from pointer without a cast
/Users/patrick/Documents/Arduino/hardware/tiny/cores/tiny/pins_arduino.c:89: warning: initialization makes integer from pointer without a cast
/Users/patrick/Documents/Arduino/hardware/tiny/cores/tiny/pins_arduino.c:91: warning: initialization makes integer from pointer without a cast

/Applications/Arduino.app/Contents/Resources/Java/hardware/tools/avr/bin/../lib/gcc/avr/4.3.2/../../../../avr/include/avr/delay.h:36:2: warning: #warning "This file has been moved to <util/delay.h>."

/Applications/Arduino.app/Contents/Resources/Java/hardware/tools/avr/bin/../lib/gcc/avr/4.3.2/../../../../avr/include/avr/delay.h:36:2: warning: #warning "This file has been moved to <util/delay.h>."

/Applications/Arduino.app/Contents/Resources/Java/hardware/tools/avr/bin/../lib/gcc/avr/4.3.2/../../../../avr/include/avr/delay.h:36:2: warning: #warning "This file has been moved to <util/delay.h>."

/Applications/Arduino.app/Contents/Resources/Java/hardware/tools/avr/bin/../lib/gcc/avr/4.3.2/../../../../avr/include/avr/delay.h:36:2: warning: #warning "This file has been moved to <util/delay.h>."
/Users/patrick/Documents/Arduino/hardware/tiny/cores/tiny/wiring_digital.c: In function 'pinMode':
/Users/patrick/Documents/Arduino/hardware/tiny/cores/tiny/wiring_digital.c:43: warning: cast to pointer from integer of different size
/Users/patrick/Documents/Arduino/hardware/tiny/cores/tiny/wiring_digital.c: In function 'digitalWrite':
/Users/patrick/Documents/Arduino/hardware/tiny/cores/tiny/wiring_digital.c:120: warning: cast to pointer from integer of different size
/Users/patrick/Documents/Arduino/hardware/tiny/cores/tiny/wiring_digital.c: In function 'digitalRead':
/Users/patrick/Documents/Arduino/hardware/tiny/cores/tiny/wiring_digital.c:146: warning: cast to pointer from integer of different size

/Applications/Arduino.app/Contents/Resources/Java/hardware/tools/avr/bin/../lib/gcc/avr/4.3.2/../../../../avr/include/avr/delay.h:36:2: warning: #warning "This file has been moved to <util/delay.h>."
/Users/patrick/Documents/Arduino/hardware/tiny/cores/tiny/wiring_pulse.c: In function 'pulseIn':
/Users/patrick/Documents/Arduino/hardware/tiny/cores/tiny/wiring_pulse.c:48: warning: cast to pointer from integer of different size
/Users/patrick/Documents/Arduino/hardware/tiny/cores/tiny/wiring_pulse.c:53: warning: cast to pointer from integer of different size
/Users/patrick/Documents/Arduino/hardware/tiny/cores/tiny/wiring_pulse.c:58: warning: cast to pointer from integer of different size

12  Using Arduino / Microcontrollers / Attiny2313 Programming on: March 29, 2013, 09:17:10 am
Hi!

I want to programm an Attiny2313 over ISP (I do have an mySmartUSB). What do I need? My plan is to write the code, choose the Board, export the hex file and burn it using atmel studio (or similar).

I already tried this: http://hlt.media.mit.edu/?p=1695
But after I placed those files in my Arduino/hardware folder and want to start the Arduino IDE it crashes and says "Menu has no enabled Items".

How do I do it correctly? Where do I get the library (?) from?
13  Using Arduino / Project Guidance / Controlling a rs-232 Relaisboard via web on: March 29, 2013, 06:39:36 am
Hi!

I want to connect an rs232 Relais board to my Arduino, thats the first step. The second will be to add an Webserver function, but lets start with the Relaisboard first.

I have two of those Boards (and some older Version which dont support function 4 and 5).

Now my try was the following
Code:
/*
  AnalogReadSerial
 Reads an analog input on pin 0, prints the result to the serial monitor.
 Attach the center pin of a potentiometer to pin A0, and the outside pins to +5V and ground.
 
 This example code is in the public domain.
 */
byte a= 3;
byte b =0;
byte c=48;
byte d= a^b^c;

void setup() {
 Serial.begin(19200);
}


void loop() {
  // read the input on analog pin 0:

  // print out the value you read:
  Serial.write(a);
  Serial.write(b);
  Serial.write(c);
  Serial.write(d);
  delay(500);        // delay in between reads for stability
}

But this doesnt work smiley-sad.

What did I do wrong? Here is the Product site
http://www.conrad.de/ce/de/product/197720/Conrad-8fach-Relaiskarte-24-VDC-7-A-Baustein-8-Relaisausgaenge
and here the Manual
http://www.produktinfo.conrad.com/datenblaetter/175000-199999/197720-an-01-ml-8FACH_RELAISKARTE_24V_7A_de_en_fr_nl.pdf
14  Using Arduino / Programming Questions / Re: Arduino Due over SWD with external Programmer on: March 21, 2013, 12:53:26 pm
*push*
15  Using Arduino / Programming Questions / Arduino Due over SWD with external Programmer on: March 18, 2013, 02:07:20 pm
Hi!

I was using my old UNO with an AVR Programmer, everything worked fine. Now I switched to the DUE and a J-Link JTAG. How can I upload my sketches directly with my programmer? With AVR I just needed to Choose one frome the menu, but there are no ARM Programmer yet. Any suggestions?

I already found the following document, but as far as I see it is for AVR programmer as well.
http://arduino.cc/en/Hacking/Programmer
Pages: [1] 2 3 ... 7