This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
* w25q64_readwrite.c | |
* | |
* Created: 2019-07-28 오후 4:47:14 | |
* Author : yeong | |
*/ | |
#define F_CPU 16000000UL | |
#include <util/delay.h> | |
#include <avr/io.h> | |
#include "uart.h" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
* w25q64.c | |
* | |
* Created: 2019-07-14 오전 4:16:22 | |
* Author: yeong | |
*/ | |
#include "w25q64.h" | |
/** @brief: initialize the ss pin |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
uint8_t *arr; | |
void w25q_fast_read(uint32_t addr, uint32_t size) | |
{ | |
arr = (uint8_t *)malloc(sizeof(uint8_t)*size); | |
uint8_t cmd[3]; | |
uint8_t trashval; | |
cmd[0] = (addr >> 16) & 0xFF; | |
cmd[1] = (addr >> 8) & 0xFF; | |
cmd[2] = addr & 0xFF; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> | |
using namespace std; | |
typedef struct __team { | |
int win, draw, lose; | |
} team; | |
team t[6]; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <Wire.h> | |
const int mpu6050_addr = 0x68; | |
int16_t GyX, GyY, GyZ; | |
void setup() { | |
Serial.begin(115200); | |
Wire.begin(); | |
Wire.beginTransmission(mpu6050_addr); | |
Wire.write(0x6b); // Power Management Register |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <string> | |
#include <cstring> | |
#include <iostream> | |
using namespace std; | |
typedef struct __pb { | |
string s; | |
int stk, ball; | |
} PB; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stack> | |
#include <sstream> | |
#include <iostream> | |
using namespace std; | |
int main(void) { | |
ios_base::sync_with_stdio(false); | |
cin.tie(nullptr); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <map> | |
#include <string> | |
#include <iostream> | |
using namespace std; | |
char mat[100][100]; | |
int main(void) { | |
ios_base::sync_with_stdio(false); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <cstring> | |
#include <sstream> | |
#include <iostream> | |
using namespace std; | |
#define max(n, m) n > m ? n : m | |
char a[2501], b[51]; | |
char* ptrarr[2501]; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> | |
using namespace std; | |
char mat[50][50]; | |
bool row[50]; | |
bool col[50]; | |
int main(void) { | |
ios_base::sync_with_stdio(false); |