Articles Posted by the Author:

  • save()

    save()

    描述 将 positions[] 阵列的内容储存为可被 ServoFrame 载入的动作帧档案。 语法 servoframevstone.save(filename) 参数 myframe:ServoFrameVstone 型别的物件。 filename:动作帧档案的名称。注意:档案会储存至 SD 卡的根目录下,假如您的 86Duino 没有插入 SD 卡,则储存会失败。 回传 true:档案储存成功。 false:档案储存失败。 范例 See also - positions[] - load() - setPostions() 函式库参考主页面 The text of the 86Duino reference is licensed under a Creative Commons Attribution-ShareAlike 3.0 License. Code samples in the reference are released into the […]


  • playPositions()

    playPositions()

    描述 将指定伺服机的目标位置设定为 positions[] 阵列储存的动作帧内容,同时命令伺服机转动。 呼叫 playPositions() 后,您的程式可以去做其他事情,转动伺服机的工作会在背景执行,如果想知道伺服机是否转到目标位置,可以呼叫 isServoMultiMoving() 来检查。 语法 myframe.playPositions() myframe.playPositions(servo0) myframe.playPositions(servo0, servo1) myframe.playPositions(servo0, servo1, ... , servo44) myframe.playPositions(time) myframe.playPositions(time, servo0) myframe.playPositions(time, servo0, servo1) myframe.playPositions(time, servo0, servo1, ... , servo44) 参数 myframe:ServoFrameVstone 型别的物件。 servo0 ~ servo44(可选):Servo 型别的物件;其中 servo0 使用 positions[0] 的值,servo1 使用 positions[1] 的值,以此类推。 time(可选):设定伺服机一起转动到目标位置所使用的时间;若没有设定此值,或者将其设定为 0,则伺服机将会以全速转动。 回传 范例 See also - positions[] - […]


  • setPostions()

    setPostions()

    描述 将指定伺服机的目标位置设定为 positions[] 阵列储存的动作帧内容。 语法 myframe.setPositions() myframe.setPositions(servo0) myframe.setPositions(servo0, servo1) myframe.setPositions(servo0, servo1, ... , servo44) myframe.setPositions(time) myframe.setPositions(time, servo0) myframe.setPositions(time, servo0, servo1) myframe.setPositions(time, servo0, servo1, ... , servo44) 参数 myframe:ServoFrameVstone 型别的物件。 servo0 ~ servo44(可选):Servo 型别的物件;其中 servo0 使用 positions[0] 的值,servo1 使用 positions[1] 的值,以此类推。 time(可选):设定伺服机一起转动到目标位置所使用的时间;若没有设定此值,或者将其设定为 0,则伺服机将会以全速转动。 回传 范例 See also - positions[] - playPositions() 函式库参考主页面 The text of […]


  • positions[]

    positions[]

    描述 存放机器人动作帧的整数阵列,每个阵列元素的值对应一个机器人伺服机的位置,单位为 us。 若 ServoFrameVstone 在初始化时,没有指定载入动作帧档案,则使用者可改由直接设定此阵列的元素值来设定动作帧。 语法 myframe.positions[channel] 参数 myframe:ServoFrameVstone 型别的物件。 channel:指定阵列元素,范围为 0 ~ 44。第 n 个元素值代表要指定给第 n 个 Servo 的位置,请见下面范例说明。(注意:在 86Duino One 上所有阵列元素都有效;在86Duino EduCake 上只有 0 ~ 25 的范围有效;在 86Duino Zero 上只有 0 ~ 16 的范围有效。) 由于 RobovieMaker2 固定支援 30 轴伺服机,当使用 load() 函式由其动作帧档案载入指定动作帧时,只有 positions[0]、positions[1]、…、positions[29] 会包含有效值,其余阵列元素皆为 0。 回传 范例 See also - setPostions() - […]


  • ServoFrameVstone constructor

    ServoFrameVstone constructor

    描述 初始化 ServoFrameVstone 类别。 ServoFrameVstone 是继承自 ServoFrame 类别,能载入用 RobovieMaker2 动作编辑器制作的机器人动作帧。 语法 ServoFrameVstone myframe ServoFrameVstone myframe(filename, frame_name) 参数 filename:由 RobovieMaker2 所储存 .txt 动作档案名称。 frame_name:动作帧的名称(可在 RobovieMaker2 中查询取得)。 如果有输入以上两个参数,则 ServoFrameVstone 在初始化类别时,会自动载入该档案内的指定动作帧做为初始动作帧。请注意,您必须将档案放在 SD 卡根目录下;假如您的 86Duino 没有置入 SD 卡,或者 SD 卡内不包含动作档案,则档案载入会失败。 范例 See also - load() - setPositions() 函式库参考主页面 The text of the 86Duino reference is licensed under a Creative […]


  • 如何建立作为 Arduino 系统扩充碟用的空白 SD 卡

    如何建立作为 Arduino 系统扩充碟用的空白 SD 卡

    当 86Duino 通电开机时,BIOS 会到三个地方去寻找可开机磁碟:内建的 Flash 记忆体、SD 卡、USB 随身碟。搜寻顺序是 SD 卡优先,然后是 USB 随身碟,最后才是 Flash。 内建的 Flash 记忆体在出厂时,已经预设安装了 86Duino 韧体系统,如果使用者在 86Duino 上没有插上可开机的 SD 卡或 USB 随身碟,预设就会从 Flash 开机;但如果使用者插上具有开机磁区的 SD 卡或 USB 随身碟,则必须确保该 SD 卡或 USB 随身碟上已安装 86Duino 韧体系统(即安装 SysImage)或其它作业系统(例如 Windows 或 Linux),否则 86Duino 将因找不到作业系统而开机失败。 如果希望能插上 SD 卡或 USB 随身碟,同时又让 86Duino 从 Flash 开机,则必须先将 SD 卡或 USB 随身碟做成没有开机磁区的空白磁碟。以下提供一种制作方法给读者参考。 […]