File tree Expand file tree Collapse file tree 1 file changed +11
-1
lines changed
content/hardware/04.pro/shields/portenta-vision-shield/tutorials/camera-to-bitmap-sd-card Expand file tree Collapse file tree 1 file changed +11
-1
lines changed Original file line number Diff line number Diff line change @@ -321,9 +321,10 @@ void setup(){
321
321
if (!cam.begin(CAMERA_R320x240, IMAGE_MODE, 30)){
322
322
Serial.println("Unable to find the camera");
323
323
}
324
-
324
+ countDownBlink();
325
325
Serial.println("Fetching camera image...");
326
326
unsigned char *imageData = captureImage();
327
+ digitalWrite(LEDB, HIGH);
327
328
328
329
Serial.println("Saving image to SD card...");
329
330
saveImage(imageData, IMAGE_PATH);
@@ -416,6 +417,15 @@ void saveImage(unsigned char *imageData, const char* imagePath){
416
417
// Close the file stream
417
418
fclose(file);
418
419
}
420
+
421
+ void countDownBlink(){
422
+ for (int i = 0; i < 6; i++){
423
+ digitalWrite(LEDG, i % 2);
424
+ delay(500);
425
+ }
426
+ digitalWrite(LEDG, HIGH);
427
+ digitalWrite(LEDB, LOW);
428
+ }
419
429
```
420
430
421
431
## Conclusion
You can’t perform that action at this time.
0 commit comments