hai,
i need to write code for a device which controls the automatic turn on and turn off lightning lamps of a home,which is connected to the serial port of the PC.
can u help me by giving the code for the serial port programming and also the required functions that i should write for the device.
7 2180
hai,
i need to write code for a device which controls the automatic turn on and turn off lightning lamps of a home,which is connected to the serial port of the PC.
can u help me by giving the code for the serial port programming and also the required functions that i should write for the device.
Sounds an interesting project - what is the interface between the serial port and the lights - is it on/off control or vaiable, e.g. relays, opto-isolator, triac, etc.?
what operating system and compiler are you usings as this will effect the serial driver code?
hi,
the interface between the serial port and pc is PLC called as power linc v2 controller developed by smarthome INSTEON network.i will connect the PLC to the serial port of pc,then i need to write some coding on pc the platform is windows.i need to develop the C programming code that should be embedded into the PLC insteon device,on the power line which is connected to plc,on that line only a product of INSTEON called lightning controller is alligned on the same power line.so i need to write code for the lightning device.
i think first i need to write code for serial port programming and then the device functions help me in total coding
the on/off control that kind of actions are taken care by the PLC.
hi,
the interface between the serial port and pc is PLC called as power linc v2 controller developed by smarthome INSTEON network.i will connect the PLC to the serial port of pc,then i need to write some coding on pc the platform is windows.i need to develop the C programming code that should be embedded into the PLC insteon device,on the power line which is connected to plc,on that line only a product of INSTEON called lightning controller is alligned on the same power line.so i need to write code for the lightning device.
i think first i need to write code for serial port programming and then the device functions help me in total coding
the on/off control that kind of actions are taken care by the PLC.
which compiler are you using? e.g. visual C, DEV-C++, borland cbuilder?
borland c compiler
have a look at
http://www.geocities.com/horacespider/Serial_IO/
the code in directory TurboC V3 works with borland Turbo C V3
The code in directory DEV-C compiles under Borland C V5.6 - gives a few warnings but you can probably ignore them - seems to work OK
hai,
can u help me by giving some tips in developing the c code for an embedded device on the serial port of pc,which has internal memory.
setbrightlevel( )
setdimlevel( )
settimer( )/* sets the time for the lamp in a day for which time it should operate on off */
hai,
can u help me by giving some tips in developing the c code for an embedded device on the serial port of pc,which has internal memory.
setbrightlevel( )
setdimlevel( )
settimer( )/* sets the time for the lamp in a day for which time it should operate on off */
I assume you have some protocol to communicate with the embedded microcntroller to set the levels, timers, e.g. could be characters such as T1540 to switch on the timer at 15.40.
you would need to
(1) initialise the RS232 serial port to required baud rate etc, e.g. if you use the code I suggested -
rs_initialise(port ,9600, '8', 'N')
-
(2) send the characters to do required control
you could form string for all the other operations
have you written the microcontroller code yet?
Sign in to post your reply or Sign up for a free account.
Similar topics
by: bigoxygen |
last post by:
Hi.
I'm using a 3 tier FrontController Design for my web application right
now.
The problem is that I'm finding to have to duplicate a lot of code for
similar functions; for example, listing...
|
by: Fritz Bosch |
last post by:
We are in the process of refactoring our GUI-based test application
for radio equipment and are rewriting a significant part in Python.
The new architecture will substantially be based on the...
|
by: SQL Sever News Group |
last post by:
Hi,
I v a problem that i have to secure my asp code. I tried "screnc.exe", it is
very useful but not hard to crack.
Anybody who can give an alternate and better way.
Thanks in Advance
|
by: Michael Strorm |
last post by:
Hi!
I posted a message a while back asking for project suggestions, and decided
to go with the idea of creating an adventure game (although it was never
intended to be a 'proper' game, rather an...
|
by: Andy Fish |
last post by:
Hi,
I have been thinking about the design of a large ASP.NET app and I've read
people have a lot of trouble implementing front controller, especially with
postbacks, so I don't feel comfortable...
|
by: Alan Silver |
last post by:
Hello,
Newbie here, so please forgive what is probably a basic question ...
I see a lot of discussion about "code behind", which if I have
understood correctly, means that the script code goes...
|
by: Griff |
last post by:
Two questions really, the first one "conceptual" and the other more involved
with design:
1 - There are two schools of thought where I work on the role of the
"controller" task.
The first is...
|
by: simon.hibbs |
last post by:
Lets say that I have an application consisting of 3 files. A main.py
file, gui.py and a data.py which handles persistent data storage.
Suppose data.py defines a class 'MyDB' which reads in data...
|
by: knkk |
last post by:
I am trying to include this code in the footer.template files of all blog templates:
<script type="text/javascript">
var gaJsHost = (("https:" == document.location.protocol) ? "https://ssl." :...
|
by: DolphinDB |
last post by:
Tired of spending countless mintues downsampling your data? Look no further!
In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
|
by: ryjfgjl |
last post by:
ExcelToDatabase: batch import excel into database automatically...
|
by: ArrayDB |
last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
|
by: PapaRatzi |
last post by:
Hello,
I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
|
by: CloudSolutions |
last post by:
Introduction:
For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
|
by: Defcon1945 |
last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
|
by: Shællîpôpï 09 |
last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
|
by: af34tf |
last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome former...
| |