Hehe, but.. will your PicProgrammer be able to program it ?
First, i wanted to post it in the USB section... But, Code Examples have to be post in the right section...
Hope you may use some part of it one day.
Bear in mind it's only a Demo and a 1-2 hours job.. yeah i count the beer, coffe and cigarette breaks, but remove those phone calls i got when doing it... always like that when you don't want to be disturbed![]()
Last edited by mister_e; - 2nd January 2007 at 01:43.
Steve
It's not a bug, it's a random feature.
There's no problem, only learning opportunities.
Mister_E,
I fart in your general direction ....
This is all your fault. I've been totally cosumed by this USB stuff for several days now. I've been so affraid of USB for so long. But after your example showed how easy it is, I've been locked in a never ending cycle of, "hmm, what else can I do with it".
Consequently, I've accomplished nothing else, "including going to work yesterday"
I haven't answered your ASM question in the other thread (or anyone elses), I haven't eaten much, and Sleep is a requirement that I would have rather done without (wish I could).
I'd like to say "Thank you for the great example", but it's ruining my life.
So instead I'll say ...
Thanks for the Mean, Vicious, Natsy, Brutal, Sadistic, yet Wonderfull piece's of code.
<br>
DT
Disclaimer
Mister E assume no responsibility for any addictions caused by the use of this actual thread, program, tutorial...
call it as you want.
Mister E don't want to be involve in any of your future or actual health, job and/or girlfriend/wife/boyfriend problem!
So use with care.
You read it, you use it... it's your problem what's happen next.
LMAO!
\_________________________________________________ ________________________________________________/
<table><tr><td></td><td>Well Darrel i'm really sorry (yeah right), but at the same time... i'm proud of me. At least you lost this USB fear! And i think, for once, i teached you something... ???
You know, I already said to few user here and there that PIC are addictive... i thought you took the advice... seems not... so
TOO BAD FOR YOU !</td></tr></table>
Now, go to sleep, eat and go back to work![]()
Last edited by mister_e; - 10th January 2007 at 06:09.
Steve
It's not a bug, it's a random feature.
There's no problem, only learning opportunities.
No kidding! I'm looking forward to reducing my sanity, food intake, sleepy time, and probably the wife soon after my 18F4550's arrive. So, if mister_e gets a call in the middle of the night from a screamin' female who he doesn't know, this thread is most definetly the reason why.
I wonder how long it'll take before he's on the 'Jerry Springer' show as the unseen homewrecker.
Thanks a lot...
May the demons of evil get confused on their way to your doorstep!![]()
No problem then, my phone number is not hidden anyway... But, LOL, maybe she will have to repeat few times and be patient when i will try to reply to her... yeah my english writing is bad... imagine how bad i talkSo, if mister_e gets a call in the middle of the night from a screamin' female who he doesn't know, this thread is most definetly the reason why.![]()
Steve
It's not a bug, it's a random feature.
There's no problem, only learning opportunities.
Hi Steve,
I'm revisting USB again and using parts of the demo as a bit of a refresher
Im writing a program where I want to send half a dozen NMEA strings (of varrying string length) which are stored in their own array, to the pc running hyperterminal.
I can send them successfully via USB using 6 separate DoUSBOut subroutines (without the SendUSB macro array code) but I want to trim my code down and use one (1) DoUSBOut routine to do the lot.
->>> I kinda have it working but the received data into hyperterminal appear as though some strings aren't received or are being over written or something.
I've modified the SendUSB macro array so that the USBBufferOut should just keep filling up according to my USBBufferCount (array size) and suspect this is the problem but I'm rusty on ASM. Perhaps the USBBufferOut needs to be "erased" after each visit to DoUSBOut? How would I do that?
I'm going blind looking at this code and wonder if you could see any traps I may have fallen into...
Code:USBBufferCount Var Byte ' USBBufferOut Var Byte[50] ' store outgoing USB data ...... this value originally [8] GPZDA VAR BYTE[28] GPGLL VAR BYTE[41] GPGGA VAR BYTE[49] GPVTG VAR BYTE[27] '...... arrays get filled up here......... '...... other code........ asm SendUSB macro array ; Use to Copy an specific array to USBBufferOut AND send it ; to USB bus variable i=0 ;while i<8 ' ...............original line here........ while i<_USBBufferCount MOVE?BB (array+i),(_USBBufferOut+i) i+=1 endw L?CALL _DoUSBOut endm endasm USBBufferCount = 28 @ SendUSB _GPZDA USBBufferCount = 41 @ SendUSB _GPGLL USBBufferCount = 49 @ SendUSB _GPGGA USBBufferCount = 27 @ SendUSB _GPVTG DoUSBOut: ' ' Send data to the USB bus & Wait for USB interface to attach ' =========================================================== T1CON.0 = 0 ' TURN OFF TIMER WaitPC: ' USBService ' keep connection alive USBOut 3, USBBufferOut, USBBufferCount, Waitpc ' if bus available, transmit data T1CON.0 = 1 ' Re-Enable TMR0 interrupt return
Last edited by Squibcakes; - 17th October 2007 at 08:30. Reason: Other thoughts....
Bookmarks