Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

12F675F Coding help

Status
Not open for further replies.

crhannah

New Member
Project:

This project will be very similar to the smart home automation line. We will have a tx/microcontroller at the remote end and rx/microcontroller on the other end. The other end being a 110v module (reciever/mc built in) that will allow the user to plug in a lighting fixture to be controlled. We will have 2 unique modules.

Remote:
- will allow the user to select device1 or device2 inorder to turn on/off or dim
- 4 buttons (device 1, device 2 , on, off) and 1 pot to controll brightness level

A couple things i need help with since I'm not a big programmer but have read many sample source codes in the past few weeks trying to figure out how to do this.

I need to be able to clock out a couple different bit packages. When the user selects device 1 from the remote control and a function (ie: on/off, dim+, dim-) the transmitter needs to send an id code along with a function code. The id code is used to determine which device the user wants to talk to and the function code to perfom.

In return i need to figure out how to write the code that will have the reciever end constantly listening for its unique idcode.

questions:
transmitter mc : how do i create an id code upon user entry of buttons?

reciever mc: how do i constantly listen for the id code?
 
I suggest you check my tutorials, both the IR and Wireless ones do what you want - they require VERY little change for the 12F675, as it's the same 14 bit core.
 
Status
Not open for further replies.

New Articles From Microcontroller Tips

Back
Top