Reply by Stefano Panichi June 17, 20082008-06-17
--- In l..., Franis wrote:
>
> Hello,
> I'm a new LPC935 user and for my first application, my microcontroller
> BUG, where is the problem???
> (Sorry for my bad English, I've some difficulties with this language)
>
> Explanation:
> First, I'm developing my program direct in assembler with vision3.
> It's a easy program to verify if my C do it correctly but I've no
> output :(
> The program :
> org 0000h
> ljmp start
>
> org 000Bh
> ljmp Timer0
>
> start: mov 0D6h,#8Eh ;TRIM : Clk at 7.373MHz divide by 14
> mov 89h,#02h ;TMOD
> mov 8Ch,#00h ;TH0
> setb 0AFh ;EA
> setb 0A9h ;ET0
> setb 8Ch ;TR0 Start timer 0
>
> Fin: sjmp Fin
>
> Timer0: cpl 0A3h ;port2.3
> reti
>
> And in the option of the project:
> the device : P89LPC935
> the target :
> Xtal : 7.373 ; Memory Model : Small ; CRS : Small ; OS : none
> the output : V Debug Information ; V Create HEX File
> The another settings are not change
>
> That is for vision3 to get the .hex
>
> Second I use Flash Magic (v4.20.1267) with 'FDI USB-ICP' :
> 1. Verify in ISP->Read Device Signature to check if the C is
> correctly connected
> 2. COM4; 89LPC935; FDI USB-ICP; 7.373.
> 3. I check Erase blocks used by Hex File
> all another checkboxes are not cheked
> 4. I select the hex file
> 5. I start the programing
> 6. (I try with and without) ISP->Device Configuration and select the
> RC oscillator.
> It's all the step that I follow to programming my LPC935
>
> After that I put 3.3V on Vss and 0V on VDD.
> At the output of the port 2.3, I connect it with a 10k resistor to the
> GND and I try without too but when I place the prob on the output
> I've no signal except noise (GND is correctly connected!).
>
> I don't know where I have a problem? I try different setting during
> hours today and no results.
> Do I forget a checkboxe somewhere? Or must I use a different way to
> programme my C
>
> Hope someone can help me !
> Thanks a lot,
> Framst
>

You forget to set the pin 2.3 as output pin: you must reset P2M1.3 and
set P2M2.3 bits respectively. At reset the pins are all set as inputs.

I suggest you to use Code Architect to make simple examples to learn
to use this micro: http://www.codearchitect.org/
Reply by June 16, 20082008-06-16
Hello,
I'm a new LPC935 user and for my first application, my microcontroller
BUG, where is the problem???
(Sorry for my bad English, I've some difficulties with this language)

Explanation:
First, I'm developing my program direct in assembler with vision3.
It's a easy program to verify if my C do it correctly but I've no
output :(
The program :
org 0000h
ljmp start

org 000Bh
ljmp Timer0

start: mov 0D6h,#8Eh ;TRIM : Clk at 7.373MHz divide by 14
mov 89h,#02h ;TMOD
mov 8Ch,#00h ;TH0
setb 0AFh ;EA
setb 0A9h ;ET0
setb 8Ch ;TR0 Start timer 0

Fin: sjmp Fin

Timer0: cpl 0A3h ;port2.3
reti

And in the option of the project:
the device : P89LPC935
the target :
Xtal : 7.373 ; Memory Model : Small ; CRS : Small ; OS : none
the output : V Debug Information ; V Create HEX File
The another settings are not change

That is for vision3 to get the .hex

Second I use Flash Magic (v4.20.1267) with 'FDI USB-ICP' :
1. Verify in ISP->Read Device Signature to check if the C is
correctly connected
2. COM4; 89LPC935; FDI USB-ICP; 7.373.
3. I check Erase blocks used by Hex File
all another checkboxes are not cheked
4. I select the hex file
5. I start the programing
6. (I try with and without) ISP->Device Configuration and select the
RC oscillator.
It's all the step that I follow to programming my LPC935

After that I put 3.3V on Vss and 0V on VDD.
At the output of the port 2.3, I connect it with a 10k resistor to the
GND and I try without too but when I place the prob on the output
I've no signal except noise (GND is correctly connected!).

I don't know where I have a problem? I try different setting during
hours today and no results.
Do I forget a checkboxe somewhere? Or must I use a different way to
programme my C

Hope someone can help me !
Thanks a lot,
Framst