Re: [Bacnet-developers] MSTP on Linux - is it ever possible?
Brought to you by:
skarg
From: Lakshmi k. P. <p.l...@ya...> - 2011-02-05 04:06:39
|
Thanks Vasu Vallabhaneni!!! It worked. --- On Fri, 4/2/11, Vasu Vallabhaneni <vas...@hc...> wrote: From: Vasu Vallabhaneni <vas...@hc...> Subject: Re: [Bacnet-developers] MSTP on Linux - is it ever possible? To: "Discussion for developers of the BACnet stack" <bac...@li...> Date: Friday, 4 February, 2011, 7:54 AM Hi Buddy. You said that the BACNET_MSTP_MAC=0x6F. We need two different MAC addresses too. So take two terminals set two different MAC addresses for env variables.and try it. Ex:- export BACNET_MSTP_MAC=0x6F. In one terminal. export BACNET_MSTP_MAC=0x01. In other terminal. I hope that it will work. Regards Vasu Vallabhaneni HCL Technologies Ltd. Chennai - AMB1, D12&12B, Ambattur Indl.Estate, Chennai 600058 (India) Tel: +91-044-26230711 Extn: 2208 cell:9566088955 vas...@hc... -----Original Message----- From: Kåre Särs [mailto:kar...@wa...] Sent: Friday, February 04, 2011 12:37 PM To: spo...@em...; Discussion for developers of the BACnet stack Subject: Re: [Bacnet-developers] MSTP on Linux - is it ever possible? Hi, On Thursday 03 February 2011 18:49:43 Sergei Poselenov wrote: > Hello all, > > I'm trying to test the bacnet-stack MSTP basic functionality, which I > have built on Linux x86, version 0.5.7. > > I have two serials on my PC, connected via a null-modem cable. > > I ran: > BACNET_MSTP_BAUD=115200 BACNET_IFACE=/dev/ttyS0 ./bin/bacwi 260001 > and > BACNET_MSTP_BAUD=115200 BACNET_MSTP_MAC=0x6F BACNET_IFACE=/dev/ttyS1 > ./bin/bacserv > > ... and got nothing. > > I also tried to enable hardware flow control, and ran both programs > under "ionice", as suggested in ports/linux/rs485.c, without much > success. > I only had success when I set: > > static uint8_t Treply_timeout = 26000; > static uint8_t Tusage_timeout = 5000; > > I found a discussion of the Linux MSTP issue here > http://sourceforge.net/mailarchive/message.php?msg_id=26633681 > > Essentially, Steve is saying here that Linux is not fast enough to > meet the strict MSTP timings. > > Could someone please explain (I'm sorry if I'm a hundredth who is > asking) why is my 2.4 GHz P4 is not fast enough? The problem is that a standard desktop Linux kernel is not a real-time kernel and does not guarantee that you get millisecond timing. The kernel tick has been 10 ms which means that if you call usleep() to sleep 1ms the thread will sleap for at least 1 ms but might sleep up to 10ms. If you also have a broken driver somewhere you might get up to 100ms sleeps even if you just asked for 1. > > Is it ever possible to use the the MSTP bacnet-stack configuration for > implementing BACNet over RS-485 between two Linux-driven machines? Most distributions do have a "real-time" kernel that improves the responsiveness, but I'm not sure how accurate timing they have achieved. The kernel tick can also be modified while compiling the kernel, but a shorter tick will decrease the performance as there will be a lot of extra context switches. I have been running an MSTP stack on linux to debug an MSTP device, so it is possible to communicate, but the reliability of the communication is not guaranteed to work 100% > > And why is BACNet IP implementation works fine on two PCs? BACNet IP does not have the same strict timing requirements. /Kåre ------------------------------------------------------------------------------ The modern datacenter depends on network connectivity to access resources and provide services. The best practices for maximizing a physical server's connectivity to a physical network are well understood - see how these rules translate into the virtual world? http://p.sf.net/sfu/oracle-sfdevnlfb _______________________________________________ BACnet-developers mailing list BAC...@li... https://lists.sourceforge.net/lists/listinfo/bacnet-developers ::DISCLAIMER:: ----------------------------------------------------------------------------------------------------------------------- The contents of this e-mail and any attachment(s) are confidential and intended for the named recipient(s) only. It shall not attach any liability on the originator or HCL or its affiliates. Any views or opinions presented in this email are solely those of the author and may not necessarily reflect the opinions of HCL or its affiliates. Any form of reproduction, dissemination, copying, disclosure, modification, distribution and / or publication of this message without the prior written consent of the author of this e-mail is strictly prohibited. If you have received this email in error please delete it and notify the sender immediately. Before opening any mail and attachments please check them for viruses and defect. ----------------------------------------------------------------------------------------------------------------------- ------------------------------------------------------------------------------ The modern datacenter depends on network connectivity to access resources and provide services. The best practices for maximizing a physical server's connectivity to a physical network are well understood - see how these rules translate into the virtual world? http://p.sf.net/sfu/oracle-sfdevnlfb _______________________________________________ BACnet-developers mailing list BAC...@li... https://lists.sourceforge.net/lists/listinfo/bacnet-developers |