This is the final version of Mini Gateway for Automation and Security desgined for Renesas GR Peach Design Contest
Dependencies: GR-PEACH_video GraphicsFramework HTTPServer R_BSP mbed-rpc mbed-rtos Socket lwip-eth lwip-sys lwip FATFileSystem
Fork of mbed-os-example-mbed5-blinky by
RF24_config.h
00001 00002 /* 00003 Copyright (C) 2011 J. Coliz <maniacbug@ymail.com> 00004 This program is free software; you can redistribute it and/or 00005 modify it under the terms of the GNU General Public License 00006 version 2 as published by the Free Software Foundation. 00007 */ 00008 00009 /* 00010 * Mbed support added by Akash Vibhute <akash.roboticist@gmail.com> 00011 * Porting completed on Nov/05/2015 00012 * 00013 * Updated 1: Synced with TMRh20's RF24 library on Nov/04/2015 from https://github.com/TMRh20 00014 * Updated 2: Synced with TMRh20's RF24 library on Apr/18/2015 from https://github.com/TMRh20 00015 * 00016 */ 00017 00018 00019 #ifndef __RF24_CONFIG_H__ 00020 #define __RF24_CONFIG_H__ 00021 00022 /*** USER DEFINES: ***/ 00023 //#define FAILURE_HANDLING 00024 //#define SERIAL_DEBUG 00025 //#define MINIMAL 00026 /**********************/ 00027 #define rf24_max(a,b) (a>b?a:b) 00028 #define rf24_min(a,b) (a<b?a:b) 00029 00030 00031 #include <mbed.h> 00032 00033 // RF modules support 10 Mhz SPI bus speed 00034 const uint32_t RF_SPI_SPEED = 10000000; 00035 00036 #define HIGH 1 00037 #define LOW 0 00038 00039 //#include <stdint.h> 00040 //#include <stdio.h> 00041 //#include <string.h> 00042 00043 #define _BV(x) (1<<(x)) 00044 #define _SPI SPI 00045 00046 #ifdef SERIAL_DEBUG 00047 #define IF_SERIAL_DEBUG(x) ({x;}) 00048 #else 00049 #define IF_SERIAL_DEBUG(x) 00050 #endif 00051 00052 //#define printf_P printf 00053 #define printf_P 00054 //#define _BV(bit) (1<<(bit)) 00055 #define pgm_read_byte(addr) (*(const unsigned char *)(addr)) 00056 00057 typedef uint16_t prog_uint16_t; 00058 #define PSTR(x) (x) 00059 // #define sprintf(...) os_sprintf( __VA_ARGS__ ) 00060 //#define printf_P printf 00061 #define printf_P 00062 #define strlen_P strlen 00063 #define PROGMEM 00064 #define pgm_read_byte(addr) (*(const unsigned char *)(addr)) 00065 #define pgm_read_word(p) (*(p)) 00066 #define PRIPSTR "%s" 00067 00068 #endif // __RF24_CONFIG_H__ 00069
Generated on Tue Jul 12 2022 15:10:52 by 1.7.2