Unoffical empeg BBS

Quick Links: Empeg FAQ | RioCar.Org | Hijack | BigDisk Builder | jEmplode | emphatic
Repairs: Repairs

Topic Options
#132657 - 01/01/2003 20:17 Empeg programming tutorial OR Tutor needed ;-)
elperepat
enthusiast

Registered: 11/01/2002
Posts: 211
Loc: Qc, Canada
Hi!!

I'm trying to get started at programming for the empeg, but I think I'll need a little help. Is there any HOWTO, tutorial or any kind of structured help document on how to begin coding?

Currently, I'm able to compile for the empeg and execute little "Hello world!" program that print on the terminal, but I can't get any program to work and display on the empeg screen. I tried scroller.c , and helloworld.c . Both bind to hijack menu, but as soon as I select them, the terminal says: hijack: removed menu entry: "scroller" OR "helloworld" respectively. The screen then turns all black for a minute or so and then hijack menu repears and both menu items are still there. I'm sure I'm not that far to succeed, but I'm missing a little something ;-)

So what I need is something to tell me what is the mecanism to bind to hijack menu, what are all those ioctl and is there a list somewhere of them all, etc.

Anyone willing to help me?

Thanks guys! and happy new year!

Patrick
_________________________
Patrick

Top
#132658 - 02/01/2003 06:48 Re: Empeg programming tutorial OR Tutor needed ;-) [Re: elperepat]
DeadFire
addict

Registered: 30/05/2002
Posts: 695
I'm not a programmer, so I can offer no more than this: Anything that I copied onto the empeg would not run without empeg-preinit, even if it did bind to the Hijack menu. I have no idea how it works, and you may even need to modify preinit for your specific program. But I'm pretty sure it would help.


Edited by DeadFire (02/01/2003 06:50)

Top
#132659 - 02/01/2003 11:25 Re: Empeg programming tutorial OR Tutor needed ;-) [Re: DeadFire]
elperepat
enthusiast

Registered: 11/01/2002
Posts: 211
Loc: Qc, Canada
Hi!

Thanks for the tip! I'll try it as soon as preinit website is up again.

Or maybe someone with the latest version could send it to my email?

Thanks!

Patrick
_________________________
Patrick

Top
#132660 - 02/01/2003 11:39 Re: Empeg programming tutorial OR Tutor needed ; [Re: elperepat]
wfaulk
carpal tunnel

Registered: 25/12/2000
Posts: 16706
Loc: Raleigh, NC US
In an attempt to thinly spread the thread of my ISP woes across as many ``physical'' threads as possible:

It turns out that my DSL problems this whole time were due to BellSouth swapping my line from BellSouth service to Covad service (as they were supposed to do) without telling anyone. So Speakeasy had to prod Covad who, in turn, had to prod BellSouth into telling them that it was turned on. So, basically, I could have had service for these whole 7 days (so far) if I'd had equipment on my end, which Covad won't send out until BellSouth tells them when the circuit will be switched, another thing they didn't do.

So, to sum up, I should be back up as soon as I get that equipment. Probably early next week, unless that equipment shows up today or miraculously on Saturday.
_________________________
Bitt Faulk

Top
#132661 - 02/01/2003 13:44 Re: Empeg programming tutorial OR Tutor needed ;-) [Re: DeadFire]
tman
carpal tunnel

Registered: 24/12/2001
Posts: 5528
Preinit is just so that your programs get started automatically everytime you restart the player. You don't actually need it to run any of the programs. It's just more convienient to use it instead of manually starting everything.

The one thing that most of the programs need to run is the Hijack kernel.

About the problem, there is a problem currently where you can't have more than one program binding into the Hijack menu without it conflicting.

- Trevor

Top
#132662 - 02/01/2003 14:56 Re: Empeg programming tutorial OR Tutor needed ;-) [Re: tman]
elperepat
enthusiast

Registered: 11/01/2002
Posts: 211
Loc: Qc, Canada
Hi Trevor,

Unfortunatly, my problem happens even if there's only one program started (both helloworld XOR scroller ;-)

Any other idea?!?

Patrick
_________________________
Patrick

Top
#132663 - 02/01/2003 16:19 Re: Empeg programming tutorial OR Tutor needed ;-) [Re: elperepat]
tman
carpal tunnel

Registered: 24/12/2001
Posts: 5528
Does the Pacman game work on your empeg? They all use vfdlib but I don't see any problems with that... I've not got my empeg with me at the moment so I can't try it.

- Trevor

Top
#132664 - 02/01/2003 21:25 Re: Empeg programming tutorial OR Tutor needed ; [Re: elperepat]
jaharkes
enthusiast

Registered: 20/08/2002
Posts: 340
Loc: Pittsburgh, PA
Did you modify any of these? Perhaps to get them to compile. I've used vfdlib myself and it worked like a charm.

Also, from looking at helloworld.c, it doesn't have a loop so it should just bind to the hijack menu and when selected run for 60 seconds and exit. No rebinding or anything. It could be that hijack doesn't play that nicely with multiple applications bound at the same time. Just try with only helloworld, you should be able to start it from the bash prompt.

As far as documentation for the ioctls. I just looked at the hijack.h header file and the sources. You can also look at how other applications are using hijack.
_________________________
40GB - serial #40104051 gpsapp

Top