Homebrew Homebrew Development

filfat

CTO @ Nordcom Group Inc.
Member
Joined
Nov 24, 2012
Messages
1,261
Trophies
1
Location
Gothenburg, Sweden
Website
www.sweetsideofsweden.com
XP
1,749
Country
Sweden
A good thing would be if someone could implement a few basic console UIs, maybe even create a class for easily creating more UIs by just doing
Code:
gui_c AppReviewPage = new gui_c("Page" /* Type */, "App Reviews" /* Title */);
AppReviewPage.printf("Reviews: %d", WHITE /* Colour */, reviews_n);
AppReviewPage.setPos(1 /* X */, 2 /* Y */)
AppReviewPage.printf("(X)Write a review", GREEN /* Colour */)
//Not changing pos
AppReviewPage.printf(" Or do something else", YELLOW /* Colour */)
Which will print out
Code:
************************************
**            Reviews             **
** Reviews: 25                    **
** (X)Write a review Or do somet- **
** hing else
**
**
**
**
**
***********************************
(didnt color them, nor did I finish the outline as this is just an example, but I hope you get the point)

Thanks :)
 

MeisterFenster

Well-Known Member
Member
Joined
Nov 18, 2014
Messages
168
Trophies
0
Age
28
XP
165
Country
Gambia, The
Hi,

I am new to all of this and I am currently trying to setup my Development Enviroment. Since I've got a Mac and not a Windows machine, I hav to compile the 3DS DevKit Arm Extension by myself (as said here: http://mtheall.com/~fincs/3dsdkA/)
But how do I do that? When I try to run that command in Terminal I get an error:
./autogen.sh: line 1: aclocal: command not found
./autogen.sh: line 2: autoconf: command not found
./autogen.sh: line 3: automake: command not found

I tried to install the XCode Console Utility, but no change. Can you help me with this step?


Please note: Yes I am a total noob in this area, but I want to get started with Homebrew Development on the 3DS and when I can get a simple Hello World running, that would be awesome :lol:
 

AlbertoSONIC

Pasta Team Member
Member
Joined
Jun 27, 2014
Messages
927
Trophies
0
Age
52
Website
www.albertosonic.com
XP
1,396
Country
Italy
Hi,

I am new to all of this and I am currently trying to setup my Development Enviroment. Since I've got a Mac and not a Windows machine, I hav to compile the 3DS DevKit Arm Extension by myself (as said here: http://mtheall.com/~fincs/3dsdkA/)
But how do I do that? When I try to run that command in Terminal I get an error:
./autogen.sh: line 1: aclocal: command not found
./autogen.sh: line 2: autoconf: command not found
./autogen.sh: line 3: automake: command not found

I tried to install the XCode Console Utility, but no change. Can you help me with this step?


Please note: Yes I am a total noob in this area, but I want to get started with Homebrew Development on the 3DS and when I can get a simple Hello World running, that would be awesome :lol:
I think you should go for a Virtual Machine. Many tools are available for windows only...
 

MeisterFenster

Well-Known Member
Member
Joined
Nov 18, 2014
Messages
168
Trophies
0
Age
28
XP
165
Country
Gambia, The
Hmm ok, I tried to avoid that step since I got a small SSD and Windows would take a lot of space. I guess it should be fine when I let it run from an SD Card. I will try that.
 

DryTaste

Well-Known Member
Member
Joined
Sep 18, 2014
Messages
162
Trophies
0
Age
28
XP
140
Country
Netherlands
Hmm ok, I tried to avoid that step since I got a small SSD and Windows would take a lot of space. I guess it should be fine when I let it run from an SD Card. I will try that.

Windows will be extremely slow if you do that, you can use a (decent) external disk with bootcamp. Works perfectly.
 

AlbertoSONIC

Pasta Team Member
Member
Joined
Jun 27, 2014
Messages
927
Trophies
0
Age
52
Website
www.albertosonic.com
XP
1,396
Country
Italy
Guys, especially Relys and st4rk , i need your help. I was trying to render some rectangles, one on top of another one. That's what i get:
d50adc894749b2094d26104fe9d34b4d.jpg


I should see something like that instead:
83b339267cd1b00483e38ffe69b16f56.jpg


What i'm doing is printing a rectangle, swap buffers, print it again and swap the buffers again, like i've always done with textes... Do i need to render it only one time?

EDIT: Fixed
 

Stalkid64

Well-Known Member
Member
Joined
Apr 20, 2008
Messages
119
Trophies
0
XP
185
Country
United States
The first person to write a complete tutorial - covering *all* aspects of setting up step-by-step in detail - and with appropriate files linked, that results in someone being able to download, eg, the Yeti3DS or Gameyob or *any* homebrew source and just have it compile and work, will be a hero to many.

Been trying to kludge this together myself and after 6 hours am just burned out of trying to get pieces of different ones to gel together. Whoever does this, you will be doing the 3DS homebrew scene a massive favour that everyone will benefit from. Right now it is just too fragmented and far too random depending on what exactly someone downloads.

Surely even here someone realises the challenge and the good that such a thing would do. Take the time at the start of this opportunity and teach people. It is crying out to be done.
 

Relys

^(Software | Hardware) Exploit? Development.$
Member
Joined
Jan 5, 2007
Messages
878
Trophies
1
XP
1,239
Country
United States
The first person to write a complete tutorial - covering *all* aspects of setting up step-by-step in detail - and with appropriate files linked, that results in someone being able to download, eg, the Yeti3DS or Gameyob or *any* homebrew source and just have it compile and work, will be a hero to many.

Been trying to kludge this together myself and after 6 hours am just burned out of trying to get pieces of different ones to gel together. Whoever does this, you will be doing the 3DS homebrew scene a massive favour that everyone will benefit from. Right now it is just too fragmented and far too random depending on what exactly someone downloads.

Surely even here someone realises the challenge and the good that such a thing would do. Take the time at the start of this opportunity and teach people. It is crying out to be done.


Follow the instructions in the readme:
https://github.com/Relys/3DSBinaryConverter
https://github.com/Relys/3DSPong
 

Relys

^(Software | Hardware) Exploit? Development.$
Member
Joined
Jan 5, 2007
Messages
878
Trophies
1
XP
1,239
Country
United States
Could you link me to every homebrew that uses bottom screen touch?


Well, I haven't tested this out because I feel too sick to do anything right now. Looking at hid.h/c this is how it should be used.

Code:
import <3ds/hid.h> // Should be included in <3ds.h> I believe.
 
//You probably already have this line included in the main.c
hidInit(NULL);
 
//Here's the code that you will put in your program to read the touch position.
touchPosition myTouchPosition;
 
//As you can see touchPosition is a struct comprised of two 16 bit unsigned integers.
//typedef struct
//{
//    u16 px, py;
//} touchPosition;
 
//Pass pointer to hidTouchRead function which updates values.
hidTouchRead(myTouchPosition);
 
//Read x cord
u16 posX=myTouchPosition.px;
//Read y cord
u16 posY=myTouchPosition.py;
 
//You probably already have this line included in the main.c
hidExit();
 
  • Like
Reactions: AlbertoSONIC

AlbertoSONIC

Pasta Team Member
Member
Joined
Jun 27, 2014
Messages
927
Trophies
0
Age
52
Website
www.albertosonic.com
XP
1,396
Country
Italy
Well, I haven't tested this out because I feel too sick to do anything right now. Looking at hid.h/c this is how it should be used.

Code:
import <3ds/hid.h> // Should be included in <3ds.h> I believe.
 
//You probably already have this line included in the main.c
hidInit(NULL);
 
//Here's the code that you will put in your program to read the touch position.
touchPosition myTouchPosition;
 
//As you can see touchPosition is a struct comprised of two 16 bit unsigned integers.
//typedef struct
//{
//    u16 px, py;
//} touchPosition;
 
//Pass pointer to hidTouchRead function which updates values.
hidTouchRead(myTouchPosition);
 
//Read x cord
u16 posX=myTouchPosition.px;
//Read y cord
u16 posY=myTouchPosition.py;
 
//You probably already have this line included in the main.c
hidExit();
Nice! But about the touchposition, how can i get a touch x which goes from 1 to 320 and a touch y which goes from 34 to 240?
 

Cid2mizard

Well-Known Member
Member
Joined
Aug 16, 2007
Messages
401
Trophies
1
Age
43
Location
Maubeuge
XP
2,483
Country
France
Relys said:
  1. Download and install DevKitARM: http://devkitpro.org
  2. Download the DevKitARM Add-on for 3DS: http://mtheall.com/~fincs/3dsdkA/
  3. Open the "dkA-3dsx-patch-12092014.zip" and copy the DevKitARM folder to DevKitPro/DevKitARM folder on your PC.
  4. Copy the "libctru" folder to C:/libctru or any other static location on your HDD.
  5. Go to System->Advanced System Settings->Environment Variables. Under System Variables click New.. Variable Name: "CTRULIB" Variable value: "C:\libctru" (change to your libctru directory).
  6. Run build.bat.
  7. Enjoy!

I've got always same errors for compil...

3DSBinaryConverter
draw.c
arm-none-eabi-gcc -MMD -MP -MF /c/devkitPro/3DSBinaryConverter/build/draw.d -g -
Wall -O2 -mword-relocations -save-temps -fomit-frame-pointer -ffast-math -mfloat
-abi=softfp -march=armv6k -mtune=mpcore -I/c/devkitPro/3DSBinaryConverter/includ
e -IC:\libctru/include -I/c/devkitPro/3DSBinaryConverter/build -DARM11 -D_3DS -c
/c/devkitPro/3DSBinaryConverter/source/draw.c -o draw.o
main.c
arm-none-eabi-gcc -MMD -MP -MF /c/devkitPro/3DSBinaryConverter/build/main.d -g -
Wall -O2 -mword-relocations -save-temps -fomit-frame-pointer -ffast-math -mfloat
-abi=softfp -march=armv6k -mtune=mpcore -I/c/devkitPro/3DSBinaryConverter/includ
e -IC:\libctru/include -I/c/devkitPro/3DSBinaryConverter/build -DARM11 -D_3DS -c
/c/devkitPro/3DSBinaryConverter/source/main.c -o main.o
program.c
arm-none-eabi-gcc -MMD -MP -MF /c/devkitPro/3DSBinaryConverter/build/program.d -
g -Wall -O2 -mword-relocations -save-temps -fomit-frame-pointer -ffast-math -mfl
oat-abi=softfp -march=armv6k -mtune=mpcore -I/c/devkitPro/3DSBinaryConverter/inc
lude -IC:\libctru/include -I/c/devkitPro/3DSBinaryConverter/build -DARM11 -D_3DS
-c /c/devkitPro/3DSBinaryConverter/source/program.c -o program.o
linking 3DSBinaryConverter.elf
built ... 3DSBinaryConverter.3dsx
'arm-none-eabi-strip' n'est pas reconnu en tant que commande interne
ou externe, un programme exécutable ou un fichier de commandes.
[ELF ERROR] Too large section size.
Segment size = 0xfdd0
Section Size = 0xfff03628
[ELF ERROR] Failed to process ELF file (-16)
[NCCH ERROR] NCCH Build Process Failed
[RESULT] Failed to build outfile
[ELF ERROR] Too large section size.
Segment size = 0xfdd0
Section Size = 0xfff03628
[ELF ERROR] Failed to process ELF file (-16)
[NCCH ERROR] NCCH Build Process Failed
[RESULT] Failed to build outfile
Appuyez sur une touche pour continuer...
 

filfat

CTO @ Nordcom Group Inc.
Member
Joined
Nov 24, 2012
Messages
1,261
Trophies
1
Location
Gothenburg, Sweden
Website
www.sweetsideofsweden.com
XP
1,749
Country
Sweden
-snip-
Code:
void render()
{
gfxFlushBuffers();
gfxSwapBuffers();
screenBottom = gfxGetFramebuffer(GFX_BOTTOM, GFX_BOTTOM, NULL, NULL);
screenTopLeft = gfxGetFramebuffer(GFX_TOP, GFX_LEFT, NULL, NULL);
screenTopRight = gfxGetFramebuffer(GFX_TOP, GFX_LEFT, NULL, NULL);
}
wait a second, shouldn't "gfxSwapBuffersGpu();" be enough?
 

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
    Psionic Roshambo @ Psionic Roshambo: https://youtu.be/fFn0llYqM8w?si=s9t6Se-c4cz5UbbP