Create New Item
Item Type
File
Folder
Item Name
Search file in folder and subfolders...
Are you sure want to rename?
File Manager
/
68hc11
:
serial.c
Advanced Search
Upload
New Item
Settings
Back
Back Up
Advanced Editor
Save
/*============================================================================ Motorola 68HC11 This is a simple program to show serial port and timer polling.. Author: Dusty Nidey, Axiom Mfg. Date: 11\22\1996 Tools: ImageCraft C Compiler V3.5 ==============================================================================*/ #include <hc11.h> // Constants, not used in this example const unsigned char SSTRING[] = "Simple String Data"; const unsigned char ANDMASK[] = {0xFB,0xF7,0xEF,0xDF}; // Function Prototypes char FlashOnOff; // 1 = flash on time, 0 = flash off time char Ibuf[18]; // serial input buffer char count; char count4; char Rcount; char Ibyte; // this function only used for debugging in buffalo monitor // it is handy to set a breakpoint here, and just call this in your program, // this way the breakpoint always stays the same void break_here(){ count=count; } // Toggle flashing pins for example Handle_Timer(){ FlashOnOff ^= 0x01; // toggle flash state, example } // After executing STARTUP code on reset, exeas follows puts("hello"); // send string putchar(0x0D); // send CR */ } if(TFLG2 & 0x80){ // if timer overflow TFLG2 |= 0x80; // clear timer overflow flag if(++count4 > 31){ // if time to flash count4=0; Handle_Timer(); // flash output pins in flash mode } } } }