Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
bit_send.h
00001 #ifndef BIT_SEND 00002 #define BIT_SEND 00003 00004 #define BIT_TICK_DELAY 125 // us - 125 us = 4 Khz base freq 00005 #define BIT_TICK_1_REPEAT 1 // nr. of ticks to stay on each output level 00006 #define BIT_TICK_1_NCYCLES 16 // nr. of output level switching, per bit 00007 #define BIT_TICK_0_REPEAT 2 // same for bit "0" 00008 #define BIT_TICK_0_NCYCLES 8 00009 00010 #define BIT_FIRST_SENT ( 1UL << 0 ) // signal for first bit sent 00011 #define BIT_LAST_SENT ( 1UL << 1 ) // signal for last bit sent 00012 #define BIT_LAST_PROCESSING ( 1UL << 2 ) // last bit is being processes 00013 #define BIT_SENDING ( 1UL << 3 ) // bit being processed 00014 00015 #ifdef FILE_BUF_SIZE 00016 //extern volatile char debugOut[]; // holding debug info to print at the end 00017 //static char debugLine[128]; 00018 //#define debug_printf(f_, ...) { sprintf((char*)debugLine,(f_), ##__VA_ARGS__); strcat ( (char*)debugOut, debugLine ); } 00019 #define debug_printf(f_, ...) 00020 #else 00021 #define debug_printf(f_, ...) printf((f_), ##__VA_ARGS__) 00022 #endif 00023 00024 void bitHandlerInit( void ) ; 00025 void bitHandlerStop ( void ) ; 00026 int bitWaitSend ( uint8_t bit_value, uint8_t invert ); 00027 bool bitHandlerRunning( void ) ; 00028 00029 #endif
Generated on Sat Jul 16 2022 05:01:30 by
1.7.2