HeptaSat

Dependencies:   HEPTA_CDH HEPTA_EPS HEPTA_SENSOR mbed

Committer:
HeptaSatTraining2019
Date:
Tue Aug 27 01:26:14 2019 +0000
Revision:
26:2d7738ea9ee4
Parent:
25:5fd40a170032
Child:
30:7d3d89289950

        

Who changed what in which revision?

UserRevisionLine numberNew contents of line
mbed_official 0:bdbd3d6fc5d5 1 #include "mbed.h"
HeptaSatTraining2019 25:5fd40a170032 2 #include "HEPTA_EPS.h"
HeptaSatTraining2019 25:5fd40a170032 3 #include "HEPTA_CDH.h"
HeptaSatTraining2019 25:5fd40a170032 4 #include "HEPTA_SENSOR.h"
umeume 2:1c5cdb2c3e0f 5
umeume 2:1c5cdb2c3e0f 6 Serial pc(USBTX,USBRX);
HeptaSatTraining2019 21:92c25e853b87 7 HEPTA_EPS eps(p16,p26);
HeptaSatTraining2019 25:5fd40a170032 8 HEPTA_CDH cdh(p5,p6,p7,p8,"sd");
HeptaSatTraining2019 21:92c25e853b87 9 HEPTA_SENSOR sensor(p17,
HeptaSatTraining2019 21:92c25e853b87 10 p28,p27,0xD0,0x18,
HeptaSatTraining2019 25:5fd40a170032 11 p13,p14,p25,p24);
umeume 5:c5ccb1b07e8f 12
umeume 2:1c5cdb2c3e0f 13 int main()
umeume 2:1c5cdb2c3e0f 14 {
HeptaSatTraining2019 26:2d7738ea9ee4 15 FILE *dummy = fopen("/sd/dummy.txt","w");
HeptaSatTraining2019 26:2d7738ea9ee4 16 if(dummy == NULL) {
HeptaSatTraining2019 26:2d7738ea9ee4 17 error("Could not open file for write\r\n");
HeptaSatTraining2019 26:2d7738ea9ee4 18 }
HeptaSatTraining2019 26:2d7738ea9ee4 19 fclose(dummy);
HeptaSatTraining2019 26:2d7738ea9ee4 20
HeptaSatTraining2019 26:2d7738ea9ee4 21 pc.printf("Camera Snapshot Mode\r\n");
HeptaSatTraining2019 26:2d7738ea9ee4 22 pc.printf("Hit Any Key To Take Picture\r\n");
HeptaSatTraining2019 26:2d7738ea9ee4 23 while(!pc.readable()) {}
HeptaSatTraining2019 26:2d7738ea9ee4 24 sensor.Sync();
HeptaSatTraining2019 26:2d7738ea9ee4 25 sensor.initialize(HeptaCamera_GPS::Baud115200, HeptaCamera_GPS::JpegResolution320x240);
HeptaSatTraining2019 26:2d7738ea9ee4 26 sensor.test_jpeg_snapshot_picture("/sd/test.jpg");
umeume 2:1c5cdb2c3e0f 27 }