Serial Data logging - Help needed

I got an Arduino Zero, an Adafruit Micro-SD breakout board+ and Adafruit Ultimate GPS.

I want to save raw GPS data to sd card when I press a button and stopp when I press again? And every time I start a new raw data logging I want it to create a new file. NRH01.txt, NRH02.txt, NRH02.txt and sow on.

Any one know how to connect the SD board to Zero? Only get error board not found

Hi Kimlorentz,

Are you connecting the SD board to the Zero's 6 pin SPI header?

The Zero differs from the UNO, in that its SPI library uses the 6 pin SPI header and not digital pins 10-13.

Ahh thats why I did not get it to work. I wil try this later today

I got it working, I used Pin 10 for the CS and SPI + 3.3v pin for the rest. :grinning:

Now i need the Zero to connect to the GPS and button to save and create new files when using the button

Adafruit ultimate GPS use uart for communication. You have to use the Serial1 instance that is connected to pin 0 and 1 of arduino Zero.

Buttons are used the same way as on other arduino : digitalRead(pin) return either true or false if switch is connected to ground.

Connection is not the problem, the programming is :)

Have you looked at the adafruit guide for the GPS?

https://learn.adafruit.com/adafruit-ultimate-gps/overview

You have to go through the library and remove instance of SoftWareSerial, replace it by Serial1.

You also should rmeove everything related to Interrupt : registers and setings are different for the Arduino Zero.

You should be able to use the GPS without interrupt I think.