From jwbruce at ece.msstate.edu Wed Sep 2 08:53:45 2009 From: jwbruce at ece.msstate.edu (J. W. Bruce) Date: Wed Sep 2 08:53:57 2009 Subject: [ece4723] Python Challenge In-Reply-To: Message-ID: <8625283.189011251899625547.JavaMail.root@zimbra.ece.msstate.edu> Zach found this website you might find fun in your spare time http://www.pythonchallenge.com/ Enjoy! ------------------ J.W. Bruce, Ph.D., Associate Professor Department of Electrical and Computer Engineering Mississippi State University 406 Hardy Road, Simrall 335 Mississippi State, MS 39762-9571 Office: (662) 325-1530 FAX: (662) 325-2298 ----- Forwarded Message ----- From: "Zach Jordan" To: "J. W. Bruce" Sent: Tuesday, September 1, 2009 7:45:57 PM GMT -06:00 US/Canada Central Subject: Python Challenge Dr. Bruce: I was looking for Python puzzles to get better with the language and I found this - I thought you might get a kick out of it: http://www.pythonchallenge.com/ Zach From jwbruce at ece.msstate.edu Thu Sep 3 14:09:13 2009 From: jwbruce at ece.msstate.edu (J. W. Bruce) Date: Thu Sep 3 14:09:24 2009 Subject: [ece4723] ece4723 repos In-Reply-To: <15863832.207011252004818572.JavaMail.root@zimbra.ece.msstate.edu> Message-ID: <2954117.207081252004953917.JavaMail.root@zimbra.ece.msstate.edu> The SVN repositories have been created at svn.ece.msstate.edu/data/classes/ece4723/svn/phobos and svn.ece.msstate.edu/data/classes/ece4723/svn/deimos Access is gained via the svn+ssh protocol. See if they work for you. jwb ------------------ J.W. Bruce, Ph.D., Associate Professor Department of Electrical and Computer Engineering Mississippi State University 406 Hardy Road, Simrall 335 Mississippi State, MS 39762-9571 Office: (662) 325-1530 FAX: (662) 325-2298 From jwbruce at ece.msstate.edu Wed Sep 9 10:41:41 2009 From: jwbruce at ece.msstate.edu (J. W. Bruce) Date: Wed Sep 9 10:41:43 2009 Subject: [ece4723] lecture notes In-Reply-To: <3c93b5d00909090703q566a8904p6b8fddebb54f810a@mail.gmail.com> Message-ID: <2590078.219571252510901954.JavaMail.root@zimbra.ece.msstate.edu> Michael Lane & Co. have deduced what has been causing my machine so much grief. My box is working better now and I am frantically trying to catch up on my work. You should find the lecture slides on the 4723 webpage. Click on "Notes" in the left-hand menu to hop over there. Let me know if anything else is missing. jwb ------------------ J.W. Bruce, Ph.D., Associate Professor Department of Electrical and Computer Engineering Mississippi State University 406 Hardy Road, Simrall 335 Mississippi State, MS 39762-9571 Office: (662) 325-1530 FAX: (662) 325-2298 ----- Original Message ----- From: "William Cleveland" To: "J. W. Bruce" Sent: Wednesday, September 9, 2009 9:03:10 AM GMT -06:00 US/Canada Central Subject: lecture notes Dr. Bruce, I cannot find the lecture slides online. Am I looking in the wrong places? Thanks, William -- William CLEVELAND 228.596.7419 (mobile) P.O. Box 905 Mississippi State University, MS 39762 USA From jwbruce at ece.msstate.edu Wed Sep 9 10:53:17 2009 From: jwbruce at ece.msstate.edu (J. W. Bruce) Date: Wed Sep 9 10:53:29 2009 Subject: [ece4723] Fwd: The Embedded Muse 180 In-Reply-To: <200909071715.n87HFTFj024460@jade.serverhost.net> Message-ID: <3243064.219741252511597330.JavaMail.root@zimbra.ece.msstate.edu> Jack has a sporadic newsletter about embedded systems that I subscribe to. It always contains at least one little gem. enjoy. ------------------ J.W. Bruce, Ph.D., Associate Professor Department of Electrical and Computer Engineering Mississippi State University 406 Hardy Road, Simrall 335 Mississippi State, MS 39762-9571 Office: (662) 325-1530 FAX: (662) 325-2298 ----- Forwarded Message ----- From: jack@ganssle.com To: tem@freelists.org Sent: Monday, September 7, 2009 12:15:15 PM GMT -06:00 US/Canada Central Subject: The Embedded Muse 180 -------------------------------------------------------------- Embedded Muse 180 Copyright 2009 TGG September 7, 2009 Permanent link to this issue: www.ganssle.com/tem/tem180.pdf -------------------------------------------------------------- You may redistribute this newsletter for noncommercial purposes. For commercial use contact info@ganssle.com. To subscribe or unsubscribe go to http://www.ganssle.com/tem-subunsub.html or drop Jack an email at jack@ganssle.com. EDITOR: Jack Ganssle, jack@ganssle.com CONTENTS: - Editor's Notes - Quotes and Thoughts - Tools and Tips - Book Review - Jobs! - Joke for the Week - About The Embedded Muse ****************************************************** This issue of The Embedded Muse is sponsored by SmartBear Software. Catching bugs before they cause failures => better software. Code review does improve software quality, and you can do it fast and pain-free with Code Collaborator, the world's most powerful online review tool: www.CodeCollaborator.com?EM Say goodbye to the tedious and time-wasting aspects of code reviews, such as meetings, print-outs, and manual metrics collection - try Code Collaborator today! And check out our *free* book on best practices for most effective code review: www.CodeReviewBook.com?EM ****************************************************** Editor's Notes -------------- Are you happy with your bug rates? If not, what are you doing about it? Are you asked to do more with less? Deliver faster, with more features? What action are you taking to achieve those goals? In his book "Quality Is Personal" Harry Roberts shows that "trying harder" won't change anything fundamental. More substantive changes must be made, and in fact it IS possible to accurately schedule a project, meet the deadline, and drastically reduce bugs. Learn how at my Better Firmware Faster class, presented at your facility. See http://www.ganssle.com/classes.htm . I'll be speaking at the Embedded Systems Conferences in Boston (September 21-24) and England (October 7-8). If you're at either of these events, do say "hi!" VDC Research is conducting its annual survey of embedded engineers, and if you are involved in the engineering of embedded systems, they'd be interested in hearing from you. The research covers embedded software, hardware, tools, and development practices. VDC will provide all respondents who complete the survey: * A summary of the 2009 survey findings * A chance to win a $100 Amazon.com gift certificate * Instant access to a summary of VDC's 2008 survey findings To begin the survey, go to: http://www.vdcresearch.com/misc/surveys/09esdt/?RID=G Electronic Design has an interesting article for those seeking jobs: http://electronicdesign.com/Articles/Index.cfm?ArticleID=21178 . And, it seems there are indeed some companies hiring - see the jobs section later in this issue. Quotes and Thoughts ------------------- From Geoff Patch: Well over half of the time you spend working on a project (on the order of 70 percent) is spent thinking, and no tool, no matter how advanced, can think for you. Consequently, even if a tool did everything except the thinking for you -- if it wrote 100 percent of the code, wrote 100 percent of the documentation, did 100 percent of the testing, burned the CD-ROMs, put them in boxes, and mailed them to your customers -- the best you could hope for would be a 30 percent improvement in productivity. In order to do better than that, you have to change the way you think. - Fred Brooks Tools and Tips -------------- Scott Rosenthal cued me in to free schematic capture and PCB layout sites. See www.pad2pad.com and http://www.capilano.com/html/dwwx.html. I've used the latter's DesignWorks package for some years. But the two together lets one get a small PCB design, plus a manufacturing quote, in a jiffy. Board prices are, to this old guy who used to spend thousands on PCBs, really cheap. There's a good summary of the differences between decentralized and centralized version control systems in Queue magazine: http://queue.acm.org/detail.cfm?id=1595636 . Evgeni Stavinov has some free web apps that will generate Verilog or VHDL code to create CRC generators, linear feedback shift registers, and scramblers. See http://outputlogic.com . Dave Kellogg sent: "Hundreds of e-books on line for free. http://www.e-booksdirectory.com/ is the top-level site. http://www.e-booksdirectory.com/programming.php may be of more interest to Muse readers. There is a surprising amount of reasonably current books." He also passed along this link to a site that has quite a few C/C++ coding standards: http://www.sourceformat.com/coding-standard.htm . And Dave also generously sent his comments about a slew of tools: Understand (www.scitools.com) is a powerful IDE plus Static Analyzer. It parses your code (C, C++, Java, Ada, VHDL, and several others) at a syntactic level, and builds a database. It can then show you textual and graphical tree views of calls to, called by, included by, read or write references to variables, dozens of metrics (including McCabes Complexity, comment density, line counts, and coupling), and much more. It has a scriptable API, multiple monitor support, and all the typical functionality of an IDE. It can generate flow charts from your code. It has an architecture feature for grouping a bunch of source files together as a unit, and then doing analysis on that unit. I'm extremely impressed with the support offered by Sci Tools. If you write code, you need to check out this tool. If you maintain code written by others, then you MUST check out this tool. The price ($500) may seem high if this were just an IDE/Editor. But with its huge range of analysis features, it is a fantastic bargain. Very highly recommended. PC-Lint (www.gimpel.com) is the most capable lint available. For $390, you get automatic detection of hundreds of questionable C or C++ constructs, coupled with extremely flexible false positive suppression. It supports dimensional analysis (detects operations on variables with incompatible units) and MISRA compliance checking. The manual is 500+ pages. Strongly recommended. One of my favorite utilities is FileLocator Pro (www.mythicsoft.com, $40). This is WAY more powerful than your fathers GREP. It can even GREP on file names and paths. It knows how to search inside of Word, Excel, PDF, and ZIP files (and many others). It can do searches (with exclusions) that combine date, size, attributes, contents (including RegEx), and file name (including RegEx). Like any good tool, it is scriptable. Highly recommended. It is the best search tool that I have found. Until I got Snagit (www.TechSmith.com, $50) it, I did not realize how handy having a full-featured screen capture and mark-up tool would be. If all you have ever used is Windows Screen Print, you are in for an amazing surprise. Being able to clip and add mark-up to a screen shot is a huge enabler. It is very helpful for interacting with tool venders, when resolving problems. Again, highly recommended. If you do many presentations, ZoomIt is a very handy free utility. Go to http://TechNet.Microsoft.com and search for ZoomIt. ZoomIt will enlarge a section of the screen, and will allow you to draw on the screen using the mouse. Book Review ----------- I gave out a number of free books a while back, and asked recipients for reviews. Carl Douglas reviewed MicroC/OS-II: "MicroC/OS-II is a small Operating System developed by Jean J. Labrosse, inspired out of frustration with proprietary Operating Systems for embedded applications. "The book "MicroC/OS-II" is the complete documentation including source code for the MicroC/OS-II Operating System. It is intended for students and professionals alike and uses a `nuts and bolts' approach which permits skipping over some of the finer details. The design discussions are quite readable and accompanied by diagrams, however I would recommend some experience with the ``C'' programming language before working through the implementation examples. Each subsystem of MicroC/OS-II is documented and implemented, including multi-tasking, memory management, message queues, semaphores and events. "MicroC/OS-II is free for non-commercial use, has been ported to many different processor families and is certified for safety critical applications. "If you ever wondered how an embedded Operating System works, this book is all you need." (Note from Jack: Jean has a new version of the book, and the OS, coming out soon. I have read the new book and am really impressed). Jobs! ----- Let me know if you're hiring firmware or embedded designers. No recruiters please, and I reserve the right to edit ads to fit the format and intents of this newsletter. Please keep it to 100 words. JOB TITLE: Lead Embedded Software Developer RESPONSIBILITIES: * Develop software solutions for gaming platforms * Responsible for results in terms of meeting ship dates and passing code quality tests QUALIFICATIONS: * BS or equivalent, MS in Engineering or CS preferred. 8+ years of relevant handson technical experience, and a record of individual technical achievement * Excellent written and verbal communication skills * Expert ability in C * Experienced in software design on embedded platforms * Experience developing on Generalplus 16-bit SoC platform. * Experience working with multiple teams: art, game design, and test * Experience developing games on systems with resource limitations and low-end processors Send resume to jobs@smithandtinker.com GE Energy Smart Grid Systems Engineering needs to fill more than 100 jobs before December 2009. T&D offers opportunities working on several product lines with offerings from Smart Meters to Transformer Monitoring and Diagnostics and Substation AutomationThe primary location for Smart Grid roles is in Atlanta, GA. Electronics Design Engineer Electronics engineers in T&D are responsible for circuit design and implementation for all new T&D devices. The ever-present challenge to balance product performance with product cost is at a maximum in this arena as these devices are being deployed by the millions into relatively taxing environments. The customer is continuously driving for addition of advanced features while the market competition continues to demand a lower cost. This is an excellent path to test the electronics engineer's skills and the bar will be continuously raised by the advancement of smart grid technology. Firmware Design Engineer Firmware engineers in T&D are currently implementing the features and functions for next generation of smart meters and substation automation equipment. These features are allowing our customers to collect, concentrate, process, analyze and act on a wealth of data. This in turn is enabling the utilities to do a variety of things that were previously not possible. These new capabilities range from condition based maintenance of transformers to grid fault detection, isolation and restoration. Test Engineer Test engineers in T&D are responsible for testing the features and functions of the new Smart Grid suite of products. The technology surrounding the Transmission and Distribution infrastructure is advancing at a rapid pace, and significant testing is needed to ensure the quality of the new products coming out. The impact of this technology on the overall system is still not fully understood, and our customers aren't even aware yet of the information they will now be presented with, or what that data means. It's an exciting time to be experimenting with, and testing out the equipment that will power the "smart grid" of the future. Software Engineer This role will be focused on the integration and communications between these systems as well as between these sub-systems and the smart grid backbone. The backbone will enable and interface from the lowest level sensors and data acquisition across the grid up to the OMS (Outage Management Systems), DMS (Distribution Management Systems) and EMS (Energy Management Systems). Although the primary duty is new product development, some product sustaining and maintenance efforts will be required. Cyber Security Engineer The Cyber Security Technical Lead is an individual skilled in the area of hacker capabilities and intentions, methodologies, methods and motives. Knowledge of hacker methodologies regarding CNE (computer network exploitation) and CNA (computer network attacks) against critical infrastructure systems is required. The Cyber Security Technical Lead should be a proven team player with excellent oral and written communications skills, and a fine attention to detail. He/she should also be a self-starter, capable of working on projects independently, if required. Extremely effective oral and written communications skills are a must, in order to present strategy, and status information to the product management and engineering management teams in both formal and informal review settings. Smart Grid Software Architect The smart grid architect will act as the key point of contact for all technical matters regarding implementation, validation, and deployment of Smart Grid software system solutions. The architect work in collaboration with the assigned program manager to ensure the interoperability and system quality attributes of the proposed system are met. The architect will interface with the Services Engineering and Software Solutions Group technical personnel and GE product line managers to ensure all requirements are met in a timely manner consistent with GE's Smart Grid vision. Candidates must have extensive knowledge and experience in the complete life cycle for large-scale information technology systems and have an extensive software engineering background. Candidate must have applied knowledge and experience in the software techniques and technologies that address the operation of electric utility T&D networks and AMI systems. Candidates are expected to demonstrate outstanding growth traits. Remote Solutions LLC is looking to hire a full time embedded >software developer to work in their office in Tucson AZ. (www.safe-t-rack.com) The successful candidate will have a strong background in embedded development, specifically in Microchip PIC assembler and C with a solid understanding of hardware. Additional experience in one or more of the following would be advantageous: PLCs, hardware design, PCB layout, mechanical integration, or CAD. Send resumes to Denny Esterline Denny.Esterline@Safe-T-Rack.com Digital Design Corporation (Arlington Heights, Illinois) is looking for an embedded C/C++ developer to help with our diverse array of projects and products, which are typically in the domains of video processing, networking, and communications. Experience with Linux driver and embedded application development is desired; experience with other BSP and embedded driver development including board debug is a plus, as well as Windows driver and .NET development experience. Contact dan.mahn@digidescorp.com, 847-359-5418 (main fax), 847-359-3828 (main number) Joke for the Week ----------------- Ben Sweet passed along one that uses four letter words as a metric of code quality: http://www.veracode.com/blog/2008/02/new-unit-of-reviews-code-quality/ . About The Embedded Muse ----------------------- The Embedded Muse is a newsletter sent via email by Jack Ganssle. Send complaints, comments, and contributions to me at jack@ganssle.com. The Embedded Muse is supported by The Ganssle Group, whose mission is to help embedded folks get better products to market faster. We offer seminars at your site offering hard-hitting ideas - and action - you can take now to improve firmware quality and decrease development time. Contact us at info@ganssle.com for more information. From jwbruce at ece.msstate.edu Thu Sep 10 12:43:21 2009 From: jwbruce at ece.msstate.edu (J. W. Bruce) Date: Thu Sep 10 12:43:24 2009 Subject: [ece4723] ECE4723 lab schedule Message-ID: <10900284.223911252604601042.JavaMail.root@zimbra.ece.msstate.edu> I've posted a tentative lab schedule on the 4723 website. Notice that some labs "overlap" and have a couple of weeks duration. You do NOT want to procrastinate. Work on the tasks early to get them done long before they are actually due. jwb ------------------ J.W. Bruce, Ph.D., Associate Professor Department of Electrical and Computer Engineering Mississippi State University 406 Hardy Road, Simrall 335 Mississippi State, MS 39762-9571 Office: (662) 325-1530 FAX: (662) 325-2298 From jwbruce at ece.msstate.edu Sat Sep 12 07:59:28 2009 From: jwbruce at ece.msstate.edu (J. W. Bruce) Date: Sat Sep 12 07:59:42 2009 Subject: [ece4723] Re: Compiling ESOS Projects In-Reply-To: <26369135.229711252760155790.JavaMail.root@zimbra.ece.msstate.edu> Message-ID: <1193871.229731252760368950.JavaMail.root@zimbra.ece.msstate.edu> The mplab project files in the archive assume that the tree you downloaded is located at C:\PIC24. So drag the "pic24_code_examples" folder to C:\ and rename it "PIC24". Then, I opened MPLAB and opened one of the chapter 14 .mcp projects. I hit "build all" and it built to completion. No fuss. (All of this assumes that your MPLAB and C30 compiler are properly installed.) If anyone else has a suggestion for Andrew, please reply all. We'd love to hear it. jwb PS: C compiler errors can be ambiguous or misleading sometimes.... But your errors below look like your compiler doesn't have the macro definition for ESOS_USER_TASK. The best approach is start from a working project file like I described above. ------------------ J.W. Bruce, Ph.D., Associate Professor Department of Electrical and Computer Engineering Mississippi State University 406 Hardy Road, Simrall 335 Mississippi State, MS 39762-9571 Office: (662) 325-1530 FAX: (662) 325-2298 ----- Original Message ----- From: at207@msstate.edu To: "J. W. Bruce" Sent: Friday, September 11, 2009 8:31:09 PM GMT -06:00 US/Canada Central Subject: Compiling ESOS Projects Dr. Bruce, I started off with a blank project, went through all the steps on the wiki to set it up, and copied the code for esos_echo from the book. However, when I go to build the project, the compiler gives me the following errors: esos_echo.c: In function 'user_init': esos_echo.c:11: warning: implicit declaration of function 'CONFIG_LED1' esos_echo.c:12: error: 'heartbeat_LED' undeclared (first use in this function) esos_echo.c:12: error: (Each undeclared identifier is reported only once esos_echo.c:12: error: for each function it appears in.) esos_echo.c:13: error: 'echo' undeclared (first use in this function) Am I missing something here? -Andrew T. at207@msstate.edu From jwbruce at ece.msstate.edu Sat Sep 12 18:56:45 2009 From: jwbruce at ece.msstate.edu (J. W. Bruce) Date: Sat Sep 12 18:56:55 2009 Subject: [ece4723-02] [ece4723] Re: Compiling ESOS Projects In-Reply-To: <2a435e710909121317q25826e86hedc29ff7da1ca09a@mail.gmail.com> Message-ID: <23352485.230201252799805783.JavaMail.root@zimbra.ece.msstate.edu> You can use the "configure" ADC routines from Chap.11 in ESOS, but you cannot use the "convertCH0" routine. Many of the hardware routines from chapts. 1-13 have a watchdog timer/while-loop structure that flashes the chapt.1-13 heartbeat LED. This loop construct is executed whenever any peripheral needs to implement a while-loop to wait for something to complete/time-out/ arrive/etc..... The heartbeat loop in chapts. 1-13 is incompatible with ESOS, so you cannot use any hw routine that is setup this way. You will need to configure your ADC, kick off a conversion, then ESOS_TASK_WAIT until the ADC conversion completes. --jwb PS: Check out the difference between the non-ESOS I2C library routines and the ESOS version. You'll see what I'm talking about. ------------------ J.W. Bruce, Ph.D., Associate Professor Department of Electrical and Computer Engineering Mississippi State University 406 Hardy Road, Simrall 335 Mississippi State, MS 39762-9571 Office: (662) 325-1530 FAX: (662) 325-2298 ----- Original Message ----- From: "Ryan Wood" To: "J. W. Bruce" Cc: at207@msstate.edu, "Vinod Rajan" , "ece4723" Sent: Saturday, September 12, 2009 3:17:44 PM GMT -06:00 US/Canada Central Subject: Re: [ece4723-02] [ece4723] Re: Compiling ESOS Projects I was able to get the project app_echo1 from Ch14 to build, but I don't understand how to configure an analog input within ESOS. I tried following the adc_test code from Ch11, but the source pic files it requires seem like they're conflicting with ESOS source files. Any idea on how this works? Ryan Wood On Sat, Sep 12, 2009 at 7:59 AM, J. W. Bruce < jwbruce@ece.msstate.edu > wrote: The mplab project files in the archive assume that the tree you downloaded is located at C:\PIC24. So drag the "pic24_code_examples" folder to C:\ and rename it "PIC24". Then, I opened MPLAB and opened one of the chapter 14 .mcp projects. I hit "build all" and it built to completion. No fuss. (All of this assumes that your MPLAB and C30 compiler are properly installed.) If anyone else has a suggestion for Andrew, please reply all. We'd love to hear it. jwb PS: C compiler errors can be ambiguous or misleading sometimes.... But your errors below look like your compiler doesn't have the macro definition for ESOS_USER_TASK. The best approach is start from a working project file like I described above. ------------------ J.W. Bruce, Ph.D., Associate Professor Department of Electrical and Computer Engineering Mississippi State University 406 Hardy Road, Simrall 335 Mississippi State, MS 39762-9571 Office: (662) 325-1530 FAX: (662) 325-2298 ----- Original Message ----- From: at207@msstate.edu To: "J. W. Bruce" < jwbruce@ece.msstate.edu > Sent: Friday, September 11, 2009 8:31:09 PM GMT -06:00 US/Canada Central Subject: Compiling ESOS Projects Dr. Bruce, I started off with a blank project, went through all the steps on the wiki to set it up, and copied the code for esos_echo from the book. However, when I go to build the project, the compiler gives me the following errors: esos_echo.c: In function 'user_init': esos_echo.c:11: warning: implicit declaration of function 'CONFIG_LED1' esos_echo.c:12: error: 'heartbeat_LED' undeclared (first use in this function) esos_echo.c:12: error: (Each undeclared identifier is reported only once esos_echo.c:12: error: for each function it appears in.) esos_echo.c:13: error: 'echo' undeclared (first use in this function) Am I missing something here? -Andrew T. at207@msstate.edu _______________________________________________ ece4723 mailing list ece4723@ece.msstate.edu http://www.ece.msstate.edu/mailman/listinfo/ece4723 _______________________________________________ ece4723-02 mailing list ece4723-02@ece.msstate.edu http://www.ece.msstate.edu/mailman/listinfo/ece4723-02 From at207 at msstate.edu Sat Sep 12 14:09:20 2009 From: at207 at msstate.edu (Andrew Turner) Date: Mon Sep 14 08:18:18 2009 Subject: [ece4723-02] [ece4723] Re: Compiling ESOS Projects In-Reply-To: <77c5af720909121128q1733f877l281a16452f0b4ed5@mail.gmail.com> References: <26369135.229711252760155790.JavaMail.root@zimbra.ece.msstate.edu> <1193871.229731252760368950.JavaMail.root@zimbra.ece.msstate.edu> <77c5af720909121128q1733f877l281a16452f0b4ed5@mail.gmail.com> Message-ID: <4AABF1E0.3040708@msstate.edu> Jacob Edwards wrote: > I am also having some of the same issues with compiling a blank > project with instructions from the wiki. I renamed my > pic_24_code_examples folder to "PIC24" on the C:\ drive.I made sure to > "include search path" on all the correct folders. I agree that it > seems like the compiler doesn't have the macro definition for > ESOS_USER_TASK. Because my user task is called > ESOS_USER_TASK(heartbeat_LED). I am using the most recent version of > MPlab and the C compiler. These are my errors I am getting. > > ledflash.c: In function 'user_init': > ledflash.c:12: error: 'heartbeat_LED' undeclared (first use in this > function) > ledflash.c:12: error: (Each undeclared identifier is reported only once > ledflash.c:12: error: for each function it appears in.) > > I also am unable to build a working project out of the chapter 14 > folder. I tried opening the "app_echo1" project and hit build all. The > errors are strange and seem to be coming from underlying code, but I > could be wrong. Here are my errors. > > ..\common\pic24_configbits.c:259: error: 'BKBUG_ON' undeclared here > (not in a function) > ..\common\pic24_configbits.c:259: error: 'COE_ON' undeclared here (not > in a function) > > Any suggestions or help would be appreciated. Thanks guys > Jacob Edwards > > On Sat, Sep 12, 2009 at 7:59 AM, J. W. Bruce > wrote: > > > The mplab project files in the archive assume that the > tree you downloaded is located at C:\PIC24. So drag > the "pic24_code_examples" folder to C:\ and rename > it "PIC24". Then, I opened MPLAB and opened one of > the chapter 14 .mcp projects. I hit "build all" > and it built to completion. No fuss. > > (All of this assumes that your MPLAB and C30 compiler > are properly installed.) > > If anyone else has a suggestion for Andrew, please > reply all. We'd love to hear it. > > jwb > > PS: C compiler errors can be ambiguous or misleading > sometimes.... But your errors below look like your > compiler doesn't have the macro definition for > ESOS_USER_TASK. The best approach is start from a > working project file like I described above. > > ------------------ > J.W. Bruce, Ph.D., Associate Professor > Department of Electrical and Computer Engineering > Mississippi State University > 406 Hardy Road, Simrall 335 > Mississippi State, MS 39762-9571 > Office: (662) 325-1530 FAX: (662) 325-2298 > > ----- Original Message ----- > From: at207@msstate.edu > To: "J. W. Bruce" > > Sent: Friday, September 11, 2009 8:31:09 PM GMT -06:00 US/Canada > Central > Subject: Compiling ESOS Projects > > > > Dr. Bruce, > > I started off with a blank project, went through all the steps on > the wiki to > set it up, and copied the code for esos_echo from the book. > However, when I go > to build the project, the compiler gives me the following errors: > > esos_echo.c: In function 'user_init': > esos_echo.c:11: warning: implicit declaration of function > 'CONFIG_LED1' > esos_echo.c:12: error: 'heartbeat_LED' undeclared (first use in > this function) > esos_echo.c:12: error: (Each undeclared identifier is reported > only once > esos_echo.c:12: error: for each function it appears in.) > esos_echo.c:13: error: 'echo' undeclared (first use in this function) > > Am I missing something here? > > -Andrew T. > at207@msstate.edu > _______________________________________________ > ece4723 mailing list > ece4723@ece.msstate.edu > http://www.ece.msstate.edu/mailman/listinfo/ece4723 > ____________________________________ > I was able to build a couple of projects from the ch. 14 folder and get them programed onto my chip. The only thing I had to change in the project was to add the linker script described in the wiki. I think I remembered getting the same errors, and that was the solution. For the blank project, I copied the settings from one of the projects I was able to build, but the errors were as far as I got. -Andrew T. at207@msstate.edu From at207 at msstate.edu Sat Sep 12 14:34:59 2009 From: at207 at msstate.edu (at207@msstate.edu) Date: Mon Sep 14 08:18:19 2009 Subject: [ece4723-02] [ece4723] Re: Compiling ESOS Projects In-Reply-To: <77c5af720909121128q1733f877l281a16452f0b4ed5@mail.gmail.com> References: <26369135.229711252760155790.JavaMail.root@zimbra.ece.msstate.edu> <1193871.229731252760368950.JavaMail.root@zimbra.ece.msstate.edu> <77c5af720909121128q1733f877l281a16452f0b4ed5@mail.gmail.com> Message-ID: <1252784099.4aabf7e36344e@webmail.msstate.edu> Quoting Jacob Edwards : > I am also having some of the same issues with compiling a blank project with > instructions from the wiki. I renamed my pic_24_code_examples folder to > "PIC24" on the C:\ drive.I made sure to "include search path" on all the > correct folders. I agree that it seems like the compiler doesn't have the > macro definition for ESOS_USER_TASK. Because my user task is called > ESOS_USER_TASK(heartbeat_LED). I am using the most recent version of MPlab > and the C compiler. These are my errors I am getting. > > ledflash.c: In function 'user_init': > ledflash.c:12: error: 'heartbeat_LED' undeclared (first use in this > function) > ledflash.c:12: error: (Each undeclared identifier is reported only once > ledflash.c:12: error: for each function it appears in.) > > I also am unable to build a working project out of the chapter 14 folder. I > tried opening the "app_echo1" project and hit build all. The errors are > strange and seem to be coming from underlying code, but I could be wrong. > Here are my errors. > > ..\common\pic24_configbits.c:259: error: 'BKBUG_ON' undeclared here (not in > a function) > ..\common\pic24_configbits.c:259: error: 'COE_ON' undeclared here (not in a > function) > > Any suggestions or help would be appreciated. Thanks guys > Jacob Edwards > > On Sat, Sep 12, 2009 at 7:59 AM, J. W. Bruce wrote: > > > > > The mplab project files in the archive assume that the > > tree you downloaded is located at C:\PIC24. So drag > > the "pic24_code_examples" folder to C:\ and rename > > it "PIC24". Then, I opened MPLAB and opened one of > > the chapter 14 .mcp projects. I hit "build all" > > and it built to completion. No fuss. > > > > (All of this assumes that your MPLAB and C30 compiler > > are properly installed.) > > > > If anyone else has a suggestion for Andrew, please > > reply all. We'd love to hear it. > > > > jwb > > > > PS: C compiler errors can be ambiguous or misleading > > sometimes.... But your errors below look like your > > compiler doesn't have the macro definition for > > ESOS_USER_TASK. The best approach is start from a > > working project file like I described above. > > > > ------------------ > > J.W. Bruce, Ph.D., Associate Professor > > Department of Electrical and Computer Engineering > > Mississippi State University > > 406 Hardy Road, Simrall 335 > > Mississippi State, MS 39762-9571 > > Office: (662) 325-1530 FAX: (662) 325-2298 > > > > ----- Original Message ----- > > From: at207@msstate.edu > > To: "J. W. Bruce" > > Sent: Friday, September 11, 2009 8:31:09 PM GMT -06:00 US/Canada Central > > Subject: Compiling ESOS Projects > > > > > > > > Dr. Bruce, > > > > I started off with a blank project, went through all the steps on the wiki > > to > > set it up, and copied the code for esos_echo from the book. However, when I > > go > > to build the project, the compiler gives me the following errors: > > > > esos_echo.c: In function 'user_init': > > esos_echo.c:11: warning: implicit declaration of function 'CONFIG_LED1' > > esos_echo.c:12: error: 'heartbeat_LED' undeclared (first use in this > > function) > > esos_echo.c:12: error: (Each undeclared identifier is reported only once > > esos_echo.c:12: error: for each function it appears in.) > > esos_echo.c:13: error: 'echo' undeclared (first use in this function) > > > > Am I missing something here? > > > > -Andrew T. > > at207@msstate.edu > > _______________________________________________ > > ece4723 mailing list > > ece4723@ece.msstate.edu > > http://www.ece.msstate.edu/mailman/listinfo/ece4723 > > _______________________________________________ > > ece4723-02 mailing list > > ece4723-02@ece.msstate.edu > > http://www.ece.msstate.edu/mailman/listinfo/ece4723-02 > > > I think I've gotten the task definitions figured out. I don't know if this will always work, but if you move the task definitions BEFORE the user_init(), it will stop complaining. However, now I have another error: esos_pic24_tick.o(.text+0x50): In function `configClock': C:\PIC24\esos\src\pic24\esos_pic24_tick.c:413: undefined reference to `configClockFRCPLL_FCY40MHz' -Andrew T. at207@msstate.edu From jwbruce at ece.msstate.edu Wed Sep 23 10:40:40 2009 From: jwbruce at ece.msstate.edu (J. W. Bruce) Date: Wed Sep 23 10:40:50 2009 Subject: [ece4723] Fwd: The Embedded Muse 181 In-Reply-To: <200909231405.n8NE5IwK023477@jade.serverhost.net> Message-ID: <19154475.260441253720440019.JavaMail.root@zimbra.ece.msstate.edu> The latest newsletter from Jack..... Enjoy! ------------------ J.W. Bruce, Ph.D., Associate Professor Department of Electrical and Computer Engineering Mississippi State University 406 Hardy Road, Simrall 335 Mississippi State, MS 39762-9571 Office: (662) 325-1530 FAX: (662) 325-2298 ----- Forwarded Message ----- From: jack@ganssle.com To: tem@freelists.org Sent: Wednesday, September 23, 2009 9:04:52 AM GMT -06:00 US/Canada Central Subject: The Embedded Muse 181 -------------------------------------------------------------- Embedded Muse 181 Copyright 2009 TGG September 23, 2009 Permanent link to this issue: www.ganssle.com/tem/tem181.pdf -------------------------------------------------------------- You may redistribute this newsletter for noncommercial purposes. For commercial use contact info@ganssle.com. To subscribe or unsubscribe go to http://www.ganssle.com/tem-subunsub.html or drop Jack an email at jack@ganssle.com. EDITOR: Jack Ganssle, jack@ganssle.com CONTENTS: - Editor's Notes - Quotes and Thoughts - Tools and Tips - Book Review - Jobs! - Joke for the Week - About The Embedded Muse Editor's Notes -------------- Are you happy with your bug rates? If not, what are you doing about it? Are you asked to do more with less? Deliver faster, with more features? What action are you taking to achieve those goals? In his book "Quality Is Personal" Harry Roberts shows that "trying harder" won't change anything fundamental. More substantive changes must be made, and in fact it IS possible to accurately schedule a project, meet the deadline, and drastically reduce bugs. Learn how at my Better Firmware Faster class, presented at your facility. See http://www.ganssle.com/classes.htm . I'll be speaking at the Embedded Systems Conferences in England (October 7-8). See http://esc-uk.techinsightsevents.com/index.php . Many of you have contributed many great comments about tools you like. Thanks and keep `em coming! I have posted them, pretty much at random, on my website. But we recently reorganized that part of the site to make it easier to find information about tools - see http://www.ganssle.com/tools.htm . For many years I've avoided the social networking sites. I had filters in place to ditch email from LinkedIn and all of the other similar web networks. But a lively debate here recently made me rethink that logic. So I've removed the filters, set up a Facebook page (whatever that is), and more. Feel free to start socializing! Quotes and Thoughts ------------------- Paraphrasing George Santayana's "Those who cannot remember the past are condemned to repeat it": Failing to acknowledge and record past success condemns an organization to not to repeat them. (Barry Boehm) Book Review ----------- Your system has to read a keyboard and update the display. That's pretty easy to handle in a simple loop. Oh, wait, then there's the A/D converter which needs service once a millisecond. The data is noisy so ten samples must be averaged and the result fed into a computation which is sent to the display. But you can't do the math till the results of the encoder become available, and that can only be read on 20 msec intervals. But don't forget to monitor the radiation source; if it goes out of limits a safety protocol has to be invoked to avoid harming users. That has to be monitored every 250 milliseconds. How would one write this code? Sure, it's possible to write an interrupt handler that takes clock ticks and then, via a number of tortured loops, sequences off the proper activities. It'll be tough to debug and harder to maintain. You can be sure the boss will come in, red-faced, wondering why the heck the system only looks at safety parameters every quarter second when any idiot knows the rate should be 0.230 sec, no matter how he wrote the spec. The loops grow more complex and the program ever more convoluted. This is a very old problem, one solved by the use of a Real-Time Operating System (RTOS). Write each activity as a separate task. The code is simple, crystal clear, and easy to change. An old problem, yes. But there's surprisingly little written about the use of an RTOS. Jean Labrosse wrote one of the first and best books on the subject: uC/OS. I'm told it, and the subsequent second edition, are the best selling books ever published about embedded systems, and I'm not surprised. Extremely-well written, they covered the subject in depth and with finesse. He wrote using the uC/OS and uC/OS-II RTOSes as examples. Now Jean and the crew at Micrium have a new and hugely improved version of that RTOS: uC/OS-III. Where uC/OS-II is a commercial quality product, one that even meets the highest safety-critical requirements, uC/OS-III takes that quality and reliability levels to even the most demanding applications. Jean has supplemented the new RTOS with a new book, uC/OS-III, The Real Time Kernel. It's much weightier than his previous RTOS books as this volume goes deeply in depth into the nuances of using an operating system in real applications. uC/OS-III lays out the rational behind an RTOS, and then in a very logical fashion presents each of the resources provided by an RTOS and how one goes about using those features in a product. Though uC/OS-III is used as an example, it is not presented as the canonical RTOS, and users of any real-time operating system will find this material immensely useable. I have long counted Jean a friend, and have great respect for his perfectionism. That is clear when reading the uC/OS source code, which is probably the most beautiful code I have read, and, since it has been used in products certified to DO-178B level A, also works! That perfectionism also manifests itself in this book, in which it's clear he has taken pains to get every fact right, every drawing clear, all while maintaining a very consistent style. This is a book by an engineer, for engineers (including engineering students). Devoid of fluff, it's packed with information about using an RTOS in a real system. today. What do I need to do to get started? What are all those files? Where is the information I need located? Are you using an RTOS? If so, read this book. If you're not using one, read this book; not every embedded system needs an operating system, but there are too many that have been cobbled together through the painful use of ad hoc loops that an RTOS would vastly improve. Tools and Tips -------------- Tim Peterson wrote: "I enjoy the embedded muse greatly. I just wanted to pass along information about a potentially useful podcast. Though it's not embedded or even engineering specific, I felt that the information would be valuable to many. The podcasts Manager Tools and Career Tools can be found at: http://www.manager-tools.com/ ." Clyde Shappee contributed: "Another very capable schematic tool and PCB package, all in one is Kicad: http://kicad.sourceforge.net/wiki/index.php/About_KiCad "It is a nicely integrated tool that keeps getting better! "I have a colleague who uses it now exclusively (start-up == no money) and has done 5 designs with it with very few complaints or "Gotchya"s." Naming Conventions ------------------ In "Some Studies of Word Abbreviation Behavior" (M.H. Hodge and F.M. Pennington, Journal of Experimental Psychology) researchers had subjects abbreviate words. Other subjects tried to reconstruct the original words. The average success rate was an appalling 67%. What does "Disp" mean? Is it the noun meaning the display hardware, or is it the verb "to display?" How about "Calc?" That could be percent calcium, calculate or calculus. With two exceptions never abbreviate a name. Likewise, with the same caveats, never use an acronym. Your jargon may be unknown to some other maintainer, or may have some other meaning. Clarity is our goal! One exception is the use of industry-standard acronyms and abbreviations like LED, LCD, CRT, UART, etc that pose no confusion. Another is that it's fine to use any abbreviation or acronym documented in a dictionary stored in a common header file. For example: /* Abbreviation Table * Dsply == Display (the verb) * Disp == Display (our LCD display) * Tot == Total * Calc == Calculation * Val == Value * MPS == Meters per second * Pos == Position */ I remember with some wonder when my college physics professor taught us to cheat on exams. If you know the answer's units it's often possible to solve a problem correctly just by properly arranging and canceling those units. Given a result that must be in miles per hour, if the only inputs are 10 miles and 2 hours, without even knowing the question it's a good bet the answer is 5 MPH. Conversely, ignoring units is a sure road to disaster. Is Descent_Rate meters per second? CM/sec? Furlongs per fortnight? Sure, the programmer who initially computed the result probably knows, but it's foolish to assume everyone is on the same page. Postfix all physical parameters with the units. Descent_Rate_MPS (note in the dictionary above I defined MPS). Timer_Ticks. ADC_Read_Volts(). Jobs! ----- Let me know if you're hiring firmware or embedded designers. No recruiters please, and I reserve the right to edit ads to fit the format and intents of this newsletter. Please keep it to 100 words. Synapse Wireless, Inc., based in Huntsville Alabama, is currently trying to fill multiple Senior Software Engineer slots. Candidates must be proficient in embedded C development on microprocessors and microcontrollers. Experience in Python Is a plus. Hardware design and troubleshooting skills are a plus. A BS degree or higher is a plus, but not a requirement We are looking for developers who can program on the bare metal of todays highly integrated (but resource constrained) devices. To see who we are and what we do, refer to the article in the September issue of Circuit Cellar, check out our website at www.synapse-wireless.com, or even better go to forums.synapse-wireless.com and download a trial version of the product you would be working on. If interested, please email a current resume to kevin.banks@synapse-wireless.com CCV (www.ccv.eu) is one of the leading providers of secure electronic payment solutions. For our office near Munich, Germany, we are searching: Software Architect C++ Senior C++ Software Developer As one of two architects you are responsible for the design of our next-generation frame work that will be used company-wide as base for new application developments on different platforms from embedded Linux to Windows Server. For this challenging task you bring sound C++ knowledge and experience in designing distributed applications or middleware. You have fun implementing parts of your design by yourself and guiding other developers transforming the design in high-quality source code. You are used to creating meaningful documents like specifications, requirements or design descriptions, preferably in English language. Experience with UML is a plus. In addition, we are looking for a Senior C++ Software Developer, who will assist the architects during the design phase and then become one of the leading developers of the new frame work. Experience in implementing platform-independent modules, multi-threading or distributed applications is a plus. Contact: personal@de.ccv.eu Joke for the Week ----------------- PAUL REVERE VIRUS: This revolutionary virus does not horse around. It warns you of impending hard disk attack: Once, if by LAN; twice if by C: POLITICALLY CORRECT VIRUS: Never identifies itself as a "virus," but instead refers to itself as an "electronic micro-organism". ARNOLD SCHWARZENEGGAR VIRUS: Terminates and stays resident. It'll be back. FEDERAL BUREAUCRAT VIRUS: Divides your hard disk into hundreds of little units, each of which does practically nothing, but all of which claim to be the most important part of your computer. TEXAS VIRUS: Makes sure that it's bigger than any other file. ADAM AND EVE VIRUS: Takes a couple bytes out of your Apple. AIRLINE LUGGAGE VIRUS: You're in Dallas, but your data is in Singapore. FREUDIAN VIRUS: Your computer becomes obsessed with marrying its own motherboard. STAR TREK VIRUS: Invades your system in places where no virus has gone before. HEALTH CARE VIRUS: Tests your system for a day, finds nothing wrong, and sends you a bill for $4,500. About The Embedded Muse ----------------------- The Embedded Muse is a newsletter sent via email by Jack Ganssle. Send complaints, comments, and contributions to me at jack@ganssle.com. The Embedded Muse is supported by The Ganssle Group, whose mission is to help embedded folks get better products to market faster. We offer seminars at your site offering hard-hitting ideas - and action - you can take now to improve firmware quality and decrease development time. Contact us at info@ganssle.com for more information.