Sponsored links

Go Back   MP3Car.com > Mp3Car Technical > General Hardware Discussion


Reply
 
Share Thread Tools Display Modes
Old 10-31-2006, 04:01 PM   #1
lez
FLAC
 
lez's Avatar
 
Join Date: Jan 2004
Location: UK
Posts: 1,313
lez is on a distinguished road
Anyone currently working with 18f2550

Anyone currently working with 18f2550 (or 4550)?

I need some hex for one to test it, just simple flash of leds on port B would be great. (I also have them on a and c)

small size etc no masterpiece....

C or asm wont do, need hex, I think my programmer is working against me so just need working tested hex.

20mhz crystal osc

my isp also seems to only work about once an hour, it must be hardware, but to say that I need tested hex etc.
lez is offline   Reply With Quote
Advertisement
 
Advertisement
Sponsored links

Old 10-31-2006, 04:27 PM   #2
MySQL Error
 
jcdillin's Avatar
 
Join Date: May 2003
Location: Miami, FL
Posts: 4,040
jcdillin is on a distinguished road
is the 28 or the 40 pin?
__________________
肚子笑痛了
S60 Install
jcdillin is offline   Reply With Quote
Old 10-31-2006, 04:29 PM   #3
MySQL Error
 
jcdillin's Avatar
 
Join Date: May 2003
Location: Miami, FL
Posts: 4,040
jcdillin is on a distinguished road
This will blink an LED on PortB.0

rename from .txt to .hex if needed.
Attached Files
File Type: txt blinkRB0.txt (399 Bytes, 337 views)
__________________
肚子笑痛了
S60 Install
jcdillin is offline   Reply With Quote
Old 11-01-2006, 03:36 AM   #4
lez
FLAC
 
lez's Avatar
 
Join Date: Jan 2004
Location: UK
Posts: 1,313
lez is on a distinguished road
Thanks a million, I cant believe migrating from the f88 to the 2550 to get extra IO lines has been such a damn PITA

At least now I can not worry about the software side and just fight the hardware.

It could even be as simple as bust crystal /?
lez is offline   Reply With Quote
Old 11-01-2006, 07:29 AM   #5
MySQL Error
 
jcdillin's Avatar
 
Join Date: May 2003
Location: Miami, FL
Posts: 4,040
jcdillin is on a distinguished road
Yeah I avoid the 18F series for now. Everything I do I have been able to do with the 16F series, at least untill I want to go USB.

Let me know if I can help further.
__________________
肚子笑痛了
S60 Install
jcdillin is offline   Reply With Quote
Old 11-01-2006, 07:35 AM   #6
lez
FLAC
 
lez's Avatar
 
Join Date: Jan 2004
Location: UK
Posts: 1,313
lez is on a distinguished road
Guess what, still cant get it to work!

I've soldered wires on it and stuck them in the 18 pin socket, no use,
I have soldered them to the ISP connector, no use.

I tried this with a f88, worked, I soldered wires to a 877,
problematic but worked........

I think I'll just go on the web/ebay and see if I can buy a boot
loader programmed 2550 and dump this damn programmer..........

But........ if it can do a f88 and 877 its got to be working, so it must be the programmer software thats setting the programmer worng and/or a timing issue...

Oh how I hate this when I think of what I could have done with the day...
lez is offline   Reply With Quote
Old 11-01-2006, 08:02 AM   #7
MySQL Error
 
jcdillin's Avatar
 
Join Date: May 2003
Location: Miami, FL
Posts: 4,040
jcdillin is on a distinguished road
More than likely it's the programmer not setting the fuses correctly. I went through 2 programmers before I finally just purchased one due to them not setting fuses right.

What mhz are you trying to run it at?

Edit: Also is this with an external or internal osc?
__________________
肚子笑痛了
S60 Install

Last edited by jcdillin; 11-01-2006 at 08:04 AM.
jcdillin is offline   Reply With Quote
Old 11-01-2006, 08:30 AM   #8
lez
FLAC
 
lez's Avatar
 
Join Date: Jan 2004
Location: UK
Posts: 1,313
lez is on a distinguished road
ucces !

hey my caps s has gone, damn keyoard hates me now!

Ok it was the POs software from sivava, tried winpic800, set it to willem, programmed and verified on the first go.

tried original software, would not even read it back correctly, back to winpic, 5 for 5 programs and verifys (with a 2550 soldered to isp)

plugged my project/proto board back in, nothing, found out I must not have anything connect to rb7 when programming, it had a 2k rsistor and an led, same as all the rb's, can leave the one on rb6, but not rb7.

so I have your code in, but nothing flashes, maybe its fuses like you say.

I'm on a 16mhz tin box crystal, so when I have had a cuppa, and watched a film to chill out, i'll come back top this...........
lez is offline   Reply With Quote
Sponsored links
Advertisement
 
Advertisement
Old 11-01-2006, 09:01 AM   #9
MySQL Error
 
jcdillin's Avatar
 
Join Date: May 2003
Location: Miami, FL
Posts: 4,040
jcdillin is on a distinguished road
ditch the metal can osc, just go internal, the 2550 has a 8mhz internal osc, at least for testing purposes you can rule that out.
__________________
肚子笑痛了
S60 Install
jcdillin is offline   Reply With Quote
Old 11-01-2006, 04:43 PM   #10
lez
FLAC
 
lez's Avatar
 
Join Date: Jan 2004
Location: UK
Posts: 1,313
lez is on a distinguished road
Quote: Originally Posted by jcdillin View Post
ditch the metal can osc, just go internal, the 2550 has a 8mhz internal osc, at least for testing purposes you can rule that out.

Oooh thats good to know, one less part to buy when I build a few of these, I now have a working light flasher!

The programming problem was the software supplied with my programmer (a willem from sivava.com) was screwed, I tried winpic800, it worked first time and I have had a 10 for 10 program/verify result.

Then I tried to write my own led flasher, count 0 to 255 on the leds on port b, compile failed, seems I have some out of date include files, a bit of cut and paste fixed it but I dont think i2c has survived...not that I need it, at this stage...



So, thanks, I will try tomorro to shift my gsm-car-alarm over from the f88 to this pic so I can continue its development, I had ran out of IO pins and I also want the alarm to communicate back to the car PC.


inbuilt 8mhz you say...........
lez is offline   Reply With Quote
Old 11-01-2006, 04:48 PM   #11
MySQL Error
 
jcdillin's Avatar
 
Join Date: May 2003
Location: Miami, FL
Posts: 4,040
jcdillin is on a distinguished road
Quote: Originally Posted by lez View Post
inbuilt 8mhz you say...........


Yup comes in quite handy in keeping the parts count low.

Let me know if I can help further.
__________________
肚子笑痛了
S60 Install
jcdillin is offline   Reply With Quote
Old 11-02-2006, 03:16 PM   #12
lez
FLAC
 
lez's Avatar
 
Join Date: Jan 2004
Location: UK
Posts: 1,313
lez is on a distinguished road
have you done any coms with it, I ported the f88 code to it, only needed port register changes.

Anyhow, powered it up, all looked fine, plugged it onto the mobile phone, nothing from phone.

Plugged it into a serial/usb dongle, garbage.........

I dont have much of an answer for this as I'm using picbasic, its hard to get the commands wrong.........

Noticed it seems to run a little fast, got a 16mhz on it and a 'def osc 16' in the code so I'm puzzled.

I have noticed some programmer allows you set a divider in the fuses, makes me wonder if thats a clue.
lez is offline   Reply With Quote
Old 11-03-2006, 05:50 AM   #13
lez
FLAC
 
lez's Avatar
 
Join Date: Jan 2004
Location: UK
Posts: 1,313
lez is on a distinguished road
Fixed it, I have to set the fuses/config in the programmer software, it defaults to stupid pll /3 and osc/5

setting them to none and /4 works and I get good serial data again.

I suppose if I go with the internal clock then I'll have to set it to /2, but I dont know how stable that will be, early pics when on internal would drift a bit
lez is offline   Reply With Quote
Old 11-03-2006, 06:17 AM   #14
lez
FLAC
 
lez's Avatar
 
Join Date: Jan 2004
Location: UK
Posts: 1,313
lez is on a distinguished road
I mistyped this in a program ( I quickly wanted to blink an LED on portA)

high porta.1
pause 500
high porta.0
pause 500
high porta.1
pause 500
high porta.0
pause 500
high porta.1
pause 500
high porta.0
pause 500

See the problem, they all should be portA.0, so in theory the LED on PortA.1 should light, slight pause, then the LED on PortA.0 should light.

Ha, no it doesnt, well OK it does BUT the first led (on PortA.1) goes out, and instead of 2 leds being on, I get alternating leds ????

Ie

01
10
01
10

I expected

01
11
11
11

?? eh ??
lez is offline   Reply With Quote
Old 11-03-2006, 07:19 AM   #15
MySQL Error
 
jcdillin's Avatar
 
Join Date: May 2003
Location: Miami, FL
Posts: 4,040
jcdillin is on a distinguished road
thats really strange. I dont see how it's flashing back and forth with that code. Unless they are too high of a MA LED and it's overloading the port and shutting down.
__________________
肚子笑痛了
S60 Install
jcdillin is offline   Reply With Quote
Sponsored links
Advertisement
 
Advertisement
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
OBDII / Elm MPG meter. Almost working but not quite! stevieg Engine Management, OBD-II, Engine Diagnostics, etc. 105 08-19-2008 04:24 AM
TS working... not working... work... not... bulgogi777 General Hardware Discussion 28 01-11-2005 10:25 AM
AT&T Sierra Aircard 775 working on Mac OS X rsanchez28 Wireless Communications 0 11-21-2004 02:18 PM
All built and working, just one last problem...... Matthew230 Power Supplies 2 10-18-2004 05:02 PM
Got GPS 16 working tekknikal General Hardware Discussion 9 06-16-2002 07:55 PM



All times are GMT -5. The time now is 10:54 PM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.3.2
Copyright © 1999 - 2008 Mp3Car.com Inc.Ad Management by RedTyger
Message Board Statistics