Thread: [Flashforth-devel] strange answer from UART
Brought to you by:
oh2aun
From: Thomas B. <bus...@gm...> - 2014-03-17 07:32:14
|
Dear Mikael and mailing listeners, I desperated, I got some strange signs back from the PIC. In my despair - I installed even MS Windows, to see whether my usb-2-serial adapter is broken - but the program "Hyperterminal" shows the same results. Here is my configuration: PIC18F2620 4 MHz Oscillator Link to Oszillator<http://www.reichelt.de/Oszillatoren/OSZI-4-000000/3//index.html?ACTION=3&GROUPID=3174&ARTICLE=13706&SHOW=1&OFFSET=500&> MAX232 FD-USB2Serial-Adapter The programing - process runs well with my PICKIT2. When the PIC gets power its send the same strange signs, and if I blind input "1 2 3" (to the stack) in the terminal, I got a answer - that could be the right one. --snip-- 38400 - 8 - N - 1 ¦¬¡³¸¦¯²´¨ •ް °©£±˜ Š Š‘ ¦¬¡³¸¦¯²´¨ •ް °©£±˜ Š Š‘ ¦¬¡³¨¦¯²´¸ •ް °©£‘¸ Š Š‘ ± ² ³ ± ² ³ Ÿ Š --snip-- Here I restart 3 times the PIC and input "1 2 3" and get back "± ² ³ Ÿ Š". I changed the baudrate, oszillator frequency, the oscillator selection bits - without success. I hope I do some configuration mistakes, so please help me. The schematics for my hw-configuration, the (binary) log-file of the terminal and my changed configurations-files you can find here as zip file. http://wikisend.com/download/262322/pic.zip If you need more informations, please drop me a mail. Greetings Thomas |
From: Herman A. <exp...@vn...> - 2014-03-17 08:33:46
|
Hi Thomas, Maybe your problem comes from low Osc-frequency/baudrate ratio. Using 4MHz osc freq. the controller generates the 38400kbs with 10% error. Try to use higher osc freq. or lower baudrate. Otherwise I recommend you to use 18F26K22 or other xxk22 controllers. They have well configurable internal oscillator and have several further excellent features. BR Attila ----- Eredeti üzenet ----- Feladó: Thomas Buschhardt <bus...@gm...> Dátum: Hétfő, Március 17, 2014 8:32 Tárgy: [Flashforth-devel] strange answer from UART Címzett: Fla...@li... > Dear Mikael and mailing listeners, > > I desperated, I got some strange signs back from the PIC. In my > despair - I > installed even MS Windows, to see whether my usb-2-serial adapter is broken > - but the program "Hyperterminal" shows the same results. > > Here is my configuration: > > PIC18F2620 > 4 MHz Oscillator Link to > Oszillator<> > MAX232 > FD-USB2Serial-Adapter > > The programing - process runs well with my PICKIT2. When the PIC gets > power > its send the same strange signs, and if I blind input "1 2 3" (to the > stack) in the terminal, I got a answer - that could be the right one. > --snip-- > 38400 - 8 - N - 1 > ¦¬¡³¸¦¯²´¨ •ް °©£±˜ Š Š‘ > ¦¬¡³¸¦¯²´¨ •ް °©£±˜ Š Š‘ > ¦¬¡³¨¦¯²´¸ •ް °©£‘¸ Š Š‘ > ± ² ³ ± ² ³ Ÿ Š > --snip-- > Here I restart 3 times the PIC and input "1 2 3" and get back "± ² ³ Ÿ > Š". > > I changed the baudrate, oszillator frequency, the oscillator selection > bits > - without success. > I hope I do some configuration mistakes, so please help me. > > The schematics for my hw-configuration, the (binary) log-file of the > terminal and my changed configurations-files you can find here as zip > file. > > > > > If you need more informations, please drop me a mail. > > Greetings Thomas > ------------------------------------------------------------------------------ > Learn Graph Databases - Download FREE O'Reilly Book > "Graph Databases" is the definitive new guide to graph databases and their > applications. Written by three acclaimed leaders in the field, > this first edition is now available. Download your free book today! > > _______________________________________________ > Flashforth-devel mailing list > Fla...@li... > |
From: Mikael N. <mik...@pp...> - 2014-03-17 09:05:37
|
Hi, I think 9600 baud should work. Mikael On 17.03.2014 10:33, Herman Attila wrote: > Hi Thomas, > > Maybe your problem comes from low Osc-frequency/baudrate ratio. Using 4MHz osc freq. the controller generates the 38400kbs with 10% error. Try to use higher osc freq. or lower baudrate. Otherwise I recommend you to use 18F26K22 or other xxk22 controllers. They have well configurable internal oscillator and have several further excellent features. > > BR > Attila > > ----- Eredeti üzenet ----- > Feladó: Thomas Buschhardt <bus...@gm...> > Dátum: Hétfő, Március 17, 2014 8:32 > Tárgy: [Flashforth-devel] strange answer from UART > Címzett: Fla...@li... > > >> Dear Mikael and mailing listeners, >> >> I desperated, I got some strange signs back from the PIC. In my >> despair - I >> installed even MS Windows, to see whether my usb-2-serial adapter is broken >> - but the program "Hyperterminal" shows the same results. >> >> Here is my configuration: >> >> PIC18F2620 >> 4 MHz Oscillator Link to >> Oszillator<> >> MAX232 >> FD-USB2Serial-Adapter >> >> The programing - process runs well with my PICKIT2. When the PIC gets >> power >> its send the same strange signs, and if I blind input "1 2 3" (to the >> stack) in the terminal, I got a answer - that could be the right one. >> --snip-- >> 38400 - 8 - N - 1 >> ¦¬¡³¸¦¯²´¨ •ް °©£±˜ Š Š‘ >> ¦¬¡³¸¦¯²´¨ •ް °©£±˜ Š Š‘ >> ¦¬¡³¨¦¯²´¸ •ް °©£‘¸ Š Š‘ >> ± ² ³ ± ² ³ Ÿ Š >> --snip-- >> Here I restart 3 times the PIC and input "1 2 3" and get back "± ² ³ Ÿ >> Š". >> >> I changed the baudrate, oszillator frequency, the oscillator selection >> bits >> - without success. >> I hope I do some configuration mistakes, so please help me. >> >> The schematics for my hw-configuration, the (binary) log-file of the >> terminal and my changed configurations-files you can find here as zip >> file. >> >> >> >> >> If you need more informations, please drop me a mail. >> >> Greetings Thomas >> ------------------------------------------------------------------------------ >> Learn Graph Databases - Download FREE O'Reilly Book >> "Graph Databases" is the definitive new guide to graph databases and their >> applications. Written by three acclaimed leaders in the field, >> this first edition is now available. Download your free book today! >> >> _______________________________________________ >> Flashforth-devel mailing list >> Fla...@li... >> > ------------------------------------------------------------------------------ > Learn Graph Databases - Download FREE O'Reilly Book > "Graph Databases" is the definitive new guide to graph databases and their > applications. Written by three acclaimed leaders in the field, > this first edition is now available. Download your free book today! > http://p.sf.net/sfu/13534_NeoTech > _______________________________________________ > Flashforth-devel mailing list > Fla...@li... > https://lists.sourceforge.net/lists/listinfo/flashforth-devel |
From: Thomas B. <bus...@gm...> - 2014-03-17 11:25:20
|
Dear Peter, is HSPLL actually for crytals and resonators? I use a oszillator (clock) see link in the first mail. But of course this evening I'll give it a try. Thomas 2014-03-17 11:54 GMT+01:00 Peter Jacobs <pe...@me...>: > Can you simply turn on the PLL (OSC = HSPLL) to get a 16MHz sys-clock > frequency? I've quite happily run a PIC18F2520 at 38400 baud with a > 4MHz crystal and the PLL active. > Peter J. > > > On 17/03/14 18:33, Herman Attila wrote: > > Hi Thomas, > > > > Maybe your problem comes from low Osc-frequency/baudrate ratio. Using > 4MHz osc freq. the controller generates the 38400kbs with 10% error. Try to > use higher osc freq. or lower baudrate. Otherwise I recommend you to use > 18F26K22 or other xxk22 controllers. They have well configurable internal > oscillator and have several further excellent features. > > > > BR > > Attila > > > > ----- Eredeti üzenet ----- > > Feladó: Thomas Buschhardt <bus...@gm...> > > Dátum: Hétfő, Március 17, 2014 8:32 > > Tárgy: [Flashforth-devel] strange answer from UART > > Címzett: Fla...@li... > > > > > >> Dear Mikael and mailing listeners, > >> > >> I desperated, I got some strange signs back from the PIC. In my > >> despair - I > >> installed even MS Windows, to see whether my usb-2-serial adapter is > broken > >> - but the program "Hyperterminal" shows the same results. > >> > >> Here is my configuration: > >> > >> PIC18F2620 > >> 4 MHz Oscillator Link to > >> Oszillator<> > >> MAX232 > >> FD-USB2Serial-Adapter > >> > >> The programing - process runs well with my PICKIT2. When the PIC gets > >> power > >> its send the same strange signs, and if I blind input "1 2 3" (to the > >> stack) in the terminal, I got a answer - that could be the right one. > >> --snip-- > >> 38400 - 8 - N - 1 > >> ¦¬¡³¸¦¯²´¨ •ް °©£±˜ Š Š‘ > >> ¦¬¡³¸¦¯²´¨ •ް °©£±˜ Š Š‘ > >> ¦¬¡³¨¦¯²´¸ •ް °©£‘¸ Š Š‘ > >> ± ² ³ ± ² ³ Ÿ Š > >> --snip-- > >> Here I restart 3 times the PIC and input "1 2 3" and get back "± ² ³ Ÿ > >> Š". > >> > >> I changed the baudrate, oszillator frequency, the oscillator selection > >> bits > >> - without success. > >> I hope I do some configuration mistakes, so please help me. > >> > >> The schematics for my hw-configuration, the (binary) log-file of the > >> terminal and my changed configurations-files you can find here as zip > >> file. > >> > >> > >> > >> > >> If you need more informations, please drop me a mail. > >> > >> Greetings Thomas > >> > ------------------------------------------------------------------------------ > >> Learn Graph Databases - Download FREE O'Reilly Book > >> "Graph Databases" is the definitive new guide to graph databases and > their > >> applications. Written by three acclaimed leaders in the field, > >> this first edition is now available. Download your free book today! > >> > >> _______________________________________________ > >> Flashforth-devel mailing list > >> Fla...@li... > >> > > > ------------------------------------------------------------------------------ > > Learn Graph Databases - Download FREE O'Reilly Book > > "Graph Databases" is the definitive new guide to graph databases and > their > > applications. Written by three acclaimed leaders in the field, > > this first edition is now available. Download your free book today! > > http://p.sf.net/sfu/13534_NeoTech > > _______________________________________________ > > Flashforth-devel mailing list > > Fla...@li... > > https://lists.sourceforge.net/lists/listinfo/flashforth-devel > > > > ------------------------------------------------------------------------------ > Learn Graph Databases - Download FREE O'Reilly Book > "Graph Databases" is the definitive new guide to graph databases and their > applications. Written by three acclaimed leaders in the field, > this first edition is now available. Download your free book today! > http://p.sf.net/sfu/13534_NeoTech > _______________________________________________ > Flashforth-devel mailing list > Fla...@li... > https://lists.sourceforge.net/lists/listinfo/flashforth-devel > -- www.aloedb.org - database for aloes |
From: Thomas B. <bus...@gm...> - 2014-03-17 16:14:13
|
Hallo now I was able to run it :-) Here are my tested configs OSC - Baud = Status ----------------------------------- ECIO6 - 9600 = working ECIO6 - 14400 = not working ECIO6 - 38400 = not working INTIO7 - 9600 = not working (without oszi) INTIO67 - 9600 = not working (without oszi) HSPLL - 9600 = not working HSPLL - 38400 = not working Thank you all very much Thomas 2014-03-17 13:03 GMT+01:00 Peter Jacobs <pe...@me...>: > Thomas, > Looking at sections 2.x in the datasheet, it seems to me that the PLL is > not exclusively for crystals and resonators; it available to the 4 and 8MHz > internal oscillator. Figure 2.8 shows it limited to these options. That > figure is (presumably) a simplified diagram and I don't know enough to be > sure what would happen if you set OSC=HSPLL and drive the OSC1 pin with > your external oscillator. Would you be abusing the silicon? You wouldn't > be able to use RA6 as an IO pin but that might be OK since you don't show > it in use on your diagram. > Peter J. > > > > On 17/03/14 21:25, Thomas Buschhardt wrote: > > Dear Peter, is HSPLL actually for crytals and resonators? I use a > oszillator (clock) see link in the first mail. But of course this evening > I'll give it a try. > Thomas > > > 2014-03-17 11:54 GMT+01:00 Peter Jacobs <pe...@me...>: > >> Can you simply turn on the PLL (OSC = HSPLL) to get a 16MHz sys-clock >> frequency? I've quite happily run a PIC18F2520 at 38400 baud with a >> 4MHz crystal and the PLL active. >> Peter J. >> >> >> On 17/03/14 18:33, Herman Attila wrote: >> > Hi Thomas, >> > >> > Maybe your problem comes from low Osc-frequency/baudrate ratio. Using >> 4MHz osc freq. the controller generates the 38400kbs with 10% error. Try to >> use higher osc freq. or lower baudrate. Otherwise I recommend you to use >> 18F26K22 or other xxk22 controllers. They have well configurable internal >> oscillator and have several further excellent features. >> > >> > BR >> > Attila >> > >> > ----- Eredeti üzenet ----- >> > Feladó: Thomas Buschhardt <bus...@gm...> >> > Dátum: Hétfő, Március 17, 2014 8:32 >> > Tárgy: [Flashforth-devel] strange answer from UART >> > Címzett: Fla...@li... >> > >> > >> >> Dear Mikael and mailing listeners, >> >> >> >> I desperated, I got some strange signs back from the PIC. In my >> >> despair - I >> >> installed even MS Windows, to see whether my usb-2-serial adapter is >> broken >> >> - but the program "Hyperterminal" shows the same results. >> >> >> >> Here is my configuration: >> >> >> >> PIC18F2620 >> >> 4 MHz Oscillator Link to >> >> Oszillator<> >> >> MAX232 >> >> FD-USB2Serial-Adapter >> >> >> >> The programing - process runs well with my PICKIT2. When the PIC gets >> >> power >> >> its send the same strange signs, and if I blind input "1 2 3" (to the >> >> stack) in the terminal, I got a answer - that could be the right one. >> >> --snip-- >> >> 38400 - 8 - N - 1 >> >> ¦¬¡³¸¦¯²´¨ •ް °©£±˜ Š Š‘ >> >> ¦¬¡³¸¦¯²´¨ •ް °©£±˜ Š Š‘ >> >> ¦¬¡³¨¦¯²´¸ •ް °©£‘¸ Š Š‘ >> >> ± ² ³ ± ² ³ Ÿ Š >> >> --snip-- >> >> Here I restart 3 times the PIC and input "1 2 3" and get back "± ² ³ Ÿ >> >> Š". >> >> >> >> I changed the baudrate, oszillator frequency, the oscillator selection >> >> bits >> >> - without success. >> >> I hope I do some configuration mistakes, so please help me. >> >> >> >> The schematics for my hw-configuration, the (binary) log-file of the >> >> terminal and my changed configurations-files you can find here as zip >> >> file. >> >> >> >> >> >> >> >> >> >> If you need more informations, please drop me a mail. >> >> >> >> Greetings Thomas >> >> >> ------------------------------------------------------------------------------ >> >> Learn Graph Databases - Download FREE O'Reilly Book >> >> "Graph Databases" is the definitive new guide to graph databases and >> their >> >> applications. Written by three acclaimed leaders in the field, >> >> this first edition is now available. Download your free book today! >> >> >> >> _______________________________________________ >> >> Flashforth-devel mailing list >> >> Fla...@li... >> >> >> > >> ------------------------------------------------------------------------------ >> > Learn Graph Databases - Download FREE O'Reilly Book >> > "Graph Databases" is the definitive new guide to graph databases and >> their >> > applications. Written by three acclaimed leaders in the field, >> > this first edition is now available. Download your free book today! >> > http://p.sf.net/sfu/13534_NeoTech >> > _______________________________________________ >> > Flashforth-devel mailing list >> > Fla...@li... >> > https://lists.sourceforge.net/lists/listinfo/flashforth-devel >> >> >> >> ------------------------------------------------------------------------------ >> Learn Graph Databases - Download FREE O'Reilly Book >> "Graph Databases" is the definitive new guide to graph databases and their >> applications. Written by three acclaimed leaders in the field, >> this first edition is now available. Download your free book today! >> http://p.sf.net/sfu/13534_NeoTech >> _______________________________________________ >> Flashforth-devel mailing list >> Fla...@li... >> https://lists.sourceforge.net/lists/listinfo/flashforth-devel >> > > > > -- > www.aloedb.org - database for aloes > > > > > ------------------------------------------------------------------------------ > Learn Graph Databases - Download FREE O'Reilly Book > "Graph Databases" is the definitive new guide to graph databases and their > applications. Written by three acclaimed leaders in the field, > this first edition is now available. Download your free book today! > http://p.sf.net/sfu/13534_NeoTech > _______________________________________________ > Flashforth-devel mailing list > Fla...@li... > https://lists.sourceforge.net/lists/listinfo/flashforth-devel > > -- www.aloedb.org - database for aloes |
From: Peter J. <pe...@me...> - 2014-03-17 10:54:35
|
Can you simply turn on the PLL (OSC = HSPLL) to get a 16MHz sys-clock frequency? I've quite happily run a PIC18F2520 at 38400 baud with a 4MHz crystal and the PLL active. Peter J. On 17/03/14 18:33, Herman Attila wrote: > Hi Thomas, > > Maybe your problem comes from low Osc-frequency/baudrate ratio. Using 4MHz osc freq. the controller generates the 38400kbs with 10% error. Try to use higher osc freq. or lower baudrate. Otherwise I recommend you to use 18F26K22 or other xxk22 controllers. They have well configurable internal oscillator and have several further excellent features. > > BR > Attila > > ----- Eredeti üzenet ----- > Feladó: Thomas Buschhardt <bus...@gm...> > Dátum: Hétfő, Március 17, 2014 8:32 > Tárgy: [Flashforth-devel] strange answer from UART > Címzett: Fla...@li... > > >> Dear Mikael and mailing listeners, >> >> I desperated, I got some strange signs back from the PIC. In my >> despair - I >> installed even MS Windows, to see whether my usb-2-serial adapter is broken >> - but the program "Hyperterminal" shows the same results. >> >> Here is my configuration: >> >> PIC18F2620 >> 4 MHz Oscillator Link to >> Oszillator<> >> MAX232 >> FD-USB2Serial-Adapter >> >> The programing - process runs well with my PICKIT2. When the PIC gets >> power >> its send the same strange signs, and if I blind input "1 2 3" (to the >> stack) in the terminal, I got a answer - that could be the right one. >> --snip-- >> 38400 - 8 - N - 1 >> ¦¬¡³¸¦¯²´¨ •ް °©£±˜ Š Š‘ >> ¦¬¡³¸¦¯²´¨ •ް °©£±˜ Š Š‘ >> ¦¬¡³¨¦¯²´¸ •ް °©£‘¸ Š Š‘ >> ± ² ³ ± ² ³ Ÿ Š >> --snip-- >> Here I restart 3 times the PIC and input "1 2 3" and get back "± ² ³ Ÿ >> Š". >> >> I changed the baudrate, oszillator frequency, the oscillator selection >> bits >> - without success. >> I hope I do some configuration mistakes, so please help me. >> >> The schematics for my hw-configuration, the (binary) log-file of the >> terminal and my changed configurations-files you can find here as zip >> file. >> >> >> >> >> If you need more informations, please drop me a mail. >> >> Greetings Thomas >> ------------------------------------------------------------------------------ >> Learn Graph Databases - Download FREE O'Reilly Book >> "Graph Databases" is the definitive new guide to graph databases and their >> applications. Written by three acclaimed leaders in the field, >> this first edition is now available. Download your free book today! >> >> _______________________________________________ >> Flashforth-devel mailing list >> Fla...@li... >> > ------------------------------------------------------------------------------ > Learn Graph Databases - Download FREE O'Reilly Book > "Graph Databases" is the definitive new guide to graph databases and their > applications. Written by three acclaimed leaders in the field, > this first edition is now available. Download your free book today! > http://p.sf.net/sfu/13534_NeoTech > _______________________________________________ > Flashforth-devel mailing list > Fla...@li... > https://lists.sourceforge.net/lists/listinfo/flashforth-devel |
From: Peter J. <pe...@me...> - 2014-03-17 12:04:03
|
Thomas, Looking at sections 2.x in the datasheet, it seems to me that the PLL is not exclusively for crystals and resonators; it available to the 4 and 8MHz internal oscillator. Figure 2.8 shows it limited to these options. That figure is (presumably) a simplified diagram and I don't know enough to be sure what would happen if you set OSC=HSPLL and drive the OSC1 pin with your external oscillator. Would you be abusing the silicon? You wouldn't be able to use RA6 as an IO pin but that might be OK since you don't show it in use on your diagram. Peter J. On 17/03/14 21:25, Thomas Buschhardt wrote: > Dear Peter, is HSPLL actually for crytals and resonators? I use a > oszillator (clock) see link in the first mail. But of course this > evening I'll give it a try. > Thomas > > > 2014-03-17 11:54 GMT+01:00 Peter Jacobs <pe...@me... > <mailto:pe...@me...>>: > > Can you simply turn on the PLL (OSC = HSPLL) to get a 16MHz sys-clock > frequency? I've quite happily run a PIC18F2520 at 38400 baud with a > 4MHz crystal and the PLL active. > Peter J. > > > On 17/03/14 18:33, Herman Attila wrote: > > Hi Thomas, > > > > Maybe your problem comes from low Osc-frequency/baudrate ratio. > Using 4MHz osc freq. the controller generates the 38400kbs with > 10% error. Try to use higher osc freq. or lower baudrate. > Otherwise I recommend you to use 18F26K22 or other xxk22 > controllers. They have well configurable internal oscillator and > have several further excellent features. > > > > BR > > Attila > > > > ----- Eredeti üzenet ----- > > Feladó: Thomas Buschhardt <bus...@gm... > <mailto:bus...@gm...>> > > Dátum: Hétfo", Március 17, 2014 8:32 > > Tárgy: [Flashforth-devel] strange answer from UART > > Címzett: Fla...@li... > <mailto:Fla...@li...> > > > > > >> Dear Mikael and mailing listeners, > >> > >> I desperated, I got some strange signs back from the PIC. In my > >> despair - I > >> installed even MS Windows, to see whether my usb-2-serial > adapter is broken > >> - but the program "Hyperterminal" shows the same results. > >> > >> Here is my configuration: > >> > >> PIC18F2620 > >> 4 MHz Oscillator Link to > >> Oszillator<> > >> MAX232 > >> FD-USB2Serial-Adapter > >> > >> The programing - process runs well with my PICKIT2. When the > PIC gets > >> power > >> its send the same strange signs, and if I blind input "1 2 3" > (to the > >> stack) in the terminal, I got a answer - that could be the > right one. > >> --snip-- > >> 38400 - 8 - N - 1 > >> ¦¬¡³¸¦¯²´¨ .Z(° °©£±~ S( S(' > >> ¦¬¡³¸¦¯²´¨ .Z(° °©£±~ S( S(' > >> ¦¬¡³¨¦¯²´¸ .Z(° °©£'¸ S( S(' > >> ± ² ³ ± ² ³ Y" S( > >> --snip-- > >> Here I restart 3 times the PIC and input "1 2 3" and get back > "± ² ³ Y" > >> S(". > >> > >> I changed the baudrate, oszillator frequency, the oscillator > selection > >> bits > >> - without success. > >> I hope I do some configuration mistakes, so please help me. > >> > >> The schematics for my hw-configuration, the (binary) log-file > of the > >> terminal and my changed configurations-files you can find here > as zip > >> file. > >> > >> > >> > >> > >> If you need more informations, please drop me a mail. > >> > >> Greetings Thomas > >> > ------------------------------------------------------------------------------ > >> Learn Graph Databases - Download FREE O'Reilly Book > >> "Graph Databases" is the definitive new guide to graph > databases and their > >> applications. Written by three acclaimed leaders in the field, > >> this first edition is now available. Download your free book today! > >> > >> _______________________________________________ > >> Flashforth-devel mailing list > >> Fla...@li... > <mailto:Fla...@li...> > >> > > > ------------------------------------------------------------------------------ > > Learn Graph Databases - Download FREE O'Reilly Book > > "Graph Databases" is the definitive new guide to graph databases > and their > > applications. Written by three acclaimed leaders in the field, > > this first edition is now available. Download your free book today! > > http://p.sf.net/sfu/13534_NeoTech > > _______________________________________________ > > Flashforth-devel mailing list > > Fla...@li... > <mailto:Fla...@li...> > > https://lists.sourceforge.net/lists/listinfo/flashforth-devel > > > ------------------------------------------------------------------------------ > Learn Graph Databases - Download FREE O'Reilly Book > "Graph Databases" is the definitive new guide to graph databases > and their > applications. Written by three acclaimed leaders in the field, > this first edition is now available. Download your free book today! > http://p.sf.net/sfu/13534_NeoTech > _______________________________________________ > Flashforth-devel mailing list > Fla...@li... > <mailto:Fla...@li...> > https://lists.sourceforge.net/lists/listinfo/flashforth-devel > > > > > -- > www.aloedb.org <http://www.aloedb.org> - database for aloes |
From: Thomas B. <bus...@gm...> - 2014-03-17 16:17:54
|
Hallo Peter, in the figure 2-7 of the datasheet http://ww1.microchip.com/downloads/en/DeviceDoc/39626b.pdf both osc-pins are connected. Cheers big ears Thomas 2014-03-17 13:03 GMT+01:00 Peter Jacobs <pe...@me...>: > Thomas, > Looking at sections 2.x in the datasheet, it seems to me that the PLL is > not exclusively for crystals and resonators; it available to the 4 and 8MHz > internal oscillator. Figure 2.8 shows it limited to these options. That > figure is (presumably) a simplified diagram and I don't know enough to be > sure what would happen if you set OSC=HSPLL and drive the OSC1 pin with > your external oscillator. Would you be abusing the silicon? You wouldn't > be able to use RA6 as an IO pin but that might be OK since you don't show > it in use on your diagram. > Peter J. > > > > On 17/03/14 21:25, Thomas Buschhardt wrote: > > Dear Peter, is HSPLL actually for crytals and resonators? I use a > oszillator (clock) see link in the first mail. But of course this evening > I'll give it a try. > Thomas > > > 2014-03-17 11:54 GMT+01:00 Peter Jacobs <pe...@me...>: > >> Can you simply turn on the PLL (OSC = HSPLL) to get a 16MHz sys-clock >> frequency? I've quite happily run a PIC18F2520 at 38400 baud with a >> 4MHz crystal and the PLL active. >> Peter J. >> >> >> On 17/03/14 18:33, Herman Attila wrote: >> > Hi Thomas, >> > >> > Maybe your problem comes from low Osc-frequency/baudrate ratio. Using >> 4MHz osc freq. the controller generates the 38400kbs with 10% error. Try to >> use higher osc freq. or lower baudrate. Otherwise I recommend you to use >> 18F26K22 or other xxk22 controllers. They have well configurable internal >> oscillator and have several further excellent features. >> > >> > BR >> > Attila >> > >> > ----- Eredeti üzenet ----- >> > Feladó: Thomas Buschhardt <bus...@gm...> >> > Dátum: Hétfő, Március 17, 2014 8:32 >> > Tárgy: [Flashforth-devel] strange answer from UART >> > Címzett: Fla...@li... >> > >> > >> >> Dear Mikael and mailing listeners, >> >> >> >> I desperated, I got some strange signs back from the PIC. In my >> >> despair - I >> >> installed even MS Windows, to see whether my usb-2-serial adapter is >> broken >> >> - but the program "Hyperterminal" shows the same results. >> >> >> >> Here is my configuration: >> >> >> >> PIC18F2620 >> >> 4 MHz Oscillator Link to >> >> Oszillator<> >> >> MAX232 >> >> FD-USB2Serial-Adapter >> >> >> >> The programing - process runs well with my PICKIT2. When the PIC gets >> >> power >> >> its send the same strange signs, and if I blind input "1 2 3" (to the >> >> stack) in the terminal, I got a answer - that could be the right one. >> >> --snip-- >> >> 38400 - 8 - N - 1 >> >> ¦¬¡³¸¦¯²´¨ •ް °©£±˜ Š Š‘ >> >> ¦¬¡³¸¦¯²´¨ •ް °©£±˜ Š Š‘ >> >> ¦¬¡³¨¦¯²´¸ •ް °©£‘¸ Š Š‘ >> >> ± ² ³ ± ² ³ Ÿ Š >> >> --snip-- >> >> Here I restart 3 times the PIC and input "1 2 3" and get back "± ² ³ Ÿ >> >> Š". >> >> >> >> I changed the baudrate, oszillator frequency, the oscillator selection >> >> bits >> >> - without success. >> >> I hope I do some configuration mistakes, so please help me. >> >> >> >> The schematics for my hw-configuration, the (binary) log-file of the >> >> terminal and my changed configurations-files you can find here as zip >> >> file. >> >> >> >> >> >> >> >> >> >> If you need more informations, please drop me a mail. >> >> >> >> Greetings Thomas >> >> >> ------------------------------------------------------------------------------ >> >> Learn Graph Databases - Download FREE O'Reilly Book >> >> "Graph Databases" is the definitive new guide to graph databases and >> their >> >> applications. Written by three acclaimed leaders in the field, >> >> this first edition is now available. Download your free book today! >> >> >> >> _______________________________________________ >> >> Flashforth-devel mailing list >> >> Fla...@li... >> >> >> > >> ------------------------------------------------------------------------------ >> > Learn Graph Databases - Download FREE O'Reilly Book >> > "Graph Databases" is the definitive new guide to graph databases and >> their >> > applications. Written by three acclaimed leaders in the field, >> > this first edition is now available. Download your free book today! >> > http://p.sf.net/sfu/13534_NeoTech >> > _______________________________________________ >> > Flashforth-devel mailing list >> > Fla...@li... >> > https://lists.sourceforge.net/lists/listinfo/flashforth-devel >> >> >> >> ------------------------------------------------------------------------------ >> Learn Graph Databases - Download FREE O'Reilly Book >> "Graph Databases" is the definitive new guide to graph databases and their >> applications. Written by three acclaimed leaders in the field, >> this first edition is now available. Download your free book today! >> http://p.sf.net/sfu/13534_NeoTech >> _______________________________________________ >> Flashforth-devel mailing list >> Fla...@li... >> https://lists.sourceforge.net/lists/listinfo/flashforth-devel >> > > > > -- > www.aloedb.org - database for aloes > > > > > ------------------------------------------------------------------------------ > Learn Graph Databases - Download FREE O'Reilly Book > "Graph Databases" is the definitive new guide to graph databases and their > applications. Written by three acclaimed leaders in the field, > this first edition is now available. Download your free book today! > http://p.sf.net/sfu/13534_NeoTech > _______________________________________________ > Flashforth-devel mailing list > Fla...@li... > https://lists.sourceforge.net/lists/listinfo/flashforth-devel > > -- www.aloedb.org - database for aloes |
From: Mikael N. <mik...@pp...> - 2014-03-17 18:25:00
|
Hello ! With the 4 MHz external clock the following should work: HSPLL , 9600 , constant clock=d'16000000' HSPLL , 38400 , constant clock=d'16000000' FlashForth always configures the internal clock to run at 8 MHz. With the internal oscillator the following should work. INTIO67 , 9600, constant clock=d'8000000' The INTIO67 with PLL requires that the PLL is enabled in software. There is a define missing in the processor configuration file for that. The INTIO67 with PLL requires that you define in p18f2525-2620-4525-4620.cfg ;;; Activate 4xPLL from SW for INTOSC modes in FlashForth 5.0 #define PLL ENABLE ; ENABLE or DISABLE and then these should also work INTIO67 , 9600 , constant clock=d'32000000' INTIO67 , 38400 , constant clock=d'32000000' BR Mike On 03/17/2014 06:14 PM, Thomas Buschhardt wrote: > Hallo now I was able to run it :-) > > Here are my tested configs > OSC - Baud = Status > ----------------------------------- > ECIO6 - 9600 = working > ECIO6 - 14400 = not working > ECIO6 - 38400 = not working > INTIO7 - 9600 = not working (without oszi) > INTIO67 - 9600 = not working (without oszi) > HSPLL - 9600 = not working > HSPLL - 38400 = not working > > Thank you all very much > Thomas > > > 2014-03-17 13:03 GMT+01:00 Peter Jacobs <pe...@me... > <mailto:pe...@me...>>: > > Thomas, > Looking at sections 2.x in the datasheet, it seems to me that the > PLL is not exclusively for crystals and resonators; it available > to the 4 and 8MHz internal oscillator. Figure 2.8 shows it > limited to these options. That figure is (presumably) a > simplified diagram and I don't know enough to be sure what would > happen if you set OSC=HSPLL and drive the OSC1 pin with your > external oscillator. Would you be abusing the silicon? You > wouldn't be able to use RA6 as an IO pin but that might be OK > since you don't show it in use on your diagram. > Peter J. > |
From: Thomas B. <bus...@gm...> - 2014-03-18 19:02:48
|
Hallo, sorry for disturbing - but thats are my further test results: Freq - OSC - Baud = Status ------------------------------- 16 MHz - HSPPL - 9600 = working 16 MHz - HSPPL - 38400 = working 8 MHz - INTIO67 - 9600 = working (without oszi) 32 MHz - INTIO67 - 9600 = working (without oszi and PPLEnable) 32 MHz - INTIO67 - 38400 = working (without oszi and PPLEnable) It seems I test the last weekend everytime with a wrong configuration :-) Thank You all Bye Thomas 2014-03-17 19:24 GMT+01:00 Mikael Nordman <mik...@pp...>: > Hello ! > With the 4 MHz external clock the following should work: > > HSPLL , 9600 , constant clock=d'16000000' > HSPLL , 38400 , constant clock=d'16000000' > > > FlashForth always configures the internal clock to run at 8 MHz. > With the internal oscillator the following should work. > INTIO67 , 9600, constant clock=d'8000000' > > The INTIO67 with PLL requires that the PLL is enabled in software. > There is a define missing in the processor configuration file for that. > > The INTIO67 with PLL requires that you define in > p18f2525-2620-4525-4620.cfg > ;;; Activate 4xPLL from SW for INTOSC modes in FlashForth 5.0 > #define PLL ENABLE ; ENABLE or DISABLE > > and then these should also work > > INTIO67 , 9600 , constant clock=d'32000000' > INTIO67 , 38400 , constant clock=d'32000000' > > BR Mike > > On 03/17/2014 06:14 PM, Thomas Buschhardt wrote: > > Hallo now I was able to run it :-) > > > > Here are my tested configs > > OSC - Baud = Status > > ----------------------------------- > > ECIO6 - 9600 = working > > ECIO6 - 14400 = not working > > ECIO6 - 38400 = not working > > INTIO7 - 9600 = not working (without oszi) > > INTIO67 - 9600 = not working (without oszi) > > HSPLL - 9600 = not working > > HSPLL - 38400 = not working > > > > Thank you all very much > > Thomas > > > > > > 2014-03-17 13:03 GMT+01:00 Peter Jacobs <pe...@me... > > <mailto:pe...@me...>>: > > > > Thomas, > > Looking at sections 2.x in the datasheet, it seems to me that the > > PLL is not exclusively for crystals and resonators; it available > > to the 4 and 8MHz internal oscillator. Figure 2.8 shows it > > limited to these options. That figure is (presumably) a > > simplified diagram and I don't know enough to be sure what would > > happen if you set OSC=HSPLL and drive the OSC1 pin with your > > external oscillator. Would you be abusing the silicon? You > > wouldn't be able to use RA6 as an IO pin but that might be OK > > since you don't show it in use on your diagram. > > Peter J. > > > > > > ------------------------------------------------------------------------------ > Learn Graph Databases - Download FREE O'Reilly Book > "Graph Databases" is the definitive new guide to graph databases and their > applications. Written by three acclaimed leaders in the field, > this first edition is now available. Download your free book today! > http://p.sf.net/sfu/13534_NeoTech > _______________________________________________ > Flashforth-devel mailing list > Fla...@li... > https://lists.sourceforge.net/lists/listinfo/flashforth-devel > -- www.aloedb.org - database for aloes |