Homebrew app Can't compile homebrew (hidKeysDown)

ThatBenderGuy

Well-Known Member
OP
Member
Joined
Dec 16, 2013
Messages
150
Trophies
0
Age
31
XP
348
Country
United States
I have recently installed Ubuntu and was setting up my development environment for DevKitPro. My project is to update a dead homebrew for personal use. I have installed all the switch libraries using dkp-pacman, and when I run make in the project's directory I get a bunch of errors but they all stem from the error:
source/main.c:501:33: error: 'CONTROLLER_P1_AUTO' undeclared (first use in this function) u64 kDown = hidKeysDown(CONTROLLER_P1_AUTO);
I have not programmed in C much but I assume due to changes in libraries since this the last time the homebrew was updated that CONTROLLER_P1_AUTO is deprecated now but I have no clue how to figure out what replaced it. The project does use SDL2 but it's not used in the main.c file (which is where this compile error is occuring). Any suggestions or ideas? I'm new to switch homebrew development but I really wanted to update this app because it's useful.

EDIT:
I also noticed I get these compile errors
warning: implicit declaration of function 'hidScanInput' [-Wimplicit-function-declaration]
warning: implicit declaration of function 'hidKeysDown' [-Wimplicit-function-declaration]
 

rash1613

Member
Newcomer
Joined
Apr 16, 2022
Messages
11
Trophies
0
Age
24
Location
New York
XP
114
Country
United States
I have recently installed Ubuntu and was setting up my development environment for DevKitPro. My project is to update a dead homebrew for personal use. I have installed all the switch libraries using dkp-pacman, and when I run make in the project's directory I get a bunch of errors but they all stem from the error:

I have not programmed in C much but I assume due to changes in libraries since this the last time the homebrew was updated that CONTROLLER_P1_AUTO is deprecated now but I have no clue how to figure out what replaced it. The project does use SDL2 but it's not used in the main.c file (which is where this compile error is occuring). Any suggestions or ideas? I'm new to switch homebrew development but I really wanted to update this app because it's useful.

EDIT:
I also noticed I get these compile errors
take a look at this example to see how button presses are read now
https://github.com/switchbrew/switch-examples/blob/master/hid/read-controls/source/main.c
 

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
  • Psionic Roshambo @ Psionic Roshambo:
    No no continue, I hear these things women say so often I decided to start counting
  • K3Nv2 @ K3Nv2:
    I tried that new Pepsi lime it just taste like pepsi
  • DTApple @ DTApple:
    With lime, right?
  • K3Nv2 @ K3Nv2:
    Just pepsi lol
  • K3Nv2 @ K3Nv2:
    Oh yeah it's D-Days 80th anniversary today
  • BigOnYa @ BigOnYa:
    I drink the Coke with lime all the time, in my Spiced rum (Captain Morgans) I hate pepsi
  • K3Nv2 @ K3Nv2:
    Probably better just to jizz a lime squeeze inside it
  • DinohScene @ DinohScene:
    volvic > anything else
    +1
  • K3Nv2 @ K3Nv2:
    My piss is water
  • BigOnYa @ BigOnYa:
    That looks like the router i just got from microcenter. Spectrum wanted to charge me $7 a month for a wifi router, so I said no thank you and just bought one, I paid like $65 tho
  • K3Nv2 @ K3Nv2:
    Linksys?
  • BigOnYa @ BigOnYa:
    Yea its Linksys, but not sure if same model, has 4 antennas
  • K3Nv2 @ K3Nv2:
    6gbps and two usb ports that supports ntfs is pretty solid dont care if it's reconditioned for $55
  • K3Nv2 @ K3Nv2:
    Just trying to figure out if it's vpn supported
  • K3Nv2 @ K3Nv2:
    I could probably set it up like a nas device
  • K3Nv2 @ K3Nv2:
    TP your router
    +1
  • K3Nv2 @ K3Nv2:
    Unless @Psionic Roshambo can convince me to spend $100 on a better option I'm probably going with it
  • BigOnYa @ BigOnYa:
    Works great for me, all i need. Can go way back on edge of property and still get 3/5 bars. And it let me setup IP Vanish on it no problem.
  • K3Nv2 @ K3Nv2:
    Google fibers router sucks keeps randomly blocking websites
  • BigOnYa @ BigOnYa:
    Does it say "Unexpected Database Error"?
  • K3Nv2 @ K3Nv2:
    Might as well 403
    +1
  • K3Nv2 @ K3Nv2:
    I yell at my isp like listen if I get a virus that's on me stop trying to protect me
    +1
    K3Nv2 @ K3Nv2: I yell at my isp like listen if I get a virus that's on me stop trying to protect me +1