Jump to content
  • Advertisement
Sign in to follow this  
kaktusas2598

SDL Arduino Port?

This topic is 2121 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hey guys,

I wanna ask if SDL have port or some kind of binding to create games for Arduino? I can't find enough info on Google. Generally, for me it's enough any rendering library which has a port to Arduino. It should be sth similar like OpenGL, SDL, SFML and such.

THanks ;)

Share this post


Link to post
Share on other sites
Advertisement

Sry, but are you talking about "http://www.arduino.cc/"?

 

I don't think there is a SDL 'port' to Arduino.. and I don't think it will be one...

 

May you explain why or how you intent to use something like SDL to Arduino?

Maybe you must look to RaspberyPI ( http://www.raspberrypi.org/ ) if you want do some 'embebed' game or something like that....

Edited by krinosx

Share this post


Link to post
Share on other sites

The problem is that porting SDL to Arduino is like asking to port SDL to a CPU... That alone simply isn't enough, and Arduino is meant to be used with pretty much any hardware configuration you can come up with. Basically, you'd need to make your own port, and your code would work only on your system.

 

I suppose you could find something that does software rendering, but don't expect anything to help you pushing stuff to screen or read input and such, because that'd be your custom hardware.

 

...or you could just tell us what you're using exactly, because I doubt it's just an Arduino.

Share this post


Link to post
Share on other sites

You need to build your rendering, sound, and input hardware around your arduino, then write the software routines to interface with it and do what you need. Arduino's are neat, but they're not terribly powerful, and unless you have hardware to actually offload the time-consuming task of generating the video signal, you're literally only going to have about 3% of the CPU to actually run the game. Uzebox is something quite close to what you'd end up with, using fairly minimal hardware. You can get good results with exceedingly clever programming, but the programming model ends up looking much like an old game console, where graphics are controlled by writing to specific memory locations rather than discrete blits, and you face similar 'hard' limits on the complexity of your scene. IIRC, the Uzebox has something like 6 CPU cycles per pixel to generate a color, including any reads from memory. even drawing the background color, (potentially) overlaying a sprite, and resolving the palette color consumes that many instructions.

 

You're just not going to get anything approaching SDL out of an arduino without complex additional hardware -- simple graphics and sound are doable with single hardware (like R2R dacs, video encoder), but its not going to resemble SDL at all. The practical minimum for anything resembling SDL is probably hardware with fast DMA and enough RAM to support a framebuffer, together with a video encoder IC.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!