View previous topic :: View next topic |
Author |
Message |
MIKRO_MAN
Joined: 22 Jan 2015 Posts: 38
|
Posted: Fri Feb 12, 2016 12:39 pm Post subject: Re: 1 or 4 Mhz |
|
|
bzijlstra wrote: | From the factory the ATmega8 comes with its CKSEL fuses programmed for 1 Mhz.
What about your fusebit settings?
You got an atmega8 and a LED. Is it possible to write a small program to just blink the LED at an interval of 1 second?
And if you Print "AA" you are sending AA+CR+LF
If you just want to send "AA" you do a Print "AA";
Ben Zijlstra |
about fuse
-Did not try practically Simulations only
Print "AA"; ok but i need to print in software to specific pin like [ Print #6 , "AA" ;] [#6] // output pin define it soft
[Open "comd.6:9600,8,n,1" For Output As #6]
whai is CR+LF mean ??how can i neglect it software[/quote] |
|
Back to top |
|
|
Duval JP
Joined: 22 Jun 2004 Posts: 1161 Location: France
|
Posted: Fri Feb 12, 2016 3:48 pm Post subject: |
|
|
From my school : 46 years old !
ASCII code 0 à 27 for serial use THOSE CHARACTERS ARE NOT PRINT OR DISPLAYED !
Note 0, 10 and 13 and 27
Code ASCII
0 Null
is not nothing ! you can send a chr(0) 'null
1 SOH
start of head
2 STX
start of text
3 ETX
end of tex
4 EOT
end of transmission
5 ENQ Who are you ?
6 ACK
Acknoledge
7 BEL
ring
8 BS
back slash 1 lettre en arrière
9 HT 1lettre en avant
10 LF
Line feed (avance d'une ligne)
11 VT
Vertical Tabulation
12 FF
Start new page 'début prochaine page
13 CR
(Carriage Return) retour chariot -à la ligne
17 DC1 XON
18 DC2 Contrôle dispo 2
19 DC3 XOFF
20 DC4 Contrôle dispo 4
21 NAK Bad reception Mal reçu
22 SYN
23 ETB Reçu? J'attends
24 CAN Annulé
25 EM
26 SUB End of file 'Fin de fichier
27 ESC
JP |
|
Back to top |
|
|
bzijlstra
Joined: 30 Dec 2004 Posts: 1179 Location: Tilburg - Netherlands
|
Posted: Fri Feb 12, 2016 4:54 pm Post subject: Inkey only 1 character |
|
|
Dim value as string * 6
Value = inkey(#6)
Value gets only one character.
So it will never get "AA"
If you realy studied the weatherstation code you will notice that I use a buffer and with an INSTR check if the keywords pass by.
There is nothing wrong with your hardware.what is missing is a good crystal to get a correct baudrate.
At the start you mentioned things are working on single characters, so this must be the error.
Have fun
Ben Zijlstra |
|
Back to top |
|
|
aphawk
Joined: 23 Jan 2010 Posts: 168 Location: Brazil
|
Posted: Sat Feb 13, 2016 2:40 am Post subject: |
|
|
Hi Duval,
Well, many of us in this Forum have more than 50 years.... And we have worked sometimes witm modens and serial rs232 communications. I have worked with Apple ][ videotext in ASM , and have pained with the Hardware 1200 /75 bps communications and Videotext protocol here at Brazil.
I see all values you have posted for the Ascii code, and think .... today most schools don't teach this anymore !
What you ( and many of us ) think that is obvius, maybe is not so obvius because the learning today is focused in others communications types, like Rs422 and others.
Seeing this topic leaves me to think that we are like dinossaurs in the 20 century..... All our knowledge is useless to the new generation..... At least this is what the "new generation engineers" thinks....
If we tell something like 7 bits / even parity / 2 stop bits many people will think that we are crazy ! And if we mentioned something like the Baudot code , they will call the Mental Care to take us !!!
This topic is strange because only the old peoples understand that we cant have an "55AA" using the normal commands. We need to read two bytes and join the values !
Making the "new generation" people understand this is not an easy task !
Paulo |
|
Back to top |
|
|
Duval JP
Joined: 22 Jun 2004 Posts: 1161 Location: France
|
Posted: Sat Feb 13, 2016 6:28 pm Post subject: |
|
|
thanks for your post Paulo,
É o velho panelas que fazemos os melhores doces I hope Bing translator work well !
Jean-Pierre |
|
Back to top |
|
|
|