Skip to content

Instantly share code, notes, and snippets.

@emmanuel-nwogu
emmanuel-nwogu / CMakeError
Created April 10, 2023 10:48
ITK CMakeError 5.3.0
Performing C SOURCE FILE Test C_HAS_WARNING-Wno-long-double failed with the following output:
Change Dir: /c/Users/nwogu/OneDrive/Documents/4mLab/ITK-build/CMakeFiles/CMakeTmp
Run Build Command(s):/usr/bin/make.exe -f Makefile cmTC_ab219/fast && /usr/bin/make -f CMakeFiles/cmTC_ab219.dir/build.make CMakeFiles/cmTC_ab219.dir/build
make[1]: Entering directory '/c/Users/nwogu/OneDrive/Documents/4mLab/ITK-build/CMakeFiles/CMakeTmp'
Building C object CMakeFiles/cmTC_ab219.dir/src.c.o
/usr/bin/cc.exe -DC_HAS_WARNING-Wno-long-double -Wno-long-double -o CMakeFiles/cmTC_ab219.dir/src.c.o -c /c/Users/nwogu/OneDrive/Documents/4mLab/ITK-build/CMakeFiles/CMakeTmp/src.c
<command-line>: warning: ISO C99 requires whitespace after the macro name
cc1: note: unrecognized command-line option '-Wno-long-double' may have been intended to silence earlier diagnostics
Linking C executable cmTC_ab219.exe
@emmanuel-nwogu
emmanuel-nwogu / CMakeOutput
Created April 10, 2023 10:46
ITK CMakeOutput 5.3.0
The system is: MSYS - 3.3.4-341.x86_64 - x86_64
Compiling the CXX compiler identification source file "CMakeCXXCompilerId.cpp" succeeded.
Compiler: /usr/bin/c++.exe
Build flags:
Id flags:
The output was:
0
@emmanuel-nwogu
emmanuel-nwogu / CMakeLists
Created April 10, 2023 10:42
ITK CMakeLists 5.3.0
# ==== Define cmake build policies that affect compilation and linkage default behaviors
#
# Set the ITK_NEWEST_VALIDATED_POLICIES_VERSION string to the newest cmake version
# policies that provide successful builds. By setting ITK_NEWEST_VALIDATED_POLICIES_VERSION
# to a value greater than the oldest policies, all policies between
# ITK_OLDEST_VALIDATED_POLICIES_VERSION and CMAKE_VERSION (used for this build)
# are set to their NEW behaivor, thereby suppressing policy warnings related to policies
# between the ITK_OLDEST_VALIDATED_POLICIES_VERSION and CMAKE_VERSION.
#
# CMake versions greater than the ITK_NEWEST_VALIDATED_POLICIES_VERSION policies will
@emmanuel-nwogu
emmanuel-nwogu / makefile
Last active March 29, 2023 23:17
makefile for continuously saving images taken with an OV5642 connected to a Pi 4B to a text file
NAME=run_Save_To_Pi
# NAME=run_Arducam_Demo
CC=gcc
CFLAGS=-Wall -pthread
ODIR=obj
SDIR=src
_DEPS=ArduCAM.h bcm283x_board_driver.h sccb_bus.h ov2640_regs.h ov5640_regs.h ov5642_regs.h
DEPS=$(patsubst %,$(SDIR)/%,$(_DEPS))
@emmanuel-nwogu
emmanuel-nwogu / Save_To_Pi.c
Created March 29, 2023 23:02
Continuously save images taken with an OV5642 connected to a Pi 4B to a text file
#include <stdlib.h>
#include <stdio.h>
#include <stdbool.h>
#include "ArduCAM.h"
#include "sccb_bus.h"
#include <unistd.h>
#include <string.h>
#include <sys/types.h>
#include <sys/socket.h>
#include <netinet/in.h>
@emmanuel-nwogu
emmanuel-nwogu / realsense.py
Created November 21, 2022 23:45
RealSense
## License: Apache 2.0. See LICENSE file in root directory.
## Copyright(c) 2015-2017 Intel Corporation. All Rights Reserved.
###############################################
## Open CV and Numpy integration ##
###############################################
import os
import pyrealsense2 as rs
import numpy as np