Wrt54gl

nevil010

Member
my first project on Autonomous robot worked fine...thanks to all..
Is it possible to connect picaxe 18m2 directly to wrt54gl without max232...do picaxe support TTL serial ports?
 

hippy

Ex-Staff (retired)
Should be able to get it connected directly to a PICAXE. 1K in series on TX and RX lines would be recommended which should also cater for 3V3 / 5V differences if there are any ( and protect against accidental cross-overs ). Probably need to use Txxxx baud rates.
 

nevil010

Member
I have connected as below...and i sent message "123" from router to picaxe....actually it is reading message...when i checked terminal what i can see is this "<ðø€øø" :p ..in terminal the baud rate i choosed was 19200..what is the problem
Code:
setfreq m8	; setfreq to 4MHz

main:
	  serin c.4,T9600_8,b1	; receive serial value
	  
	  goto main
[\code][ATTACH=CONFIG]12883.vB[/ATTACH][ATTACH=CONFIG]12883.vB[/ATTACH]
 

SAborn

Senior Member
So you are receiving data at 9600 baud and you have terminal baud rate set to 19200 baud, now ask yourself do these two baud rates match...........er i think not.

Perhaps i missed something as i have not read the full thread, but reading your last post it seems wrong to me.
 

nevil010

Member
I tried all baud rate in terminal..but i am not getting the correct message...the routers default baud rate is 115200..i have not changed(actually i dont know how to)
 

hippy

Ex-Staff (retired)
You seem to have the router wired into the PICAXE download serial in and out pins, but I've no idea how you are connecting to use Terminal, nor what you are seeing on that as the 18M2 program does not output anything.

I would say, at this point, everything is wrong. Use a standard PICAXE setup with normal download circuit, then connect power plus the router TX into pin C.0, try this code ...

#Picaxe 18M2
#Terminal 4800
Do
SerIn C.0, T9600, b0
SerTxd( #b0, " " )
Loop
 

nevil010

Member
Hippy! can you do me a favour?..can you post a simple diagram on how to connect it to router..i searched a lot in google...what i get is all about arduino..And i am also planning to post it on blog..so it would be very helpful if u post . :D
 

nevil010

Member
Untitled.pngHippy Thankx Man...It worked when i changed wrt54gl 's baud rate to 19200....
Code:
setfreq m16
main:
	  serout c.6,T19200_16,(" *wasup wrt54gl* ")	
	  wait 1
	goto main
Transfering worked fine..i connected to rx and downloaded this code
Code:
setfreq m16
main:
	  serin c.6,T19200_16,b1	
	
	goto main		;
and i echoed 123456789 from router but picaxe isnt getting any message..
is the code wrong
 
Last edited:

hippy

Ex-Staff (retired)
actually i connected picaxe c.6 to Router's tx...
I would recommend connecting TX to one PICAXE pin, RX to another, stick with that configuration, post a full circuit diagram, write your code to us the appropriate pins, then it's much easier to assess what is being done and why it may not be working.
 

nevil010

Member
aa.png
I would recommend connecting TX to one PICAXE pin, RX to another, stick with that configuration, post a full circuit diagram, write your code to us the appropriate pins, then it's much easier to assess what is being done and why it may not be working.
Code:
setfreq m16
main:
	  serin c.6,T19200_16,b1	
	
	goto main
And i echoed "123" from my router but the picaxe is not receiving..I set router's baud rate to 19200..
 

hippy

Ex-Staff (retired)
i echoed "123" from my router but the picaxe is not receiving.
Not receiving anything, or receiving something but not what was expected; and in that case what did it receive ?

I would guess it likely received a "1" which would set the b1 to "1", 49 decimal, $31 hexadecimal, %00110001 binary.

Try sending "[123]" and using the following ...

serin c.6, T19200_16, ( "[" ), #b1

That should hopefully put decimal 123 into b1. It would probably be worth trying with a lower baud rate if that doesn't work.
 
Top