激光发射
来自Labplus盛思维基百科
概述
内置激光发射头,高电平开启激光器,低电平则否
技术参数
- 工作电压: VCC 3.3V -5V
- 发射功率:150mW
- 激光波长:650nm(红色)
- 出光功率:<5mW
- 光点大小:15米处光直径:<φ15mm
- 模块尺寸:24x46x7.5mm
引脚定义
VCC | 电源 |
NC | 空脚 |
DI | 数字输入 |
GND | 地 |
使用教程
Arduino示例
//程序功能:按键按下,发射激光;按键松开,激光关闭// int buttonPin =2; int laserPin=3; int val; void setup() { // put your setup code here, to run once: Serial.begin(9600); pinMode(buttonPin,INPUT); pinMode(laserPin,OUTPUT); } void loop() { val=digitalRead(buttonPin); Serial.print(val); if(val==HIGH) { digitalWrite(laserPin,HIGH); } else { digitalWrite(laserPin,LOW); } }