2

I need some information about interfacing Bluetooth module to HSC12 board.

I'm making a project with microcontroller (HSC12 freescale) and I want to interface it with Bluetooth device (bc417) .

I am planning to use SCI0 port which has RXD on pin PS0 and TXD on pin PS1. Now can I use SCI port with Bluetooth module or do I need to use SPI port ? Does the SCI port only support RS-232 interface?

As you can see I am a little confused as to the steps required to interface the Bluetooth module correctly.

If someone can break the steps down for me, it would help a lot. Just remember my goal is to be able to receive/transmit data from a smart phone via Bluetooth. Please any help would be appreciated. If there is anything missing let me know and I will add it.

Thank a lot in advance!

Ammar
  • 1,203
  • 5
  • 27
  • 64
  • Your HCS12 probably supports both Asynchronous Serial (logic-level RS232) and SPI, but you will have to consult its data sheet to determine which ports support which. From memory, SCI would be an asynchronous port, but on some embedded processors (not sure if this one) the engine implementing it may be able to operate in a synchronous serial (SPI-style) mode as well. I strongly suspect the HCS12 devices have a hardware SPI on another port. – Chris Stratton Dec 06 '13 at 15:53
  • So if I am able to display something to the terminal using SCI port, can I connect the Bluetooth module to the correct pins of the SCI port and still be able to see those messages from a smart phone using a terminal app? – Ammar Dec 06 '13 at 16:27
  • Eventually to a degree, if you get the port parameters to match your bluetooth module, and send whatever commands are needed to get the module in a serial pass through mode. Arduino folks seem to do that kind of thing regularly, for example. – Chris Stratton Dec 06 '13 at 16:29
  • 1
    `If someone can break the steps down for me, it would help a lot.` This is unfortunately not the right forum for such. Stack Overflow is a question & answer site, where each question is expected to address a specific, programming-related problem. That being said, I have worked with the HCS12 pretty much non-stop since it was released, particularly with various radio and Bluetooth projects, so I should be able to answer most questions, as long as they are specific. – Lundin Dec 10 '13 at 16:29

1 Answers1

2

Does the SCI port only support RS-232 interface?

SCI is Freescale's way of saying UART. The interface is UART and nothing but UART. Add a RS-232 transceiver to a UART port and you get RS-232.

All HCS12 devices have both SCI and SPI. Pick either of them, depending on what the Bluetooth chip supports. SPI is generally to prefer for on-board communication.

Lundin
  • 195,001
  • 40
  • 254
  • 396