Home
JAQForum Ver 24.01
Log In or Join  
Active Topics
Local Time 07:27 25 Nov 2024 Privacy Policy
Jump to

Notice. New forum software under development. It's going to miss a few functions and look a bit ugly for a while, but I'm working on it full time now as the old forum was too unstable. Couple days, all good. If you notice any issues, please contact me.

Forum Index : Electronics : beginning picaxe for old dogs

     Page 4 of 5    
Author Message
Downwind

Guru

Joined: 09/09/2009
Location: Australia
Posts: 2333
Posted: 12:51am 16 Jan 2010
Copy link to clipboard 
Print this post

And i thought i had problems just finding a driver for windows.
Good to hear you nutted it out.

Do that mean you have put a end to jingle bells?

Pete.
Sometimes it just works
 
VK4AYQ
Guru

Joined: 02/12/2009
Location: Australia
Posts: 2539
Posted: 12:59am 16 Jan 2010
Copy link to clipboard 
Print this post

Hi Oztules

I was hoping to convert to lynix but I think you just demonstrated that it is beyond my capability.
And I thought Picaxe was complicated.

All the best

Bob
Foolin Around
 
oztules

Guru

Joined: 26/07/2007
Location: Australia
Posts: 1686
Posted: 01:37am 16 Jan 2010
Copy link to clipboard 
Print this post

Pete, Jingle bells is still top of the pops at this stage. Haven't had time to scratch myself.

Bob, don't let this put you off. If you only do all the normal stuff, linux will run out of the box, with all drivers loaded, and all the software you will ever need preinstalled.

It is when you want something offbeat to run, than it gets a little sticky. Fortunately there are people like Vasi, out there who can set you straight.

I'm not the gardener that Vasi thinks I am.... just a plodder.

Windows has every bit as much trouble running new add-ons, the only difference is that htere are drivers usually available. The draw back is that those drivers will be hidden from you. In linux, they will be transparent enough for you to alter and trick them up.... which is more difficult in windows. In windows you (just) need to find another driver for your machine. If there isn't one ..... it is twice as hard as in linux.

For a decent linux, get hold of ultimate2 linux. It will do everything you need very nicely, and without fuss.
It is really ubuntu based, but with little care for the purist software bent that ubuntu has. So lots of proprietry drivers are included, which would normally not come in hard core linux distro's.

If your a telstra customer , you can download it from the telstra files resource for no cost against your usage. (one month I used 22GB messing with different linux for no charge from Telstra)



Thanks Vasi for the prod ID etc.


...........oztules
Village idiot...or... just another hack out of his depth
 
VK4AYQ
Guru

Joined: 02/12/2009
Location: Australia
Posts: 2539
Posted: 03:43am 16 Jan 2010
Copy link to clipboard 
Print this post

HI OZTULES

I have dell server given to me that didnt have any origional disks so wasnt happy so after much fiddling I got it to load Umbuntu but it wouldmt find all the HD,s it worked for email and internet OK and the word processer worked but very slow I couldnt do anything else I wanted to do so went back to XP which is a pain in the AR-- but at least it will do what I want.
Back to trying to make sense of picaxe.
In have one of those rural satalite connections a bit slow and limited download capacity so havent experimented with downloads.
All the best

Bob
Foolin Around
 
Downwind

Guru

Joined: 09/09/2009
Location: Australia
Posts: 2333
Posted: 12:54pm 18 Jan 2010
Copy link to clipboard 
Print this post

Waffle part 3

For, Next loops.

A….. for / next… loop…… is a way of repeating a procedure.

It is written as
[code]
For b1 = 0 to 9
………..
…………
…………..
Next b1
[/code]
Where b1 can be any variable ( b0……….b13) ( or w0…to… w6 )
0 to 9 can be any thing up to 255 (or W …to.. 65335 ) and is the number of times the.. for / next… procedure will be repeated

A Working example would be
[code]
Main:

For b5 = 0 to 9

High 0,1,2,4
Pause 100
Low 0,1,2,4
Pause 100
Next b5

end
[/code]
This will flash a all leds for 100 ms ten times and then switch off as there is no program instructing it after the example.
It will repeat the procedure each time the power is switched on.

Example 2……… to sound the buzzer for a set amount of times. (1001 times )

[code]
Main:

For w0 = 0 to 1000
High 2
Low 2
Pause 0
Next w0

end
[/code]

By changing the value of pause will alter the tone of the buzzer.

Example 3 ……. Adding the push switch in, to advance the value of pause when the switch is pressed.
[code]

Symbol cycles = w0
symbol tone = b2

tone = 0

Main:
for cycles = 0 to 1000
high 2
low 2
pause tone
gosub check_pin3
next cycles

goto finish

Check_pin3:
if pin3 = 1 then
inc tone
cycles = 0
high 0
pause 200
low 0
endif

return

finish:
end
[/code]


In example 3 a …gosub…. Is used to send the program off each cycle to check on the condition of pin3, and if it is high then the value of …tone ….is increased.

The …tone….. value will increase by 1 for every 200ms the switch is pressed.
The red led will light to indicate the switch is pressed.

Ensure the slide switch is off or it will override the push switch as they are one of the same.


Pete.

Sometimes it just works
 
Greenbelt

Guru

Joined: 11/01/2009
Location: United States
Posts: 566
Posted: 02:33am 19 Jan 2010
Copy link to clipboard 
Print this post

DOWNWIND;
I too was born with a hammer in both hands To wit;
I ordered and received a picaxe 18x with the breadboard and serial plug also a 9 volt battery socket all wired to blink the LED's I plugged in the battery and no lights.
I immediately checked the battery to make sure it was snapped in and burnt my finger on the 1N4004 heat sink.
I quickly Disconnected the Battery. It too was so hot I thought it would blow up. Back to the drawing Board for the distributor. I'll probably have to eat this one.
Many years ago I had a Compac < brand)Computer built like a suitcase with handle. It had a 21 meg. hard drive, 64 kilobytes ram.
The operating system was basic and I learned some of the commands that are used to program the picaxe. I chose the 18 X because of the GOSUBS = 42 and several inputs. it cost about a dollar more than the O8-M , A lot of places to POKE and PEEK, I suspect that poke and peek refers to
memory locations on the chip rather than pixel locations on a monitor as was the case with the compac.
You are doing a worthwhile service for many more people than you will know about. RoeEdited by Greenbelt 2010-01-20
Time has proven that I am blind to the Obvious, some of the above may be True?
 
Downwind

Guru

Joined: 09/09/2009
Location: Australia
Posts: 2333
Posted: 03:42am 19 Jan 2010
Copy link to clipboard 
Print this post

Greenbelt,

Hmmmmmmm!
Look like a problem??
A 1N4004 is a diode and have never seen one with a heat sink??
What battery voltage are you using??
Do the board have a voltage reg? (LM7805) ( i am guessing this is what was hot)
If the reg was hot then it may well be in the wrong way around or your battery was reversed.

Firstly remove the 18X from the board and then try to trouble shoot the power problem.
You need to have 5 volts supply to the 18X Ic pins 5 and 14. pin5 = 0v and pin14 = 5v.

All might not be lost just yet as they can be tough little buggers but then i have mannaged to kill a few.

If you can give a little more information we might be able to get you back on track.

the 18x will go to 256 gosub not 42 and peek and poke is to read / write to memory but in simple programs is not always needed to do, as variables are used for this.

The 18X is a good chip and allows much more to be done than the 08m.
Here the 18x is double the price of a 08m and for starters i was trying to keep costs down to make it more tempting for others to give it a go.
Im sure most will move onto a 18x for bigger projects.

Pete.
Sometimes it just works
 
VK4AYQ
Guru

Joined: 02/12/2009
Location: Australia
Posts: 2539
Posted: 03:44am 19 Jan 2010
Copy link to clipboard 
Print this post

Hi Pete

Does the scanner play mono or stereo and flash the leds at the same time.

I had a computer like Greenbelt it had a harddrive that was as big a two filing cabinets had to send the operator for a week to learn how to type on it.

Bob
Foolin Around
 
Downwind

Guru

Joined: 09/09/2009
Location: Australia
Posts: 2333
Posted: 04:15am 19 Jan 2010
Copy link to clipboard 
Print this post

Bob,

Huh?? Scanner??
Not sure which project you are referring to??

If you mean the test board it is just mono and a very basic form.

The ring tones have a a bit up front that says...... Tune 1, 4, ( $??...............$??)

If you change the 1 to 2 it will flash output4 led (yellow) or change the 1 to 3 it will flash output0 and output4 alternately. (red and yellow)

If you change the 4 (tune 1, 4,) it will change the speed of the tune.( or beats per minutes)

If you look up " TUNE " in the basic commands there is the data on what i said above and also how to write a tune if one would like to.
( when you get prog editor to load )

Pete.
Sometimes it just works
 
VK4AYQ
Guru

Joined: 02/12/2009
Location: Australia
Posts: 2539
Posted: 05:15am 19 Jan 2010
Copy link to clipboard 
Print this post

Hi Pete

Just having a joke about all the things the picaxe can do maybee an extra relay and we could program a cup of coffee every two hours or toast in the morning and turn on the AC when the OAT gets to 30c.
Im just full of ideas now that I read some of the notes.
In the mean time Im just as dumb as usual about how to do it.

All the best

Bob
Foolin Around
 
Downwind

Guru

Joined: 09/09/2009
Location: Australia
Posts: 2333
Posted: 06:09am 19 Jan 2010
Copy link to clipboard 
Print this post

Bob,

As for the bit of hot crumpet in the morning... Well i will let you work on that one!

We are only dumb when we dont understand.
And you are not getting of the hook with picaxe's that easy!
Once you get everything talking to each other and am able to get a program to load things will get clearer.

You will write a little program, make mistakes, workout what was wrong, and learn another step.
Trial and error with these things is the easiest way to learn.
You will be teaching me soon.

Pete.
Sometimes it just works
 
Greenbelt

Guru

Joined: 11/01/2009
Location: United States
Posts: 566
Posted: 06:34am 19 Jan 2010
Copy link to clipboard 
Print this post

DOWNWIND;
Quote;
Greenbelt,

Hmmmmmmm!
Look like a problem??
A 1N4004 is a diode and have never seen one with a heat sink??
What battery voltage are you using??
Do the board have a voltage reg? (LM7805)( End Quote.)

The problem is yours Truly. I took a better look at the little Drawing that came with it -I now see that what I thought was a detailed internal circuit for the pictured
voltage reg.with no connections and quickly concluded
the large number above the diode was its ID. The little arrow pointing at the box. its been sometime since I
messed with a circuit. I should have remembered that
the 1N-- prefix indicates a Diode, or maybe not anymore. and yes The LM7805 is right where it should be. I'm using a standard 9 volt dry cell Battery. when I get some time I'll Check it Out. My Clothes Drier on a stacked system went on the Blink, Man what a Pile of Screws to get in to the blower fan!! When Things are broke, life is not good around the house. Blower Fan is plastic,
Hub wallowed out on the motor shaft. Thanks for the Tips--Roe
Time has proven that I am blind to the Obvious, some of the above may be True?
 
Greenbelt

Guru

Joined: 11/01/2009
Location: United States
Posts: 566
Posted: 08:59pm 19 Jan 2010
Copy link to clipboard 
Print this post

Downwind;
This is a link to a distributor of the Picaxe Chips,
I don't know how this price compare's to your sources?
There will be shipping charges added and there is a $25.00 US. minimum order.
I was thinking that a startup board and chip with a serial cable would satisfy the minimum order and a few more chips and things at this price would increase the shipping value only slightly.(charges).
Picaxe dealer USA.
#
This is the description of my disabled board.
I found a small cap has a broken lead, it has the appearance of damage in shipment, things are bent to one side, laid over as if something heavy rode along on top of it.
# Solderless Dev Package - 18-pin consisting of 830 point solderless breadoard, serial connection to solderless breadboard, PICAXE-18X, 5VDC voltage regulator and associated capacitors and monitor LEDs, 9V transistor battery connector (battery not included) and 22 awg solid hookup wire suitable for use with a solderless breadboard. Assembled and tested with blinking LED example. This is the same as the package for the PICAXE-08M except it uses the PICAXE-18X. Includes one PICAXE-18X. $24.95 US Only.

Edited by Greenbelt 2010-01-21
Time has proven that I am blind to the Obvious, some of the above may be True?
 
Downwind

Guru

Joined: 09/09/2009
Location: Australia
Posts: 2333
Posted: 01:48am 20 Jan 2010
Copy link to clipboard 
Print this post

Hi Greenbelt,

The link for picaxe has some good pricing, just waiting on a reply to a question before i place an order.
They are about 1/2 the price of here even with shipping but then need to add the exchange rate on top.
Cant be any worse than here so will give them a go.

Now your sad sorry board

I had a look at the kit you bought and can only see a photo no schematic.
It aint rocket science and the cap thats damaged is only on the voltage reg part of the circuit.
What is the value of the mangled cap??

Would not mind to see the instructions you got with the board if you are able to post them or pm me for an email address if thats easier.

Think we can get you back on track.
Dont know if you have used a bread board before.
The one you have has 2 power rails either side of the board that run length wise to the board and the other inner rails run cross wise to the board.

Some how you wired a dead short across the vreg or inserted/wired it backwards to cause the problem you had.
The damaged cap would not cause the problem of making a heater.
Unless you inserted the cap backwards??

The easiest way to sort this out might be to piss the vreg and caps etc off.
Get 3 x AA batterys and tape them together to give 4.5 volts and use them for now without the vreg etc.
The picaxe will work fine down to 3 volts but must not go above 5 volts.

This way you will only end up with the 18x, 1 x 10K resistor, 1 x 22K resistor the programming socket, and the led.(you can even leave the program socket off for now to)
Plug the positive battery wire into ic pin 14 of the 18x and negative into ic pin 5 of the 18x and all being well you should have a blinking led.

From what i can see the led will need a positive wire connected to the other leg ( flat side of led towards the 18x)
Ensure the led dont have both legs plugged into the same rail or rails used by another pin.
Use one of the 2 outer rails for the other led leg and run a positive wire to that rail.


Pete.

Sometimes it just works
 
Greenbelt

Guru

Joined: 11/01/2009
Location: United States
Posts: 566
Posted: 11:56pm 20 Jan 2010
Copy link to clipboard 
Print this post

Downwind;
I have not used a breadboard but i have it figured out.and I don't anticipate having a problem with the board.
The only thing I did was plug on the battery. no kind of
rewiring or alteration. I checked the diode, It is shot.
the 7805 is definatly blown. I will get back to this in a couple days when i can concentrate here is the drawing
that came with the board its in pencil and didn't scan
very well. also I recently had computer problems and have lost the driver for my digg Camera so I tried to scan the board, Didn't work as you can see.


Edited by Greenbelt 2010-01-22
Time has proven that I am blind to the Obvious, some of the above may be True?
 
Downwind

Guru

Joined: 09/09/2009
Location: Australia
Posts: 2333
Posted: 01:18am 21 Jan 2010
Copy link to clipboard 
Print this post

Greenbelt,

The 1N4004 diode dont need to be in the circuit to start with for this application so get rid of it we dont need it.

It takes a lot to kill a 7805 voltage reg so can only think someone has wired your board incorrectly to start with.

The 7805 has thermal protection so if you just had a short after the reg it would get hot and shut down and the diode should not be affected.

At a guess i think the leads from the battery might be connected to the board the wrong way around.

With a bit of luck the diode may have taken the brunt of the load and fused closed circuit and protected the 18X.

Worst situation is you own a nice breadboard and need some new components to plug into it.

Just disconnect one of the power wires going to the 18x before testing the v reg circuit any further.

Will wait to see what you find when you get back to it.

Pete.
Sometimes it just works
 
Greenbelt

Guru

Joined: 11/01/2009
Location: United States
Posts: 566
Posted: 05:13am 21 Jan 2010
Copy link to clipboard 
Print this post

Downwind;
Your Right my man!! The Battery connector still has the rubber band around the dangeling wires as it came from the vendor.
Do you understand my signature
Edited by Greenbelt 2010-01-22
Time has proven that I am blind to the Obvious, some of the above may be True?
 
GWatPE

Senior Member

Joined: 01/09/2006
Location: Australia
Posts: 2127
Posted: 11:07am 21 Jan 2010
Copy link to clipboard 
Print this post

Just a note:

Picaxe has a 20X2 chip. I will be using this for some projects. These appear to be very useful. they have 11 analogue inputs. Plenty of programming space and registers. default COMMS is 9600baud. A good step up from the 08M.

Gordon.


become more energy aware
 
Downwind

Guru

Joined: 09/09/2009
Location: Australia
Posts: 2333
Posted: 11:33am 21 Jan 2010
Copy link to clipboard 
Print this post

Gordon,

Did you notice the 20x2 has a internal clock speed of 64 meg.
Mind boggling fast compared to the 08M at 4 meg clock speed.

Its worth checking out Greenbelt's link of a supplier in the USA as it can work out less than 1/2 what we pay here even with postage. WORTH A LOOK!

The 20x2 looks to be the pick of the picaxe in the current generation with the built in comands avaliable.

At usd $6.00 +p/h well worth while if you get a few.

Pete
Sometimes it just works
 
GWatPE

Senior Member

Joined: 01/09/2006
Location: Australia
Posts: 2127
Posted: 01:22pm 21 Jan 2010
Copy link to clipboard 
Print this post

Hi Pete,

I already have this unit on test. Have just finished VB app for 11 channel logging and graphing.

This will be a revamped battery cell logging unit.

The picaxe program ends up quite trivial compared to the VB app. Will need to revisit the logging, as the XML format log file is now over 1MB per day.

Gordon.


become more energy aware
 
     Page 4 of 5    
Print this page
© JAQ Software 2024