|
Forum Index : Microcontroller and PC projects : picoMite Bug report: keyboard ignored while SetPin FIN,10
| Author | Message | ||||
| Amnesie Guru Joined: 30/06/2020 Location: GermanyPosts: 719 |
Hello, I am working on a program of transmitting text via audio cable for later encoding / decoding ideas etc. so I connected my signal generator to the picoMite and wrote the following short testprogram: Option Explicit SetPin GP0, FIN,10 '100 makes more sense - just a test... Dim integer freq CLS Do freq = Pin(GP0) 'Display frequency Text 10,10,Str$(freq,0,3),,5,1,RGB(white),RGB(black) 'Signal Gen. set to sweep between 6500 and 12600 because 'it is easier to catch the frequency 'show the corresponding Char from ASCII (eg. Freq of 6500/100= 65 = A) Text 10,80,Chr$(freq/100),,5,1,RGB(white),RGB(black) Loop PROBLEM: When the program runs, it is not possible to interrupt / stop the program by hitting "CTRL+C" while - AND THIS IS IMPROTANT - the frequency (in my case sine) is applied to the picoMite. If the program runs and I turn the frequency generator off, everything is fine and I can exit the program by CTRL+C. The problem is independet from the gate time, even with gate time 1000 the keyboard does not react WHILE fed with the signal. Even when stopped it takes a second or so until I can stop the running program. This leads me to the assumption that in the background there is some kind of buffer which needs to empty and shut down first, so it lets my PS/2 keyboard read it's keys again. Edit: using the latest version of picoVGA (5.070408) Greetings Daniel Edited 2022-04-26 08:00 by Amnesie |
||||
| Mixtel90 Guru Joined: 05/10/2019 Location: United KingdomPosts: 8298 |
The waveform doesn't matter. I think FIN is blocking. If so, this would be expected. Try using PULSEIN, where you have better control and accuracy over the measurement, although you'll have to think period rather than frequency. Mick Zilog Inside! nascom.info for Nascom & Gemini Preliminary MMBasic docs & my PCB designs |
||||
| matherp Guru Joined: 11/12/2012 Location: United KingdomPosts: 10620 |
Will look at it. Please confirm that you can CTRL-C OK from the console using teraterm or similar. Please provide your current OPTION settings as I assume you have changed the count pins in use Edited 2022-04-26 17:06 by matherp |
||||
| Amnesie Guru Joined: 30/06/2020 Location: GermanyPosts: 719 |
Hi Peter! I can confirm that CTRL+C works with Teraterm! Only PS/2 keyboard is ignored (WHILE a frequency / signal is fed in). I can only interrupt via PS/2 Keyboard if the signal is shut down on the freq. generator. My Option List: OPTION SYSTEM I2C GP14,GP15 OPTION COLOURCODE ON OPTION KEYBOARD GR OPTION CPUSPEED (KHz) 252000 OPTION DEFAULT COLOURS WHITE, BLUE OPTION SDCARD GP13, GP10, GP11, GP12 OPTION AUDIO GP6, GP7, ON PWM CHANNEL 3 OPTION COUNT GP0, GP1, GP1, GP3 Thank you! Greetings Daniel Edited 2022-04-26 19:48 by Amnesie |
||||
| matherp Guru Joined: 11/12/2012 Location: United KingdomPosts: 10620 |
Please try the attached PicoMiteVGA.zip |
||||
| Amnesie Guru Joined: 30/06/2020 Location: GermanyPosts: 719 |
What can I say? Just perfect. Problem solved, case closed :) Great work and many thanks! |
||||
| The Back Shed's forum code is written, and hosted, in Australia. | © JAQ Software 2025 |