I have a problem with a multi colored LED.
I am using this LED which is 3 colored, 4 leged. This LED has a common anode so I have to use the low command not high. While the 08M was on the schl. ex. board pin 0 was not very bright. Even with the other LED legs on pin 0 it is always dim. I then took the chip off thew board and had just the LED soldered on. Now LED on pin 0 doesn't go at all. (again, it is not the LED) The multimeter says the pin is going and a normal LED works fine. The LED is round the right way and the batteries are fine. A tie down resistor on SerIn doesn't seem to help.
Here is my shematic...
5VAnd a basic version of my code...
Any ideas
I am using this LED which is 3 colored, 4 leged. This LED has a common anode so I have to use the low command not high. While the 08M was on the schl. ex. board pin 0 was not very bright. Even with the other LED legs on pin 0 it is always dim. I then took the chip off thew board and had just the LED soldered on. Now LED on pin 0 doesn't go at all. (again, it is not the LED) The multimeter says the pin is going and a normal LED works fine. The LED is round the right way and the batteries are fine. A tie down resistor on SerIn doesn't seem to help.
Here is my shematic...
Code:
+------------------+ multicolor LED
| .----------. | ____
| |PICAXE 08M| | / \
| +-o-|5V 0V|-o +--o---|<-o |
| | -|SerIn Out0|-o--------+ | | | common
| | -|In4 Out1|-o-----------o---|<-o---o anode
| | -|In3 Out2|-o--------+ | | | |
| | '----------' +--o---|<-o | |
| +--------------------+ \----/ |
| | |
| | | | | |
+-----------o-||-||-||-o------------------+
- | | | +
Code:
output 0
output 1
output 2
symbol time = w1 'w1 is used as pause time
main:
let w1 = 1000 '1 sec
flash1:
let pins = %0000011 'as the led is backwards the pin neads no be negative
pause time 'pause for w1 value
let pins = %0000101 'pin 1
pause time
let pins = %0000110 'pin 0
pause time
if time = 0 then goto flash2 'if there is no delay between flashes go to flash2 sequence
let time = time - 50 'time value is decreased by 50
goto flash1 'loop back with new pause time
flash2:
let pins = %0000011 'as the led is backwards the pin neads no be negative
pause time 'pause for w1 value
let pins = %0000101 pin 1
pause time
let pins = %0000110 pin 0
pause time
if time = 1000 then goto flash1 'if there is a 1 sec delay between flashes go to flash1 sequence
let time = time + 50 'time value is increased by 50
goto flash2 'loop back with new pause time
Last edited: