Pages: [1]   Go Down
Author Topic: 'writestring'was not declared in this scope error  (Read 468 times)
0 Members and 1 Guest are viewing this topic.
Saginaw, Michigan
Offline Offline
Newbie
*
Karma: 0
Posts: 21
Love math physics and science.
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

I got my SD shield in yesterday and soldered in the headers, I have checked and rechecked the solder joints under a magnifing glass and see no soldering errors. But I keep getting the same error.

Here is my sketch.

// Geiger Counter Lib example

/* Adapted by Tracy Albert from programing for a frequecy counter by,
  Martin Nawrath KHM LAB3
  Kunsthochschule f¸r Medien Kˆln
  Academy of Media Arts
  http://www.khm.de
  http://interface.khm.de/index.php/labor/experimente/   
 */
#include <FreqCounter.h>
#include <SdFat.h>
#include <SdFatUtil.h>

Sd2Card card;
SdVolume volume;
SdFile root;
SdFile file;
 

unsigned long frq;
int cnt;
int pinLed=13;

void setup() {
  pinMode(pinLed, OUTPUT);

  Serial.begin(9600);        // connect to the serial port
  Serial.println("Geiger Counter");

}



void loop() {

  // wait if any serial is going on
  FreqCounter::f_comp=10;   // Cal Value / Calibrate with professional Freq Counter
  FreqCounter::start(60000);  // 1 minuit Gate Time

  while (FreqCounter::f_ready == 0)
 
 
Serial.println("Done");

  frq=FreqCounter::f_freq;
  Serial.print(cnt++);
  Serial.print("  cpm: ");
  Serial.println(frq);
   // write 100 line to file
  for (uint8_t i = 0; i < 100; i++) {
  writeString(file, "line");
  writeNumber(file, i);
  writeString(file, " millis = ");
  writeNumber(file, millis());
  writeCRLF(file);
}
// close file and force write of all data to the SD card
file.close();
    delay(1000);
   
   
  digitalWrite(pinLed,!digitalRead(pinLed));  // blink Led

Logged

A human being should be able to change a diaper, Plan an invasion, Butcher a hog, Con a ship, Design a building, Write a sonnet, Balance acc

Global Moderator
UK
Offline Offline
Brattain Member
*****
Karma: 299
Posts: 26180
I don't think you connected the grounds, Dave.
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Which object are you trying to call writestring on?
Quote
I have checked and rechecked the solder joints under a magnifing glass and see no soldering errors
Soldering is rarely a cause of compiler errors
Logged

"Pete, it's a fool looks for logic in the chambers of the human heart." Ulysses Everett McGill.
Do not send technical questions via personal messaging - they will be ignored.

Saginaw, Michigan
Offline Offline
Newbie
*
Karma: 0
Posts: 21
Love math physics and science.
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

frq I believe its the data I want to save as a data logger, I am kind of new at this. smiley smiley
Logged

A human being should be able to change a diaper, Plan an invasion, Butcher a hog, Con a ship, Design a building, Write a sonnet, Balance acc

Seattle, WA USA
Offline Offline
Brattain Member
*****
Karma: 610
Posts: 48993
Seattle, WA USA
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

You are trying to call two functions, writeString and writeNumber, that you have not defined.

Your problem is kind of like a cave man trying to call his neighbor before the telephone was invented, complaining I don't understand why I can't do this.
Logged

Pages: [1]   Go Up
Jump to: