The C500 microcontroller family usually provides only one on-chip synchronous serialchannel (SSC). If a second SSC is required, an emulation of the missing interface mayhelp to avoid an external hardware solution with additional electronic components.The solution presented in this paper and in the attached source files emulates the mostimportant SSC functions by using optimized SW routines with a performance up to 25KBaud in Slave Mode with half duplex transmission and an overhead less than 60% atSAB C513 with 12 MHz. Due to the implementation in C this performance is not the limitof the chip. A pure implementation in Assembler will result in a strong reduction of theCPU load and therefore increase the maximum speed of the interface. In addition,microcontrollers like the SAB C505 will speed up the interface by a factor of two becauseof an optimized architecture compared with the SAB C513.Moreover, this solution lays stress on using as few on-chip hardware resources aspossible. A more excessive consumption of those resources will result in a highermaximum speed of the emulated interface.Due to the restricted performance of an 8 bit microcontroller a pin compatible solution isprovided only; the internal register based programming interface is replaced by a set ofsubroutine calls.The attached source files also contain a test shell, which demonstrates how to exchangeinformation between an on-chip HW-SSC and the emulated SW-SSC via 5 external wiresin different operation modes. It is based on the SAB C513 (Siemens 8 bit microcontroller).A table with load measurements is presented to give an indication for the fraction of CPUperformance required by software for emulating the SSC.
8051 Absolute Encoder Positioner How to connect and drive absolute position encoder with SSI serial interface. The encoder has been made by Siemens (6FX2001-5FS12). Archive contains: 1) schematic, 2) source in C and Assembler
Many many developers all over the net respect NASM for what i s
- a widespread (thus netwide), portable (thus netwide!), very
flexible and mature Assembler tool with support for many output
formats (thus netwide!!).
Now we have good news for you: NASM is licensed under LGPL.
This means its development is open to even wider society of
programmers wishing to improve their lovely Assembler.
The NASM project is now situated at SourceForge.net, the most
famous Open Source development center on The Net.
Visit our development page at http://nasm.2y.net/ and our
SF project at http://sf.net/projects/nasm/
CBC下寫的串口編程,API函數(shù)實例
I wish this site had been around when I was trying to figure out how to make serial communications work in Windows95. I, like many programmers, was hit with the double-whammy of having to learn Windows programming and Win95 serial comm programming at the same time. I found both tasks confusing at best. It was particularly frustrating because I had, over the years, written so much stuff (including lots of serial comm software) for the DOS environment and numerous embedded applications. Interrupt driven serial comm, DMA transfer serial comm, TSR serial comm, C, Assembler, various processors... you name it, it had written it. Yet, everything I knew seemed upside-down in the message-driven-callback world of Windows.
EXAMPLE SOURCE CODE FOR TASM FILTER
his filter accepts input through the standard input stream, converts it and outputs it to the standard output stream. The streams are linked
through pipes, such that the input stream is the output from the Assembler
being invoked, and the output stream is connected to the message window of the IDE, ie.
This a simple example project for the MSP430 series MCU and the GCC port
of the mspgcc project. The project contains a makefile and uses Assembler
and C sources. It shows a clock on an character LCD.
The programming port of all the FP PLC’s support OPEN MEWTOCOL-COM. This is very useful when you want to monitor PLC values/bits or to set PLC values or bits via your COMPUTER. You can use any language such as Basic, C, Pascal, Assembler or even if other suppliers of PLCs can send ASCII strings, they can talk to our PLCs to exchange data.