Show Posts
Pages: [1] 2 3 ... 9
1  Using Arduino / Programming Questions / Re: SD CARD HELP on: April 12, 2013, 06:50:26 pm
and represent the numbers 0-255 in one byte, in txt. ???
2  Using Arduino / Programming Questions / Re: SD CARD HELP on: April 12, 2013, 06:46:45 pm
Spanish official forum is dead, more questions than answers.
3  Using Arduino / Programming Questions / Re: SD CARD HELP on: April 12, 2013, 06:38:48 pm
apology from the question I am trying to do and language, that mine is the spanish. how to say no.


as 0-255 numbers represent, as a single byte in txt file, so I Leea arduino single byte or character and represents me the number???
4  Using Arduino / Programming Questions / Re: SD CARD HELP on: April 12, 2013, 06:27:40 pm
I'm doing this:

the problem is not how to represent numbers between 0-255, in one
byte in a txt file of the car Sd.

all the examples I've seen use two bytes, but a delimiter. and when
I decode this data certainly would be something of 20000, the arduino, it takes forever.
5  Using Arduino / Programming Questions / Re: SD CARD HELP on: April 12, 2013, 06:14:26 pm
these control are well represented by this instance with the backslash '\ n'?, and others as they are?
6  Using Arduino / Programming Questions / Re: SD CARD HELP on: April 12, 2013, 06:03:03 pm
but as I can represent these numbers similarly,in byte?
7  Using Arduino / Programming Questions / SD CARD HELP on: April 12, 2013, 05:45:01 pm
as representing numbers 0-255 in one byte in a txt file

example:
here the caracter 'þ'  = 254


and the numbers between 0 and 33 as represented?
8  International / Software / Re: SD CARD-LEER-HELP on: April 11, 2013, 08:38:55 pm
estoy usando processing , no se lo conoces-primo hermano de Arduino Soft. con el
hago escaneo de una imagen y saco los valores rgb.

como estan los valores, y no importaria, luego yo me encargaria de llevarlo al formato que usted menciona.

es decir me gustaria que ponga los datos del 0 al 255, en su formato en el archivo y leerlos en un int en el arduino
9  Using Arduino / Programming Questions / Re: SD CARD-read-HELP on: April 11, 2013, 07:05:36 pm
??? smiley-cry
10  Using Arduino / Programming Questions / SD CARD-read-HELP on: April 11, 2013, 05:49:49 pm
GOOD, I commented that I have installed a SD Card and it works perfect.

  the problem is
I want to read in the arduino Numbers in 0-255. and if I write to the SD memory, in a file
txt for example

12,123,255,0,5


as seen numbers between 0-255, separated by a comma.
arduino with the read () function to read the txt file, it interprets this byte or character,
ie only shows or going one on one like this, '1 ''2' '' '1 ''2' '3 '', 'etc. ...........
which should make the process of composing and filter out ',' to interpret the number arduino.
Because what if I have the arduino relantiza 20000 I comment to make.


--------------------------------------------

i was thinking, thinking, thinking, thinking .....
and because no caracters use directly, according to the code ASSII (http://www.asciitable.com/), and need not
compose, or filter out. but ........
the proplema is that between DEC 0-32 in number, are reserved to speak, which the arduino not me in terpretaria
because these characters are not readable.


clarifying;:
ie put the characters in txt

!"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~€‚ƒ„…†‡ˆ‰Š‹ŒŽ‘’“”•–—˜™š›œžŸ ¡¢£¤¥¦§¨©ª«¬­®¯°±²³´µ¶·¸¹º»¼½¾¿ÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏÐÑÒÓÔÕÖ×ØÙÚÛÜÝÞßàáâãäåæçèéêëìíîïðñòóôõö÷øùúûüýþÿ



and Assi code eg in DEC! represents 33, and so on, but between 0-32, no how. Means???
11  International / Software / Re: SD CARD-LEER-HELP on: April 11, 2013, 05:47:04 pm
HOLA AGAIN, PODRIAS PONER UN ARCHIVO CON LOS CARACTERES, Y LUEGO PONERLOS EN UNA VARIABLE  INT.
NO ME INTERESA GUARDAR LA DATA DESDE EL ARDUINO AL SD CARD.
TE COMENTO QUE QUIERO HACER UNA MATRIZ RGB, Y NECESITO LEER LO MAS RAPIDO POSIBLE.
12  International / Software / SD CARD-LEER-HELP on: April 11, 2013, 04:46:59 pm
BUENAS, LES COMENTO QUE TENGO INsTALADO UN SD CARD Y FUNCIONA PERFECTO.

 el problema es
que quiero leer en el arduino numeros que estan entre 0-255. y si escribo en la memoria Sd , en un archivo
txt  por ejemplo

12,123,255,0,5


como se ve numeros entre 0-255, separados por una coma.
el arduino con la funcion read(), para leer el archivo txt, este lo interpreta byte o caracter,
es decir solo muestra o va de uno a uno  asi,  '1'    '2'    ','   '1'    '2'     '3'      ','   ...........etc
lo cual se debe hacer un proceso de componer y filtar ',' para que arduino interprete el numero.
lo que causa si dispongo de 20000 se relantiza el arduino para efectuar lo que comento.


--------------------------------------------

estube pensando ,pensado,pensado,pensado.....
y porque no usar los caracters directamente, segun el code ASSII(http://www.asciitable.com/), y no necesitaria
componer ,ni filtar. pero........
el proplema es que  entre 0-32 en numero DEC, estan reservados por decirlo de alguna manera, lo cual el arduino no me lo in terpretaria
porque estos caracteres no son legibles.


aclarando;:
es decir , pongo lo caracteres  en el txt   


 !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~€‚ƒ„…†‡ˆ‰Š‹ŒŽ‘’“”•–—˜™š›œžŸ ¡¢£¤¥¦§¨©ª«¬­®¯°±²³´µ¶·¸¹º»¼½¾¿ÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏÐÑÒÓÔÕÖ×ØÙÚÛÜÝÞßàáâãäåæçèéêëìíîïðñòóôõö÷øùúûüýþÿ



y el code Assi en DEC por ejemplo el  !   representa el 33, asi sucesivamente, pero entre 0-32, no como hacerlo. Se entiende ???

la verdad que  deque otra forma puede ser  , ¿alguna sugerencia?
13  Using Arduino / Programming Questions / Re: SD Card Read -uint8_t from memory - help on: April 10, 2013, 11:55:02 am
sorry did not understand your question.


I can read more than 1 txt file at once?
14  Using Arduino / Programming Questions / Re: SD Card Read -uint8_t from memory - help on: April 10, 2013, 11:10:22 am
does not run beyond the series, because I know how much data I have available, this number is fixed.

  beyond which change the value of the data.


so as I'm reading, reading in the library is full speed?
15  Using Arduino / Programming Questions / Re: SD Card Read -uint8_t from memory - help on: April 10, 2013, 10:27:38 am
Code:

#include <SPI.h>
#include <SD.h>

File myFile;
char str[3] ;
uint8_t  i=0;
uint8_t RGB[3];

void setup()
{
 // Open serial communications and wait for port to open:
  Serial.begin(9600);
   while (!Serial) {
    ; // wait for serial port to connect. Needed for Leonardo only
  }


  Serial.print("Initializing SD card...");
   pinMode(10, OUTPUT);
   
  if (!SD.begin(10)) {
    Serial.println("initialization failed!");
    return;
  }
  Serial.println("initialization done.");
 
 
  myFile = SD.open("data/ALL0.txt");
  if (myFile) {
   
    // read from the file until there's nothing else in it:
   if (myFile.available()) {
     for(int a=0;a<60;a++){

            for(int x=0;x<3;x++){

       
      char c=myFile.read();
      i=0;
      str[2]=' ';
      while(c != ','){
 
        str[i]= c;
       c=myFile.read();
       i++;
    }
     RGB[x] =atof(str);
            }
    Serial.println( RGB[0]);
    Serial.println( RGB[1]);
    Serial.println( RGB[2]);

 
 
   } 
   }
    // close the file:
    myFile.close();
  } else {
  // if the file didn't open, print an error:
    Serial.println("error opening test.txt");
  }
}

void loop()
{
// nothing happens after setup
}
Pages: [1] 2 3 ... 9