MCPcopy Create free account
hub / github.com/BlitterStudio/amiberry / dongle_potgor

Function dongle_potgor

src/dongle.cpp:304–329  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

302}
303
304uae_u16 dongle_potgor (uae_u16 val)
305{
306 if (!currprefs.dongle)
307 return val;
308 switch (currprefs.dongle)
309 {
310 case LOGISTIX:
311 val |= 1 << 14;
312 break;
313 case SCALA_RED:
314 case SCALA_GREEN:
315 {
316 uae_u8 mode = 0x80;
317 if ((dflag & 1) || get_cycles() >= cycles + CYCLE_UNIT * (currprefs.dongle == SCALA_RED ? 450000 : 80000)) {
318 mode = 0x00;
319 dflag |= 1;
320 }
321 if (((dflag & 0x80) ^ mode) == 0x80)
322 val |= 1 << 14;
323 else
324 val &= ~(1 << 14);
325 break;
326 }
327 }
328 return val;
329}
330
331int dongle_analogjoy (int joy, int axis)
332{

Callers 1

POTGORFunction · 0.85

Calls 1

get_cyclesFunction · 0.85

Tested by

no test coverage detected