|
Although RS232C requires both positive and negative voltage levels, neither a microprocessor (with the addition of an external device such as MAX232) nor any other chip will have great difficulty in conforming to the specification.
All USB-to-RS232C cables I've seen (quite a few actually) were OK. If you have to worry, it is about your peripheral, assuming you would venture to design and build one yourself.
The (MAX232) drivers provide RS-232 voltage level outputs (approx. ± 7.5 V) from a single + 5 V supply via on-chip charge pumps and external capacitors. That is what one source of information has on the subject.
End of story. The sequel is on Google.
|
|
|
|
|
Most logic is active low, so logic 1 is 0 volts. I am not saying it is like this for RS232, its been a long time since I touched it and I cant be bothered to google it.
You can easilly see, stick an oscilliscope on the data wires and see what they are reading when its idle.
Morality is indistinguishable from social proscription
|
|
|
|
|
|
Thats why I said I wasnt saying RS232 is like this, but its common of circuits to have active low logic. And he did ask about the logic.
I thought RS 234 was the differential one alowing long cable lengths? Could be wrong though. Its been a while.
Morality is indistinguishable from social proscription
|
|
|
|
|
RS485 is differential, using two signal lines of opposite polarity. RS232 uses one line, but uses +V and -V for logic levels.
Will Rogers never met me.
|
|
|
|
|
|
I want to practise writing win32 ddk drivers.
Need some hardware, cheap and interesting. Any suggestion?
Thanks in advance.
BTW, I had posted many times until it was posted successfully, is it the problem of the forum?
|
|
|
|
|
Try eBay or any of the discount resellers in your locality.
It's time for a new signature.
|
|
|
|
|
|
The explanation in msdn is too brief to me.
FILE_SYNCHRONOUS_IO_ALERT
All operations on the file are performed synchronously. Any wait on behalf of the caller is subject to premature termination from alerts. This flag also causes the I/O system to maintain the file-position pointer. If this flag is set, the SYNCHRONIZE flag must be set in the DesiredAccess parameter.
Any wait? For example, when WaitForSingleObjectEx's bAlertable is FALSE ?
In fact, I'm not clear about the concepts. Does it mean that ZwReadFile/ZwWriteFile (in synchronous mode) will
returned prematurely when there are APC's?
modified on Sunday, August 29, 2010 8:08 PM
|
|
|
|
|
i wrote a small code to test the ADC in atmega16 , the code doesn't contain errors but i tried to simulate the code on proteus and it doesn't work
here is the link for the code and proteus file i used to simulate
http://uploading.com/files/cb852548/adc.rar/
it is very simple but it doesn't work
i wish anybody can help ,
thnx in advance .
|
|
|
|
|
People are unlikely to download and unpack some packed file just to help out. Paste the relevant code (inside PRE tags!) if you think it's useful. Also explain "doesn't work", it is not informative at all.
|
|
|
|
|
thnx very much , it has just worked 
|
|
|
|
|
then you could add the solution so others might benefit.
|
|
|
|
|
i will explain the problem and the solution :
i wrote a code just to take an analog i/p and convert it to digital then send it to portc
and the output could be seen on leds connected to portc
the could is easy and has no errors :
.include "m16def.inc"
.def temp = r16
.org $000
rjmp start
start:
cli
ldi temp,$5f
out spl,temp
ldi temp,$04
out sph,temp
ser temp
out ddrc , temp
clr temp
out ddra , temp
rcall adc_initial
sei
Main_loop:
in temp , adch ;read adc high
out portc , temp
rjmp Main_loop
adc_initial:
sbi acsr , acd
ldi temp , $60 ;single i/p (ADC0)
out admux , temp ; *1 gain - left adjust result
;ref = Vcc
ldi temp , $a6 ;adc enable - auto trigger
out adcsra , temp ;/64 prescaling - no interrupt
ldi temp , $00 ;free running mode - no pull up
out sfior , temp
sbi adcsra , adsc ;start conv
ret
when i simulated the program on proteus it doesn't work at first , because i used to connect the AVR without connecting the Vcc pin and it was working so in all programs with no problems , but in this code you have to connect the Vcc pin 
|
|
|
|
|
|
ammeer_a wrote:
when i simulated the program on proteus it doesn't work at first , because i used to connect the AVR without connecting the Vcc pin and it was working so in all programs with no problems , but in this code you have to connect the Vcc pin
Sounds like a really detailed simulator. I'd think if external power was being applied would be overkill. Out of curiosity what happens in the simulator if you connect VCC to 50VDC or 120VAC instead of the 5(3.3?)VDC the chip being simulated is expecting. Does it error out with "Magic smoke released!"?
3x12=36
2x12=24
1x12=12
0x12=18
|
|
|
|
|
Initially it runs faster, and then it blows up. What did you expect?
|
|
|
|
|
I sh*t you not; I’ve never asked a question neither here nor in MSDN or other programing forums.
Here is my problem – my Alienware suddenly lost the monitor drivers and set them to some basic monitor with no 1920x1200 resolution option. I removed the driver, restarted the thing and it still insists that I have some old CRT monitor instead of 22’’ Dell widescreen. I’m out of ideas how to fix this without a system restore. The OS is Weven and my best guesses what causing this mess are:
0. I’m not using a DVI cable, so this could confuses the OS.
1. MS Security Essentials cleaned a couple of nasty viruses two weeks ago, so they could have left some crap behind.
Any ideas beyond the obvious “format-reinstall” routine?
The narrow specialist in the broad sense of the word is a complete idiot in the narrow sense of the word.
Advertise here – minimum three posts per day are guaranteed.
|
|
|
|
|
Try Microsoft Update to see if it updates your drivers (you will have to choose the custom option so you can select hardware updates).
If that doesn't work, go find the drivers and install them manually.
If that doesn't work, find the drivers for your video card and install them manually too.
Deyan Georgiev wrote: I’m not using a DVI cable
Maybe. Above a certain resolution, VGA looks crappy. Not sure if you are actually prevented from doing so though.
Deyan Georgiev wrote: My first question in programing forum
The Lounge is not a programming forum. Lucky for you, your question is not a programming question either.
|
|
|
|
|
aspdotnetdev wrote: Try Microsoft Update to see if it updates your drivers (you will have to choose the custom option so you can select hardware updates).
Already tried to update VGA and Monitor drivers from the device manager – regarding Windows there are no new versions.
aspdotnetdev wrote: If that doesn't work, find the drivers for your video card and install them manually too.
This sound reasonable, I’m gonna try it today after work, thanks.
aspdotnetdev wrote: Maybe. Above a certain resolution, VGA looks crappy. Not sure if you are actually prevented from doing so though.
It used to work for me, at least until now.
aspdotnetdev wrote: The Lounge is not a programming forum.
Really?! I need to remove it from my CV then!
The narrow specialist in the broad sense of the word is a complete idiot in the narrow sense of the word.
Advertise here – minimum three posts per day are guaranteed.
|
|
|
|
|
Deyan Georgiev wrote: Really?! I need to remove it from my CV then!
Yes please, and while you are at it you might want to give back your degree certificate to the university
|
|
|
|
|
I would try, but they won’t let me to step back in the uni. I have a 10 kilometers restriction order from the campus.
The narrow specialist in the broad sense of the word is a complete idiot in the narrow sense of the word.
Advertise here – minimum three posts per day are guaranteed.
|
|
|
|
|
Do you have the "Works on my machine[^]" certification?
(Also: do you mind if I move this thread to the Hardware forum?)
cheers,
Chris Maunder
The Code Project | Co-founder
Microsoft C++ MVP
|
|
|
|
|
No and no
The narrow specialist in the broad sense of the word is a complete idiot in the narrow sense of the word.
Advertise here – minimum three posts per day are guaranteed.
|
|
|
|