Lab #4 Reading and Writing to Super Stepper Memory

Introduction:

After this lab, the user will have gathered basic knowledge on how to read and write the internal RAM and EEPROM memory locations found on all Super Stepper control modules. Knowing how to modify such resources allows the user to configure the module to their own particular needs.

Objectives:

Why is there memory in the Super Stepper Controller?

The Super Stepper control modules contain a series of memory resources intended for flexibility. Per example, it is at this time known that there can be up to 32 devices connected to the same serial port since every module contains a different address which identifies it from the other 31. This address parameter is stored in EEPROM memory. After reset, the address stored in EEPROM is transferred to its pertinent register in the controller operating system.

Other important Super Stepper parameters are baud rate. Again, this parameter is stored in EEPROM and after reset transferred into a pertinent register in the OS.

Application specific parameters are those which are required by the application to properly function. Per example, the SS-ST68 contains a few memory bytes utilized for programming initial speed, acceleration rate, acceleration time base, etc. These parametes should be studied on the particular application controller data sheet.

Not all memory in the controller is used for specific functions. Most of the space is left for the user as a general purpose scratch pad. Most users will find this resource useful for application personalization and limited data storage.

In this tutorial we will learn how to access the memory in the controller both by reading and writting it.

Reading the EEPROM and RAM Memory

All Super Stepper Controllers contain 128 bytes of EEPROM and 64 bytes of RAM. There is a SS Command to read these memory locations. The same commands knows how to differentiate RAM from EEPROM by means of one of the command parameters. We need to know this as in the Windows application, one of the parameters must be specified in order to select RAM from EEPROM. Future releases will make this totally transparent for the user.

The previous steps are identical for when reading from RAM memory. Just select the “Read RAM” from the pull down menu on the “Stepper Instructions (for Advanced Users)” frame and choose the address to read.

Notice the second text box label reads “RD RAMB” for Read RAM Byte. This text box contains a “0” while when we where reading EEPROM it contained a 1. That is how the controller differentiates an EEPROM read from a RAM read.

Writing the EEPROM and RAM Memory

Writting to RAM or EEPROM is a different matter, because now we must specify not only the address but the data to be written as well. The instruction follows:

Writting to RAM consist of the same set of steps but choosing “Read RAM” from the pull down list. Again notice that the WR RAMB text box contains a 0 instead that a 1 for the WR EEPROM text box. This parameter is used to specify RAM or EEPROM access and the Windows application takes care of this detail making it transparent to the user.

 

Reading Multiple EEPROM and RAM Bytes

The Super Stepper Test Application contains a tool to read memory in a faster way. Basically the entire RAM and EEPROM bank can be read with a single stroke. The application reads all bytes one by one using the same commands we just learned how to use. Then, the five byte data stream returned is parsed to obtain the read byte. All bytes read are displayed on a single text box making it easy to sample the entire memory contents.

That’s all you need. It would be nice to have a tool to write all bytes at the same time, but that is just a feature we will be developing in the future.

Congratulations!!! You have successfully completed the fourth lab on the Super Stepper Architecture. You are now capable of reading and writing data from and to the memory inside the super stepper controller module.

Hungry for more? Next topic is EEPROM Programming!

Last Updated on Jan 10, 2008

Other Avayanic Web Sites