Editor Review
Ease of Set-Up:
Documentation Completeness and Clarity:
Hardware Completeness and Quality:
Sample Projects/Tutorials:
Meets Expectations:
Overall rating:
Time to Complete
About 10 (ten) hours, which included time to download new software and about eight hours of trying to run my own code based on the demo programs.
Prerequisite Skills
Experience programming in C, experience using interrupt service routines, and knowledge of how CAN communications work. Understanding of the CAN hardware in the Renesas MCUs also will help.
What We Liked
Good hardware that ran demos right away. Good QuickStart Guide and Manual Navigator. The E8 debugging/programming module simplifies development work. Free HEW tools and updates. The SYSTEC CAN-bus monitor module adds to the kit's value.
What we Didn't Like
The original demo code was difficult to understand and provided an overly complicated framework for someone who needs to start a CAN-based project. Documentation for the API left gaps not covered in other documents. The kit lacked tutorials on writing code for or using the CAN port. No simple example programs for users to build on.
Full Review
In this kit, buyers receive two development boards that communicate back and forth over a 2-wire Controller Area Network (CAN), a protocol common in automotive and industrial- electronic equipment. Unlike an RS-232 (EIA-232) serial bus, CAN-bus communications have a distinct protocol that includes message priority, collision detection, error detection, and other functions that make it appealing to designers.
The kit includes two RSK-R8C23 boards, each with an R5F21237JFP microcontroller (MCU), an 8-character 2-line LCD, a CAN port, a JTAG programming/debugging port plus LEDs, pushbuttons, and a potentiometer that drives an analog-to-digital converter (ADC) on the MCU. A power supply module (included) powers the two boards and has connectors that can power three additional RSK-R8C23 boards you can buy and add to the 2-board network.
On the programming side, the kit comes with an E8 USB pod that connects to an RSK-R8C23 board's JTAG connector. The pod will program the MCU's flash memory and provide debug information during development work. To work with a board, you simply move the pod's cable to that board, as needed.
The RCDK8C package also includes a CAN-bus "sniffer" module from SYSTEC Electronics. You can use this module, which also connects to a host PC through a USB port, to monitor bus traffic or to transmit information on the bus. The SYSTEC CD-ROM includes a user manual and documentation for the module's API, should you need to write diagnostic routines for lab or production tests. I used this module to confirm transmission of information on the bus.
To help developers get off to a quick start, Renesas provides a CAN Development Kit CD-ROM that includes the High-performance Embedded Work shop (HEW) integrated development environment (IDE) as well as code and documents. A Manual Navigator program helps users find code, data sheets, and application notes included on the CD. An accompanying sheet lists the CD's and the kit's contents--helpful information that saves setup time.
A QuickStart Guide explains how to connect the equipment and how to run two demonstration programs, "Streaming A-D," and "PlayCatch." The two demos run as soon as you connect the two boards with a CAN cable (supplied) and apply power. The pushbuttons let you toggle between the demos that demonstrate the transfer of information between the modules.
The Guide also explains how to set up the HEW software and the USB drivers for the E8 USB pod. The CD I received came with HEW version 4.04. After you install the HEW software, use the Auto-Update function, as described in the Guide, to check for newer software. I decided to download the newer HEW 4.06, run the update program and update all of the code. This process took about two hours. Downloads went quickly, but I had to click on OK, Yes, or Finish many times for all 12 updates, which took a lot of time. Still, the upgrade was worth the effort.
Before going farther, I printed the "CAN Development Kit User's Manual" (Rev. 2.02) and the manual, "Application Programming Interface for the M16C CAN MCUs," (Rev 2.00) to get basic information on the hardware and software. The former manual has a lot of good information about the development board, board layout, connectors and signals, the I/O pins used by the LEDs and pushbuttons, memory use, and so on. The manual does not include schematic diagrams, but lists a Web link you can follow to download them.
The API manual gives developers information on the C function calls they can use to initialize CAN functions, check for errors, and transmit or receive information. It's a helpful reference and it includes a code example that shows how you can use the API functions. But the example includes a warning, "Some code is missing, such as chip initialization, interrupt setup, etc., because that is not the scope of this document." That sentence raised a warning flag.
After printing the manuals and running the demo programs I wanted to adapt the demo code to a simple task--transfer a few bytes back and forth between the two boards. That shouldn't prove too difficult, but in fact it did. The demo program is a mess, with bits and pieces of the code stuck here and there, and with routines that read data from the ADC, average data, check and debounce pushbuttons, flash LEDs in various patterns, and check for any bus errors.
When you open the demo code in the HEW, you see many include and header files as well as an interrupt-service-routine file. So users have to make sense of a lot of bits and pieces strung together in odd ways when they simply want to run a basic program that exercise each MCU's CAN port. In some cases, code appears in odd places. The ADC routines (AD.C), for example, include code to transmit information on the CAN bus.
I spent about eight hours stumbling through the code trying to determine the various operations and how to use the code as a framework for my own simple program. I printed and marked up many pages of C code and finally managed to send two bytes from one board to the other. A lot of time spent to do something so basic.
No kit user should fall into the same rut, so I contacted the CAN experts at Renesas and asked them if they had a simple byte-transfer program that didn't involve flashing LEDs, reading an ADC, and so on. They quickly responded and created a simpler program that I compiled and ran on both boards, each of which displayed a string of characters sent by the other. Renesas should have the new program--actually a project--called RSK_R8C23_Simple_TxRx on its Web site. If you cannot find it, send me an email and I'll ensure you receive it or can locate it. (You need HEW 4.06 to use this code--a good reason to download the latest HEW code and updates.)
The new program still includes pushbutton routines because you need a way to start a transmission. But you can understand the SWITCHES.C code and relate it to the CANDKIT.C main routine. The project also includes interrupts, LCD drivers, and CAN-port set-up code, but each resides in a separate dot-C file, which helps you dive into the code only as deeply as you need to.
It me took about 10 minutes to modify this basic code to have one board act as a "slave" and increment the 8-byte value sent by the other board, which will act as the "master." Both boards display the current hexadecimal value. Of course I had the eight hours of experience with the earlier CAN code.
I'd still like Renesas to supply more details about how to set up and operate a CAN port, include a flow chart, and create solid documentation for the bits and pieces. Even just identifying what happens in each section of the code would help developers quickly get a grasp of how to set up and use the CAN ports. Dev-kit users deserve this type of tutorial information. (Renesas isn't alone here. Many kits lack basic tutorial material, understandable and useful sample code, flowcharts, and so on.)
A few hints that might help you with this kit:
1. The power cable includes three additional male power connectors. These bare connectors can easily flop around on a lab bench and inadvertently short to ground or burn out a component. Put heat-shrink tubing on these unused power connections.
2. If you're about to start a CAN project and plan to use a Renesas MCUs, obtain the hardware and software manuals and study the CAN information. The CAN port is quite complicated, although the C API isolates you from some details. You should understand how to set up flags, interrupts, and bit rates, though.
3. An oscilloscope with mixed-signal capabilities can help during debugging. Although the SYSTEC CAN monitor works well, you might need to relate analog and digital signals to CAN-bus communications. Suppose you want to measure a sensor's output and send it via a CAN bus to another device. A mixed-signal scope lets you see the sensor output and the related bus activity. Scope manufacturers now offer serial-bus monitor-and-decode capabilities in their products and you can find mixed-signal inputs on CAN-bus monitors and small logic-analyzers, too.
4. I gave the Renesas kit low ratings for documentation, completeness and clarity because the kit did not provide complete documentation for the APIs and did not explain how to use them with the MCU-setup and interrupt-service routines. (Where would a user find those?) I hope Renesas can include this type of information in future kits and on its Web site.
And the kit received low marks for sample projects and tutorials because the code for the demo project was almost incomprehensible and the kit included no sample projects or tutorials. Adding them to future kits or making this information available on the Renesas Web site would help.
5. Check the RenesasRulz Web site at www.renesasrulz.com for information, comments, discussions, and sample codes. When I checked in mid August 2009, the site lacked information about CAN applications and sample CAN code, but you might find other useful information on the site.
Samples & Tutorials
Users will find the demo code difficult to understand. Renesas should have a simpler demo program available for the kit either on the Renesas.com or the RenesasRulz.com Web site. Otherwise, the kit lacked any tutorials or projects for users.