PDA

View Full Version : Help with, SEROUT



Kimto
- 28th March 2006, 16:54
I'm new on PICBASIC.
As I understand I can use the command SEROUT if I want to write a simple "Hello World" program and print to Hyperterminal.
Iīm using the PIC16F876. And downloading the code with PICBASIC-LAB 3.9.

Something like this: SEROUT 3,103,0,1,["Hello World",(0)]

So the problem is that I cant find what 103,0,1 stands for. Sometimes itīs 108,0,0 and so on.
How do I write a simple "Hello" that will show up on the Hyperterminal...?

Or is there limits so I must get PBP??
/K

Melanie
- 28th March 2006, 17:32
Kimto...

One of these answers is correct...

(a) these are just Random Numbers put in by programmers to make their program look impressive...

(b) These are important assignments for Port, Mode and other features that can be found in the SEROUT section in the PICBASIC MANUAL... go see...

Kimto
- 28th March 2006, 20:00
If you donīt have anything else to do than write stupid answers to newbies you should get something else to do!!
I have already checked the manual they have. (When itīs possible to download without missing pages??!!)
And yeah I found something in the manual but not what the figures stand for, thats why I came here. But there is maybe another forum for newbies..?? After all I think that everyone who asks a questions deserves a good answer. And hopefully as I did, I checked the manual first.. (or I checked the wrong manual.. but neverless I didnīt find the answer to my question)
So if someone else then Melanie can answer It would be great!

Melanie
- 29th March 2006, 03:11
I've checked that the documentation downloadable (in the Support Section) from the MeLabs website is full, complete and has no pages missing. And asking you to look in it where you will find a COMPREHENSIVE and detailed ANSWER to your question is a valid response and not 'stupid' at all. Newbie or Expert, you cannot program with PICBASIC or PICBASIC PRO without referring to the manual for the correct syntax and usage for any of the higher functions. The forum isn't a on-line Manual or Datasheet substitute.

Oh, and yeah, I do have better things to do... but be grateful that somebody gave up their time to try to kick your butt in looking in the right direction - and then if you don't understand what you read, come back and ask what you don't grasp about the concept of pin, or mode, or item. But until then, ask yourself why you don't have a manual, and go download for free or buy one!

Kimto
- 29th March 2006, 08:22
Ok. The manual I had was from Comfile.
So when the code says 1,103,0,1[] it canīt be a code for the mel-Pic.
Because they donīt use the code 103. Only 0-15..

Kimto
- 29th March 2006, 09:02
Ok, there is a big difference between "mel" and comfile. But now I now, what compiler I should have bought. I thought the code should be the same, when they use the same microcontroller.
Thanks for the reply.

Melanie
- 29th March 2006, 09:15
Do you have a Compiler currently? If you've bought something other than the MeLabs product then this isn't the place for you because the program syntax and functions will almost certainly be different and folks here will probably not be able to help. There's now a lot of compilers out for the PIC, some good, some bad and some really awful. I can't comment on how good Comfile is versus MeLabs because I don't know and have no experience of the product.

If you've already spent money on another product, then firstly you should consider a damage limitation excercise and give the other product a go (and see if they have a support forum) before thinking about buying something else. But, when considering MeLabs, it's been around for a long time, produces nice code, and it works - even for newbies! *smiles*