5 #include "../hubolib.h"
21 const char*
g_pCode =
"ADCBADADADCBCBCBADADADADADADCBCBCBCBADADCEADCE";
26 CCode (
unsigned short time,
unsigned char signal)
33 unsigned short m_time;
34 unsigned char m_signal;
49 int main(
int argc,
char *argv[])
53 printf (
"GPIO not properly initialized. Are you running the program as sudoer?\n");
58 unsigned short transmit_pin = 17;
67 for (
int i=0; i<10; i++)
99 printf (
"Error - unknown code\n");
114 pthread_t threadHandle = pthread_self();
117 ret = pthread_getschedparam (threadHandle, &policy, ¶m);
122 param.sched_priority = sched_get_priority_max(policy);
123 ret = pthread_setschedparam(threadHandle, policy, ¶m);
void Delay_MicroSeconds(unsigned long delay_micros)
delays the execution of the calling thread for the given number of micro seconds. ...
bool IsGPIOInitialized()
Returns the status of the initialisation of the GPIO part of the library.
void BoostThreadPriority()
int main(int argc, char *argv[])
void FunctionSelectPin(unsigned char pin, FunctionSelectType mode)
Use FunctionSelect() to configure the mode of a BCM2835 pin.
void SendDatagram(unsigned short pin)
void WritePin(unsigned char pin, unsigned char value)
Sets or clears a pin configured to be an output.
CCode(unsigned short time, unsigned char signal)