Shop OBEX P1 Docs P2 Docs Learn Events
Unable to connect Scribbler to a Microcontroller using Serial — Parallax Forums

Unable to connect Scribbler to a Microcontroller using Serial

imperatorimperator Posts: 3
edited 2012-12-09 17:27 in Robotics
Greetings
This is my first time posting on this forum so please excuse any inconsistencies.
I need help trying to connect Scribbler 2 using serial connection to Freescale MCF52259 microcontroller. http://www.freescale.com/webapp/sps/site/prod_summary.jsp?code=MCF5225X

I have a more software background and I am not familiar with kind of setup needed to allow for serial connection to take place like the mapping of pins from the board to the scribbler. The MCF52259 board has a UART module that I wanted to use.

I tried one setup in which I connected three pins, recieve, transmit and ground but the response from scribbler was just that it reset itself. The three lights would turn on and off in a sequence and then the middle light would turn on and off.
Here is the pin setup for the microcontroller:


Signal

Pin

Signal



No Connection

1

2

No Connection



TXD

3

4

CTS



RXD

5

6

RTS



No Connection

7

8

No Connection



GND

9

10

3.3V





I am following the IPRE guide for the commands to the scribbler. http://wiki.roboteducation.org/Scribbler_Wire_Protocol
The buad rate is 38400.

Thanks for the help.

Comments

  • Mike GreenMike Green Posts: 23,101
    edited 2012-12-09 15:09
    I don't understand how you're trying to connect the two together. The Scribbler 2 has no 10-pin connector like the one you described and the IPRE guide appears to be describing the Scribbler (1). Perhaps you're trying to connect to the Fluke board that gets plugged into either a Scribbler (1) or Scribbler 2. The Fluke documentation is quite clear that the connection to the Scribbler is an RS232 serial port with voltages that are not logic level signals and can destroy your microcontroller. You would need an RS232 to TTL adapter like the MAX232 or MAX3232 depending on what voltages you need for your logic (5V or 3.3V respectively). Parallax and SparkFun both make this sort of adapter for sale and you can make your own as well. Look at the datasheet for the devices or do a web search for them for examples.
  • imperatorimperator Posts: 3
    edited 2012-12-09 15:38
    Thanks for the quick reply.

    The microcontroller board has 10 pins and the table I provided shows the functions of each pin. I was not using any adapter to connect to the scribbler. I just hard wired the pins I thought were needed like the connecting the microcontroller's TXD to the scribbler's pin 3 (shows how little I know about hardware) .

    I used the Scribbler wire protocol guide on the ipre website because I could not find any other documentation for the serial communication.

    Thanks again for the prompt response.
  • imperatorimperator Posts: 3
    edited 2012-12-09 16:44
    I am looking at the MAX3232 breakout. https://www.sparkfun.com/products/11189

    how would I connect the scribbler and the microcontroller to this board? thanks
  • Mike GreenMike Green Posts: 23,101
    edited 2012-12-09 17:27
    Well, Vcc and ground get connected to 3.3V and ground so the MAX3232 has a power source. DB9 pin 3 gets connected to T1OUT, DB9 pin 2 gets connected to R1IN, DB9 pin 5 gets connected to ground. T1IN will need to be connected to your microcontroller's Tx pin and R1OUT will need to be connected to your microcontroller's Rx pin. All the grounds have to be connected together. Unless you really need them, I would leave CTS and RTS unconnected as well as the other DB9 pins.

    Depending on how your microcontroller board was designed, the serial interface may be "toast" at this point. The voltages provided by the DB9 connector are well beyond what your microcontroller's serial port is likely to be designed for. You'll just have to try it with the MAX3232 and see what happens.
Sign In or Register to comment.