text
stringlengths
3.08k
10.5k
/* This is code to drive the X compatible mini-uart */ /* As decribed in Chapter XX of the BCM2835 ARM Peripherals Manual */ /* This UART is used by default on the Pi3 */ /* As the pl011 is connected to bluetooth */ /* The code assumes you have a serial connector with TX/RX connected */ /* To GPIO pins 14 and 15 ...
#include <stdint.h> #include <stdbool.h> #include "FreeRTOS.h" #include "task.h" #include "semphr.h" #include "iodefine.h" /* task stacks */ static StackType_t task_1_stack[128]; static StackType_t task_2_stack[128]; static StackType_t task_3_stack[128]; /* task handles */ static StaticTask_t task_1_handle; static St...
/* * Copyright (c) 2011 The Chromium OS Authors. * * See file CREDITS for list of people who contributed to this * project. * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License as * published by the Free Software Foundation; either versi...
/* * lcd.c * * Created: 11.12.2017 22:10:52 * Author: <NAME> */ #include <string.h> #include <stdlib.h> #include "global.h" #include "lcd/lcd.h" volatile uint8_t lcd_shift_flag = 0; volatile uint8_t lcd_shift_abort = 0; void lcd_init(void) { LCDDDR = ((0xF0) | (1 << LCD_RS_PIN) | (1 << LCD_E_PIN)); LCDPORT =...
#define _CRT_SECURE_NO_DEPRECATE //buffer security is imoortant, but not as much as portability #include <stdio.h> #include <stdlib.h> #include <string.h> #include <stdint.h> #include "include/debug.h" #include "include/hash.h" #include "include/compiler.h" #include "include/opcodes.h" #include "include/mac...
#include "init_rx631.h" #include "iodefine.h" /*** Function Declaration ***/ static void init_clock(void); static void init_cmt0(void); static void init_cmt1(void); static void init_mtu4(void); /*---- RX631 Initialization ----*/ void init_rx631(void){ SYSTEM.PRCR.WORD = 0xA503; // Unprotect // MainCLK, SUBCLK and...
// We're using sigvis for visualizations. This will include miniaudio for us, so no need to include miniaudio in this file. #define NO_SIGVIS #define MA_NO_SSE2 #define MA_NO_AVX2 #ifdef NO_SIGVIS #define MINIAUDIO_IMPLEMENTATION #include "../miniaudio.h" #else #define MINI_SIGVIS_IMPLEMENTATION #incl...
#include <math.h> static int testf(float float_x, long double long_double_x, /*float complex float_complex_x,*/ int int_x, long long_x) { int r = 0; r += acosf(float_x); r += acoshf(float_x); r += asinf(float_x); r += asinhf(float_x); r += atan2f(float_x, float_x); r += atanf(float_x); r += atanhf(float_x); /*r += car...
#include <arpa/inet.h> #include <netdb.h> #include <netinet/in.h> #include <stdio.h> #include <stdlib.h> #include <string.h> #include <strings.h> #include <sys/socket.h> #include <sys/types.h> #include <unistd.h> #define BUF_SIZE 300 #define PORT_NUMBER "9999" #define BCAST_ADDRESS "255.255.255.255" #define MAX_PEERS ...
#include "genmap-impl.h" #include <math.h> #include <stdio.h> /* Orthogonalize by 1-vector (vector of all 1's) */ int GenmapOrthogonalizebyOneVector(GenmapComm c, GenmapVector q1, GenmapLong n) { GenmapInt i; GenmapScalar sum = 0.0; for(i = 0; i < q1->size; i++) { sum += q1->data[i]; } GenmapGop(c, &s...
//***************************************************************************** //! @file bsp.c //! @brief Board support package for CC26xx Cortex devices on SensorTag. //! //! Revised $Date: 2014-11-07 04:45:28 -0800 (Fri, 07 Nov 2014) $ //! Revision $Revision: 14396 $ // // Copyright (C) 2014 Texas...
/* * ======================================================================================= * * Author: <NAME> (je), <EMAIL> * Copyright (c) 2021 RRZE, University Erlangen-Nuremberg * * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and asso...
/** * Copies a BMP piece by piece, just because. */ #include <stdio.h> #include <stdlib.h> #include <string.h> #include "bmp.h" // define bool typedef enum { false, true } bool; bool isInteger(char *number); // to check if string is an int int getPadding(BITMAPINFOHEADER *bi); // calculate padding int mai...
/** * @author <NAME> * ECE 1166 * MPI Matrix Multiplication * January 30, 2019 * * This program is a matrix multiply program for use over a distrubted * computing network, capable of multiplying an (M X N) * (N x P) matrix sizes. * * This program was successfully compiled on Pitt's CRC cluster using the * com...
/* * BridJ - Dynamic and blazing-fast native interop for Java. * http://bridj.googlecode.com/ * * Copyright (c) 2010-2015, <NAME> (http://ochafik.com/) * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditio...
/********************************************************************* * Microsoft Diagnostics Version 2.0 * * A diagnostic utility to detect as much useful information about a * customer's computer system as is possible. * * Microsoft Diagnostics: We detect the World. * * GETINFO.C - Source file with the pr...
/* * Copyright (c) 2013 <NAME> <<EMAIL>> * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2 as * published by the Free Software Foundation. */ #define _GNU_SOURCE #include <stdlib.h> #include <stdbool.h> #include <unistd.h> #i...
/* * * Copyright (c) International Business Machines Corp., 2001 * Copyright (c) Red Hat Inc., 2007 * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the L...
/* * options.c * * Command line options parsing routine for apcupsd. */ /* * Copyright (C) 2000-2004 <NAME> * Copyright (C) 1999-2000 <NAME> <<EMAIL>> * Copyright (C) 1996-99 <NAME> <<EMAIL>> * * This program is free software; you can redistribute it and/or * modify it under the terms of version 2 of the GNU...
/* $NetBSD: insdelln.c,v 1.16 2009/07/22 16:57:15 roy Exp $ */ /* * Copyright (c) 2000 The NetBSD Foundation, Inc. * All rights reserved. * * This code is derived from software contributed to The NetBSD Foundation * by <NAME>. * * Redistribution and use in source and binary forms, with or without * modificatio...
/*- * Copyright (c) 2015 Nuxi, https://nuxi.nl/ * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the f...
/* * Copyright (C) 2015 <NAME> * Copyright (C) 2013-2015 Intel Corporation * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any lat...
/* * test.c * * Created on: Jul 19, 2019 * Author: zhangzm */ #include <stdio.h> #include <stdlib.h> #include <string.h> #include <unistd.h> #include <time.h> #include <sys/types.h> #include <sys/stat.h> #include <sys/socket.h> #include <sys/wait.h> #include <netinet/in.h> #include <arpa/inet.h> #include <ne...
/* stail stail is a simplified version of the well-knowed 'tail' command. //---------------------------------------------------------------------------------- Simplified BSD License Copyright (c) 2012-2013, <NAME> All rights reserved. Redistribution and use in source and binary forms, with or without modification,...
#undef StickyIcons /*#define DEBUG_PAGER */ /*#define DEBUG_X_PAGER */ /*#define DEBUG_BACKGROUNDS*/ typedef struct pager_window { Window w; Window frame; int x; int y; int width; int height; int desk; int frame_x; int frame_y; int frame_width; int frame_height; int title_height; int border...
/* * Copyright 2014 <NAME> * * Licensed under the Apache License, segment_id 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to i...
/* xvdraw.c - Linien, Ellipsen und Rechtecke zeichnen */ # include <xview/frame.h> # include <xview/canvas.h> # include <xview/xv_xrect.h> # define KEY_DRAWING 1 # define KEY_FRAME 2 # define MAX_OBJECTS 100 typedef struct { enum {line, ellipse, rect} type; int x1, y1, x2, y2; } object; typ...
#include <string.h> #include <stdint.h> #include <GL/gl.h> #include <stb_image.h> #include <CNFG.h> #include <chew.h> #include "tophat.h" extern GLuint gRDShaderProg; extern GLuint gRDBlitProg; extern GLuint gRDShaderProgUX; extern GLuint gRDBlitProgUX; extern GLuint gRDBlitProgUT; extern GLuint gRDBlitProgTex; exte...
/* * (C) Copyright 2015 HY Research LLC * Author: <EMAIL> * * Apache License. * * Project magnetometer data onto the X/Y plane using the * accel. Angles are computed from that using trig functions. */ #include <stdio.h> #include <stdint.h> #include "fpsup.h" #include "fp_sensor.h" #include "ecompass.h" st...
#include <gtk/gtk.h> #include <arpa/inet.h> #include <sys/socket.h> #include <netdb.h> #include <ifaddrs.h> #include <string.h> #include <stdio.h> #include <stdlib.h> #include <unistd.h> #include <linux/if_link.h> #define _GNU_SOURCE /* To get defns of NI_MAXSERV and NI_MAXHOST */ // static GtkWidget * create_row...
/* * Copyright (c) 2021 * IoTech Ltd * * SPDX-License-Identifier: Apache-2.0 */ /* Custom application component function implementations */ #include "app-component.h" /* Implementation struct, first member must be the base component type iot_component_t */ struct app_component_t { iot_component_t component; ...
#include <unistd.h> #include <stdio.h> //#include <conio.h> #include <stdlib.h> #include <string.h> #include <time.h> #include <fcntl.h> #include <linux/fb.h> #include <sys/mman.h> // Defines #define clear() printf("\033[H\033[J") #define gotoxy(x, y) printf("\033[%d;%dH", (y), (x)) #define F_COLOR 0x...
#include <stdio.h> #include "helpers/lh_base.h" #include "helpers/lh_inject.h" #include "helpers/lh_sljit.h" #include "lh_module.h" #include <dlfcn.h> #include <sys/mman.h> #include <signal.h> void (*original_test_function) (int a, char *b); void installHooks(){ void *sljit_code = NULL; struct sljit_compiler *comp...
/*s: linkers/5l/asm.c */ #include "l.h" #include "m.h" /*s: function [[entryvalue]](arm) */ long entryvalue(void) { char *a; Sym *s; a = INITENTRY; // usually "_main" /*s: [[entryvalue()]] if digit INITENTRY */ if(*a >= '0' && *a <= '9') return atolwhex(a); /*e: [[entryvalue()]] if dig...
/* 2019 <NAME>, licensed CC0 (public domain worldwide) */ #include <stdio.h> #include <stdint.h> #include <stdlib.h> /* for exit() */ #include <SDL.h> #if defined(PLATFORM_LDK) #include "ldk.h" #endif #define _CLAMP(var, min, max) var = (var < min) ? min : ((var > max) ? max : var) static const ssize_t screen_w...
/* * Copyright (C) 2015 University of Oregon * * You may distribute under the terms of either the GNU General Public * License or the Apache License, as specified in the LICENSE file. * * For more information, see the LICENSE file. */ /* dv7dfl.f -- translated by f2c (version 20090411). You must link the res...
/** * \file * * \brief AVR XMEGA TC45 Driver Example 4 * * Copyright (c) 2014-2018 Microchip Technology Inc. and its subsidiaries. * * \asf_license_start * * \page License * * Subject to your compliance with these terms, you may use Microchip * software and any derivatives exclusively with Microchip product...
// // Binocle // Copyright(C)2015-2020 <NAME> // #include <stdio.h> #ifdef __EMSCRIPTEN__ #include "emscripten.h" #endif #include "binocle_sdl.h" #include "binocle_color.h" #include "binocle_window.h" #include "binocle_game.h" #include "binocle_viewport_adapter.h" #include "binocle_camera.h" #include <binocle_input....
/******************************************************************************/ /** @file project.c @author <NAME> @brief Implementation of the projection operator. @see For external method documentation, @ref project.h. @details @copyright Copyright 2013 <NAME> @license Licensed under the Apache License, Version ...
#include <stdio.h> /* included to allow prototypes with FILE * as parameter or as return value */ /* used a lot as return values */ #define FALSE 0 #define TRUE 1 #define MIN_LENGTH_LABEL 1 /* the minimum length of label */ #define TWELVE_MASK 0xFFF /* a mask used...
#include <stdio.h> #include <stdlib.h> #include <strings.h> #include <string.h> #include <unistd.h> #include <errno.h> #include <sys/socket.h> #include <sys/types.h> #include <arpa/inet.h> #include "common.h" #define LISTENQ 20 #define SERVER_ERRNO __LINE__ #define SERVER_PRINT(_fmt, ...) printf("[%04d] "_fm...
#ifdef WIN32 #include <windows.h> #include <direct.h> #endif #include <stdio.h> #include <string.h> #include <time.h> #include <assert.h> #include "wadlib.h" void Usage(void) { printf("Usage tex2png.exe [-w wad_dir] [-o output_dir] [-s search] [-f] [-oa]\n"); printf(" [-mml level]\n"); printf("Ext...
/* * libhfs - library for reading and writing Macintosh HFS volumes * Copyright (C) 1996-1998 <NAME> * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or ...
/* ************************************************************************** */ /* */ /* ::: :::::::: */ /* fractal.c :+: :+: :+: ...
/** * @file p_flight_dynamics.c * @brief RROSACE Scheduling of cyber-physical system library flight dynamics * body. * @author <NAME> * @version 1.0.0 * @date 2016-06-10 * * Based on the Open Source ROSACE (Research Open-Source Avionics and Control * Engineering) case study. * Implementations of ROSACE availa...
/* $OpenBSD: getopt_long.c,v 1.23 2007/10/31 12:34:57 chl Exp $ */ /* $NetBSD: getopt_long.c,v 1.15 2002/01/31 22:43:40 tv Exp $ */ /* * Copyright (c) 2002 <NAME> <<EMAIL>> * * Permission to use, copy, modify, and distribute this software for any * purpose with or without fee is hereby granted, provided that the a...
/* * Copyright (C) 1997 Massachusetts Institute of Technology * * This software is being provided by the copyright holders under the * following license. By obtaining, using and/or copying this software, * you agree that you have read, understood, and will comply with the * following terms and conditions: * *...
#include <stdbool.h> #include "app_error.h" #include "app_timer.h" #include "app_scheduler.h" #include "nordic_common.h" #define NRF_LOG_MODULE_NAME "SYS_T" #define NRF_LOG_LEVEL 4 #include "nrf_log.h" #include "nrf_log_ctrl.h" #include "nrf_sdm.h" #include "nrf52_counter.h" #include "nrf52_ravel_error.h" #include "...
/* Copyright (C) 2000, 2001 Silicon Graphics, Inc. All Rights Reserved. This program is free software; you can redistribute it and/or modify it under the terms of version 2.1 of the GNU Lesser General Public License as published by the Free Software Foundation. This program is distributed in the hope tha...
/* * Copyright 2021 tevador <<EMAIL>> * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of condit...
/********************************** (C) COPYRIGHT ******************************* * File Name : main.c * Author : WCH * Version : V1.0.0 * Date : 2019/10/15 * Description : Main program body. **************************************************************************...
#include <assert.h> #include <errno.h> #include <fcntl.h> #include <getopt.h> #include <limits.h> #include <signal.h> #include <stdint.h> #include <stdio.h> #include <stdlib.h> #include <string.h> #include <unistd.h> #include <sys/ioctl.h> #include <sys/stat.h> #include <sys/types.h> /* @TODO During kernel upstreamin...
#include "zetnet.h" HttpRequest * HttpRequest_New(char * _type , char * _url , char * _host , char * _referer , const char * _mime , bool _is_binary , char * _content_type , zn_list * _param ) { HttpRequest * http_request=ZN_MALLOC(sizeof(HttpRequest)); strcpy(http_request->type, _t...
// Copyright (c) 2014-2015 The Pebblecoin developers // Copyright (c) 2012-2013 The Cryptonote developers // Distributed under the MIT/X11 software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. #pragma once #include <cstdint> #define CRYPTONOTE_MAX_BLOCK_NUMBER ...
/* * Copyright (c) 2020, Cascoda Ltd. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of con...
/* Copyright (c) 2017-2018, The Tor Project, Inc. */ /* See LICENSE for licensing information */ #include "or/or.h" #include "lib/crypt_ops/crypto_rand.h" #include "common/address_set.h" #include "or/microdesc.h" #include "or/networkstatus.h" #include "or/nodelist.h" #include "or/routerlist.h" #include "or/torcert.h" ...
#include "log.h" #include <stdarg.h> #include <stdio.h> #include <string.h> // for memset #include <calendon/string.h> CnLogHandle LogSysMain; const char* g_logSystemNames[CN_LOG_MAX_SYSTEMS]; /** * Log functions don't work until the logging system is initialized, so that * needs to be tracked. */ static bool...
/* * Copyright (c) 2019 Intel Corporation * * SPDX-License-Identifier: Apache-2.0 */ #include <zephyr/kernel.h> #include <string.h> #include <zephyr/arch/x86/multiboot.h> #include <zephyr/arch/x86/memmap.h> struct multiboot_info multiboot_info; /* * called very early in the boot process to fetch data out of the...
/* compile with `cc -O2 monorale_encoder.c -o monorale_encoder` */ #include <assert.h> #include <stdint.h> #include <stdio.h> #include <stdlib.h> #include <string.h> #include <stdbool.h> #include <getopt.h> #define GREY_THRESHOLD (33808) /* grey */ #define SCREEN_SZ (400*240) typedef uint16_t rle_t; #define RLE_...
/* EDEF: Global variable definitions for MicroEMACS 3.2 written by <NAME> modified by <NAME>, <NAME> greatly modified by <NAME> */ /* some global fuction declarations */ /* char *malloc(); */ #include <stdlib.h> #include <string.h> #ifdef maindef /* for MAIN.C */ /* initialized global definitions */ ...
/* * e2undo.c - Replay an undo log onto an ext2/3/4 filesystem * * Copyright IBM Corporation, 2007 * Author <NAME> <<EMAIL>> * * %Begin-Header% * This file may be redistributed under the terms of the GNU Public * License. * %End-Header% */ #include <stdio.h> #include <stdlib.h> #ifdef HAVE_GETOPT_H #include ...
#include <u.h> #include <libc.h> void split(char *, char **, char **); int samefile(char *, char *); int mv(char *from, char *todir, char *toelem); int copy1(int fdf, int fdt, char *from, char *to); void main(int argc, char *argv[]) { int i; Dir dirto, dirfrom; char *todir, *toelem; if(argc<3){ fprint(2, "usag...
//<NAME>, nUSP: 11369767 //<NAME>, nUSP: 11796594 #include "funcoesArvB.h" #include "funcoesLeitura.h" #include "funcoesEscrita.h" #include "funcoesFornecidas.h" /* * Funcionalidades do Trabalho 2 Utilizadas */ // Função que nos auxilia na escrita de cada um dos campos do cabecalho da arvore, alocando lixo no fi...
/* * SMPTE 302M decoder * Copyright (c) 2008 <NAME> <<EMAIL>> * Copyright (c) 2009 <NAME> <<EMAIL>> * * This file is part of FFmpeg. * * FFmpeg is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public * License as published by the Free Software Foundation; e...
#include <u.h> #include <libc.h> #include <bio.h> #include "snap.h" void panic(char *s) { fprint(2, "%s\n", s); abort(); exits(s); } static Proc* findpid(Proc *plist, long pid) { while(plist) { if(plist->pid == pid) break; plist = plist->link; } return plist; } Page* findpage(Proc *plist, long pid, int ...
/* * stereo.c * * Implementation of stereo.h * * See the header for further information. */ #include "stereo.h" #include <stdlib.h> #include <string.h> /* * Static data * =========== */ /* * The flatten flag. * * If non-zero, it means that single-channel flattening has been * requested with stereo_fl...
// Copyright 2015 Heidelberg University Copyright and related rights are // licensed under the Solderpad Hardware License, Version 0.51 (the "License"); // you may not use this file except in compliance with the License. You may obtain // a copy of the License at http://solderpad.org/licenses/SHL-0.51. Unless // requir...
#include <stdlib.h> #include <stdio.h> #include <string.h> #include <errno.h> #include <assert.h> #include "../include/data.h" #include "../include/entry.h" #include "../include/serialization.h" void pee(const char *msg) { perror(msg); exit(0); } /*************************************************************...
/* Copyright (c) 2009-2010 Xiph.Org Foundation Written by <NAME> */ /* Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: - Redistributions of source code must retain the above copyright notice, this list of c...
/*---------------------------------------------------------------------------- * File: ooaofooa_R_RGO_class.c * * Class: Referring Class In Assoc (R_RGO) * Component: ooaofooa * * your copyright statement can go here (from te_copyright.body) *-----------------------------------------------------...
#pragma once #include <stdbool.h> #include <stdint.h> #include <stddef.h> // only for contracts #include "arch/cache.h" //@ #include <list.gh> //@ #include "proof/listexex.gh" #ifdef VERIFAST // VeriFast does not support 'restrict', let's verify without it (which is sound since restrict adds constraints so we're ef...
/* PR c/63357 */ /* { dg-do compile } */ /* { dg-options "-Wlogical-op" } */ #ifndef __cplusplus # define bool _Bool # define true 1 # define false 0 #endif #if __SIZEOF_INT__ < 4 __extension__ typedef __INT32_TYPE__ int32_t; __extension__ typedef __UINT32_TYPE__ uint32_t; __extension__ typedef __INT16_TYPE__ i...
/* Copyright (c) 2011 <NAME> <<EMAIL>> Copyright (c) 2011 Center for Bioinformatics, University of Hamburg Permission to use, copy, modify, and distribute this software for any purpose with or without fee is hereby granted, provided that the above copyright notice and this permission notice appear in all cop...
/*------------------------------------------------------------------------- * * hio.c-- * POSTGRES heap access method input/output code. * * Copyright (c) 1994, Regents of the University of California * * * IDENTIFICATION * $Id: hio.c,v 1.1.1.1 1996/07/09 06:21:11 scrappy Exp $ * *---------------------...
/* * flash.c * * Created on: 2019/4/8 * Author: lc */ #include <stdio.h> #include <string.h> #include <stdlib.h> #include <stdint.h> #include <stdbool.h> #include "fibo_opencpu.h" #include "msg.h" #include "log.h" #include "types.h" #include "flash.h" #define FLASH_APPIMG_BASE 0x60000000 //unused,...
/* FreeRTOS V9.0.0rc2 - Copyright (C) 2016 Real Time Engineers Ltd. All rights reserved VISIT http://www.FreeRTOS.org TO ENSURE YOU ARE USING THE LATEST VERSION. This file is part of the FreeRTOS distribution. FreeRTOS is free software; you can redistribute it and/or modify it under ...
/* arvore.c Autor: <NAME> Data: 27/08/17 */ #include "arvore.h" // Devolve índice correspondente aos filhos da esquerda de um nó int esquerda(int i){ return 2*i; } // Devolve índice correspondente aos filhos da direita de um nó int direita(int i){ return 2*i + 1; } // Devolve índice correspondente ao meio do veto...
/* * linux/net/sunrpc/socklib.c * * Common socket helper routines for RPC client and server * * Copyright (C) 1995, 1996 <NAME> <<EMAIL>> */ #include <linux/compiler.h> #include <linux/netdevice.h> #include <linux/gfp.h> #include <linux/skbuff.h> #include <linux/types.h> #include <linux/pagemap.h> #include <linu...
#include "drm_util.h" #include "errors.h" #include "vcap.h" #include <assert.h> #include <getopt.h> #include <poll.h> #include <stdbool.h> #include <stdio.h> #include <stdlib.h> typedef bool (*frame_notify_t)(buf_t, uint32_t); static void capture_loop(frame_notify_t notify) { bool const continuous = (frame_count =...
/* * Copyright (c) 2009, NSF Cloud and Autonomic Computing Center, Rutgers University * All rights reserved. * * Redistribution and use in source and binary forms, with or without modification, are permitted provided * that the following conditions are met: * * - Redistributions of source code must retain the ab...
/* Copyright (C) 2003-2008, 2012-2013, 2017 <NAME> <<EMAIL>> This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. Thi...
#include "archivist/table.h" #include <errno.h> #include <stdbool.h> #include <stdint.h> #include <stdlib.h> #include "archivist/hash.h" #include "archivist/list.h" #include "archivist/uuid.h" #include "archivist/record.h" #define _ARCH_TABLE_INHERITP(record) (record->data[0]) #define _ARCH_TABLE_INDEX_NIL ARCH_SIZE_M...
#include "20161641.h" void printError(int errorCase){ // 에러 종류별 에러구문 출력 switch(errorCase){ case MEMORY_ERROR_VALUE_EXCEED: printf("VALUE OUT OF RANGE\n"); break; case MEMORY_ERROR_ADDRESS_EXCEED: printf("ADDRESS OUT OF RANGE\n"); break; case MEMORY_ERROR_ADDRESS_START_END: printf("START ADDRESS IS...
/* * Variant Inlines * * Copyright 2003 <NAME> * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public * License as published by the Free Software Foundation; either * version 2.1 of the License, or (at your option) any later version. * * ...
/* * Copyright (c) 2021 <NAME> <<EMAIL>> * * SPDX-License-Identifier: Apache-2.0 */ #include <zephyr/drivers/mbox.h> #include <nrfx_ipc.h> #define LOG_LEVEL CONFIG_MBOX_LOG_LEVEL #include <zephyr/logging/log.h> LOG_MODULE_REGISTER(mbox_nrfx_ipc); #define DT_DRV_COMPAT nordic_mbox_nrf_ipc struct mbox_nrf_data { ...
#include <vr_core.h> static pthread_rwlock_t rwlocker; static dlist *slowlog; /* SLOWLOG list of commands */ static long long slowlog_entry_id; /* SLOWLOG current entry ID */ /* Create a new slowlog entry. * Incrementing the ref count of all the objects retained is up to * this function. */ slo...
/* sb.c - string buffer manipulation routines Copyright 1994, 1995, 2000, 2003 Free Software Foundation, Inc. Written by Steve and <NAME> of Cygnus Support, <EMAIL> This file is part of GAS, the GNU Assembler. GAS is free software; you can redistribute it and/or modify it under the terms of the ...
/* * Copyright (c) 2017, The OpenThread Authors. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * 1. Redistributions of source code must retain the above copyright * notice, this ...
/* * * Copyright 2015, Google Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are * met: * * * Redistributions of source code must retain the above copyright * notice, this list of condi...
/* * This program gets the out-degree and in-degree of a particular node in * a graph represented by adjacency list. The out-degree is the number of * nodes to which a given node has out-going edges. The in-degree of a node * in the graph is the number of nodes which have edges going into this * node. * TODO:DOC ...
/* Part of the code in this file has been copied and modified from ARM copyrighted code, following is the copyright information. The copyrighted code is unrelated to the AES implementation */ /* Copyright (c) 2013 - 2016 ARM LIMITED All rights reserved. Redistribution and use in source and binary fo...
/********************************************************************** * gostsum.c * * Copyright (c) 2005-2006 Cryptocom LTD * * This file is distributed under the same license as OpenSSL * * ...
/* ** MXR - A Simple Audio Mixer ** Copyright (c) 2017 by <NAME>. ** ** Permission is given by the author to use this version of MXR freely, ** provided that the message "Copyright (c) 2017 by <NAME>" in this ** and associated files is not changed or removed. ** ** See "mxr.h" for details. */ #include "mxr.h" /*******...
/*- * Copyright (c) 1998 <NAME> <<EMAIL>> * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of co...
#include <ctype.h> #include <dirent.h> #include <errno.h> #include <stdbool.h> #include <stdio.h> #include <stdlib.h> #include <string.h> #include <sys/types.h> #define require(exp) do { \ if (!(exp)) { \ fprintf(stderr, "\"%s\" failed in %s:%d (%s)\n", #exp, __FILE__, __LINE__, strerror(errno)); \ ...
#define NULL ((void*)0) typedef unsigned long size_t; // Customize by platform. typedef long intptr_t; typedef unsigned long uintptr_t; typedef long scalar_t__; // Either arithmetic or pointer type. /* By default, we understand bool (as a convenience). */ typedef int bool; #define false 0 #define true 1 /* Forward d...
/*---------------------------------------------------------------------------- * Copyright (c) <2016-2018>, <Huawei Technologies Co., Ltd> * All rights reserved. * Redistribution and use in source and binary forms, with or without modification, * are permitted provided that the following conditions are met: * 1. R...
#include <synos/synos.h> #include <synos/mm.h> #include <string.h> void *heap_start; mheader_t *header_start; mpointer_t *pointer_start; bool MemStack_init = false; bool MemStack_enable = true; uintptr_t MemStack; int mm_init() { vpage_init(); ppage_init(); // Allocate first page for the heap heap_s...
/** * @file bmp.h * @author rmyamaguchi (<EMAIL>) * @brief BMP related stuff * @version 0.1 * @date 2020-02-21 * * @copyright Copyright (c) 2020 * */ #include "bmp.h" static byte vb_background[] = {0xff, 0xff, 0xff}; /* white */ /** * @brief Computes the Lowest Multiple of a Power of 2 Greater than or Eq...
/* * ESPRESSIF MIT License * * Copyright (c) 2018 <ESPRESSIF SYSTEMS (SHANGHAI) PTE LTD> * * Permission is hereby granted for use on all ESPRESSIF SYSTEMS products, in which case, * it is free of charge, to any person obtaining a copy of this software and associated * documentation files (the "Software"), to dea...