Serial to Parallel

This is a discussion on Serial to Parallel within the Tech Board forums, part of the Community Boards category; Hi, I been working on my FYP and came across this problem. I need converting a Serial data into parallel ...

  1. #1
    Registered User ssharish2005's Avatar
    Join Date
    Sep 2005
    Location
    Cambridge, UK
    Posts
    1,682

    Serial to Parallel

    Hi, I been working on my FYP and came across this problem. I need converting a Serial data into parallel which i get from RS232. As we all know that the UART chip is the one which converts the serial - parallel and parallel to serial.

    But this is already built on my target board (Serial Port which is already on the board). But the output from RS232 should be an input to one more board which i am designing. I am trying to keep the other board as simple possible, since i am not electronic expert.

    According to my research on what I have done it looks like, I need one more UART on my user designed board. And to make that UART chip to work I need a micro controller as well. Which i think is getting complicated.

    I might me wrong here, please correct me if i am wrong. I need converting this Serial data to parallel. Any simple circuits or any idea on how to convert that to 8-bit parallel data?

    Thank you

    ssharish2005

  2. #2
    and the hat of wrongness Salem's Avatar
    Join Date
    Aug 2001
    Location
    The edge of the known universe
    Posts
    32,484
    The heart of the UART is just a shift register and a clock. If you're prepared to hard-wire the baud rate, and you're only interested in transmitting a few bytes of data to your 2nd target board, then something simple might be do-able.

    > And to make that UART chip to work I need a micro controller as well. Which i think is getting complicated.
    True, but once you've got it, it might make a whole lot of other things a lot simpler.
    Are there any other outstanding design issues apart from the UART problem?
    If you dance barefoot on the broken glass of undefined behaviour, you've got to expect the occasional cut.
    If at first you don't succeed, try writing your phone number on the exam paper.
    I support http://www.ukip.org/ as the first necessary step to a free Europe.

  3. #3
    Kernel hacker
    Join Date
    Jul 2007
    Location
    Farncombe, Surrey, England
    Posts
    15,677
    Could you describe a little bit more about what you want to happe - I agree with Salem that using a uart isn't particularly difficult - most uarts require about 15 lines of C to set up and read/write if you don't want lots of other features.

    --
    Mats
    Compilers can produce warnings - make the compiler programmers happy: Use them!
    Please don't PM me for help - and no, I don't do help over instant messengers.

  4. #4
    Registered User ssharish2005's Avatar
    Join Date
    Sep 2005
    Location
    Cambridge, UK
    Posts
    1,682
    Quote Originally Posted by Salem View Post
    The heart of the UART is just a shift register and a clock. If you're prepared to hard-wire the baud rate, and you're only interested in transmitting a few bytes of data to your 2nd target board, then something simple might be do-able.
    Yes, this is what i am expecting. Since i do not have a parallel port on my 1st target board i am suppose to send data through serial port to the 2nd port, where that second board needs a parallel data. The parallel data is then i.e the 8 bits is then used as an input to the demux chip either 4-16 or 8-256 line. And then the output of those demux chip is connected to relay which can then put-on or put-off the source.

    In this case you can see that i just needs that serial data to be converted to parallel. Once that is converted, I can send them to the Demux chip, since demux cannot accept serial data.

    Quote Originally Posted by matsp
    Could you describe a little bit more about what you want to happe
    What is it basically, is that you send some code sent out those the serial port from the 1st Target board through a serial port (I am sending through serial port just because it donst have any other port expect network port). But 2nd Target board needs data in parallel. But now, I am sending data in serial which need to be converted, the only way which i came across is through RS232-UART. As mentioned earlier it needs a micro controller to make that UART chip to work. But i dunno how to go along with these microcontroller, i mean building a board with the micro controllers .

    And one more question, does micro controller has their memory with the chip or is it an external. I can understand that micro controller consist of everything in one single chip, but i dunno about the memory.

    Or if it is within the memory, is there any option of increasing that memory as an extension.

    Any way, any idea on Serial to parallel conversion?

    Thanks a lot guys

    ssharish2005

  5. #5
    Kernel hacker
    Join Date
    Jul 2007
    Location
    Farncombe, Surrey, England
    Posts
    15,677
    Quote Originally Posted by ssharish2005 View Post
    Yes, this is what i am expecting. Since i do not have a parallel port on my 1st target board i am suppose to send data through serial port to the 2nd port, where that second board needs a parallel data. The parallel data is then i.e the 8 bits is then used as an input to the demux chip either 4-16 or 8-256 line. And then the output of those demux chip is connected to relay which can then put-on or put-off the source.

    In this case you can see that i just needs that serial data to be converted to parallel. Once that is converted, I can send them to the Demux chip, since demux cannot accept serial data.


    What is it basically, is that you send some code sent out those the serial port from the 1st Target board through a serial port (I am sending through serial port just because it donst have any other port expect network port). But 2nd Target board needs data in parallel. But now, I am sending data in serial which need to be converted, the only way which i came across is through RS232-UART. As mentioned earlier it needs a micro controller to make that UART chip to work. But i dunno how to go along with these microcontroller, i mean building a board with the micro controllers .

    And one more question, does micro controller has their memory with the chip or is it an external. I can understand that micro controller consist of everything in one single chip, but i dunno about the memory.

    Or if it is within the memory, is there any option of increasing that memory as an extension.
    Both of the above questions are "Yes, maybe". Any microcontroller needs some memory. Some models have memory built in, others have memory externally. Some can have extra memory added externally when there's only internal memory (perhaps with the disabling of internal memory).

    Any way, any idea on Serial to parallel conversion?

    Thanks a lot guys

    ssharish2005
    Can't you just connect your hardware to a parallel IO interface of the microcontroller.

    What microcontroller is it?

    --
    Mats
    Compilers can produce warnings - make the compiler programmers happy: Use them!
    Please don't PM me for help - and no, I don't do help over instant messengers.

  6. #6
    Registered User ssharish2005's Avatar
    Join Date
    Sep 2005
    Location
    Cambridge, UK
    Posts
    1,682
    Can't you just connect your hardware to a parallel IO interface of the microcontroller.

    What microcontroller is it?
    The microcontroller dosn't have a parallel port thats the problem. It just has an serial. But any way I can send data out through serial from my 1st Target board i.e Viper-lite. But my 2nd board should convert that serial data into parallel, thats what i am trying to find lout how.

    It has a PXA255 microcontroller RISC ARM based processor manufactured by Intel.

    ssharish2005

  7. #7
    Registered User Frobozz's Avatar
    Join Date
    Dec 2002
    Posts
    546
    Rather than have a separate UART chip, why not look into a microcontroller that has a built-in UART? I'd recommend the AVR series from Atmel.

    I purchased a chip to experiment with but I have yet to do anything with it at all. I bought the best chip my programmer (TOP2048 from eBay for $160) could handle - the ATMega32. A quick rundown of the features are: 32KB of flash memory for the program, 1KB EEPROM, 2KB SRAM, 8MHz internal oscillator with capability to use an external 16MHz oscillator, 32 IO pins, 8-channel 10-bit ADC, and programmable serial UART.

    More information is available at Atmel's product info page.

  8. #8
    Malum in se abachler's Avatar
    Join Date
    Apr 2007
    Posts
    3,189
    Look into the BASIC stamps, they are simple microcontrollers. They have on chip UART's that can do what you want. Just write the parallel data out oen of the IO buses for your parallel output.
    Until you can build a working general purpose reprogrammable computer out of basic components from radio shack, you are not fit to call yourself a programmer in my presence. This is cwhizard, signing off.

  9. #9
    Registered User Frobozz's Avatar
    Join Date
    Dec 2002
    Posts
    546
    The BASIC stamp might seem like a good deal until you consider that the cheapest module is $29. Compare that to the Atmel ATMega32 which cost me $6.90. That's quite a difference.

    Also I'll point out that the BASIC stamp modules are simply using PIC microcontrollers produced by Microchip. If you zoom in on the simplest BASIC stamp you'll see its using the PIC16C56. The closest I can find for a reasonable price is the PIC16C54 for $2.90.

    Edit: Any limits placed on your FYP?
    Last edited by Frobozz; 09-07-2007 at 06:54 PM.

  10. #10
    Registered User ssharish2005's Avatar
    Join Date
    Sep 2005
    Location
    Cambridge, UK
    Posts
    1,682
    Thanks a lot for such lot information. The UART within the micro controller is a brilliant idea never through abut. It makes the whole lot of job easier.

    Edit: Any limits placed on your FYP?
    Limits? well, financial there no limits, since i am spending for everything. No support from the university what so ever.

    And I have got one more queston; Is there any electronic device or an IC which could automate the variable resister. I mean i need to control the variable Resistance not manually but through sending some signals from the computer?

    And I will have look at those micro controller.

    Thanks a lots guys once again.

    ssharish

  11. #11
    Kernel hacker
    Join Date
    Jul 2007
    Location
    Farncombe, Surrey, England
    Posts
    15,677
    You can certainly BUILD something that is a variable resistor controll - a latch that is "output or open", which has, say, 8 inputs, each input connected to resistor, e.g.
    Code:
    Pin 0 1 ohm
    Pin 1 2 ohm
    Pin 2 4 ohm
    Pin 5 8 ohm
    This particular setup will support 0-15 ohm in 1 ohm steps. If you want 0.5-7.5 ohm in 0.5 ohm steps, 0.5, 1, 2, 4 ohm resistors, etc.

    With more pins, you can do bigger ranges or better precision.

    --
    Mats
    Compilers can produce warnings - make the compiler programmers happy: Use them!
    Please don't PM me for help - and no, I don't do help over instant messengers.

  12. #12
    Registered User Frobozz's Avatar
    Join Date
    Dec 2002
    Posts
    546
    Sounds like you need a digital potentiometer. Mouser has a decent selection of those.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. serial port to poll on request
    By infineonintern in forum C++ Programming
    Replies: 2
    Last Post: 06-11-2009, 06:52 AM
  2. Lame null append cause buffer to crash
    By cmoo in forum C Programming
    Replies: 8
    Last Post: 12-29-2008, 02:27 AM
  3. Music Programming - Serial Matrix Display (Help needed)
    By CrazyHorse in forum C Programming
    Replies: 1
    Last Post: 11-13-2007, 03:28 PM
  4. Please help with serial communication problem - Long
    By spdylude in forum Windows Programming
    Replies: 3
    Last Post: 04-06-2005, 09:41 AM
  5. DOS, Serial, and Touch Screen
    By jon_nc17 in forum A Brief History of Cprogramming.com
    Replies: 0
    Last Post: 01-08-2003, 03:59 PM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21