Advertising (This ad goes away for registered users. You can Login or Register)

Learning to code: python, lua, C (for Vita homebrew)?

Open discussions on programming specifically for the PS Vita.
Forum rules
Forum rule Nº 15 is strictly enforced in this subforum.
User avatar
CPUzX
Moderator
Posts: 276
Joined: Thu Nov 28, 2013 8:25 pm
Location: United Kingdom

Re: Learning to code: python, lua, C (for Vita homebrew)?

Post by CPUzX » Fri Sep 09, 2016 9:08 pm

hgoel0974 wrote:I intended to reply earlier, but got caught up with other stuff.
So, for starters, don't worry about asking programming questions as a moderator, people will most likely actually end up responding to you faster/in a better way to get on your good side :P (going by how I started out at least).

As for writing homebrew for the Vita, as it stands, things are still pretty new and so there is very little documentation to go by, which is why most developers have experience working with other systems. Getting up and running however, isn't too hard if you have your basics down well. Namely, if you can understand simple makefiles and can write basic C code, you're ready to at least give it a shot. I would recommend practicing writing code for say Linux, or for Windows with an Msys environment. This should help you get used to makefiles and building from the command line, while also giving you some confidence working with C.

As for choice of an editor, I tend to use Sublime Text 2 for C/C++ but you can use pretty much anything you want (except something like Visual Studio - which doesn't let you easily use makefiles, dunno about XCode), source code is just a plain text file which means it can be opened in anything (this is one of those things Windows tries to hide from people, back when I started out, the idea that I could theoretically open any file in a text editor, or a hex editor was pretty surprising to me too).

I didn't actually rely on any books to learn most of what I know so I can't recommend any books, but on the Freenode IRC network, you'll find the ##c channel to be helpful for any C programming related questions, as well as #henkaku for henkaku specific questions.
Alright, it'll be worth putting this thread in the public programming or support section, was a bit concerned from earlier.

Got it. I'll look into "MinGW", which has popped up once during some research to do with C a little while back. Thanks for the tip. There is limited resources available right now on the Vita scene, and with barely any knowledge to do with programming in general, it would be a much better idea to learn C while the Vita scene unfolds.

Learning to program without a book, that must've been more to do with experience and gradual learning through mostly trial & error, right? That must've been even tougher than actually learning from a guide.
Even with books and the vast information on the net, programmers still make errors on occasion, huh, so it it's all about taking the risks and overcoming the issues with a gradual pace.

Since I'm familiar with Windows the most, it'll be MinGW for the moment.
Linux is a cool platform though.
lol. Visual studio is off the list of priorities now. It won't become a waste of time now that it's no longer a point of interest in the research.

Could you use Windows' default Notepad to program? You could, right(?) You just need to compile it afterwards, if I'm not mistaken. Perhaps Notepad++ is way more suitable for programming than just Notepad, but I'll also look into getting Sublime Text 2, as I've already got Notepad++

Thanks for the help - much appreciated!
Advertising

User avatar
fate6
Big Beholder
Posts: 7599
Joined: Fri Mar 09, 2012 1:18 am
Location: [fate6@Canterlot ~]$

Re: Learning to code: python, lua, C (for Vita homebrew)?

Post by fate6 » Fri Sep 09, 2016 9:51 pm

Yea you could use regular notepad but im not sure how it handles new lines or indentation so IDK if it could cause issues down the line.
Just use N++ and enjoy pulling a little bit less hair out of your head.
Advertising
Image
anon wrote:If you can't trust a 600 year old vampire in a prepubescent girl's body, who can you trust?

User avatar
CPUzX
Moderator
Posts: 276
Joined: Thu Nov 28, 2013 8:25 pm
Location: United Kingdom

Re: Learning to code: python, lua, C (for Vita homebrew)?

Post by CPUzX » Sat Sep 10, 2016 1:23 am

I've ran into a problem.
There only seems to be a GNU compiler for ARM and the DS-5/6 Development Studio for compiling ARM code, but both DS-5 & DS-6 require license files, which means you must be a developer in the first place and purchase a license to use the compiler?

Is there an alternate ARM compiler that anybody can use and is preferably free?
Would the GNU ARM compiler be any good?
Figuring out how to download it is a bit of a pain right now.
Would it be called an assembler instead of a compiler?

I plan to set everything up ahead of time to be prepared for when I've learned more about C...
Still attempting to learn C right now, so it's not a high priority right at this moment, but it would be nice to get an idea of all the things required for Vita development beforehand, during the knowledgable part of learning C to begin with.

User avatar
fate6
Big Beholder
Posts: 7599
Joined: Fri Mar 09, 2012 1:18 am
Location: [fate6@Canterlot ~]$

Re: Learning to code: python, lua, C (for Vita homebrew)?

Post by fate6 » Sat Sep 10, 2016 4:28 am

toolchain
https://github.com/vitasdk/buildscripts

Just follow the instructions and you'll be all set up.
And honestly just use GCC for your compiler, for compiling for any system really.
Image
anon wrote:If you can't trust a 600 year old vampire in a prepubescent girl's body, who can you trust?

User avatar
CPUzX
Moderator
Posts: 276
Joined: Thu Nov 28, 2013 8:25 pm
Location: United Kingdom

Re: Learning to code: python, lua, C (for Vita homebrew)?

Post by CPUzX » Tue Sep 13, 2016 11:40 pm

fate6 wrote:toolchain
https://github.com/vitasdk/buildscripts

Just follow the instructions and you'll be all set up.
And honestly just use GCC for your compiler, for compiling for any system really.
Got a question:
Can the Vita SDK Toolchain/build scripts be used with Windows, or do you have to install Ubuntu?

User avatar
fate6
Big Beholder
Posts: 7599
Joined: Fri Mar 09, 2012 1:18 am
Location: [fate6@Canterlot ~]$

Re: Learning to code: python, lua, C (for Vita homebrew)?

Post by fate6 » Wed Sep 14, 2016 3:42 am

IDK with the linux sub-system on W10 yea.
I use Fedora for dev stuff so can't help you here.
Image
anon wrote:If you can't trust a 600 year old vampire in a prepubescent girl's body, who can you trust?

User avatar
CPUzX
Moderator
Posts: 276
Joined: Thu Nov 28, 2013 8:25 pm
Location: United Kingdom

Re: Learning to code: python, lua, C (for Vita homebrew)?

Post by CPUzX » Wed Sep 14, 2016 1:01 pm

fate6 wrote:IDK with the linux sub-system on W10 yea.
I use Fedora for dev stuff so can't help you here.
I'll create a seperate boot partition for Ubuntu, (specifically for Ubuntu programming, SDK environmental developing when it comes to the Vita), but learning C will probably remain Windows-sided. Thanks anyway.

Post Reply

Return to “Programming and Security”