找回密码
 立即注册

QQ登录

只需一步,快速开始

搜索
查看: 2699|回复: 2
收起左侧

LabVIEW黑白棋程序

[复制链接]
ID:538312 发表于 2019-5-14 20:38 | 显示全部楼层 |阅读模式
今天因为工作需要,察看了我原来备份的一些文件。
结果我翻出来了好多已经被我遗忘了的东西,都拿来跟大家分享吧,也作为一个纪念。

先分享一个 LabVIEW 下黑白棋的程序。这不是我说过的使用遗传算法的那个程序。
这是我刚开始学习 LabVIEW 时编写的程序。那时还是1999年,使用的是LabVIEW 5.1。
程序里基本只有界面,没有实现什么算法。

程序在LabVIEW 5.1上开发之后,我再也没有再维护过。我今天在LabVIEW 8.1 上试着打开它,发现以前所使用的一些库VI已经找不到了,不过只影响到了Othello server.vi。其他VI还可以正常运行。


解开zip包:
Othello.vi             是在本机两人对战的主VI
Othello auto.vi   或 Othello super.vi  是人机对战的主VI
Othello server.vi   是在局域网两人对战的服务端VI
Othello client.vi   是在局域网两人对战的客户端VI
0.png

单片机源程序如下:
  1. // Othello.cpp : Defines the entry point for the console application.
  2. //

  3. #include "stdio.h"
  4. #include "stdlib.h"
  5. #include "CheckStatus.h"
  6. #include "TurnOver.h"
  7. #include "AutoPutOneChess.h"


  8. int GetNewChessPosition(int thePositionArrary[8][8], int chessColor,
  9.                                                  int step, int *autoRow, int *autoColumn)
  10. {   rand();
  11.         if ((step)<54)
  12.                 Auto_Put_Chess(thePositionArrary, chessColor, 7, autoRow, autoColumn);
  13.         else
  14.                 Auto_Put_Chess(thePositionArrary, chessColor, 64-(step), autoRow, autoColumn);
  15.         return(0);
  16. }
复制代码

所有资料51hei提供下载:
黑白棋程序.zip (518.59 KB, 下载次数: 11)

评分

参与人数 1黑币 +50 收起 理由
admin + 50 共享资料的黑币奖励!

查看全部评分

回复

使用道具 举报

ID:328014 发表于 2019-5-17 05:28 | 显示全部楼层
好资料,51黑有你更精彩!!!
回复

使用道具 举报

ID:320935 发表于 2019-5-20 15:23 | 显示全部楼层

好资料,51黑有你更精彩!!!
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

手机版|小黑屋|51黑电子论坛 |51黑电子论坛6群 QQ 管理员QQ:125739409;技术交流QQ群281945664

Powered by 单片机教程网

快速回复 返回顶部 返回列表