text
stringlengths
3.12k
18.7k
/** * @file runtime_mgt.c * @brief manage the thread scheduling among runtimes * @author <NAME> (<EMAIL>) * @date 2020.1.2 * @version 1.0 */ /*----------------------------------------------------------------------------*/ /* - History: * 1. Date: 2020.1.2 * Author: <NAME> * Modification: create * 2...
/* * Licensed to the OpenAirInterface (OAI) Software Alliance under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. * The OpenAirInterface Software Alliance licenses this file to You under * the Apache License...
#include "http-server-internal.h" #include "http-header-range.h" #include "rfc822-datetime.h" #include "sys/path.h" #include "ctypedef.h" #include <errno.h> #include <stdio.h> #include <stdlib.h> #include <string.h> #include <stdint.h> #define N_SENDFILE (2 * 1024 * 1024) #if defined(OS_WINDOWS) #define fseek _fseeki...
/******************************************************************** * klibc.c * * (Any collaborators, please add your name) * Author: <NAME>, <NAME>, <NAME>, <NAME>, <NAME> * * Last edited: 4 December 2015 * * Purpose: Provide basic libc funtionality for CourseOS * This file provides function implementa...
#include "Python.h" #ifndef HAVE_HYPOT double hypot(double x, double y) { double yx; x = fabs(x); y = fabs(y); if (x < y) { double temp = x; x = y; y = temp; } if (x == 0.) return 0.; else { yx = y/x; return x*sqrt(1.+yx*yx); } } #endif /* HAVE_HYPOT */ #ifndef HAVE_COPYSIGN static double copysig...
#pragma once #ifndef _STDINT // we're using an older SDK that doesn't have these types. Define them for clarity typedef unsigned long long uint64_t; typedef unsigned long uint32_t; typedef unsigned short uint16_t; #endif // for usage when building with the tracer #ifndef _MSC_VER_ typedef __int64 LONG64;...
/* mya - get distance in millions of years between two species * * Contents: * 1. Miscellaneous functions for msatree * 2. Unit tests * 3. Test driver * 4. License and copyright * * ER, Fri Oct 21 10:26:52 EDT 2011 [Janelia] * SVN $Id:$ */ #include "p7_config.h" #include <unistd.h> #include <std...
/*************************************************************************** * Copyright (c) 2009-2010, Open Information Security Foundation * Copyright (c) 2009-2012, Qualys, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided...
#include "io_uart.h" #include "tim.h" #include "shell_port.h" #if defined(USING_RTTHREAD) #include "rtthread.h" #else #include "cmsis_os.h" #endif /*定义串口*/ IoUart_HandleTypeDef S_Uart1 = {0}; // static uint16_t g_table[MAX_PARAM] = {0}; /** * @brief 定义模拟串口相关波特率表 * @4800bps __________________ * | St...
/*- * Copyright (c) 2003-2007 <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 conditi...
#include <assert.h> #include <pthread.h> #include <stdlib.h> #include "algo/array.h" #include "algo/maxmin.h" #include "config.h" #include "dataplane.h" #include "network.h" #include "freelist.h" #include "plan.h" #include "util/common.h" #include "util/monte_carlo.h" #include "exec/longterm.h" /* TODO: Merge this a...
/* Copyright Joyent, Inc. and other Node contributors. All rights reserved. * 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 ...
#include <stdio.h> #include <math.h> #include <stdlib.h> #include <string.h> const int MAX_ITERS = 1000000; const double H = 0.01; const double ERROR = 0.00001; int imagesFromFile(char* filename, double** images, int num_to_read, int data_dim); void recognize...
/* ---------------------------------------------------------------------------- Copyright (c) 2018, Microsoft Research, <NAME> This is free software; you can redistribute it and/or modify it under the terms of the Apache License, Version 2.0. A copy of the License can be found in the file "license.txt" at the root of t...
/* * Copyright (c) 2016-2019, ARM Limited and Contributors. All rights reserved. * * SPDX-License-Identifier: BSD-3-Clause */ #include <assert.h> #include <platform_def.h> #include <common/debug.h> #include <plat/common/platform.h> #include "psci_private.h" #ifndef PLAT_MAX_PWR_LVL_STATES #define PLAT_MAX_PWR_...
/* * kernel/power/suspend.c - Suspend to RAM and standby functionality. * * Copyright (c) 2003 <NAME> * Copyright (c) 2003 Open Source Development Lab * Copyright (c) 2009 <NAME> <<EMAIL>>, Novell Inc. * * This file is released under the GPLv2. */ #include <linux/string.h> #include <linux/delay.h> #include <li...
/** * \file * \brief TNG root certificate (DER) * * \copyright (c) 2015-2019 Microchip Technology Inc. and its subsidiaries. * * \page License * * Subject to your compliance with these terms, you may use Microchip software * and any derivatives exclusively with Microchip products. It is your * respo...
/*$Header: /data/petsun4/data1/src_solaris/algebra_4dfp/RCS/spatial_corr_4dfp.c,v 1.3 2012/06/07 23:01:13 avi Exp $*/ /*$Log: spatial_corr_4dfp.c,v $ * Revision 1.3 2012/06/07 23:01:13 avi * option -M * * Revision 1.2 2010/05/03 21:08:27 avi * correct usage; option -c * * Revision 1.1 2010/03/17 20:31:44...
///////////////////////////////////////////////////////////////////////// //// //// //// Joystick.c //// //// Joystick 8 ejes 24 botones //// //// Autor: Alejandro ...
/********************************************************************************* * Copyright (c) 2016 - 2020,Tencent * All rights reserved. * * File Name: board.c * * Description: board drivers for stm32F103 dev kit board * * History: <author> <time> ...
/* @(#)defs.h 1.7 */ /* * UNIX shell */ /* error exits from various parts of shell */ #define ERROR 1 #define SYNBAD 2 #define SIGFAIL 2000 #define SIGFLG 0200 /* command tree */ #define FPRS 0x0100 #define FINT 0x0200 #define FAMP 0x0400 #define FPIN 0x0800 #define FPOU 0x1000 #define FPCL 0x...
/* * Copyright 2017 GoPro Inc. * * Licensed to the Apache Software Foundation (ASF) under one * or more contributor license agreements. See the NOTICE file * distributed with this work for additional information * regarding copyright ownership. The ASF licenses this file * to you under the Apache License, Vers...
/* * Copyright 2015 The Netty Project * * The Netty Project licenses this file to you 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: * * https://www.apache.org/licenses/LICENSE-2.0 * * Unless...
/* * This file is part of the Bus Pirate project (http://code.google.com/p/the-bus-pirate/). * * Written and maintained by the Bus Pirate project. * * To the extent possible under law, the project has * waived all copyright and related or neighboring rights to Bus Pirate. This * work is published from Uni...
/* * Copyright (c) 2001 <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 the rights * to use, copy, modify, merge, publish, dis...
/* * Copyright (C) 2006-2011 <NAME> <<EMAIL>> * 2010 <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; either * versi...
#include "postgres.h" #include "replication/walproposer.h" #include "libpq-fe.h" /* Required for anything that's dynamically loaded */ PG_MODULE_MAGIC; void _PG_init(void); /* Header in walproposer.h -- Wrapper struct to abstract away the libpq connection */ struct WalProposerConn { PGconn* pg_conn; bool is_non...
/* * i.MX drm driver - parallel display implementation * * Copyright (C) 2012 <NAME>, Pengutronix * * 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 ...
/** * * @file * * PLASMA is a software package provided by: * University of Tennessee, US, * University of Manchester, UK. * * @precisions normal z -> c d s * **/ #include "core_blas.h" #include "core_lapack.h" #include "plasma_barrier.h" #include "plasma_descriptor.h" #include "plasma_internal.h" #includ...
/********** Copyright 1990 Regents of the University of California. All rights reserved. Author: 1985 <NAME>, U. C. Berkeley CAD Group **********/ #include "spice.h" #include "cpdefs.h" #include "ftedefs.h" #include "ftedata.h" #include "ftehelp.h" #include "hlpdefs.h" #include "suffix.h" static void byemesg(); vo...
#include "kanji.h" #include "kanjis.h" #include "binary.h" #include <wchar.h> #include "distance.h" #include "strokemap.h" #include "math_ext.h" struct result { kanji k; int weight; }; kanjis init(char filename[]) { kanjis kjs = read_bin_file(filename); return kjs; } void insert_into(result rs[],...
/* * * debugger * */ #include "defs.h" #include "fns.h" void scanform(long icount, int prt, char *ifp, Map *map, int literal) { char *fp; char c; int fcount; ADDR savdot; int firstpass; firstpass = 1; while (icount) { fp=ifp; savdot=dot; /*now loop over format*/ while (*fp) { if (!isdigit((ucha...
/* * Copyright (c) 2014-2015, Xerox Corporation (Xerox) and Palo Alto Research Center, Inc (PARC) * 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 r...
/* * Copyright (C) 2015-2020 Alibaba Group Holding Limited */ #include "drv_acc_gyro_inv_mpu6050.h" #include "aos/hal/i2c.h" #include "aos/kernel.h" #include "hal_iomux_haas1000.h" #include "ulog/ulog.h" #include <stdio.h> #include <stdlib.h> static i2c_dev_t i2c_dev; // wtite one byte to register uint8_t MPU_Writ...
/* $Id$ $Revision$ */ /* vim:set shiftwidth=4 ts=8: */ /************************************************************************* * Copyright (c) 2011 AT&T Intellectual Property * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License v1....
/* * FB driver for the SSD1325 OLED Controller * * 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 version. * * This progra...
#include <AL/al.h> #include <AL/alc.h> #include <math.h> #include <stdio.h> #include <limits.h> #include <signal.h> #include <unistd.h> #include <stdlib.h> #include <audio/wave.h> #include <stdbool.h> static volatile int running = 1; void stop() { running = 0; } int sign(double value) { if(value < 0) ...
/* * Copyright (C) 2017 XRADIO TECHNOLOGY 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. Redistributions of source code must retain the above copyright * notice,...
/* * Copyright (c) 2012-2015, Juniper Networks, Inc. * All rights reserved. * * You may distribute under the terms of : * * the BSD 2-Clause license * * Any patches released for this software are to be released under these * same license terms. * * BSD 2-Clause license: * * Redistribution and use in source...
/* * Vortex OpenSplice * * This software and documentation are Copyright 2006 to TO_YEAR ADLINK * Technology Limited, its affiliated companies and licensors. All rights * reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file e...
/* * Copyright (c) 2018 <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, p...
/* * MIT License * * Copyright (c) 2017 Fabvalaaah - <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,...
/* * This file is part of the Sofia-SIP package * * Copyright (C) 2006 Nokia Corporation. * * Contact: <NAME> <<EMAIL>> * * 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;...
/* Copyright (c) 2013 The Chromium OS Authors. All rights reserved. * Use of this source code is governed by a BSD-style license that can be * found in the LICENSE file. */ /* * Keyboard power button LED state machine. * * This sets up TIM_POWER_LED to drive the power button LED so that the duty * cycle can ran...
/* * Author: <NAME>, Finland 2016-2019 * * This file is part of Kunquat. * * CC0 1.0 Universal, http://creativecommons.org/publicdomain/zero/1.0/ * * To the extent possible under law, Kunquat Affirmers have waived all * copyright and related or neighboring rights to Kunquat. */ #include <player/devices/pro...
#define __USE_MINGW_ANSI_STDIO 1 #include <stddef.h> #include <string.h> #include <stdio.h> #include <locale.h> #include "umka_compiler.h" #include "umka_runtime_src.h" void parseProgram(Compiler *comp); static void compilerDeclareBuiltinTypes(Compiler *comp) { comp->voidType = typeAd...
/* $NetBSD: pnaphy.c,v 1.4.4.1 2002/12/07 22:04:27 he Exp $ */ /* * Copyright 2001 Wasabi Systems, Inc. * All rights reserved. * * Written by <NAME> for Wasabi Systems, Inc. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following condition...
/* CalculiX - A 3-dimensional finite element program */ /* Copyright (C) 1998-2019 <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...
/* Ejercicio2: main.c TP3 - Ejercicio 2 Integrantes: <NAME> DNI 41332191 <NAME> DNI 37350600 <NAME> DNI 38983722 <NAME> DNI 40808276 <NAME> DNI 40258471 Número de entrega: segunda reentrega. */ #include <dirent.h> #include <errno.h> #include <fcntl.h> #include <libgen.h> #include <limits.h> #inclu...
/* Copyright 2014 The Chromium OS Authors. All rights reserved. * Use of this source code is governed by a BSD-style license that can be * found in the LICENSE file. */ /* UART module for Chrome EC */ #include "clock.h" #include "common.h" #include "console.h" #include "gpio.h" #include "hwtimer.h" #include "hwtim...
/* This software is subject to the license described in the License.txt file included with this software distribution. You may not use this file except in compliance with this license. Copyright (c) Dynastream Innovations Inc. 2015 All rights reserved. */ /* * Before compiling this example for NRF52, compl...
/* borf.c was originally generated by the autoSql program, which also * generated borf.h and borf.sql. This module links the database and * the RAM representation of objects. */ #include "common.h" #include "linefile.h" #include "dystring.h" #include "jksql.h" #include "borf.h" #include "hdb.h" #include "dnaseq.h"...
/*------------------------------------------------------------------------- * * proclang.c * PostgreSQL LANGUAGE support code. * * Portions Copyright (c) 1996-2020, PostgreSQL Global Development Group * Portions Copyright (c) 1994, Regents of the University of California * * IDENTIFICATION * src/backend/co...
/* $NetBSD: client.c,v 1.2 2008/12/06 20:01:14 plunky Exp $ */ /*- * Copyright (c) 2008 <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 re...
/*Copyright (c) 2019 , <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 conditions and the following discl...
// // vr4300/dcache.c: VR4300 instruction cache. // // CEN64: Cycle-Accurate Nintendo 64 Emulator. // Copyright (C) 2015, <NAME>. // // This file is subject to the terms and conditions defined in // 'LICENSE', which is part of this source code package. // #include "common.h" #include "vr4300/dcache.h" static inline s...
/********************************* File: base_itries.h Author: <NAME> Comments: Tries module for ILP version: $ID$ *********************************/ /* --------------------------- */ /* Defines */ /* --------------------------- */ #define ITRIES_MODE_NONE 0 #define ITRIES_MO...
/** ****************************************************************************** * @file vl53l0x_proximity.c * @author MCD Application Team * @brief High level API for VL53L0x proximity/time-of-flight sensor. ****************************************************************************** * @attention...
#include "common_task.h" /* helpers */ void remove_new_line(char* str) { int i; for(i = strlen(str) - 1; i >= 0; i--) { if(str[i] == '\r' || str[i] == '\n') str[i] = '\0'; else break; } } int are_words_equal(char* pattern, char* input) { int len_pattern = strlen(pattern); int len_input = strlen(input)...
#include "search_cluster.h" #include "partition.h" #include "alias.h" #include <stdlib.h> #include <stdio.h> #include <string.h> SearchCluster NewSearchCluster(size_t size, const char **table, size_t tableSize) { SearchCluster ret = (SearchCluster){.size = size, .shardsStartSlots=NULL,}; PartitionCtx_Init(&ret.p...
#include <pthread.h> #include "includes.h" #define uint unsigned int typedef struct pt2 { uint address[1024]; int valid[1024]; int full; } pt2; typedef struct pt1 { pt2 * table2[1024]; } pt1; typedef struct process { pthread_t tid; pt1 table1; uint virtuals[1024]; int size; } process; process threads[4]; in...
#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 "ch.h" #include "hal.h" #include "touch.h" #include "lcd.h" #include "touch_calib.h" #include "gui.h" #include "message.h" #include "app_cfg.h" #include <stdbool.h> #define XP 4 #define XN 6 #define YP 5 #define YN 7 #define NUM_SAMPLES 8 #define DISCARDED_SAMPLES 1 #define TOUCH_THR...
/* * sd.c * * Created on: Jan 9, 2021 * Author: bastian */ #include <stdio.h> #include <string.h> #include <sys/unistd.h> #include <sys/stat.h> #include <freertos/FreeRTOS.h> #include <freertos/task.h> #include <freertos/semphr.h> #include <esp_vfs_fat.h> #include <esp_err.h> #include <esp_log.h> #include <...
/* * parser.c * * Created on: 10 Nov 2014 * Author: marcin */ #include "utils.h" #include "parser.h" void addToCommandList(Command **CommandList, int hour, int minute, char *commandContent, int info) { // jesli brak elementow w liscie zaalokuj pierwszy element if (*CommandList == NULL) { *CommandList = ...
/** @file @brief Free RTOS Example 1 An example with FreeRTOS illustrating the use of Interrupts with context switching, and data exchange with Queues. A Transmission Task sends over UART1 (user should connect the UART1_RX and UART1_TX lines together) at random intervals. The UART ISR receives the data and...
// SPDX-License-Identifier: GPL-2.0+ /* * comedi_parport.c * Comedi driver for standard parallel port * * For more information see: * http://retired.beyondlogic.org/spp/parallel.htm * * COMEDI - Linux Control and Measurement Device Interface * Copyright (C) 1998,2001 <NAME> <<EMAIL>> */ /* * Driver: comedi_p...
/******************************************************************* * Copyright (C) 2011 Rensselaer Polytechnic Institute * * This work is licensed under the FreeBSD License. * * Please see the included LICENSE file in the top level directory. * ********************************************...
/* * task_cpu.c - example of per-thread remote monitoring with per-cpu breakdown * * Copyright (c) 2010 Google, Inc * Contributed by <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 *...
/* * This file is part of SWT21 lab kit firmware. * * SWT21 lab kit firmware 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....
// SPDX-License-Identifier: GPL-2.0-or-later /* * x86 decoder sanity test - based on test_get_insn.c * * Copyright (C) IBM Corporation, 2009 * Copyright (C) Hitachi, Ltd., 2011 */ #include <stdlib.h> #include <stdio.h> #include <string.h> #include <assert.h> #include <unistd.h> #include <sys/types.h> #include <sy...
/* vi: set sw=4 ts=4: */ /* Port to Busybox Copyright (C) 2006 <NAME> <<EMAIL>> * * Licensed under GPL v2, see file LICENSE in this tarball for details. * * DHCP Relay for 'DHCPv4 Configuration of IPSec Tunnel Mode' support * Copyright (C) 2002 <NAME> <<EMAIL>>, * Zuercher Hochschule Winterthur,...
/* * Copyright (C) 2010 <NAME> <<EMAIL>> * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Library General Public * License as published by the Free Software Foundation; either * version 2 of the License, or (at your option) any later version. * * This libr...
/* * sddc_vhf_stream_test - simple VHF/UHF stream test program for libsddc * * Copyright (C) 2020 by <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 3 of the Licen...
/* * read a zone file from disk and prints it, one RR per line * * (c) NLnetLabs 2005-2008 * * See the file LICENSE for the license */ #include "config.h" #include <unistd.h> #include <stdlib.h> #include <ldns/ldns.h> #include <ldns/host2str.h> #include <errno.h> static void print_usage(const char* progname) ...
#define MEMORY_MANAGE_HEAP_SIMPLIFY #ifdef MEMORY_MANAGE_HEAP_SIMPLIFY #define NULL (void *)0 #define BOOL unsigned char #define FALSE 0 #define TRUE 1 #endif #define MEMORY_MANAGE_HEAP_STRATEGY #ifdef MEMORY_MANAGE_HEAP_STRATEGY #endif #define MEMORY_MANAGE_HEAP_DISTRIBUTOR #ifdef MEMORY_MANAGE_HEAP_DIST...
/* Line numbers refer to: https://github.com/codybartfast/sicp/blob/master/chapter5/mc-evaluator-50.scm */ #include "environment.h" #include <string.h> #include "custom.h" #include "error.h" #include "list.h" #include "output.h" #include "primproc.h" #define AREA "ENVIRONMENT" static obj the_empty_environment(void...
/* * Copyright (c) 2014-2021 <NAME>. * All rights reserved. * Use of this source code is governed by a BSD-style * license that can be found in the BSD_LICENSE file. * * SPDX-License-Identifier: BSD-2-Clause */ #include <unistd.h> #include <fcntl.h> #include <stdio.h> #include <stdlib.h> #include <stdarg.h> #in...
//--------------------------------------------------------------------------- // NEOPOP : Emulator as in Dreamland // // Copyright (c) 2001-2002 by neopop_uk //--------------------------------------------------------------------------- //--------------------------------------------------------------------------- // Th...
// Copyright (c) 2012 DotNetAnywhere // // 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, publish...
// Copyright 2016 <NAME> <<EMAIL>>. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. #include <stdio.h> #include <stdlib.h> #include "run68.h" extern ULong zmusic_driver; extern char* zmusic_work; extern void jsrt_midi_out(UChar data); extern ...
/* $OpenBSD: protocol.c,v 1.4 2005/04/13 02:33:09 deraadt Exp $ */ /* * POP protocol handling. */ #include <stdio.h> #include <unistd.h> #include <stdlib.h> #include <signal.h> #include <setjmp.h> #include <string.h> #include <stdarg.h> #include <errno.h> #include "misc.h" #include "params.h" #include "protocol.h"...
#include "include/map.h" //spawn an item/enemy/wall in random spot void spawn_random_location(map_t* map_ref, u8 num_to_spawn, u8* tile_list, u8 num_tiles_in_list, bool spawn_enemy) { actor_t new_enemy; bool enemy_already_at_x_y = false; for (u8 i = 0; i < num_to_spawn; i++) { //select a rand...
#include <sys/types.h> #include <sys/stat.h> #include <fcntl.h> #include <stdio.h> #include <stdlib.h> #include <string.h> #include <stdint.h> #include <err.h> #include <errno.h> #include <unistd.h> #include "bcm2835.h" // Default parameters (defined in bcm2835) uint8_t mode = BCM2835_SPI_MODE0; uint16_t clk_div = ...
/* * hosts.c Copyright (C) 1992 <NAME> * Copyright (C) 1993, 1994, 1995 <NAME> * * mid to lowlevel SCSI driver interface * Initial versions: <NAME> * Subsequent revisions: <NAME> * * <<EMAIL>> * * Jiffies wrap fixes (host->resetting), 3 Dec 1998 <NAME> * Added QLOGIC QLA1280 SCSI cont...
/* $OpenBSD: fcnvff.c,v 1.3 1998/07/02 19:05:18 mickey Exp $ */ /* * Copyright 1996 1995 by Open Software Foundation, Inc. * All Rights Reserved * * Permission to use, copy, modify, and distribute this software and * its documentation for any purpose and without fee is hereby granted, * prov...
/* USER CODE BEGIN Header */ /** ****************************************************************************** * @file HAL/HAL_TimeBase/Src/main.c * @author MCD Application Team * @brief This example describes how to configure HAL time base using * the STM32WLxx HAL API. *******************...
/* $NetBSD: h_getopt_long.c,v 1.1 2011/01/01 23:56:49 pgoyette Exp $ */ /*- * Copyright (c) 2007 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 * m...
/* vi:set ts=4 sw=4: * * VIM - Vi IMproved by <NAME> * * Do ":help uganda" in Vim to read copying and usage conditions. * Do ":help credits" in Vim to see a list of people who contributed. */ #include <stdio.h> #include <ctype.h> #include <sys/types.h> #include <sys/stat.h> #ifdef HAVE_STDLIB_H # include <st...
#include "../headers/global.h" void* game_handler(){ while(1){ printf("debut SESSION\n"); game->tour_act = 0; //message SESSION msg_session(); //boucle des tours while(game->tour_act < nb_tours){ //on empeche les clients de lire les donnees du jeu. ...
// Copyright (C) 2021 <NAME> <<EMAIL>> #include "flexalloc_daemon_base.h" #include "src/flexalloc_cli_common.h" #include "src/flexalloc_util.h" #include "libflexalloc.h" #include <bits/getopt_core.h> #include <bits/getopt_ext.h> #include <stdlib.h> #include <inttypes.h> #define MAX_CLIENTS 110 #define MAX_CONN_QUEUE 1...
/* $Id$ */ /* * Copyright (c) 2017--2018 <NAME> <<EMAIL>> * * 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 copies. * * THE SOFTWARE IS PROVIDED "AS IS" AND...
// SPDX-License-Identifier: GPL-2.0 // // Copyright (c) 2018 MediaTek Inc. // Author: <NAME> <<EMAIL>> #include <linux/clk-provider.h> #include <linux/platform_device.h> #include "clk-mtk.h" #include "clk-gate.h" #include <dt-bindings/clock/mt8183-clk.h> static const struct mtk_gate_regs mm0_cg_regs = { .set_ofs =...
/************************************************************************ * Copyright (C) 2002-2009, Xiph.org Foundation * Copyright (C) 2010, <NAME> for Pinknoise Productions Ltd * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted prov...
// SPDX-License-Identifier: GPL-2.0-only /* * Copyright (C) 2012 <NAME> <rabin at rab.in> */ #include <linux/kernel.h> #include <linux/stddef.h> #include <linux/errno.h> #include <linux/highmem.h> #include <linux/sched.h> #include <linux/uprobes.h> #include <linux/notifier.h> #include <asm/opcodes.h> #include <asm/...
#include <stdio.h> #include <conio.h> typedef struct JogoDaVelha{ int id; char nome[50]; struct JogoDaVelha *prox; struct JogoDaVelha *prev; }Info; typedef struct MapaJogoDaVelha{ char Mapa[9]; }Tabuleiro; void Limpar(Info **Jogador, Tabuleiro **Informacoes){ *Jogador = NULL; *Informacoe...
/* -*- mode: C; c-file-style: "gnu"; indent-tabs-mode: nil; -*- */ /* expirelist.c List of items that expire * * Copyright (C) 2003 Red Hat, Inc. * * Licensed under the Academic Free License version 2.1 * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU Gen...
/* * Copyright 2021, alex at staticlibs.net * * 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 ag...
/********************************************************************** // @@@ START COPYRIGHT @@@ // // Licensed to the Apache Software Foundation (ASF) under one // or more contributor license agreements. See the NOTICE file // distributed with this work for additional information // regarding copyright ownership. ...
/* * 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 conditio...