Problems with sceNetAdhocPdpCreate

Discuss the development of new homebrew software, tools and libraries.

Moderators: cheriff, TyRaNiD

Post Reply
PiCkDaT
Posts: 69
Joined: Thu Oct 04, 2007 9:49 pm

Problems with sceNetAdhocPdpCreate

Post by PiCkDaT »

okay well I am trying to work on adhoc for luaplayer. I have a working ad-hoc example in C. but it isn't turning out so well for luaplayer because of the damn C++. I can get it to init the libs and connect with sceNetAdhocctlConnect(""); just fine but it freezes upon trying to create. I know I'm probably doing something rediculously wrong.

Code: Select all

static int adhoc_CreatePDP(lua_State *L)
{
	char mac[6];
	int err;

//Already tested and its not this that freezes it.
	sceWlanGetEtherAddr((unsigned char*)mac);

	if&#40;pdpID < 0&#41;
	&#123;

//Here is where I believe the trouble is
		pdpID = sceNetAdhocPdpCreate&#40;&#40;unsigned char*&#41;mac, 0x309, 0x400, 0&#41;;

	&#125;
	if&#40;pdpID < 0&#41;
		lua_pushnumber&#40;L, 0&#41;;
	else
		lua_pushnumber&#40;L, 1&#41;;

	return 1;
	
&#125;
Enlighten me, Reveal my fate -- Follow - Breaking Benjamin
PiCkDaT
Posts: 69
Joined: Thu Oct 04, 2007 9:49 pm

Post by PiCkDaT »

ok I lied.. jk. I just made a seperate C file and it works fine.. the send works now.. the recv isn't though :( still working on it.
Enlighten me, Reveal my fate -- Follow - Breaking Benjamin
Post Reply