UART to control the led

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

UART to control the led

702 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by wzq121381 on Sun Nov 03 05:15:13 MST 2013
I am  going   to  using  the   uart  to  control  the  led,if   i   using  the  uart  in  the  computer  to  send   the 01 05 00 02 FF 00 2D FA,then  the  led  on  the  p-2-10  will  be  lighten.if  i   send  the   01 05 00 02 00 00 6C 0A  ,the   led  will  be  not   dark.Can  you  help   
  me..   thanks.
Labels (1)
0 Kudos
11 Replies

693 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by capiman on Tue Nov 05 08:32:20 MST 2013
Seems there is already some code available. Thread continues here:
http://www.lpcware.com/zh-hans/content/forum/lpc11c24-about-uart
0 Kudos

693 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by liaochengyi on Tue Nov 05 08:03:28 MST 2013
I am from Taiwan.

Don't buy a fish. Because you will buy more fishes and always to do.

Do it by yourself!!
0 Kudos

693 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by wzq121381 on Tue Nov 05 05:33:51 MST 2013
my  email  727835199@qq.com
0 Kudos

693 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by capiman on Tue Nov 05 04:43:09 MST 2013
Clarifying via private email
0 Kudos

693 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by wzq121381 on Tue Nov 05 03:34:44 MST 2013
I  am  in   China,how  to  pay  and  how  much  do  you  want?
0 Kudos

693 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by capiman on Mon Nov 04 07:24:51 MST 2013
Do you pay for writing the code?
0 Kudos

693 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by wzq121381 on Mon Nov 04 07:05:55 MST 2013
can  you  write  the  code? I  know 
1. receive uart data.
2. parser the uart data command.
3. let LED on/off.
but   i   do  not  konw  how  to  write  the  code
thanks
0 Kudos

693 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by liaochengyi on Sun Nov 03 09:42:13 MST 2013
Hi,

That Just
1. receive uart data.
2. parser the uart data command.
3. let LED on/off.


You can get the LPCxx sample code to modify it.
0 Kudos

693 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by capiman on Sun Nov 03 09:37:50 MST 2013
Without giving us more input (e.g. source code and perhaps protocol description), we are not able to see if and where there is a bug, sorry.
0 Kudos

693 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by wzq121381 on Sun Nov 03 06:51:48 MST 2013
I am  using  the  rs232,and  the  p2.10  can  be  lighten  by GPIOSetValue(2,10,1);but  I  need  to  control  it   by   uart  ,just   if   the   uart   send   something ,then  the  led  will  be  control.
0 Kudos

693 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by capiman on Sun Nov 03 06:14:58 MST 2013
Hello wzq121381,

this will be difficult, because we know almost nothing about your environment.
We don't know your protocol, uC, software you are using.
Check if you can control your led without UART, just by setting your GPIO in main (e.g. in a while loop).
Check if P2.10 is a special pin, which perhaps needs a pull-up/pull-down (open collector pin).

Best regards,

Martin

0 Kudos