text stringlengths 3.12k 18.7k |
|---|
/*
* Copyright (C) 2018 Texas Instruments Incorporated - http://www.ti.com/
*
*
* 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
* ... |
#include <assert.h>
#include <stdlib.h>
#include <stdio.h>
#include <stdarg.h>
#include <ctype.h>
#include <string.h>
#include <unistd.h>
#include "picosat.h"
typedef struct Clause {
int cid, *lits;
struct Clause *next;
} Clause;
typedef struct MCS {
int mid, *clauses;
struct MCS *next;
} MCS;
static... |
/*
Copyright (c) 2009 <NAME> and <NAME>, University of Geneva
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 ... |
/*********************************************************************************************
* File�� tp.c
* Author: embest
* Desc�� LCD touch screen control function
* History:
*********************************************************************************************/
/*--- include files ---*/
#include <string... |
/*
* Copyright (c) 1997-1999 Massachusetts Institute of Technology
*
* 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 later versio... |
/* printline.c
* <NAME>
Jgraph - A program for plotting graphs in postscript.
* $Source: /Users/plank/src/jgraph/RCS/printline.c,v $
* $Revision: 8.5 $
* $Date: 2017/11/28 17:33:27 $
* $Author: plank $
<NAME>
Department of Electrical Engineering and Computer Science
University of Tennessee
Knoxville, TN 37996
... |
#include "terminal.h"
#include "lib.h"
#include "syscalls.h"
#include "types.h"
#include "i8259.h"
#include "paging.h"
#include "scheduler.h"
#define LOCATION 2*NUM_ROWS*NUM_COLS
/* current terminal declaration */
volatile uint8_t cur_term;
term_t terminal[MAX_TERM];
/*
* init_terminal()
* DESCRIPTION: Initialize... |
/**
* Copyright 2015 <NAME>
*
* Licensed under the Apache License, Version 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 in writ... |
#include "sympow.h"
#define DEBUG (FALSE || GLOBAL_DEBUG)
llint BOUND; int SQBND,*small_prime;
extern double EXPANSION_AROUND_ZERO_LIMIT;
QD *SUM,**coeff_small,***coeff_primepower;
#define NS CURR_MAX
static void malloc_arrays(int SQBND,int NUMP)
{int i,j; QD **P; if (DEBUG) printf("malloc_arrays %i %i\n",SQBND,NUMP)... |
/******************************************************************************
Copyright (C) 2013 by <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 2... |
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <libgen.h>
#include <unistd.h>
#include <dirent.h>
#include "parse.h"
#include "extractArchive.h"
#include "helper.h"
#include "cJSON.h"
void parseZip(char *arg1){
char *fileExt = strrchr(arg1, '.'); // Check file extension if present
if (fileExt =... |
/**********************************************************************
BHS.c:
BHS.c is a subroutine to calculate norm conseving pseudo
potentials using BHS's scheme.
Log of BHS.c:
10/Dec/2002 Released by T.Ozaki
***********************************************************************/
#include ... |
/*-
* Copyright (c) 1990, 1993
* The Regents of the University of California. All rights reserved.
*
* Portions copyright (c) 1999, 2000
* Intel Corporation.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the followin... |
#include "main.h"
#include "backProcess.h"
#include "foreProcess.h"
#include "history.h"
#include "ls.h"
#include "pinfo.h"
#include "signal_handlers.h"
#include "cd.h"
#include "nightswatch.h"
#include "jobs.h"
#include "kjob.h"
#include "overkill.h"
#include "fg.h"
#include "bg.h"
#include "util.h"
void command_hand... |
/*
* This file is part of the kyuba.org Dev9 project.
* See the appropriate repository at http://git.kyuba.org/ for exact file
* modification records.
*/
/*
* Copyright (c) 2008-2014, Kyuba Project Members
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and as... |
#include <assert.h>
#include <wchar.h>
#include <string.h>
#include "freetype-gl.h"
#include "vertex-buffer.h"
#include "mat4.h"
#include "utils.h"
#include "evil.h"
#include "font.h"
#include "shader.h"
static const char* VERTEX_SHADER = \
"uniform mat4 projection; \
attribute vec3 vertex; \
attribute vec2 tex_coord... |
/*
* Dynamic pipelines example, uridecodebin with sinks added and removed
*
* Copyright (c) 2014 <NAME> <<EMAIL>>
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction... |
/**
* Copyright (c) 2006-2010 Spotify Ltd
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, p... |
//
// Sample adaptative entropy coder for CCSDS123-B-2 issue
// Created by Wesley on 2/22/2022
//
#include "sample_adaptative.h"
unsigned int mlog2( unsigned int x ) {
unsigned int ans = 0 ;
while( x >>= 1 ) ans++;
return ans;
}
void write_bits(int data, int size){
int i;
for (i = size-1; i >= 0... |
/*
* Academic License - for use in teaching, academic research, and meeting
* course requirements at degree granting institutions only. Not for
* government, commercial, or other organizational use.
*
* cross.c
*
* Code generation for function 'cross'
*
*/
/* Include files */
#include "rt_nonfinite.h"
#inclu... |
//-----------------------------------------------------------------------------
// Copyright (c) 2018 Semiconductor Components Industries LLC
// (d/b/a "ON Semiconductor"). All rights reserved.
// This software and/or documentation is licensed by ON Semiconductor under
// limited terms and conditions. The terms and c... |
#include "q.h"
#include "integrals.h"
#include "gc.h"
#include "nlmc.h"
double kinetic_scale(
int n1, int l1, int m1,
int n2, int l2, int m2,
double a, double b, double u,
double ra[3], double rb[3], double ru[3],
double rab[3]){
/* Computes ``scaled'' kinetic energy (up to a constant)
* ... |
/*
* Copyright (c) 2020 <NAME> <<EMAIL>>
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, pu... |
/* Copyright (C) 2001-2021 Artifex Software, Inc.
All Rights Reserved.
This software is provided AS-IS with no warranty, either express or
implied.
This software is distributed under license and may not be copied,
modified or distributed except as expressly authorized under the terms
of the license ... |
/*
* CDDL HEADER START
*
* The contents of this file are subject to the terms of the
* Common Development and Distribution License (the "License").
* You may not use this file except in compliance with the License.
*
* You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
* or http://www.opensolar... |
/*
* $QNXLicenseC:
* Copyright 2008, QNX Software Systems.
*
* Licensed under the Apache License, Version 2.0 (the "License"). You
* may not reproduce, modify or distribute this software except in
* compliance with the License. You may obtain a copy of the License
* at: http://www.apache.org/licenses/... |
/**
******************************************************************************
* @file IAP_Main/Src/flash_if.c
* @author MCD Application Team
* @version 1.0.0
* @date 8-April-2015
* @brief This file provides all the memory related operation functions.
*********************************... |
/* id_ttp.c: Interdata PASLA console interface
Copyright (c) 2000-2012, <NAME>
Permission is hereby granted, free of charge, to any person obtaining a
copy of this software and associated documentation files (the "Software"),
to deal in the Software without restriction, including without limitation
... |
#include "cogcatmullrom3.h"
static CogVector3 _evalSegmentPosition3(const CogCatmullRom3 spline, const float t, const int segment) {
int i = segment + 1;
float t2 = t * t;
float t3 = t2 * t;
return (CogVector3) {
.x = 0.5f * ( (2.0f * spline->points->data[i].x) +
( -spline->point... |
/* An example of using kallsyms data in a kernel debugger.
Copyright 2000 <NAME> <<EMAIL>> April 2000
This file is part of the Linux modutils.
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 Fou... |
/*
* Copyright (c) 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* The Universal Permissive License (UPL), Version 1.0
*
* Subject to the condition set forth below, permission is hereby granted to any
* person obtaining a copy of this s... |
/*
* Copyright (c) 2010 Telechips, Inc.
*
* Permission is hereby granted, free of charge, to any person obtaining
* a copy of this software and associated documentation files
* (the "Software"), to deal in the Software without restriction,
* including without limitation the rights to use, copy, modify, merge,
* ... |
#include "ctxt.h"
#include "install.h"
struct install_item insthier[] = {
{INST_MKDIR, 0, 0, ctxt_bindir, 0, 0, 0755},
{INST_MKDIR, 0, 0, ctxt_incdir, 0, 0, 0755},
{INST_MKDIR, 0, 0, ctxt_dlibdir, 0, 0, 0755},
{INST_MKDIR, 0, 0, ctxt_slibdir, 0, 0, 0755},
{INST_MKDIR, 0, 0, ctxt_repos, 0, 0, 0755},
{INST_C... |
#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... |
#include <stdlib.h>
#include <stdint.h>
#include <stdbool.h>
#include <sys/mman.h>
#include <string.h>
#include <signal.h>
#include <stdio.h>
// OS X compatibility
#ifndef PAGESIZE
#include <unistd.h>
#define PAGESIZE (getpagesize())
#endif
// Linux compatibiity
#ifndef MAP_ANON
#define MAP_ANON MAP_ANONYMOUS
#endif
... |
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
#include "uart.h"
typedef enum {
WRITE = 1,
READ = 2
} cmd_t;
typedef struct write_request {
cmd_t type;
uart_cb user_cb;
uint8_t uart_num;
uint8_t* buf;
int len;
struct write_request* next;
} request_t;
static int uart_dispatch_request(r... |
/*
* Copyright (c), NXP Semiconductors Bangalore / India
*
* (C)NXP Semiconductors
* All rights are reserved. Reproduction in whole or in part is
* prohibited without the written consent of the copyright owner.
* NXP reserves the right to make changes without notice at any time.
... |
/* -----------------------------------------------------------------------------
*
* (c) The GHC Team 1998-2008
*
* Weak pointers and weak-like things in the GC
*
* Documentation on the architecture of the Garbage Collector can be
* found in the online commentary:
*
* http://hackage.haskell.org/trac/ghc/wik... |
/*************************************************************************
> FileName: cairo-demo6.c
> Author : DingJing
> Mail : <EMAIL>
> Created Time: Вс 22 дек 2019 16:34:32
************************************************************************/
#include <cairo.h>
#include <math.h>
#define WIDTH 600
#defin... |
/*
* eeprom.c
* Copyright (C) 2016 xent
* Project is distributed under the terms of the MIT License
*/
#include <halm/irq.h>
#include <halm/platform/lpc/clocking.h>
#include <halm/platform/lpc/eeprom.h>
#include <halm/platform/lpc/lpc43xx/eeprom_defs.h>
#include <assert.h>
#include <string.h>
/*-------------------... |
/* qw - A minimalistic text editor by grunfink - public domain */
#include "qw.h"
#include <stdlib.h>
#include <string.h>
#include <ctype.h>
/** code **/
qw_synhi *qw_synhi_find_by_name(const char *name, qw_synhi *list)
/* finds a syntax highlight definition by name */
{
while (list && strcmp(name, list->name)... |
// based on sketch.c from Minimap2
// https://github.com/lh3/minimap2
#include <stdio.h>
#include <stdlib.h>
#include <assert.h>
#include <string.h>
#include "bloom.h"
#include "hashmap.h"
#include "heap.h"
#include "slog.h"
unsigned char seq_nt4_table[256] = {
0, 1, 2, 3, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4,
4, ... |
#include "../tools/tools.h"
#include "../tools/easySdl2.h"
#include "commands.h"
#include "display.h"
enum {VN1 = -20, V0 = 0, V1 = 20, V2 = 45, V3 = 60};
typedef struct {
int speed;
double lat;
double lon;
double distToNext;
} t_point;
typedef struct {
double lat;
double lon;
int indexLastPoint;
double dist... |
/**
* \file
* \brief Quadrature encoder
* \author <NAME>, <EMAIL>
*
* This module implements decoding the quadrature position encoders.
*/
#include "Platform.h"
#include "McuLib.h"
#include "Pin.h"
#include "Quadrature.h"
#if PL_CONFIG_HAS_SHELL
#include "McuShell.h"
#include "McuUtility.h"
#endif
#define Q... |
#include <stdint.h>
#include <string.h>
#include "piezo.h"
#include <libopencm3/stm32/gpio.h>
#include <libopencm3/stm32/rcc.h>
#include <libopencm3/stm32/timer.h>
#include <libopencm3/cm3/nvic.h>
#define PIEZO_PORT GPIOB
#define PIEZO_PIN GPIO0
#define MIN(x, y) (((x) < (y)) ? (x) : (y))
/* Inspired by Rich's piezo... |
/*
B.Wolfe | V00205547
SENG 265 - Assignment 1
Description: This program is phase 1 of a text compression scheme. The Program
performs the transformation forwards and backwards in word sizes up to 20
characters. The program adjusts depending on the compression scheme used and
implements a number of error checks to ... |
/* Copyright (c) 1993
* <NAME> (<EMAIL>)
* <NAME> (<EMAIL>)
* Copyright (c) 1987 <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, or (at your option)
... |
#include "polynomial_adt.h"
PolyAdt *create_adt(int hp)
{
PolyAdt *pAdt = malloc(sizeof(PolyAdt));
assert(pAdt != NULL);
pAdt->head = NULL;
pAdt->terms = 0;
pAdt->hp = hp;
return pAdt;
}
void insert_term(PolyAdt *pAdt, float c, int e)
{
assert(pAdt != NULL); //assume client code didn... |
/*
* arm64
*/
#define NSNAME 8
#define NSYM 50
#define NREG 32
#define NOPROF (1<<0)
#define DUPOK (1<<1)
#define REGRET 0
#define REGARG 0
/* R1 to R7 are potential parameter/return registers */
#define REGIRL 8 /* indirect result location (TO DO) */
/* compiler allocates R9 up as temps */
/* compiler all... |
#include <stdio.h>
#include <stdlib.h>
#include <math.h>
#include <sys/types.h>
#include <sys/stat.h>
#include <unistd.h>
#include <locale.h>
#include <gmt.h>
#include "libget.h"
/*
* grad2vs30: convert topographic slope to Vs30
*
* Takes three input files, each formatted GMT grd files
* and point for point co-... |
#include <stdbool.h>
#include "disk.h"
struct mbr_t {
struct {
uint8_t status;
/* Head Sector Track */
uint8_t hst[3];
uint8_t type;
uint8_t end_hst[3];
} entries[4];
};
struct fat_t fat_new(size_t offset) {
fat_t ret = {
/* - 0x200 because 0x8000 is start of second sector */
.buf = (fat_bs_t *) ((ui... |
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#define thisprog "xe-strxmlparse1"
#define TITLE_STRING thisprog" v 6: 10.October.2018 [JRH]"
#define MAXWORDLEN 256
/*
<TAGS>string</TAGS>
v 6: 18.January.2019 [JRH]
- bugfix: avoid string-copies and additional memory allocation - shift indices instead
v ... |
#define _GNU_SOURCE
#include <sys/wait.h>
#include <sys/mount.h>
#include <stdio.h>
#include <stdlib.h>
#include <sched.h>
#include <unistd.h>
#include <string.h>
#include <fcntl.h>
#include <mqueue.h>
#include <time.h>
// Define size of space for stack used by child process
#define STACK_SIZE (64 * 1024)
// Define ... |
/* Program to test the vga_waitevent function. */
#include <stdlib.h>
#include <stdio.h>
#include <unistd.h>
#include <sys/time.h>
#include <sys/types.h>
#include <vga.h>
#include <vgagl.h>
#include <vgamouse.h>
#include <vgakeyboard.h>
#define USE_RAWKEYBOARD
static int newcolor(void)
{
if (BYTESPERPIXEL == 1)
... |
/*
* crew.c
*
* Demonstrate a work crew implementing a simple parallel search
* through a directory tree.
*
* Special notes: On a Solaris 2.5 uniprocessor, this test will
* not produce interleaved output unless extra LWPs are created
* by calling thr_setconcurrency(), because threads are not
* timesliced.
*/
... |
/*
gc-lru-repl.c - perfect LRU replacement implementation for all caches
Copyright 2003-2007 Virtutech AB
The contents herein are Source Code which are a subset of Licensed
Software pursuant to the terms of the Virtutech Simics Software
License Agreement (the "Agreement"), and are being distributed under
... |
/*
* This file is part of the libpayload project.
*
* Copyright (C) 2008 Advanced Micro Devices, Inc.
*
* 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 c... |
/*
* configsym.h - Offsets into the mpars structure
* When the mpars structure is changed,
* change these define's too.
*
* $Id: configsym.h,v 1.1.1.1 2003/03/30 18:55:48 al-guest Exp $
*
* This file is part of the minicom communications package,
* Copyright 1991-1995 <NAME>.
*
* This program is fre... |
/*
* Copyright 2020 ReliaSolve, Inc.
*
* Licensed under the Apache License, Version 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... |
// this file contains helpers for the compositing part of the window manager prototype
#include <wm.h>
#include <X11/extensions/Xcomposite.h>
// we need to use Xfixes because, for whatever reason, X (and even Xcomposite, which is even weirder) doesn't include a way to make windows transparent to events
#include <X1... |
/*! @file
@brief
UART class for Cypress PSoC5LP
<pre>
Copyright (C) 2018-2021 Kyushu Institute of Technology.
Copyright (C) 2018-2021 Shimane IT Open-Innovation Center.
This file is distributed under BSD 3-Clause License.
(Usage)
Hardware configration.
1. Use PSoC Creator, place "Communication > ... |
/* Copyright (c) 2013, <NAME>
* 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 conditions and the... |
/********************************************************************
* File : bapi.h
* Author : <NAME> Copyright (C) 1994-2019
* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://moz... |
/*
* Copyright (c) 2016, Freescale Semiconductor, Inc.
* Copyright 2017 NXP
* All rights reserved.
*
* SPDX-License-Identifier: BSD-3-Clause
*/
/**
* @file diff_p_demo.c
* @brief The diff_p_demo.c file implements the ISSDK DIFF_P sensor driver
* example demonstration with Interrupt mode.
*/
//-------... |
/*
* Copyright (C) 2018-2019 <NAME>
*/
#include <vtf.h>
#include <string.h>
#include <vtm/core/math.h>
#include <vtm/core/variant.h>
#define VTM_TEST_VALUE(VAR, TYPE, ELEM, VAL) \
do { ... |
#include "unes.h"
// ppu.c controls
extern nt_mirroring_mode_t ppu_ntmirroring_mode;
extern uint8_t* ppu_pattern[2];
extern bool ppu_need_screen_update;
// cpu.c controls
extern const uint8_t* cpu_prgrom[2];
extern uint8_t cpu_sram[0x2000];
extern const void* ppu_pattern_base_addr;
// rom.c globals
bool rom_chrdata_... |
#include <inttypes.h>
#include <stdio.h>
#include <stdlib.h>
#include <errno.h>
#include <string.h>
#include <ctype.h>
#include <sys/types.h>
#include "equations.h"
#include "functions.h"
static double executeEquationStep(Equation*, size_t);
static eqfunc parseFunctionName(const char*, const char**);
static int parseE... |
/*
* BMS1.h
*
* Created on: Oct 24, 2021
* Author: Martin
* Brief: Module for one-way communication with BMS on battery pack ()
*/
#include "BMS1.h"
#include "VARS.h"
static uint8_t mRxData[DMA_REC_LENGTH +2]; // buffer for reception of raw BMS data
static uint8_t* mBmsData;
static uint8_t mNewData... |
#include "ricochet_plugin.h"
// Function: upgrade(uint256 amount)
// Selector: 0x45977d03
static const uint8_t UPGRADE_SELECTOR[SELECTOR_SIZE] = {0x45, 0x97, 0x7d, 0x03};
// Function: upgradeToETH()
// Selector: 0xcf81464b
static const uint8_t UPGRADE_TO_ETH_SELECTOR[SELECTOR_SIZE] = {0xcf, 0x81, 0x46, 0x4b};
// Fun... |
/*
---------------------------
Authors:
- <NAME>
- GitHub ID: Prometheus59
- 160349950
- <NAME>
- GitHub ID: Raman-Saini
- 170627510
Github:
- Repository Link: https://github.com/Prometheus59/deadlock-be-gone
Date:
- August 1, 2020
Desc:
- CP386 Assignment Four - Deadlock-Be-Gone
--------... |
/*
* CDDL HEADER START
*
* The contents of this file are subject to the terms of the
* Common Development and Distribution License (the "License").
* You may not use this file except in compliance with the License.
*
* You can obtain a copy of the license at src/OPENSOLARIS.LICENSE
* or http://www.opensolaris.o... |
#include <stdio.h>
#include <stdint.h>
#include <stdlib.h>
#include <unistd.h>
#include <fcntl.h>
#include <errno.h>
#include <sys/ptrace.h>
#include <sys/mman.h>
#include <cutils/properties.h>
#include <jni.h>
#include <inttypes.h>
/* include the common system property implementation definitions */
#define _REALLY_IN... |
#include <ctype.h>
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
#include <time.h>
#include <sys/stat.h>
#include <unistd.h>
#include "lizard.h"
#include "map.h"
#include "lizgame.h"
#include "filefunc.h"
char *lzOnStr = "on";
char *lzOffStr = "off";
char *data_path = "DATA";
char *game_code;
void show_... |
/*
* Copyright 2017-2019 NXP
* All rights reserved.
*
* SPDX-License-Identifier: BSD-3-Clause
*/
/* SDK Included Files */
#include "board.h"
#include "fsl_debug_console.h"
#include "fsl_i2c.h"
#include "fsl_dma.h"
#include "pin_mux.h"
/****************************************************************************... |
/*
* Authors: <NAME> <<EMAIL>>
*
* $Id: terminator.c,v 1.3 2006/12/19 08:33:17 hochstenbach Exp $
*
*/
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <stdarg.h>
#include <errno.h>
#include <sys/stat.h>
#include <sys/types.h>
#include <sys/file.h>
#include <unistd.h>
#include <cgi-util.h>
#in... |
#include "c_utils.h"
#include <stdlib.h>
#include <math.h>
/*{{{ Encode*/
int intArray2Bool(int * arr, int size, int bit_len, int * dst_arr){
for(int idx = 0; idx < size; idx++){
int2Bool(arr[idx], dst_arr, bit_len);
dst_arr += bit_len;
}
return 0;
}
... |
/*
Author: <NAME> <<EMAIL>>
Copyright (c) 2015 Cromulence LLC
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, m... |
// Bibliotecas utilizadas
#include <stdlib.h>
#include <stdio.h>
#include <jpeglib.h>
#include <inttypes.h>
#include <sys/types.h>
#include <sys/wait.h>
#include <unistd.h>
// Se definen constantes para el pipe
#define READ 0
#define WRITE 1
// Esta estructura contiene la informacion escencial de la imagen.
// Esta d... |
#include "sys_command_line.h"
#include "usart.h"
#include "ICOPYX_BSP.h"
//#define commdebug
static uint8_t cli_presspm3(void *para, uint8_t len);
static uint8_t cli_turnoffpm3(void *para, uint8_t len);
static uint8_t cli_turnonpm3(void *para, uint8_t len);
static uint8_t cli_restartpm3(void *para, uint8_t len);
stat... |
#include <stdio.h>
#include <stdlib.h>
#include <sys/types.h>
#include "include/matestr.h"
#include "include/tableflip.h"
typedef unsigned char bool; /* lol */
#define readln __tf_readln
bool __tf_readln(const char *content, matestr *ln, size_t *offset) {
size_t old_offset;
ln->length = 0;
matestr_normalize(ln);... |
/*-*- Mode: C; c-basic-offset: 8; indent-tabs-mode: nil -*-*/
#pragma once
/***
This file is part of systemd.
Copyright 2010 <NAME>
systemd 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; eith... |
/*************************************************************************
* arp.c
*
* arp = Address Resolution Protocol
* Project: eZ2944
*************************************************************************/
#include <stdio.h>
#include <string.h>
#include "project.h"
#include "bmz.h"
#include "tcpip.h"
#in... |
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
#include <openssl/evp.h>
#include <openssl/err.h>
#include <openssl/conf.h>
#include <openssl/cmac.h>
#define BLOCK_SIZE 16
#define CMAC_SIZE 16
#define AES_ECB(bits) (bits == 128) ? EVP_aes_128_ecb() : EVP_aes_256_ecb()
/* function prot... |
/*
* Copyright 1998-2018 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the Apache License 2.0 (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
* in the file LICENSE in the source distribution or at
* https://www.openssl.org/source/l... |
/*
* ____ ____ __ __ ______ ______
* /\ _`\ /\ _`\ /\ \ /\ \ /\__ _\/\ _ \
* \ \ \/\ \ \ \L\_\ `\`\/'/'\/_/\ \/\ \ \L\ \
* \ \ \ \ \ \ _\L`\/ > < \ \ \ \ \ __ \
* \ \ \_\ \ \ \L\ \ \/'/\`\ \ \ \ \ \ \/\ \
* \ \____/\ \____/ /\_\\ \_\ \ \_\ \ \_\ \_\
* \/___/ \/___/ \/_/ \/_/... |
//*****************************************************************************
// Filename : 'wave.c'
// Title : Animation code for MONOCHRON wave banner clock
//*****************************************************************************
#include "../global.h"
#include "../glcd.h"
#include "../anim.h"
#include "... |
/*
* =====================================================================================
*
* Filename: fsm.c
*
* Description: 状态机模块
*
* Version: 1.0
* Created: 01/03/2019 09:58:45 AM
* Revision: none
* Compiler: gcc
*
* Author: 疯狂十六进制
* Organization: ... |
/*
foidl_regex.c
Library support for regular expressions
Copyright <NAME>
All Rights Reserved
*/
#define REGEX_IMPL
#include <foidlrt.h>
#include <foidl_regex11.hpp>
#include <stdio.h>
// Symbol compiled regex
constKeyword(unknownKW,":unknown");
constKeyword(typeKW,":type");
constKeyword(regexKW,":regex");
cons... |
#include "../../common.h"
#include "../../vendor/murmur3.h"
#include "../../dss/hash.h"
#include <stdio.h>
#include <stdlib.h>
#include "rte_atomic.h"
#include "rte_malloc.h"
#include "rte_memcpy.h"
#include "countheap.h"
#include "common.h"
#include "../../dss/hashmap_linear.h"
struct CountHeap
{
uint32_t rowsize... |
/*
* Driver for Altera Partial Reconfiguration IP Core
*
* Copyright (C) 2016 Intel Corporation
*
* Based on socfpga-a10.c Copyright (C) 2015-2016 Altera Corporation
* by <NAME> <<EMAIL>>
*
* This program is free software; you can redistribute it and/or modify it
* under the terms and conditions of the GNU Ge... |
/*****************************************************************************
* sphere.c
*
* DESCRIPTION:
* This module contains computations that deal with distances or angles on
* a sphere.
*
* HISTORY
* 10/2003 <NAME> (MDL / RSIS): Created.
*
* NOTES
* The original procedures assumed: 60nm = 1 degree ... |
/*
* Copyright 2014 <NAME>.
*
* Licensed under the Apache License, Version 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 in... |
#include "win32uv_window.h"
#include "win32uv_timers.h"
#include "win32uv.h"
#include <commctrl.h>
extern HWND g_uv_loop_result;
extern HWND g_win32_loop_result;
#define WINDOW_CLASS_NAME L"Win32-Libuv"
#define BUTTON_W 75
#define DEFAULT_CONTROL_H 23
#define PADDING_SM 7
#define PADDING 11
#define PADDING_LABEL_TEX... |
/*
* Copyright (c) 2015, Intel Corporation
* 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 li... |
/**
* @file dns.c DNS Testcode
*
* Copyright (C) 2010 Creytiv.com
*/
#include <string.h>
#include <re.h>
#include "test.h"
#define DEBUG_MODULE "dns"
#define DEBUG_LEVEL 5
#include <re_dbg.h>
enum {NUM_TESTS = 32};
static int mkstr(char **strp)
{
size_t sz = 8;
char *str;
str = mem_alloc(sz, NULL);
if (!... |
/*******************************************************************************
Copyright (c) 2016, <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:
* Redistributions of source co... |
/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/ati/r128_probe.c,v 1.17 2003/02/07 20:41:15 martin Exp $ */
/*
* Copyright 1999, 2000 ATI Technologies Inc., Markham, Ontario,
* Precision Insight, Inc., Cedar Park, Texas, and
* VA Linux Systems Inc., Fremont, California.
... |
#include "apa102.h"
#include "get_config.h"
#include "state_handler.h"
#include "rsp_corev2.h"
#include <common.h>
#include <mqtt.h>
#include <pthread.h>
#include <signal.h>
#include <posix_sockets.h>
#define CLIENT_ID_LEN 10
static void get_site_id(const char *msg);
static void interrupt_handler(int sig);
void che... |
/*
Processor topology storage.
Uses algorithms from
https://software.intel.com/en-us/articles/intel-64-architecture-processor-topology-enumeration
*/
/* INCLUDES */
#include <smp/topology.h>
#include <cpu/cpuid.h>
#include <stdlib/stdlib.h>
#include <stdint.h>
#include <stdbool.h>
#include <panic/panic.h>
#inclu... |
/**
******************************************************************************
* @file ntp.c
* @author WIZnet Software Team
* @version V1.0
* @date 2015-02-14
* @brief ntp 演示函数
******************************************************************************
**/
#include "w5500.h"
#include "w5500_con... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.