Archive for the ‘BACnet’ Category

BACnet at Long Beach

Saturday, June 30th, 2007

We had our Summer BACnet committee meeting in Long Beach, California. We mostly discussed new addenda or responses to public review comments on addenda that had been out for public review.

bacnet_committee_meeting_512x256.jpg

Our traditional Saturday evening BACnet dinner was held at the Rock Bottom Brewary.

BACnet_Dinner_1.jpgBACnet_Dinner_2.jpg

BACnet_Dinner_3.jpgBACnet_Dinner_4.jpg

We had time to shoot billiards after our dinner was served.

BACnet_Billiards_1.jpgBACnet_Billiards_2.jpg

I stayed on board the RMS Queen Mary, a former cruise ship and former troop carrier during World War II.

queen_mary.jpgqueen_mary_front.jpg

QM_A019_Hall_Id.jpgqueen_mary_lifeboats.jpg

QM_A019_Entry_Out.jpgQM_A019_Inside.jpg

QM_A019_StewardCall.jpgQM_A019_Air.jpgQM_A019_Bathroom.jpg

BACnet Meeting Traditions, Legends, and Phrases

Tuesday, November 21st, 2006

IMG_0212.JPGThe BACnet committee has a dining tradition: when we go out to dinner, we get one bill and divide it equally among those present. The restuarant must serve beer, and have good food. The restuarant or brewery also needs to have some vegetarian fare since Carl is a vegetarian. If we have a meeting that is during the weekdays, the group dinner is held on a Tuesday. If we have a meeting that is during the weekend, the group dinner is held on Saturday.

IMG_0197.JPG IMG_0195.JPG IMG_0196.JPG

I heard the legend of the “J” stamp a couple of weeks ago while at dinner during the BACnet meetings held in Atlanta, Georgia. Apparently, when the BACnet standard was first published for public review, many comments flowed into the committee from some unfriendly commenters. Some comments were either impossible or nit-picky. As the legend goes, a rubber stamp with the letter “J” was purchased and was used on some of these comments to notate “Jerk.

During the last transition of committee chair in Nashville, Tennessee, Steve Bushby handed a wooden gavel to Bill Swan. Bill now uses the gavel to signify the beginning or end of the meeting, or a call to order. It makes quite a few of us jump!

BACnet committee meetingBACnet Chairman and Secretary - Bill Swan and Carl NeilsonJerry and Sharon at the BACnet meeting

Sometimes during a meeting something is said that requires a definition. I keep a notebook of some of these words, and what they mean in the context of a BACnet meeting. Here are some examples:

  • “lame device” or “weak device” – a BACnet device implements only the minimal required functionality.
  • “data sucking” – learning the system using Who-Is and reading the object list.
  • “raising the bar” – changing the benchmark. Usually means that more than minimal functionality is now required.
  • “tickling” – a method to get a client device to do something.
  • “barf” – what a device does when it messes up. Similar to BSOD.
  • MIRV – multiple independent reentry vehicle. Used to describe the Mulitplexer object.
  • “lurking” – what an MS/TP device does before joining in on the token passing.

coleman_beer.jpgSometimes during a meeting something memorable gets said. Here are some examples:

  • “The first question to ask in response is: ‘Well, who the hell are you?’” – David Robin
  • “Choice is the enemy of interoperability.” – John Hartman
  • “Size Matters.” – David Ritter

Is there a BACnet legend, tradition, or phrase that I missed?

Linux in-flight entertainment

Thursday, October 19th, 2006

Linux entertainment LCD touch screen in every headrest of a Song airline 757.I traveled to Phoenix this week to give a BACnet and Lighting Applications presentation to the NEMA JSC on DALI. I flew there aboard a Song Airlines 757. During the powerup sequence for the plane, all the passengers were greeted with the image of Tux and the Linux boot sequence as the in-flight entertainment system in each headrest initialized. The touch panel color LCD screens provided games, movies, music, flight information, and satellite television. During the 3 hour flight, I watched Fox News, Mythbusters on Discovery, TLC, and Sunday night football. I also listened to some Ramones and The Smiths. I played trivia with other passengers – I came in 3rd place out of 3 players. I normally dread longer flights, but having satellite TV and Linux serving up entertainment really made the trip go by quickly.

BACnet Plugfest Complete

Friday, October 6th, 2006

Today was the final day of the BACnet Interoperability Workshop, or Plugfest as it is commonly called. Over the two and a half days we found only two bugs in the open source BACnet stack at SourceForge that I ported into our lighting panel in 5 days. I fixed both bugs in a few minutes and uploaded the firmware into the lighting panels using the in-circuit-debugger. The fixes were verified by the other vendor.

BTL Plugfest - Lighting panels and laptops

The MS/TP state machine worked. We tested it at 9600 baud, 19200 baud, and 38400 baud and worked fine. 76800 baud did not work, so I will need to figure out why. I may need to clock the processor at 40 MHz instead of 20 MHz to get some extra horsepower. I will also need to optimize the other processes, like the input reading and debouncing, to take less time in the main loop.

Lithonia Lighting and Loytec testing BACnet and DALI and LON.

The food was great and I met a lot of nice folks. Hopefully my flight home tomorrow will be uneventful.

BACnet Interoperability Workshop

Thursday, September 28th, 2006

SwitchPak MS/TP MenuAt work, I have spent the past month, and in particular, the past two weeks, preparing for the BACnet Interoperabilty Workshop. What does that mean? Well, we were going to take two beta products to the plugfest, as it is affectionately called. My original plan was to take our existing product, convert and upgrade the BACnet stack in it, and add routing capability. It probably requires about a month of work to do that. However, many other things came up at work, and I didn’t even come close getting a good start on the project. Two weeks ago I talked to our specification manager who is going to be at the plugfest with me, and she asked for a completely different product to have BACnet capability added.

One side of my cubicle officeSo two weeks ago on a Monday afternoon, I pulled the product source code from our version control system (I wish it was Subversion). I setup the MPLAB IDE for that project, and connected my ICD2 to the PIC18F6720 based lighting controller. The product was developed by my friend and colleague Mark. We use a software coding standard at work that I created. Coding standards make it easy to work on each others code and it still looks somewhat familiar.

On Tuesday I grabbed the latest version of the BACnet Stack at Sourceforge from subversion, and set about integrating BACnet into the product. I cut out some code to make space for the BACnet stack – just the self test code and the RS-232 terminal. By Wednesday I had MS/TP communications and a Device Object responding to WhoIs service requests with I-Am service responses.

On Wednesday and Thursday I added support for the rest of the objects (8 Binary Inputs, 8 Binary Values, and 1 Analog Input) and DeviceCommunicationControl, ReadProperty, TimeSync, ReinitializeDevice, WhoIs, and I-Am services.

On Friday I fine tuned the MS/TP state machine. I started to use the Bitscope attached to my PC, but it didn’t have the deep capture and user friendly features of my favorite scope, the HP54645D 100MHz 2+16 channel mixed signal oscilloscope. The HP54645D is great for protocol analysis. For example, I capture 5 seconds of communication. Then I use the MegaZoom feature.  I simply twist the timebase knob and zoom in on the trace.  I use the horizonal scroll to move the trace in time to the place of interest. I can then use the cursors to measure the time or frequency or voltage. This works great, for example, when checking to see how long it takes from receiving an MS/TP token to actually using the token.  It also works well to spot a collision and determine which packet caused it.

HP54645D Scope of MS/TP Trace actual capture HP54645D Scope MSTP trace - some Mega Zoom HP54645D Scope MSTP trace - more Mega Zoom and time cursors

This week, on Monday, I added the WriteProperty service, and began validating that all the services were integrated properly. I added hooks to write to various BACnet properties since I didn’t take the time to modify the keypad menus for setting things like the BACnet Device Object Instance Number and the MS/TP baud rate.

So, it took about five working days to go from zero to BACnet. Wow! I still have some work to do in order to design the networking interaction of this device with other devices of its kind. In other words, I have to figure out how to make it do simple control networking out of the box. I also have to add menus to configure the BACnet parameters. However, I am able to read and write to the 8 relays. I am able to read the values of the inputs. I am able to read the time and date, and set the time and date. I am able to control the device communications, and able to reset the device. All using the BACnet protocol.

I guess we will see how robust the unit is based on how it behaves at the plugfest. Stay tuned!

Subversion Inconsistent Newlines

Wednesday, September 27th, 2006

Copperhead snake at the Entrance to Bert Adams Scout ReservationI was minding my own business, coding the BACnet stack project, and decided to commit some files to subversion on SourceForge. However, tortoise-svn gave me the “inconsistent newlines” error. I googled the problem, and found a solution, but that solution didn’t fix the problem – it only masked the problem since my files were legitimate C files.

I fired up SciTE with the problem file, and selected Options – Convert Line End Characters. After saving the changes, I promptly committed the problem file to subversion without having to change thesvn:eol-style option for that file. Problem solved!

Remembering the World Trade Center

Monday, September 11th, 2006

In April, 2004, the BACnet committee toured a NIST facility. Part of the tour covered the Building and Fire Research Laboratory, and we glimpsed some of the twisted metal beams from the World Trade Center after it collapsed on September 11, 2001, in New York. It was a very solemn moment for all of us.

World Trade Center steel beams at NIST World Trade Center steel beams at NIST World Trade Center steel beams at NIST

World Trade Center steel beams at NIST World Trade Center steel beams at NIST World Trade Center steel beams at NIST

BACnet Meets in Quebec

Saturday, July 1st, 2006

SSPC-135 Meeting in Quebec City June 24, 2006

The BACnet committee and working groups met in Quebec City for the summer meeting. The meetings were mostly productive, especially for my Lighting Applications working group, which didn’t meet. However, our proposal for the Lighting Output object received discussion time during the SSPC-135 meeting on Saturday, Dave Fisher (of Polarsoft fame) and I edited it on Sunday afternoon, and it was discussed again on Monday during the SSPC-135 meeting. It will most likely be voted out in an addendum for public review at our November meeting.

Dave and Coleman near the wall around Old Quebec Quebec City was delightful! I had a little time to walk into Old Quebec, and also toured The Battlefields Park. I checked out Wikipedia to see if there were any articles on The Battlefields Park, and there were none. So I created one, and took pictures of it for the article. I also walked around Old Quebec with Dave and Coleman, two driving forces at Polarsoft, and did a little shopping as well. Dave and Coleman are delightful and intelligent and generally fun to hang out with. We often met other members of the BACnet committee while out and about in Old Quebec.

Saint Jean Baptiste Day fireworks!We were also in Quebec for the celebration on the eve of Saint Jean Baptiste Day. I walked up onto the Plains of Abraham in The Battlefields Park with Steve Bushby and Mike Newman, and we watched some of the free concert, waiting patiently for the fireworks. One of the Canadians on our committee, Roland Laird, stopped by and listened to the concert with us. We saw the bonfire, but decided to go back to the hotel shortly after 11pm. Apparently the celebration and concert lasted until 6am! I saw fireworks from my hotel room window around 12:30 am and also 1:30am (or was it 2:30am?). I added some photos of the event to the Wikipedia entry for Saint Jean Baptiste Day.

Learning Python

Saturday, April 29th, 2006

Last year I started teaching my son Joshua, who was 10 years old at the time, to learn the programming language of Python. I had searched for and researched a Kids Programming Language, and settled on Python and the Livewires course. Python promotes good programming practices, the language and its tools are available for free on many platforms and operating systems, and the language can be used to develop some serious software. The Livewires course includes a series of worksheets and reference sheets that culminate in the skills necessary to write a game.

I decided that I wanted to learn to program Python too, so a friend of mine suggested reading Dive Into Python, a Python book for experienced programmers. You can buy a printed copy, read it online, or download it in a variety of formats.

Setting up Python is easy on most operating systems, and it came already installed on Ubuntu Linux. There are lots of libraries and frameworks for Python, including pyGame and wxPython. There are free and open source development environments that make editing and running your programs easy – I like DrPython.

I also want to write a BACnet workstation client using Python, and my friend Joel donated some core BACnet code that is written in Python just for doing that. Hopefully I will be up to speed soon on programming Python and will be able to create some demos for the project.

BACnet – Building Automation and Control NETwork

Monday, February 13th, 2006

I participate in an international standard called BACnet. We exchange ideas and proposals via email and teleconference, and meet face to face at least 4 times a year in various parts of the U.S. and Canada. We handle a lot of the details by utilizing working groups. The working groups are usually formed to attack a certain problem area, and generate proposals to change the BACnet standard. The BACnet committee (AKA ASHRAE SSPC-135) then reviews the proposals, and if they are okay, vote them out for publication. At that point the proposals are open game for the world to assault, and sometimes they get public review comments. All the comments must be addressed before the proposal becomes a standard.

I lead a working group call the BACnet Lighting Applications working group. We have created a number of proposals over the past 4 years, and they are just now getting formal review by the BACnet committee. It usually takes several years for a proposal to become a standard. I hope I can be patient!

In my spare time, I work on a BACnet Protocol Stack for embedded systems. I figure that since I know a little about decoding the ASN.1 in the standard that I should put it to good public use. I also am committed to promoting BACnet, and think that having a free protocol stack allows anyone to give it a try.

I wrote the initial entry for BACnet on WikiPedia based on some history shared with me by the BACnet elders.