資源簡介
工作需要學習BACnet協議,希望對大家學習BACnet協議有用!

代碼片段和文件信息
/*####COPYRIGHTBEGIN####
?-------------------------------------------
?Copyright?(C)?2007?Andreas?Kahl
?This?program?is?free?software;?you?can?redistribute?it?and/or
?modify?it?under?the?terms?of?the?GNU?General?Public?License
?as?published?by?the?Free?Software?Foundation;?either?version?2
?of?the?License?or?(at?your?option)?any?later?version.
?This?program?is?distributed?in?the?hope?that?it?will?be?useful
?but?WITHOUT?ANY?WARRANTY;?without?even?the?implied?warranty?of
?MERCHANTABILITY?or?FITNESS?FOR?A?PARTICULAR?PURPOSE.??See?the
?GNU?General?Public?License?for?more?details.
?You?should?have?received?a?copy?of?the?GNU?General?Public?License
?along?with?this?program;?if?not?write?to:
?The?Free?Software?Foundation?Inc.
?59?Temple?Place?-?Suite?330
?Boston?MA??02111-1307?USA.
?As?a?special?exception?if?other?files?instantiate?templates?or
?use?macros?or?inline?functions?from?this?file?or?you?compile
?this?file?and?link?it?with?other?works?to?produce?a?work?based
?on?this?file?this?file?does?not?by?itself?cause?the?resulting
?work?to?be?covered?by?the?GNU?General?Public?License.?However
?the?source?code?for?this?file?must?still?be?made?available?in
?accordance?with?section?(3)?of?the?GNU?General?Public?License.
?This?exception?does?not?invalidate?any?other?reasons?why?a?work
?based?on?this?file?might?be?covered?by?the?GNU?General?Public
?License.
?-------------------------------------------
####COPYRIGHTEND####*/
using?System;
using?System.Collections.Generic;
using?System.Text;
using?BACnetApplicationlayer;
namespace?AppTest
{
????class?Program
????{
????????static?void?Main(string[]?args)
????????{
????????????Program?app?=?new?Program();
????????????app.DoCompleteTest1();????????????
????????}
????????private?void?DoCompleteTest1()
????????{
????????????byte[]?buffer?=?new?byte[20];
????????????UInt16?pos?=?new?UInt16();
????????????pos?=?0;
????????????IAmRequest?request?=?new?IAmRequest();
????????????request.DeviceIdentifier?=?200;
????????????request.MaxAPDULengthAccepted.Value?=?1024;
????????????request.VendorID.Value?=?15;
????????????
????????????request.Encode(bufferref?pos);
????????????BacnetPDU?pdu=BacnetPDU.Decode(buffer?0);
????????}
????????private?void?DoCompleteTest()
????????{
????????????IAmRequest?request?=?new?IAmRequest();
????????????request.DeviceIdentifier?=?200;
????????????request.MaxAPDULengthAccepted.Value?=?1024;
????????????request.VendorID.Value?=?15;
????????????ApplicationService?appService?=?new?ApplicationService(?new?Networklayer(new?linklayer()?)?);
????????????appService.SendBACnetPDU(request);
????????}
????????private?void?DoTests()
????????{
???????????
????????????byte[]?buffer?=?new?byte[20];
????????????UInt16?pos?=?new?UInt16();
????????????pos?=?0;
????????????//DoTestVendor(buffer?ref?pos);
????????????DoIAM(buffer?ref?pos);
????????????ShowBuffer(buffer?pos);
????????}
????????private?void?DoIAM(byte[]?buffer?ref?UInt16?pos)
????????{
????????????pos?=?0;
???????
?屬性????????????大小?????日期????時間???名稱
-----------?---------??----------?-----??----
?????目錄???????????0??2013-04-28?11:41??BACnet\
?????目錄???????????0??2013-04-28?11:41??BACnet\branches\
?????目錄???????????0??2013-04-28?11:41??BACnet\tags\
?????目錄???????????0??2013-04-28?11:41??BACnet\trunk\
?????目錄???????????0??2013-04-28?11:41??BACnet\trunk\AppTest\
?????文件????????2202??2008-01-15?06:37??BACnet\trunk\AppTest\AppTest.csproj
?????文件????????3714??2010-03-12?10:57??BACnet\trunk\AppTest\Program.cs
?????目錄???????????0??2013-04-28?11:41??BACnet\trunk\AppTest\Properties\
?????文件????????1267??2010-03-12?10:57??BACnet\trunk\AppTest\Properties\AssemblyInfo.cs
?????目錄???????????0??2013-04-28?11:41??BACnet\trunk\BACnetApplicationla
?????文件????????2543??2010-03-12?10:57??BACnet\trunk\BACnetApplicationla
?????文件????????2335??2010-03-12?10:57??BACnet\trunk\BACnetApplicationla
?????文件????????2355??2008-01-15?06:37??BACnet\trunk\BACnetApplicationla
?????文件????????2656??2010-03-12?10:57??BACnet\trunk\BACnetApplicationla
?????文件????????2112??2010-03-12?10:57??BACnet\trunk\BACnetApplicationla
?????文件????????1590??2010-03-12?10:57??BACnet\trunk\BACnetApplicationla
?????文件????????5697??2010-03-12?10:57??BACnet\trunk\BACnetApplicationla
?????文件????????2070??2010-03-12?10:57??BACnet\trunk\BACnetApplicationla
?????文件????????2076??2010-03-12?10:57??BACnet\trunk\BACnetApplicationla
?????文件????????2163??2010-03-12?10:57??BACnet\trunk\BACnetApplicationla
?????文件????????2079??2010-03-12?10:57??BACnet\trunk\BACnetApplicationla
?????目錄???????????0??2013-04-28?11:41??BACnet\trunk\BACnetApplicationla
?????文件????????1418??2010-03-12?10:57??BACnet\trunk\BACnetApplicationla
?????目錄???????????0??2013-04-28?11:41??BACnet\trunk\bacsharp\
?????文件????????1908??2008-01-15?06:37??BACnet\trunk\bacsharp.sln
?????文件???????33280??2008-01-15?06:37??BACnet\trunk\bacsharp.suo
?????文件?????????123??2010-03-12?10:57??BACnet\trunk\bacsharp\AI.cs
?????文件???????53648??2010-03-12?10:57??BACnet\trunk\bacsharp\BACnetEnums.cs
?????文件????????2611??2008-01-15?06:37??BACnet\trunk\bacsharp\bacsharp.csproj
?????文件?????????238??2008-01-15?06:37??BACnet\trunk\bacsharp\bacsharp.csproj.user
?????文件????????1634??2010-03-12?10:57??BACnet\trunk\bacsharp\Datali
............此處省略7個文件信息
評論
共有 條評論