repo_name stringlengths 5 122 | path stringlengths 3 232 | text stringlengths 6 1.05M |
|---|---|---|
kipiberbatov/idec | src/array/jagged3_fprint_raw.c | #include <errno.h>
#include "int.h"
#include "jagged_private.h"
void jagged3_fprint_raw(FILE * out, const jagged3 * arr)
{
int arr_a2_size, arr_a3_size;
fprintf(out, "%d\n", arr->a0);
int_array_fprint(out, arr->a0, arr->a1, "--raw");
arr_a2_size = int_array_total_sum(arr->a0, arr->a1);
int_array_fprint(ou... |
RufUsul/gator | daemon/TtraceDriver.h | /* Copyright (C) 2015-2021 by Arm Limited. All rights reserved. */
#ifndef TTRACEDRIVER_H
#define TTRACEDRIVER_H
#include "SimpleDriver.h"
#include "mxml/mxml.h"
class FtraceDriver;
class TtraceDriver : public SimpleDriver {
public:
TtraceDriver(const FtraceDriver & ftraceDriver);
// Intentionally unimpleme... |
RufUsul/gator | daemon/mali_userspace/MaliGPUClockPolledDriverCounter.h | <filename>daemon/mali_userspace/MaliGPUClockPolledDriverCounter.h
/* Copyright (C) 2019-2021 by Arm Limited. All rights reserved. */
#ifndef MALI_USERSPACE_MALIGPUCLOCKPOLLEDDRIVERCOUNTER_H_
#define MALI_USERSPACE_MALIGPUCLOCKPOLLEDDRIVERCOUNTER_H_
#include "DriverCounter.h"
#include <cstdint>
namespace mali_usersp... |
RufUsul/gator | daemon/linux/perf/PerfAttrsBuffer.h | /* Copyright (C) 2013-2021 by Arm Limited. All rights reserved. */
#ifndef PERF_ATTRS_BUFFER_H
#define PERF_ATTRS_BUFFER_H
#include "Buffer.h"
#include "linux/perf/IPerfAttrsConsumer.h"
struct perf_event_attr;
class PerfAttrsBuffer : public IPerfAttrsConsumer {
public:
PerfAttrsBuffer(int size, sem_t & readerSe... |
RufUsul/gator | daemon/lib/WaitForProcessPoller.h | /* Copyright (C) 2018-2021 by Arm Limited. All rights reserved. */
#ifndef WAIT_FOR_PROCESS_POLLER_H
#define WAIT_FOR_PROCESS_POLLER_H
#include "lib/FsEntry.h"
#include "linux/proc/ProcessPollerBase.h"
#include <set>
/**
* Polls /proc/ for some process matching the given command name
*/
class WaitForProcessPoller... |
RufUsul/gator | daemon/SessionData.h | /* Copyright (C) 2010-2021 by Arm Limited. All rights reserved. */
#ifndef SESSION_DATA_H
#define SESSION_DATA_H
#include "Config.h"
#include "Configuration.h"
#include "Constant.h"
#include "Counter.h"
#include "GatorCLIFlags.h"
#include "ProtocolVersion.h"
#include "lib/SharedMemory.h"
#include "mxml/mxml.h"
#incl... |
RufUsul/gator | daemon/PrimarySourceProvider.h | <filename>daemon/PrimarySourceProvider.h
/* Copyright (C) 2017-2021 by Arm Limited. All rights reserved. */
#ifndef INCLUDE_PRIMARYSOURCEPROVIDER_H
#define INCLUDE_PRIMARYSOURCEPROVIDER_H
#include "lib/Span.h"
#include "linux/perf/PerfEventGroupIdentifier.h"
#include <cstdint>
#include <functional>
#include <memory>... |
RufUsul/gator | daemon/HwmonDriver.h | <filename>daemon/HwmonDriver.h
/* Copyright (C) 2013-2021 by Arm Limited. All rights reserved. */
#ifndef HWMONDRIVER_H
#define HWMONDRIVER_H
#include "PolledDriver.h"
class HwmonDriver : public PolledDriver {
public:
HwmonDriver();
~HwmonDriver() override;
// Intentionally unimplemented
HwmonDriver... |
RufUsul/gator | daemon/ProtocolVersion.h | <gh_stars>100-1000
/* Copyright (C) 2021 by Arm Limited. All rights reserved. */
#pragma once
/* Define the product release version / protocol version */
// Protocol version Streamline v7.8
#define PROTOCOL_VERSION 780
// Differentiates development versions from release code
#define PROTOCOL_VERSION_DEV_MULTIPLIER 10... |
RufUsul/gator | daemon/AnnotateListener.h | <gh_stars>100-1000
/* Copyright (C) 2014-2021 by Arm Limited. All rights reserved. */
#ifndef ANNOTATELISTENER_H
#define ANNOTATELISTENER_H
struct AnnotateClient;
class OlyServerSocket;
class AnnotateListener {
public:
AnnotateListener();
~AnnotateListener();
// Intentionally unimplemented
AnnotateL... |
RufUsul/gator | daemon/FtraceDriver.h | <filename>daemon/FtraceDriver.h
/* Copyright (C) 2014-2021 by Arm Limited. All rights reserved. */
#ifndef FTRACEDRIVER_H
#define FTRACEDRIVER_H
#include "SimpleDriver.h"
#include "Tracepoints.h"
#include <pthread.h>
#include <utility>
#include <vector>
class DynBuf;
class IPerfAttrsConsumer;
// The Android NDK do... |
RufUsul/gator | daemon/linux/perf/PerfCpuOnlineMonitor.h | /* Copyright (C) 2019-2021 by Arm Limited. All rights reserved. */
#ifndef INCLUDE_LINUX_PERF_PERF_CPU_ONLINE_MONITOR_H
#define INCLUDE_LINUX_PERF_PERF_CPU_ONLINE_MONITOR_H
#include <atomic>
#include <functional>
#include <set>
#include <thread>
/**
* A thread that monitors CPU online / offline state (for when ueve... |
RufUsul/gator | daemon/linux/perf/PerfConfig.h | <gh_stars>100-1000
/* Copyright (C) 2018-2021 by Arm Limited. All rights reserved. */
#ifndef PERFCONFIG_H
#define PERFCONFIG_H
struct PerfConfig {
bool has_fd_cloexec = false; // >=3.14
bool has_count_sw_dummy = false; // >=3.12
bool has_sample_identifier = false; // >= 3.12
bool h... |
RufUsul/gator | daemon/PolledDriver.h | <gh_stars>100-1000
/* Copyright (C) 2013-2021 by Arm Limited. All rights reserved. */
#ifndef NATIVE_GATOR_DAEMON_POLLEDDRIVER_H_
#define NATIVE_GATOR_DAEMON_POLLEDDRIVER_H_
#include "SimpleDriver.h"
class IBlockCounterFrameBuilder;
class PolledDriver : public SimpleDriver {
public:
// Intentionally unimplement... |
RufUsul/gator | daemon/armnn/ByteOrder.h | <reponame>RufUsul/gator
/* Copyright (C) 2019-2021 by Arm Limited. All rights reserved. */
#ifndef INCLUDE_ARMNN_BYTE_ORDER_H
#define INCLUDE_ARMNN_BYTE_ORDER_H
#include "lib/Assert.h"
#include "lib/Span.h"
#include <cstdint>
#include <type_traits>
namespace armnn {
/** Enumerate possible byte orderring */
... |
RufUsul/gator | daemon/armnn/ICounterDirectoryConsumer.h | /* Copyright (C) 2019-2021 by Arm Limited. All rights reserved. */
#ifndef INCLUDE_ARMNN_I_COUNTER_DIRECTORY_CONSUMER_H
#define INCLUDE_ARMNN_I_COUNTER_DIRECTORY_CONSUMER_H
#include <cstdint>
#include <map>
#include <string>
#include <vector>
namespace armnn {
/**
* Interface for consumer that is called with... |
RufUsul/gator | daemon/SimpleDriver.h | /* Copyright (C) 2013-2021 by Arm Limited. All rights reserved. */
#ifndef NATIVE_GATOR_DAEMON_SIMPLEDRIVER_H_
#define NATIVE_GATOR_DAEMON_SIMPLEDRIVER_H_
#include "Driver.h"
#include "DriverCounter.h"
class SimpleDriver : public Driver {
public:
~SimpleDriver() override;
// Intentionally unimplemented
... |
RufUsul/gator | daemon/DynBuf.h | /* Copyright (C) 2013-2021 by Arm Limited. All rights reserved. */
#ifndef DYNBUF_H
#define DYNBUF_H
#include <cstdarg>
#include <cstdlib>
class DynBuf {
public:
DynBuf() : capacity(0), length(0), buf(nullptr) {}
~DynBuf() { reset(); }
// Intentionally undefined
DynBuf(const DynBuf &) = delete;
... |
RufUsul/gator | daemon/non_root/GlobalStatsTracker.h | /* Copyright (C) 2017-2021 by Arm Limited. All rights reserved. */
#ifndef INCLUDE_NON_ROOT_GLOBALSTATSTRACKER_H
#define INCLUDE_NON_ROOT_GLOBALSTATSTRACKER_H
#include "linux/proc/ProcLoadAvgFileRecord.h"
#include "linux/proc/ProcStatFileRecord.h"
#include "non_root/CounterHelpers.h"
#include "non_root/GlobalCounter.... |
RufUsul/gator | daemon/linux/perf/PerfGroups.h | <filename>daemon/linux/perf/PerfGroups.h
/* Copyright (C) 2013-2021 by Arm Limited. All rights reserved. */
#ifndef PERF_GROUPS_H
#define PERF_GROUPS_H
#include "linux/perf/IPerfGroups.h"
#include "linux/perf/PerfEventGroup.h"
#include "linux/perf/PerfEventGroupIdentifier.h"
#include <cstdint>
#include <map>
#includ... |
RufUsul/gator | daemon/Counter.h | /* Copyright (C) 2013-2021 by Arm Limited. All rights reserved. */
#ifndef COUNTER_H
#define COUNTER_H
#include "EventCode.h"
#include <new>
#include <string>
class Driver;
class Counter {
public:
static const size_t MAX_DESCRIPTION_LEN = 400;
Counter() = default;
// Intentionally unimplemented
C... |
RufUsul/gator | daemon/armnn/ThreadManagementServer.h | <gh_stars>100-1000
/* Copyright (C) 2019-2021 by Arm Limited. All rights reserved. */
#pragma once
#include "armnn/IAcceptor.h"
#include "armnn/ISession.h"
#include "armnn/IStartStopHandler.h"
#include <condition_variable>
#include <memory>
#include <thread>
#include <vector>
namespace armnn {
/**
* Class t... |
RufUsul/gator | daemon/Fifo.h | <reponame>RufUsul/gator<filename>daemon/Fifo.h
/* Copyright (C) 2010-2021 by Arm Limited. All rights reserved. */
#ifndef __FIFO_H__
#define __FIFO_H__
#ifdef WIN32
#include <windows.h>
#define sem_t HANDLE
#define sem_init(sem, pshared, value) ((*(sem) = CreateSemaphore(nullptr, value, LONG_MAX, nullptr)) == nullptr... |
RufUsul/gator | daemon/linux/perf/PerfDriverConfiguration.h | <gh_stars>100-1000
/* Copyright (C) 2013-2021 by Arm Limited. All rights reserved. */
#ifndef PERFDRIVER_CONFIGURATION_H
#define PERFDRIVER_CONFIGURATION_H
#include "lib/Span.h"
#include "linux/perf/PerfConfig.h"
#include "xml/PmuXML.h"
#include <map>
#include <memory>
#include <vector>
class GatorCpu;
class Uncore... |
RufUsul/gator | daemon/DiskIODriver.h | /* Copyright (C) 2013-2021 by Arm Limited. All rights reserved. */
#ifndef DISKIODRIVER_H
#define DISKIODRIVER_H
#include "DynBuf.h"
#include "PolledDriver.h"
class DiskIODriver : public PolledDriver {
private:
using super = PolledDriver;
public:
DiskIODriver() : PolledDriver("DiskIO") {}
// Intentiona... |
RufUsul/gator | daemon/NetDriver.h | /* Copyright (C) 2013-2021 by Arm Limited. All rights reserved. */
#ifndef NETDRIVER_H
#define NETDRIVER_H
#include "DynBuf.h"
#include "PolledDriver.h"
class NetDriver : public PolledDriver {
private:
using super = PolledDriver;
public:
NetDriver() : PolledDriver("Net") {}
// Intentionally unimplement... |
RufUsul/gator | daemon/xml/MxmlUtils.h | <filename>daemon/xml/MxmlUtils.h<gh_stars>100-1000
/* Copyright (C) 2019-2021 by Arm Limited. All rights reserved. */
#ifndef MXML_UTILS_H
#define MXML_UTILS_H
#include "mxml/mxml.h"
#include <memory>
#include <string>
/** unique_ptr for mxml nodes */
using mxml_unique_ptr = std::unique_ptr<mxml_node_t, void (*)(mx... |
RufUsul/gator | daemon/Logging.h | /* Copyright (C) 2010-2021 by Arm Limited. All rights reserved. */
#ifndef __LOGGING_H__
#define __LOGGING_H__
#include "DynBuf.h"
#include <pthread.h>
class Logging {
public:
Logging();
void setDebug(bool debug) { mDebug = debug; }
void reset();
#define logError(...) _logError(__func__, __FILE__, __... |
RufUsul/gator | daemon/UEvent.h | <reponame>RufUsul/gator
/* Copyright (C) 2013-2021 by Arm Limited. All rights reserved. */
#ifndef UEVENT_H
#define UEVENT_H
struct UEventResult {
const char * mAction;
const char * mDevPath;
const char * mSubsystem;
char mBuf[1 << 13];
};
class UEvent {
public:
UEvent();
~UEvent();
// I... |
RufUsul/gator | trace/events/module_shared_annotate/gator_annotate.c | <filename>trace/events/module_shared_annotate/gator_annotate.c<gh_stars>100-1000
/* Copyright (C) 2020-2021 by Arm Limited. All rights reserved. */
// SPDX-License-Identifier: GPL-2.0-only
/*
* gator kernel annotation trace points.
*/
#include <linux/module.h>
#define CREATE_TRACE_POINTS
#include "../include/gator... |
NathanFreeman/yasd | include/cmder_debugger.h | /*
+----------------------------------------------------------------------+
| Yasd |
+----------------------------------------------------------------------+
| This source file is subject to version 2.0 of the Apache license, |
| that is bundl... |
NathanFreeman/yasd | php_yasd.h | <filename>php_yasd.h
/*
+----------------------------------------------------------------------+
| Yasd |
+----------------------------------------------------------------------+
| This source file is subject to version 2.0 of the Apache license, ... |
Swanee-2106/C-calculator-simple | calculator.c | <reponame>Swanee-2106/C-calculator-simple
#include <stdio.h>
int main() {
float num1,num2,sum;
printf("Enter first number\n");
scanf("%f",&num1);
printf("Enter second number\n");
scanf("%f",&num2);
sum=num1+num2;
printf("The sum is %.3f",sum);
return 0;
}
|
aggarg/aws-iot-device-sdk-embedded-C | platform/posix/transport/src/plaintext_posix.c | <gh_stars>0
/*
* AWS IoT Device SDK for Embedded C 202103.00
* Copyright (C) 2020 Amazon.com, Inc. or its affiliates. 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 Soft... |
aggarg/aws-iot-device-sdk-embedded-C | demos/defender/defender_demo_json/report_builder.c | <reponame>aggarg/aws-iot-device-sdk-embedded-C
/*
* AWS IoT Device SDK for Embedded C 202103.00
* Copyright (C) 2020 Amazon.com, Inc. or its affiliates. All Rights Reserved.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the ... |
aggarg/aws-iot-device-sdk-embedded-C | demos/mqtt/mqtt_demo_basic_tls/mqtt_demo_basic_tls.c | /*
* AWS IoT Device SDK for Embedded C 202103.00
* Copyright (C) 2020 Amazon.com, Inc. or its affiliates. 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... |
aggarg/aws-iot-device-sdk-embedded-C | demos/fleet_provisioning/fleet_provisioning_with_csr/fleet_provisioning_serializer.h | /*
* AWS IoT Device SDK for Embedded C 202103.00
* Copyright (C) 2020 Amazon.com, Inc. or its affiliates. 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... |
Palatis/esp8266-restclient | src/RestClient.h | <reponame>Palatis/esp8266-restclient
#ifndef __REST_CLIENT_H__
#define __REST_CLIENT_H__
#include <list>
#ifdef DEBUG_REST
#define REST_DEBUGP(...) Serial.print(__VA_ARGS__)
#define REST_DEBUGF(...) Serial.printf(__VA_ARGS__)
#define REST_DEBUGLN(...) Serial.println(__VA_ARGS__)
#else
#define REST_DEBUGP(...)
#define... |
AVassilev98/ece350 | manual_code/Timer0_irq/src/main.c | /**
* @brief Timer interrupt example code.
Prints 0-9 every second. Loops around when 9 is reached.
* @author <NAME>
* @date 2020/10/02
*/
#include <LPC17xx.h>
#include "timer.h"
#include "uart_polling.h"
extern volatile uint32_t g_timer_count;
int main () {
volatile uint8_t sec = 0;
Syste... |
AVassilev98/ece350 | manual_code/Context_Switching/src/usr_tasks.c | /**
* @file: usr_tasks.c
* @brief: Two user/unprivileged tasks: task1 and task2
* @author: <NAME>
* @date: 2020/09/20
* NOTE: Each task is in an infinite loop. Processes never terminate.
*/
#include "rtx.h"
#include "uart_polling.h"
#include "usr_tasks.h"
#ifdef DEBUG_0
#include "printf.h"
#endif /* DEBUG... |
AVassilev98/ece350 | manual_code/util/printf_uart/uart_polling.c | /**
* @brief: uart_polling.c, polling UART to send and receive data
* @author: <NAME>
* @date: 2020/09/06
* NOTE: the code handles UART0/1.
*/
#include <LPC17xx.h>
#include "uart_polling.h"
/**
* @brief: initialize the n_uart
* @param: n_uart 0 for UART 0 and 1 for UART1
*/
int uart_init(int n_uart) {
L... |
AVassilev98/ece350 | manual_code/Context_Switching/src/k_rtx.h | /**
* @file: k_rtx.h
* @brief: kernel deinitiation and data structure header file
* @auther: <NAME>
* @date: 2020/09/21
*/
#ifndef K_RTX_H_
#define K_RTX_H_
#include "common.h"
/*----- Definitations -----*/
/*----- Types -----*/
/*
TCB data structure definition to support two kernel tasks.
You wi... |
AVassilev98/ece350 | manual_code/UART0_irq/src/uart_irq.c | <reponame>AVassilev98/ece350<gh_stars>0
/**
* @brief: uart_irq.c
* @author: NXP Semiconductors
* @author: <NAME>
* @date: 2020/10/04
*/
#include <LPC17xx.h>
#include "uart_irq.h"
#include "uart_polling.h"
#ifdef DEBUG_0
#include "printf.h"
#endif
uint8_t g_buffer[]= "You Typed a Q\n\r";
uint8_t *gp_buffer = g_... |
AVassilev98/ece350 | manual_code/Context_Switching/src/main_svc.c | /**
* @file: main_svc.c
* @brief: main routine to start up the RTX and two initial tasks
* @author: <NAME>
* @date: 2020/09/24
* NOTE: standard C library is not allowed in the final kernel code.
* A tiny printf function for embedded application development
* taken from http://www.sparetimelabs.c... |
AVassilev98/ece350 | manual_code/UART0_irq/src/main_irq.c | /**
* @brief: main routine for echoing user input through UART0 by interrupt.
* uart1 is by polling. It is used as a debugging terminal.
* @file: main_irq.c
* @author: <NAME>
* @date: 2020/10/04
*/
#include <LPC17xx.h>
#include "uart_irq.h"
#include "uart_polling.h"
#ifdef DEBUG_0
#include "printf.h"
#e... |
AVassilev98/ece350 | manual_code/util/printf_uart/uart_polling.h | /**
* @brief: uart_polling.h
* @author: <NAME>
* @date: 2020/09/06
*/
#ifndef UART_POLLING_H_
#define UART_POLLING_H_
#include <stdint.h> /* typedefs */
#include "uart_def.h"
#define uart0_init() uart_init(0)
#define uart0_get_char() uart_get_char(0)
#define uart0_put_char(c) uart_put_char(0,c... |
AVassilev98/ece350 | manual_code/SVC/src/k_mem.h | #ifndef _K_MEM_H_
#define _K_MEM_H_
#include "common.h"
#define IRAM1_END 0x10008000
int k_mem_init(size_t blk_size, int algo);
void *k_mem_alloc(size_t size);
void k_mem_dealloc(void *ptr);
int k_mem_count_extfrag(size_t size);
#endif // ! _K_MEM_H_
|
AVassilev98/ece350 | manual_code/Context_Switching/src/k_rtx_init.h | /**
* @file: k_rtx_init.h
* @brief: Kernel initialization header file
* @auther: <NAME>
* @date: 2020/09/26
*/
#ifndef K_RTX_INIT_H_
#define K_RTX_INIT_H_
#include "k_rtx.h"
/* Functions */
int k_rtx_init(size_t blk_size, int alog, RTX_TASK_INFO *task_info, int num_tasks);
#endif /* ! K_RTX_INIT_H_ */
|
AVassilev98/ece350 | manual_code/util/printf_uart/uart_def.h | <filename>manual_code/util/printf_uart/uart_def.h
/**
* @brief: UART defines
* @file: uart_def.h
* @author: <NAME>
* @date: 2014/02/08
*/
#ifndef UART_DEF_H_
#define UART_DEF_H_
/* The following macros are from NXP uart.h */
#define IER_RBR 0x01
#define IER_THRE 0x02
#define IER_RLS 0x04
#define IIR_PEND 0x0... |
AVassilev98/ece350 | manual_code/Context_Switching/src/k_rtx_init.c | /**
* @file: k_rtx_init.c
* @brief: Kernel initialization C file
* @auther: <NAME>
* @date: 2020/09/26
*/
#include "k_rtx_init.h"
#include "uart_polling.h"
#include "k_mem.h"
#include "k_task.h"
int k_rtx_init(size_t blk_size, int algo, RTX_TASK_INFO *task_info, int num_tasks)
{
/* interrupts are alrea... |
AVassilev98/ece350 | manual_code/Context_Switching/src/HAL.c | <filename>manual_code/Context_Switching/src/HAL.c
/* @brief: HAL.c Hardware Abstraction Layer
* @author: <NAME>
* @date: 2020/09/20
* NOTE: This file contains embedded assembly.
* The code borrowed some ideas from ARM RL-RTX source code
*/
/* pop off exception stack frame from the stack */
__asm void __rt... |
AVassilev98/ece350 | manual_code/Timer0_irq/src/timer.h | /**
* @brief timer.h - Timer header file
* @author <NAME>
* @date 2013/02/12
*/
#ifndef _TIMER_H_
#define _TIMER_H_
extern uint32_t timer_init ( uint8_t n_timer ); /* initialize timer n_timer */
#endif /* ! _TIMER_H_ */
|
AVassilev98/ece350 | manual_code/SVC/src/common.h | /* @brief: common defines and structs for both kernel and user
* @file: common.h
* @author: <NAME>
* @date: 2020/09/11
*/
#ifndef _COMMON_H_
#define _COMMON_H_
/* ----- Types ----- */
typedef signed char S8;
typedef unsigned char U8;
typedef short S16;
typedef unsigned short U16;
typedef int ... |
AVassilev98/ece350 | manual_code/SVC/src/rtx.h | <reponame>AVassilev98/ece350
/* @brief: rtx.h User API header file. Do not modify
* @author: <NAME>
* @date: 2020/09/03
*/
#ifndef _RTX_H_
#define _RTX_H_
/*----- Includes -----*/
#include "common.h"
#define __SVC_0 __svc_indirect(0)
extern int k_mem_init(size_t blk_size, int algo);
#define mem_init(blk_size, a... |
AVassilev98/ece350 | manual_code/UART0_irq/src/uart_irq.h | <reponame>AVassilev98/ece350
/**
* @brief: uart_irq.h
* @author: <NAME>
* @date: 2020/08/03
*/
#ifndef UART_IRQ_H_
#define UART_IRQ_H_
/* typedefs */
#include <stdint.h>
#include "uart_def.h"
/* initialize the n_uart to use interrupt */
int uart_irq_init(int n_uart);
#endif /* ! UART_IRQ_H_ */
|
AVassilev98/ece350 | manual_code/SVC/src/main_svc.c | /**
* @brief: main_svc.c, demonstrate svc as a gateway to os functions
* @author: <NAME>
* @date: 2020/09/09
* NOTE: Standard C library is not allowed in the final kernel code.
* A tiny printf function for embedded application development
* taken from http://www.sparetimelabs.com/tinyprintf/tinypri... |
AVassilev98/ece350 | manual_code/Context_Switching/src/k_mem.c | <gh_stars>0
/**
* @file: k_mem.c
* @brief: kernel memory managment routines
* @author: <NAME>
* @date: 2020/09/28
*/
#include "k_mem.h"
#ifdef DEBUG_0
#include "printf.h"
#endif /* ! DEBUG_0 */
/* The final memory map of IRAM1 looks like the following.
Refer to k_task.c for initilization function detai... |
AVassilev98/ece350 | manual_code/HelloWorld/src/main.c | <gh_stars>0
/**
* @brief: Display strings to UART0 and UART1 on MCB1700 by polling
* @author: <NAME>
* @date: 2020/09/06
*/
#include <LPC17xx.h>
#include "uart_def.h"
#include "uart_polling.h"
int main() {
SystemInit();
uart0_init();
uart1_init();
uart0_put_string("UART0 - Howdy!\r\n");
uart1_put_string("UAR... |
AVassilev98/ece350 | manual_code/SVC/src/k_mem.c | /**
* @brief: k_mem.c kernel API implementations, this is only a skeleton.
* @author: <NAME>
* @date: 2020/09/03
*/
#include "k_mem.h"
#include "uart_polling.h"
#ifdef DEBUG_0
#include "printf.h"
#endif /* DEBUG_0 */
/*
This symbol is defined in the scatter file,
refer to ARM Compiler v5.x Linker Use... |
AVassilev98/ece350 | manual_code/Context_Switching/src/k_mem.h | <gh_stars>0
/**
* @file: k_mem.h
* @brief: kernel memory managment header file
* @author: <NAME>
* @date: 2020/09/20
*/
#ifndef K_MEM_H_
#define K_MEM_H_
#include "k_rtx.h"
/* ----- Definitions ----- */
#define IRAM1_END 0x10008000
/* ----- Variables ----- */
/* This symbol is defined by linker (see ARM ... |
qmuntal/go-draco | draco/packaged/include/c_api.h | // Copyright 2021 <NAME>.
//
// Licensed under the BSD 2-Clause License (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// https://opensource.org/licenses/BSD-2-Clause
//
// Unless required by applicable law or agreed to in writing,... |
ololoshka2871/esp32-modbusTCP2RTU-gateway | main/mDNSServer.h | #ifndef _M_DNS_SERVER_H_
#define _M_DNS_SERVER_H_
#include <vector>
#include <mdns.h>
/// Это по факту служба Zeroconf/Bonjur
/// На ведре использовать приложуху навроде de.wellenvogel.bonjourbrowser
/// Адрес будет nixie-esp32.local
struct mDNSServer {
static mDNSServer &instance();
mDNSServer &addService(cons... |
sorphin/ESP-RFID-Tool | Source Code/esprfidtool/api.h | void apiTX(String apiBIN, int apipulsewidth, int apidatainterval, int wait) {
wg.pause();
digitalWrite(DATA0, HIGH);
pinMode(DATA0,OUTPUT);
digitalWrite(DATA1, HIGH);
pinMode(DATA1,OUTPUT);
for (int i=0; i<=apiBIN.length(); i++) {
if (apiBIN.charAt(i) == '0') {
digitalWrite(DATA0, LOW);
dela... |
sorphin/ESP-RFID-Tool | Source Code/esprfidtool/version.h | String version = "1.2.1";
String APIversion = "1.0.4";
|
sorphin/ESP-RFID-Tool | Source Code/esprfidtool/aba2str.h | <reponame>sorphin/ESP-RFID-Tool<filename>Source Code/esprfidtool/aba2str.h
String aba2str (String magstripe, int magStart, int magEnd, String swipeDirection) {
//f.println(String()+"Start pos:"+magStart);
//f.println(String()+"Start pos:"+magEnd);
String ABA="";
String aba2str="";
int magCount=abs(magEnd-magS... |
sorphin/ESP-RFID-Tool | Source Code/esprfidtool/pinSEND.h | <filename>Source Code/esprfidtool/pinSEND.h
void pinSEND(int pinDELAY,String pinBIN) {
for (int i=0; i<=pinBIN.length(); i++) {
if (pinBIN.charAt(i) == '0') {
digitalWrite(DATA0, LOW);
delayMicroseconds(txdelayus);
digitalWrite(DATA0, HIGH);
}
else if (pinBIN.charAt(i) == '1') {
di... |
sorphin/ESP-RFID-Tool | Source Code/esprfidtool/License.h | <gh_stars>100-1000
const char License[] PROGMEM = R"=====(
<!DOCTYPE HTML>
<html>
<head><title>ESP-RFID-Tool Licensing Page</title></head>
<body>
<a href="/"><- BACK TO INDEX</a><br><br>
<pre>
ESP-RFID-Tool by <NAME>: https://www.LegacySecurityGroup.com
Code available at: https://github.com/rfidtool/ESP-RFID-Tool
ESP-... |
even4void/rkt-stats | ext/glm.c | <filename>ext/glm.c
/* glm.c (originally, glm_test.c and mla.{c,h} from the snpMatrix R package */
#include <stdlib.h>
#include <stdio.h>
#include <math.h>
#include <string.h>
#include "glm.h"
/* Fit GLM, possibly with a stratification in the RHS
Input:
family GLM family (see below)
link Link functio... |
even4void/rkt-stats | ext/glm.h | <reponame>even4void/rkt-stats<gh_stars>0
#define Calloc(n,t) (t *)calloc((unsigned)(n),sizeof(t))
#define Free(p) free((char *)(p))
/* Family */
#define BINOMIAL 1
#define POISSON 2
#define GAUSSIAN 3
#define GAMMA 4
/* Link */
#define LOGIT 1
#define LOG 2
#define IDENTITY 3
#define INVERSE 4... |
qqibrow/asyncCpp | include/arg_pack.h | <gh_stars>0
#ifndef PROJECTTEMPLATE_ARGPACKHELPER_H
#define PROJECTTEMPLATE_ARGPACKHELPER_H
/*
* code from
* http://stackoverflow.com/questions/14261183/how-to-make-generic-computations-over-heterogeneous-argument-packs-of-a-variadic
*/
#include <type_traits>
#include <utility>
namespace SO {
//=================... |
qqibrow/asyncCpp | include/series.h | <filename>include/series.h
//
// Created by <NAME> on 8/30/15.
//
#ifndef PROJECTTEMPLATE_SERIES_H
#define PROJECTTEMPLATE_SERIES_H
#include <iostream>
#include <functional>
#include "arg_pack.h"
#include "lambda_traits.h"
/*
* traits to extract 1st function parameter from template shape like std::function<void(R)>... |
qqibrow/asyncCpp | include/lambda_traits.h | /*
* lambda_traits is used to extract parameter type and return type of a lambda. code copy from:
* http://stackoverflow.com/questions/7943525/is-it-possible-to-figure-out-the-parameter-type-and-return-type-of-a-lambda/7943765#7943765
*/
#ifndef PROJECTTEMPLATE_LAMBDA_TRAITS_H
#define PROJECTTEMPLATE_LAMBDA_TRAITS... |
qqibrow/asyncCpp | include/Each.h | //
// Created by <NAME> on 8/28/15.
//
#ifndef PROJECTTEMPLATE_EACH_H
#define PROJECTTEMPLATE_EACH_H
#include <vector>
#include <functional>
namespace Async {
template<typename T>
struct Each {
// here func should be a side-effect async func
void operator()(const std::vector<T>& list, std::fun... |
zhaipro/unet | src/demo.c | #include <math.h>
#include <stdint.h>
#include <stdio.h>
#include <stdlib.h>
typedef struct {
uint32_t w, h;
uint8_t *data;
}image_t;
image_t imread(const char *fn)
{
image_t im;
FILE *fp = fopen(fn, "rb");
char buf[256];
fgets(buf, 256, fp);
fgets(buf, 256, fp);
fscanf(fp, "%d %d\n255... |
crespum/Ceedling-PIC32 | firmware/src/calc.c | <filename>firmware/src/calc.c
#include "calc.h"
uint32_t sum(uint32_t a, uint32_t b) {
return a+b;
}
|
crespum/Ceedling-PIC32 | firmware/src/app.c | #include "app.h"
APP_DATA appData;
void APP_Initialize(void) {
/* Place the App state machine in its initial state. */
appData.state = APP_STATE_INIT;
/* TODO: Initialize your application's state machine and other
* parameters.
*/
}
void APP_Tasks(void) {
/* Check the a... |
crespum/Ceedling-PIC32 | firmware/src/ws2812b.h | <gh_stars>1-10
#ifndef __WS2812B_H__
#define __WS2812B_H__
#include <stdint.h>
#include "peripheral/ports/plib_ports.h"
typedef struct {
uint8_t red;
uint8_t green;
uint8_t blue;
} colors_t;
typedef struct {
PORTS_MODULE_ID ports_id;
PORTS_CHANNEL port_channel;
PORTS_BIT_POS port_bit_positio... |
crespum/Ceedling-PIC32 | firmware/test/support/plib_ports.h | #ifndef __DUMMY_PLIB_H__
#define __DUMMY_PLIB_H__
typedef uint16_t PORTS_DATA_MASK;
typedef uint32_t PORTS_DATA_TYPE;
#include "peripheral/ports/processor/ports_processor.h"
void PLIB_PORTS_PinSet(PORTS_MODULE_ID index, PORTS_CHANNEL channel, PORTS_BIT_POS bitPos );
void PLIB_PORTS_PinClear(PORTS_MODUL... |
crespum/Ceedling-PIC32 | firmware/src/system_config/microchip/system_config.h | <reponame>crespum/Ceedling-PIC32
/*******************************************************************************
MPLAB Harmony System Configuration Header
File Name:
system_config.h
Summary:
Build-time configuration header for the system defined by this MPLAB Harmony
project.
Descripti... |
crespum/Ceedling-PIC32 | firmware/src/calc.h | #ifndef _CALC_H
#define _CALC_H
#include <stdint.h>
uint32_t sum(uint32_t a, uint32_t b);
#endif /* _CALC_H */
|
crespum/Ceedling-PIC32 | firmware/test/test_ws2812b.c | #include "unity.h"
#include "ws2812b.h"
#include "mock_plib_ports.h"
NeopixelHandler_t neopixel;
void setUp(void) {
ws2812b_init(&neopixel, PORTS_ID_0, PORT_CHANNEL_B, PORTS_BIT_POS_5);
}
void tearDown(void) {
}
void test_should_ReturnError_when_IncorrectInput(void) {
TEST_ASSERT_FALSE(ws2812b_set_rgb_color... |
crespum/Ceedling-PIC32 | firmware/src/app.h | #ifndef _APP_H
#define _APP_H
#include <stdint.h>
#include <stdbool.h>
#include <stddef.h>
#include <stdlib.h>
#include "system_config.h"
#include "system_definitions.h"
/**
* This enumeration defines the valid application states. These states
* determine the behavior of the application at various time... |
crespum/Ceedling-PIC32 | firmware/src/ws2812b.c | <gh_stars>1-10
#include "ws2812b.h"
/**************************************************************************
* PRIVATE FUCTIONS
**************************************************************************/
bool ws2812b_hex2struct(colors_t *colors, int32_t hex) {
if (hex <= 0xFFFFFF && ... |
crespum/Ceedling-PIC32 | firmware/test/test_calc.c | #include "unity.h"
#include "calc.h"
void setUp(void) {
}
void tearDown(void) {
}
void test_should_ReturnSum_when_ValidInput(void) {
TEST_ASSERT_EQUAL_INT32(9, sum(4, 5));
}
|
suwilanji-chipofya/Pinecone | h/Type.h | <reponame>suwilanji-chipofya/Pinecone<filename>h/Type.h
#pragma once
#include <string>
using std::string;
#include <vector>
using std::vector;
#include <memory>
using std::shared_ptr;
using std::unique_ptr;
#include <cstring>
using std::memcpy;
class TypeBase;
typedef shared_ptr<TypeBase> Type;
const extern Type... |
michaelsabo/DeviceAgent.iOS | Server/Application/SpringBoard.h | <reponame>michaelsabo/DeviceAgent.iOS<filename>Server/Application/SpringBoard.h
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT license.
/**
* Copyright (c) 2015-present, Facebook, Inc.
* All rights reserved.
*
* This source code is licensed under the BSD-style license found... |
michaelsabo/DeviceAgent.iOS | Server/PrivateHeaders/XCTest/XCElementSnapshot-Hitpoint.h | // class-dump results processed by bin/class-dump/dump.rb
//
// Generated by class-dump 3.5 (64 bit) (Debug version compiled Jul 30 2018 09:07:48).
//
// class-dump is Copyright (C) 1997-1998, 2000-2001, 2004-2015 by <NAME>.
//
#import <Foundation/Foundation.h>
#import <CoreGraphics/CoreGraphics.h>
#import <XC... |
michaelsabo/DeviceAgent.iOS | Server/PrivateHeaders/XCTAutomationSupport/XCAccessibilityElement.h | <gh_stars>0
// class-dump results processed by bin/class-dump/dump.rb
//
// Generated by class-dump 3.5 (64 bit) (Debug version compiled Jul 30 2018 09:07:48).
//
// class-dump is Copyright (C) 1997-1998, 2000-2001, 2004-2015 by <NAME>.
//
#import <Foundation/Foundation.h>
#import <CoreGraphics/CoreGraphics.h>... |
michaelsabo/DeviceAgent.iOS | Server/PrivateHeaders/CDStructures.h | <reponame>michaelsabo/DeviceAgent.iOS<filename>Server/PrivateHeaders/CDStructures.h
// class-dump results processed by bin/class-dump/dump.rb
//
// Generated by class-dump 3.5 (64 bit) (Debug version compiled Jul 30 2018 09:07:48).
//
// class-dump is Copyright (C) 1997-1998, 2000-2001, 2004-2015 by <NAME>.
//
... |
michaelsabo/DeviceAgent.iOS | Server/PrivateHeaders/XCTest/XCTestRun.h | // class-dump results processed by bin/class-dump/dump.rb
//
// Generated by class-dump 3.5 (64 bit) (Debug version compiled Jul 30 2018 09:07:48).
//
// class-dump is Copyright (C) 1997-1998, 2000-2001, 2004-2015 by <NAME>.
//
#import <Foundation/Foundation.h>
#import <CoreGraphics/CoreGraphics.h>
#import <XC... |
michaelsabo/DeviceAgent.iOS | Server/Utilities/JSONUtils.h |
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT license.
#import <Foundation/Foundation.h>
#import "XCUIElement+WebDriverAttributes.h"
/**
Utilities involving json manipulation, particularly with XCUIElements.
*/
@interface JSONUtils : NSObject
/**
@return List of supported ... |
michaelsabo/DeviceAgent.iOS | Server/PrivateHeaders/XCTest/XCTestSuiteRun.h | // class-dump results processed by bin/class-dump/dump.rb
//
// Generated by class-dump 3.5 (64 bit) (Debug version compiled Jul 30 2018 09:07:48).
//
// class-dump is Copyright (C) 1997-1998, 2000-2001, 2004-2015 by <NAME>.
//
#import <Foundation/Foundation.h>
#import <CoreGraphics/CoreGraphics.h>
#import <XC... |
michaelsabo/DeviceAgent.iOS | Server/PrivateHeaders/XCTest/XCUIApplicationImpl.h | <reponame>michaelsabo/DeviceAgent.iOS
// class-dump results processed by bin/class-dump/dump.rb
//
// Generated by class-dump 3.5 (64 bit) (Debug version compiled Jul 30 2018 09:07:48).
//
// class-dump is Copyright (C) 1997-1998, 2000-2001, 2004-2015 by <NAME>.
//
#import <Foundation/Foundation.h>
#import <Co... |
michaelsabo/DeviceAgent.iOS | Server/PrivateHeaders/XCTest/XCUIApplicationMonitor.h | // class-dump results processed by bin/class-dump/dump.rb
//
// Generated by class-dump 3.5 (64 bit) (Debug version compiled Jul 30 2018 09:07:48).
//
// class-dump is Copyright (C) 1997-1998, 2000-2001, 2004-2015 by <NAME>.
//
#import <Foundation/Foundation.h>
#import <CoreGraphics/CoreGraphics.h>
#import <XC... |
michaelsabo/DeviceAgent.iOS | Server/PrivateHeaders/XCTAutomationSupport/XCTAccessibilitySnapshot_iOS.h | <gh_stars>0
// class-dump results processed by bin/class-dump/dump.rb
//
// Generated by class-dump 3.5 (64 bit) (Debug version compiled Jul 30 2018 09:07:48).
//
// class-dump is Copyright (C) 1997-1998, 2000-2001, 2004-2015 by <NAME>.
//
#import <Foundation/Foundation.h>
#import <CoreGraphics/CoreGraphics.h>... |
michaelsabo/DeviceAgent.iOS | Server/PrivateHeaders/XCTAutomationSupport/XCTApplicationStateSnapshot.h | <reponame>michaelsabo/DeviceAgent.iOS
// class-dump results processed by bin/class-dump/dump.rb
//
// Generated by class-dump 3.5 (64 bit) (Debug version compiled Jul 30 2018 09:07:48).
//
// class-dump is Copyright (C) 1997-1998, 2000-2001, 2004-2015 by <NAME>.
//
#import <Foundation/Foundation.h>
#import <Co... |
michaelsabo/DeviceAgent.iOS | Server/PrivateHeaders/XCTest/_XCTWaiterImpl.h | // class-dump results processed by bin/class-dump/dump.rb
//
// Generated by class-dump 3.5 (64 bit) (Debug version compiled Jul 30 2018 09:07:48).
//
// class-dump is Copyright (C) 1997-1998, 2000-2001, 2004-2015 by <NAME>.
//
#import <Foundation/Foundation.h>
#import <CoreGraphics/CoreGraphics.h>
#import <XC... |
michaelsabo/DeviceAgent.iOS | Server/PrivateHeaders/XCTest/XCTAutomationTarget-Protocol.h | // class-dump results processed by bin/class-dump/dump.rb
//
// Generated by class-dump 3.5 (64 bit) (Debug version compiled Jul 30 2018 09:07:48).
//
// class-dump is Copyright (C) 1997-1998, 2000-2001, 2004-2015 by <NAME>.
//
#import <Foundation/Foundation.h>
#import <CoreGraphics/CoreGraphics.h>
#import <X... |
michaelsabo/DeviceAgent.iOS | Server/PrivateHeaders/XCTAutomationSupport/XCTElementSetTransformer-Protocol.h | <filename>Server/PrivateHeaders/XCTAutomationSupport/XCTElementSetTransformer-Protocol.h
// class-dump results processed by bin/class-dump/dump.rb
//
// Generated by class-dump 3.5 (64 bit) (Debug version compiled Jul 30 2018 09:07:48).
//
// class-dump is Copyright (C) 1997-1998, 2000-2001, 2004-2015 by <NAME>... |
michaelsabo/DeviceAgent.iOS | Server/PrivateHeaders/XCTest/XCUIApplicationMonitor_iOS.h | // class-dump results processed by bin/class-dump/dump.rb
//
// Generated by class-dump 3.5 (64 bit) (Debug version compiled Jul 30 2018 09:07:48).
//
// class-dump is Copyright (C) 1997-1998, 2000-2001, 2004-2015 by <NAME>.
//
#import <Foundation/Foundation.h>
#import <CoreGraphics/CoreGraphics.h>
#import <XC... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.