derrick826
New Member
thanks eric.... i owe you a lot really! i think i will have to do more research and post my problems later on
Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
derrick826 said:thanks eric.... i owe you a lot really! i think i will have to do more research and post my problems later on
derrick826 said:those are the programs (something like GUI) that display on the pc screen using the soundcard. Eric, it seems that the project i'm doing has a bit of limitation which is using either a serial port or a paralel port, my preferably serial port.
the https://www.oscilloscope-lib.com/ is quite useful, i have also downloaded this morning. thanks a bunch
derrick826 said:hi eric,
i'm not allowed to use any external ADC , only the internal ADC of the pic, what i had in mind is that maybe when i'm sampling a high freqeuncy sinewave, i will have to store the converted values into a RAM , once it reached to a max amount in the ram, i will send it to the pc. i have calculated my sampling rate and it is more than can be trasmitted using rs232. I haven't checked about the parallel yet.can this eliminate my problem regarding on to low baudrate to send a high sampling data?
derrick826 said:wow, but for now as a learner i think i will just make a low spec frequency scope first... start from a beginner is much better for now.
derrick826 said:how low can they be? less than 5khertz?
Nigel Goodwin said:On a quick glance it looks like you're not setting the pin as a digital one, by default AN0 is an analogue input - you MUST set it to be a digital input if you want to use it as one.
Nigel Goodwin said:You appear to have a confusing number of incorrect calls and returns, with Ser_Init called from within the receive routine - it should only be called once, in the initialisation section of the program. I suggest you check the structure of my tutorials.
As it stands the program will do nothing but crash as the stack underflows.
derrick826 said:Yeap, had been corrected... i followed the sequence which i think is perfect but still no results displayed on the software UART simulation interface using the PIC simulator IDE program... i wonder why?
list p=pic16f877, f=inhx8m
include <P16F877.INC>
__config _CP_OFF & _PWRTE_ON & _XT_OSC & _WDT_OFF & _BODEN_OFF & _LVP_OFF
ERRORLEVEL -302 ;Suppress bank warning
cblock h'20'
Xmit_Byte ;Equ 0x20 ;holds byte to xmit
Rcv_Byte ; Equ 0x21 ;holds received byte
Bit_Cntr ; Equ 0x22 ;bit counter for RS232
Delay_Count ; Equ 0x23 ;delay loop counter
endc
ORG 0x00
GOTO Main
int ORG 0x04
RETFI
Main CALL SER_INIT ; receive using pin A0
again
CALL Rcv_RS232
goto again
SER_INIT
BSF STATUS, RP0 ;select bank 1
; BCF TRISB, 6 ;set B6 as an output
MOVLW h'06'
MOVWF ADCON1
CLRF TRISB ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; i set as trisb
BSF TRISA,0 ;set A0 as an input ;;;;;;;;;;;;;;; i set as trisA
BCF STATUS, RP0 ;select bank 0
; BSF PORTB, 6 ;set B6 high
RETURN
derrick826 said:i'll try to burn the codes into the pic to test if it works. in your tutorial, it is possible to assign any pins as a RX or a TX pin except for portc,7 and portc,6 ?
Yeap, had been corrected... i followed the sequence which i think is perfect but still no results displayed on the software UART simulation interface using the PIC simulator IDE program... i wonder why?