My bad. I made a misguided assumption. Even though your schematic shows the chips, not modules I got it wrong. I would go with the 4.7K resistors in place of the 10K resistors that you have. Sorry for my confusion.
Yes, it writes to the card when the buffer fills, at the point your code calls file.print().There are advanced writing options supported by SdFat. You could research that. Another alternative would be to compress the information you are writing each time. You could easily cut it down by a factor of three although from previous discussions it seems you aren't interested in that. Post a question on the storage forum; hopefully you will attract the attention of user fat16lib who authored SdFat (and SD).Unless you call flush (or close) your file will appear empty even though the data is on the card. So how many minutes of data loss would make you cry if your battery died unexpectedly? Pick some interval you'd be comfortable with and call flush that often. Maybe it's fifteen minutes, maybe it's five seconds. It's up to you.
I did something similar a few years back, but I dropped the 328P to 8MHz so I could run everything at 3.3V (supplied by the regulator on the SD-Card breakout.)Barebones 328 8Mhz ASCII dataloggerRay
I don't see an attachment. The Aref pin should not be connected to anything but a 0.1uf cap to ground unless you are actually using an external reference. Do not connect to Vcc, that connection is done internally when using the default reference.
The attachment shows for me now.The main omission I see is there are no programming or ICSP headers (unless I'm just missing them). I assume you intend to bootload this to use through the Arduino IDE? You'll need the serial pins for that, plus access to the SPI pins to actually put the bootloader on (unless you are bootloading before soldering.I can't speak to the need for the Aref cap, as I always stick in in there. It may not be needed if you aren't doing anything with analog pins? I'll let someone else answer that for sure.Layout-wise, I've seen far worse first uses with Eagle. We can't tell for sure if the circuit is right without a schematic, but there aren't any right-angle traces, isolation looks good on the pour, etc.I'm curious what the 2 vias in the middle of the (connected) pads up top are for? Bringing in power? If so, you're going to want one of those on ground, not both on the same net
I was going to program it through the microsd socket on the bottom of the board, which is why I have left access to the reset pin. The pads at the top are the grounds for the batteries. The vias are connecting them to the ground plane on the bottom.I have attached a schematic.Cheers.
3.3V system then? I would change the I2C pullups to 3.3K, will provide quicker low to high transitions compared to 4.7K.
Ah, well that will work for programming. A little fiddly, but certainly functional. This might already exist out there, but perhaps cracking open an old uSD card, removing the guts, and soldering jumper wires to the pads inside of the card body could be done for a click-in programmer, with the reset wire off to the side.And I now get the vias/pads. I was stuck in soldering wires through-hole to connect power, but you are just soldering to exposed pads. Makes plenty of sense. DOH!