首页| JavaScript| HTML/CSS| Matlab| PHP| Python| Java| C/C++/VC++| C#| ASP| 其他|
购买积分 购买会员 激活码充值

您现在的位置是:虫虫源码 > 其他 > gsm

gsm

  • 资源大小:10.12 kB
  • 上传时间:2021-06-30
  • 下载次数:0次
  • 浏览次数:0次
  • 资源积分:1积分
  • 标      签: arduino

资 源 简 介

arduino的io控制输入输出#include #include #include "RC522.h"#include "DS1302.h"#include #define GSMSerial Serial1#define ID "768E4DA5"uint8_t CE_PIN   = 4;uint8_t IO_PIN   = 3;uint8_t SCLK_PIN = 2;char buf[50];//4 bytes Serial number of card, the 5 bytes is verfiy bytesunsigned char serNum[5];unsigned char state_pre=1;/* 创建 DS1302 对象 */DS1302 rtc(CE_PIN, IO_PIN, SCLK_PIN);void print_time() {     /* 从 DS1302 获取当前时间 */     Time t = rtc.time();     snprintf(buf, sizeof(buf), "%04d-%02d-%02d %02d:%02d:%02d", t.yr, t.mon, t.date, t.hr, t.min, t.sec);     /* 输出日期到串口 */     Serial.println(buf); }void setup() {   Serial.begin(9600);

文 件 列 表

ArduinoCodeRFID
ArduinoCodeRFID.ino
DS1302.cpp
DS1302.h
RC522.cpp
RC522.h
VIP VIP
0.198125s