{"id":254,"date":"2019-04-08T15:38:05","date_gmt":"2019-04-08T07:38:05","guid":{"rendered":"https:\/\/www.ientertech.com\/blog\/?p=254"},"modified":"2019-04-08T15:38:05","modified_gmt":"2019-04-08T07:38:05","slug":"wincc-%e5%af%b9%e8%b1%a1%e7%a7%bb%e5%8a%a8%e4%b8%8d%e5%b9%b3%e6%bb%91","status":"publish","type":"post","link":"https:\/\/www.ienter.com.cn\/blog\/2019\/04\/wincc-%e5%af%b9%e8%b1%a1%e7%a7%bb%e5%8a%a8%e4%b8%8d%e5%b9%b3%e6%bb%91.html","title":{"rendered":"WinCC \u5bf9\u8c61\u79fb\u52a8\u4e0d\u5e73\u6ed1"},"content":{"rendered":"<p>WinCC\u811a\u672c\u8fd8\u4e0d\u592a\u719f\u6089\u4f7f\u7528\u5411\u5bfc\u5b8c\u6210\u79fb\u52a8\uff0c\u53d1\u73b0\u4e0d\u5e73\u6ed1\uff0c\u8bd5\u4e86\u8bd5\uff0c\u5206\u8fa8\u7387\u662f10\u4e2a\u50cf\u7d20\uff0c\u6253\u5f00\u751f\u6210\u7684\u811a\u672c<\/p>\n<p>#include \"apdefap.h\"<br \/>\nlong _main(char* lpszPictureName, char* lpszObjectName, char* lpszPropertyName)<br \/>\n{<\/p>\n<p>\/\/ WINCC:TAGNAME_SECTION_START<br \/>\n\/\/ syntax: #define TagNameInAction \"DMTagName\"<br \/>\n\/\/ next TagID : 1<br \/>\n#define TAG_0 \"Move_NumX\"<br \/>\n#define TAG_1 \"Move_NumY\"<br \/>\n\/\/ WINCC:TAGNAME_SECTION_END<\/p>\n<p>\/\/ WINCC:PICNAME_SECTION_START<br \/>\n\/\/ syntax: #define PicNameInAction \"PictureName\"<br \/>\n\/\/ next PicID : 1<br \/>\n\/\/ WINCC:PICNAME_SECTION_END<\/p>\n<p>long i,j,k;<br \/>\ni=GetTagWord(TAG_0);<br \/>\nj=((i-0)*100\/(1010-0));<br \/>\nk=min((((j*(1090-80))\/100)+80),1090);<br \/>\nreturn max(80,k);<\/p>\n<p>}<\/p>\n<p>\u5176\u4e2d\u7684<\/p>\n<p>j=((i-0)*100\/(1010-0));<br \/>\nk=min((((j*(1090-80))\/100)+80),1090);<\/p>\n<p>\u8fd9\u4e24\u53e5\u4e2d\u7684100\u662f\u8fd0\u7b97\u7684\u4e00\u4e2a\u57fa\u6570\uff0c\u65391000\u5c31ok\u4e86\uff0c\u518d\u79fb\u52a8\u5e73\u6ed1\u987a\u7545\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>WinCC\u811a\u672c\u8fd8\u4e0d\u592a\u719f\u6089\u4f7f\u7528\u5411...<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[13],"tags":[31],"class_list":["post-254","post","type-post","status-publish","format-standard","hentry","category-13","tag-wincc"],"_links":{"self":[{"href":"https:\/\/www.ienter.com.cn\/blog\/wp-json\/wp\/v2\/posts\/254","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.ienter.com.cn\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.ienter.com.cn\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.ienter.com.cn\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.ienter.com.cn\/blog\/wp-json\/wp\/v2\/comments?post=254"}],"version-history":[{"count":0,"href":"https:\/\/www.ienter.com.cn\/blog\/wp-json\/wp\/v2\/posts\/254\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.ienter.com.cn\/blog\/wp-json\/wp\/v2\/media?parent=254"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.ienter.com.cn\/blog\/wp-json\/wp\/v2\/categories?post=254"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.ienter.com.cn\/blog\/wp-json\/wp\/v2\/tags?post=254"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}