MCPcopy Create free account
hub / github.com/360Controller/360Controller / SetForce

Method SetForce

Feedback360/Feedback360.cpp:595–600  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

593}
594
595void Feedback360::SetForce(LONG LeftLevel, LONG RightLevel)
596{
597 //fprintf(stderr, "LS: %d; RS: %d\n", (unsigned char)MIN( 255, LeftLevel * Gain / 10000 ), (unsigned char)MIN( 255, RightLevel * Gain / 10000 ));
598 unsigned char buf[] = {0x00, 0x04, (unsigned char)min(SCALE_MAX, LeftLevel * (LONG)Gain / 10000 ), (unsigned char)min(SCALE_MAX, RightLevel * (LONG)Gain / 10000 )};
599 if (!Manual) Device_Send(&device, buf, sizeof(buf));
600}
601
602void Feedback360::EffectProc( void *params )
603{

Callers 1

EffectProcMethod · 0.45

Calls 1

Device_SendFunction · 0.85

Tested by

no test coverage detected