Cons: On the other hand, although it will be less complex to code up, it forces the microcontroller to write the data twice once when saving to the – microcontroller EEPROM then once again when copying the data to the SD card. Another shortcoming is that in this method, if there is an error with the writing instruction, all the data in that set may be damaged and useless as well. Conclusion: After reviewing both approaches presented, it seems to be a tossup as to which method best suits our needs. One thing to note with both methods is that before data is passed to be written onto the SD card it will be converted into a 32 bit IEEE single float. After thorough discussion it was decided that we should save data in a consistent stream rather than big blocks of data. As defined in the data storage section, all data will be stored in a comma value separated file and these numbers need to be input in the same position each entry. In the rare event that a sensor is unable to calculate data or the microcontroller is unable to grab the value from the specified port in a timely manner, we cannot just skip over this port, because if we go without writing in a value for that certain sensor, it will offset the format of the data recorded. Table 8 displays the complete pinout of the Microchip microcontroller to each sensor. Connection Microcontroller Sensor Type Wire Type Pin# SCK (Clock) P76 SDO (Data Out) P77 3-Axis Gyroscope SPI 4-Wire SDI (Data In) P80 CS P81 (Chip Select) SCK P10 SDO P12 3-Axis Accelerometer SPI 4-Wire SDI P11 CS P05 Rotary Position Sensor Analog Analog In P26 (Angle-of-Attack) Rotary Position Sensor Analog Analog In P27 (Angle-of-Sideslip) Humidity Sensor Analog Analog P24 SCK P39 SDO P40 Temperature Sensor SPI 4-Wire SDI P38 CS P48 Barometric Pressure Clock P49 I2C Sensor SDA (Data) P50
Cons: On the other hand, although it will be less complex to code up, it forces the microcontroller to write the data twice – once when saving to the microcontroller EEPROM then once again when copying the data to the SD card. Another shortcoming is that in this method, if there is an error with the writing instruction, all the data in that set may be damaged and useless as well. Conclusion: After reviewing both approaches presented, it seems to be a tossup as to which method best suits our needs. One thing to note with both methods is that before data is passed to be written onto the SD card it will be converted into a 32 bit IEEE single float. After thorough discussion it was decided that we should save data in a consistent stream rather than big blocks of data. As defined in the data storage section, all data will be stored in a comma value separated file and these numbers need to be input in the same position each entry. In the rare event that a sensor is unable to calculate data or the microcontroller is unable to grab the value from the specified port in a timely manner, we cannot just skip over this port, because if we go without writing in a value for that certain sensor, it will offset the format of the data recorded. Table 8 displays the complete pinout of the Microchip microcontroller to each sensor. Sensor Type Connection Type Wire Microcontroller Pin# 3-Axis Gyroscope SPI 4-Wire SCK (Clock) P76 SDO (Data Out) P77 SDI (Data In) P80 CS (Chip Select) P81 3-Axis Accelerometer SPI 4-Wire SCK P10 SDO P12 SDI P11 CS P05 Rotary Position Sensor (Angle-of-Attack) Analog Analog In P26 Rotary Position Sensor (Angle-of-Sideslip) Analog Analog In P27 Humidity Sensor Analog Analog P24 Temperature Sensor SPI 4-Wire SCK P39 SDO P40 SDI P38 CS P48 Barometric Pressure Sensor I2C Clock P49 SDA (Data) P50
FDL%20SD1%20Paper.docx