Go Down

Topic: 'writestring'was not declared in this scope error (Read 754 times) previous topic - next topic


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
#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.print("  cpm: ");
   // 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());
// close file and force write of all data to the SD card
  digitalWrite(pinLed,!digitalRead(pinLed));  // blink Led


Which object are you trying to call writestring on?
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
"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.
I speak for myself, not Arduino.


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


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.
The art of getting good answers lies in asking good questions.

Go Up