描述 KeyboardController 是一个类别,包含许多控制键盘的成员函式。 语法 KeyboardController keyboard(usb); 范例 函式 - keyPressed() - keyReleased() - getModifiers() - getKey() - getOemKey() 函式库参考主页面 The text of the 86Duino reference is a modification of the Arduino reference, and is licensed under a Creative Commons Attribution-ShareAlike 3.0 License. Code samples in the reference are released into the public domain.
下面提供 86Duino 与 A/B Phase(或 Pulse/DIR、CW/CCW)信号类型的增量编码器连接的一个例子。 本例使用 86Duino One 与 AM4096 旋转编码器 IC。一般而言,增量型的旋转编码器会有二个输出,通常称为 A 和 B,可输出 A/B Phase(或 Pulse/DIR、CW/CCW)信号以指示旋转方向、位置及角度等资讯。有些增量型旋转编码器还会有第三个输出,一般称为 Z 或 index 信号,编码器每旋转一圈 Z 信号会有一个方波输出,可以用来判断转轴的绝对位置。 AM4096 输出 A、B、Z 信号的脚位在其规格书中分别被标示为 A、B、Ri,可直接连接到 86Duino One 的 ENC0 编码器介面的 A、B、Z 三根针脚(即 digital pins 42、43、44),同时因为 AM4096 需要供应 3.3V 电源,因此我们将 86Duino One 的 3.3V 输出与 GND 分别接到 AM4096 的 Vdd 与 […]
描述 回覆查询的滑鼠按键状态。 语法 mouse.getButton(button) 参数 button:可以查询的按键,有以下三种: -LEFT_BUTTON -RIGHT_BUTTON -MIDDLE_BUTTON 回传 boolean:如果查询的按键被按了,回传 true,否则回传 false。 范例 参见 - mousePressed() - mouseReleased() 函式库参考主页面 The text of the 86Duino reference is a modification of the Arduino reference, and is licensed under a Creative Commons Attribution-ShareAlike 3.0 License. Code samples in the reference are released into the public domain.
描述 回覆滑鼠从上一次查询后在 Y 轴上移动的距离,回传的值如果是正的,表示往下移动,反之则表示往上移动。 语法 mouse.getYChange() 参数 无参数 回传 int 范例 参见 - mouseDragged() - mousePressed() 函式库参考主页面 The text of the 86Duino reference is a modification of the Arduino reference, and is licensed under a Creative Commons Attribution-ShareAlike 3.0 License. Code samples in the reference are released into the public domain.
描述 回覆滑鼠从上一次查询后在 X 轴上移动的距离,回传的值如果是正的,表示往右移动,反之则表示往左移动。 语法 mouse.getXChange() 参数 无参数 回传 int 范例 参见 - mouseDragged() - mousePressed() 函式库参考主页面 The text of the 86Duino reference is a modification of the Arduino reference, and is licensed under a Creative Commons Attribution-ShareAlike 3.0 License. Code samples in the reference are released into the public domain.
描述 mouseReleased() 是一个函式,当 USB 的滑鼠按键释放时被呼叫。 语法 void mouseReleased() { // statements } 范例 参见 - mouseMoved() - mouseDragged() - mousePressed() - getXChange() - getYChange() - getButton() 函式库参考主页面 The text of the 86Duino reference is a modification of the Arduino reference, and is licensed under a Creative Commons Attribution-ShareAlike 3.0 License. Code samples in the reference […]
描述 mousePressed() 是一个函式,当 USB 滑鼠按键被按时被呼叫。 语法 void mousePressed() { // statements } 范例 参见 - mouseMoved() - mouseDragged() - mouseReleased() - getXChange() - getYChange() - getButton() 函式库参考主页面 The text of the 86Duino reference is a modification of the Arduino reference, and is licensed under a Creative Commons Attribution-ShareAlike 3.0 License. Code samples in the reference […]
描述 mouseDragged() 是一个函数,当 USB 滑鼠拖曳(按着滑鼠按键移动)时被呼叫。 语法 void mouseDragged() { // statements } 范例 参见 - mouseMoved() - mousePressed() - mouseReleased() - getXChange() - getYChange() - getButton() 函式库参考主页面 The text of the 86Duino reference is a modification of the Arduino reference, and is licensed under a Creative Commons Attribution-ShareAlike 3.0 License. Code samples in the reference […]
描述 mouseMoved()是一个函数,当 USB 滑鼠移动时被呼叫。 语法 void mouseMoved() { // statements } 范例 参见 - mouseDragged() - mousePressed() - mouseReleased() - getXChange() - getYChange() - getButton() 函式库参考主页面 The text of the 86Duino reference is a modification of the Arduino reference, and is licensed under a Creative Commons Attribution-ShareAlike 3.0 License. Code samples in the reference are […]
描述 MouseController 是一个类别,包含许多控制滑鼠的成员函式。 语法 MouseController mouse(usb); 范例 函式 - mouseMoved() - mouseDragged() - mousePressed() - mouseReleased() - getXChange() - getYChange() - getButton() 函式库参考主页面 The text of the 86Duino reference is a modification of the Arduino reference, and is licensed under a Creative Commons Attribution-ShareAlike 3.0 License. Code samples in the reference are released into the […]