Giter VIP home page Giter VIP logo

console-v0's Introduction

QSuperConsole

Super Console serial port serial bus modbus canbus tcp/ip

Qt必须5.6版本以上

git推送服务器命令:git push -uf origin master:workon 以branch 'workon' of github.com:pkzju/QSuperConsole例

canopen协议参考:canopen/CANOpen_memento.pdf CANopen_meno.pdf CanFestival源码手册:canopen/manual_en.pdf

  1. 移植时win32时 错误出现在objdictdef.h文件 identity宏定义 改为IDENTITY后ok

  2. 安装Beremiz-1.1_RC5.exe, 点击objdictedit.py 打开字典编辑器编辑对象字典 例:(win32test.c中) 初始化对象字典:CO_Data win32test_Data = CANOPEN_NODE_DATA_INITIALIZER(win32test); CANOPEN_NODE_DATA_INITIALIZER宏定义在data.h中

记录: {//record Transition from Initialisation to Pre_operational is automatic as defined in DS301. App don't have to call SetState(d, Pre_operational)

In states.c function : UNS8 setState(CO_Data* d, e_nodeState newState)

										s_state_communication:
             csBoot_Up    csSDO    csEmergency    csSYNC     csLifeGuard    csPDO        csLSS

Initialisation {1, 0, 0, 0, 0, 0, 0} Pre_operational {0, 1, 1, 1, 1, 0, 1} Operational {0, 1, 1, 1, 1, 1, 0} Stopped {0, 0, 0, 0, 1, 0, 1}

csLSS: 0 -> 1 startLSS(d), 1 -> 0 stopLSS(d)) sSDO: 0 -> 1 None, 1 -> 0 resetSDO(d)) csSYNC: 0 -> 1 startSYNC(d), 1 -> 0 stopSYNC(d)) csLifeGuard: 0 -> 1 lifeGuardInit(d), 1 -> 0 lifeGuardStop(d)) csEmergency: 0 -> 1 emergencyInit(d), 1 -> 0 emergencyStop(d)) csPDO: 0 -> 1 PDOInit(d), 1 -> 0 PDOStop(d)) csBoot_Up: 0 -> 1 None, 1 -> 0 slaveSendBootUp(d))

In sync.c function : UNS8 proceedSYNC(CO_Data* d)
-> _sendPDOevent() -> isSyncEvent? -> 比较 TPDO 的transmit_type_parameter设定值与当前值 当前值++ -> 设定值==当前值? -> 发送对应TPDO, -> 检查下一个TPDO }

{//record qt代码中判断windows/linux/arm等系统

可使用宏判断,例如: #include ... #ifdef Q_OS_MAC // mac #endif

#ifdef Q_OS_LINUX // linux #endif

#ifdef Q_OS_WIN32 // win #endif

#ifdef arm // arm #endif }

//record {9600 baudrate -> 1 char = 1.14ms 3.5char = 4ms}

//compare {exec与show: exec 关掉对话框才能操作其他窗口 show 不必关掉都可以操作}

{//warning If cell widget A is replaced with cell widget B, cell widget A will be deleted. For example, in the code snippet below, the QLineEdit object will be deleted.

setCellWidget(index, new QLineEdit); ... setCellWidget(index, new QTextEdit); }

console-v0's People

Contributors

pkzju avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.