Hey there everybody,
I've been working with the parallax rfid reader/writer I just got it's super awesome, and I can read data fine, but now I want to try to write it. I decided to write a function to do so (hooray for me!) but I can't get it to work - the error I keep getting is as follows:
rfid.cpp: In function 'void do_rfid_write(char*)':
rfid:125: error: void value not ignored as it ought to be
rfid:128: error: void value not ignored as it ought to be
Here's the code for the write function, and I can include the rest of the code if anyone's interested. How can I test to see if something is void, and then ignore it if so?
void do_rfid_write(char indata[]){
for(int i = 0; i < sizeof(indata)/sizeof(char) && i < maxAddress*4; i++){
sendWriteCommand(i/4); // this is because we can store 4 chars (or bytes) per addresswhile(!mySerial.available()){
}statusCode = mySerial.print(indata*); // <- This is line 125, where it fails first*
- while(statusCode != ERR_OK){*
- sendWriteCommand(i);*
_ statusCode = mySerial.print(indata*); // <- This is where it fails second*_
* }*
_ Serial.print("wrote address ");
Serial.println(i);
* }*
Serial.println("Finished Write");_
}
[/quote]